Why does the Mac ABI require 16-byte stack alignment for x86-32?

From “IntelĀ®64 and IA-32 Architectures Optimization Reference Manual”, section 4.4.2: “For best performance, the Streaming SIMD Extensions and Streaming SIMD Extensions 2 require their memory operands to be aligned to 16-byte boundaries. Unaligned data can cause significant performance penalties compared to aligned data.” From Appendix D: “It is important to ensure that the stack frame … Read more

How to run the Homebrew installer under Rosetta 2 on M1 Macbook

Got an answer from a developer in the Homebrew github https://github.com/Homebrew/brew/issues/9173 arch -x86_64 /bin/bash -c “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)” Use this to install packages: arch -x86_64 brew install <package> If you have not yet installed Rosetta 2 to emulate Intel CPUs on ARM Macs, you will get the error arch: posix_spawnp: /bin/bash: Bad CPU type in … Read more

editing PATH variable on mac [closed]

Open and edit /etc/paths using any text editor. $ sudo vi /etc/paths (editing text files with vi) Note: each entry is separated by a new line /usr/local/bin /usr/bin /bin /usr/sbin /sbin Save and close the file. Then restart your terminal.

Error: Cannot install in Homebrew on ARM processor in Intel default prefix (/usr/local)

For what it’s worth, before installing Homebrew you will need to install Rosetta2 emulator for the new ARM silicon (M1 chip). I just installed Rosetta2 via terminal using: /usr/sbin/softwareupdate –install-rosetta –agree-to-license This will install rosetta2 with no extra button clicks. After installing Rosetta2 above you can then use the Homebrew cmd and install Homebrew for … Read more