Apple M1: disable -march=native (#2759)

This commit is contained in:
Ștefan Talpalaru 2021-08-04 15:22:23 +02:00 committed by GitHub
parent 30cd8c79d8
commit c4bf4f8fff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -46,7 +46,9 @@ if defined(windows):
# and larger arithmetic use cases, along with register starvation issues. When
# engineering a more portable binary release, this should be tweaked but still
# use at least -msse2 or -msse3.
if defined(disableMarchNative):
#
# Apple's Clang can't handle "-march=native" on M1: https://github.com/status-im/nimbus-eth2/issues/2758
if defined(disableMarchNative) or (defined(macosx) and defined(arm64)):
if defined(i386) or defined(amd64):
switch("passC", "-msse3")
switch("passL", "-msse3")