Skip to content

Commit

Permalink
Toolchain: Replace the -march=native flag with -mtune=native
Browse files Browse the repository at this point in the history
This ensures inter-machine compatibility by not emitting any processor
specific instructions. This fixes the issue raised by the non AVX-512
supporting GitHub actions runners.
  • Loading branch information
IdanHo authored and awesomekling committed May 21, 2021
1 parent bd1bdbe commit bcfde43
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Toolchain/BuildIt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ SYSTEM_NAME="$(uname -s)"
# We *most definitely* don't need debug symbols in the linker/compiler.
# This cuts the uncompressed size from 1.2 GiB per Toolchain down to about 120 MiB.
# Hence, this might actually cause marginal speedups, although the point is to not waste space as blatantly.
export CFLAGS="-g0 -O2 -march=native"
export CXXFLAGS="-g0 -O2 -march=native"
export CFLAGS="-g0 -O2 -mtune=native"
export CXXFLAGS="-g0 -O2 -mtune=native"

if [ "$SYSTEM_NAME" = "OpenBSD" ]; then
MAKE=gmake
Expand Down

0 comments on commit bcfde43

Please sign in to comment.