Skip to content
This repository has been archived by the owner on Nov 7, 2021. It is now read-only.

Commit

Permalink
ANDROID: HACK: arm64: use -mno-implicit-float instead of -mgeneral-re…
Browse files Browse the repository at this point in the history
…gs-only

LLVM bug 30792 causes clang's AArch64 backend to crash compiling
arch/arm64/crypto/aes-ce-cipher.c.  Replacing -mgeneral-regs-only with
-mno-implicit-float is the suggested workaround.

Drop this patch once the clang bug has been fixed.

Change-Id: I89fda12d826783ffe18142ba048ff10bd769e240
Signed-off-by: Greg Hackmann <[email protected]>
Signed-off-by: Matthias Kaehlcke <[email protected]>
  • Loading branch information
greghackmann committed Oct 16, 2017
1 parent 5d15d2e commit e07bcf7
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion arch/arm64/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,14 @@ $(warning LSE atomics not supported by binutils)
endif
endif

KBUILD_CFLAGS += -mgeneral-regs-only $(lseinstr)
ifeq ($(cc-name),clang)
# This is a workaround for https://bugs.llvm.org/show_bug.cgi?id=30792.
# TODO: revert when this is fixed in LLVM.
KBUILD_CFLAGS += -mno-implicit-float
else
KBUILD_CFLAGS += -mgeneral-regs-only
endif
KBUILD_CFLAGS += $(lseinstr)
KBUILD_CFLAGS += -fno-asynchronous-unwind-tables
KBUILD_CFLAGS += $(call cc-option, -mpc-relative-literal-loads)
KBUILD_CFLAGS += -fno-pic
Expand Down

0 comments on commit e07bcf7

Please sign in to comment.