check for x32 targets
Add configure detection of the new x32 ABI as well as support in asm. Change-Id: Ic66a069599adeb81062090e3f11b71ee1fb97cb8
This commit is contained in:
@@ -989,6 +989,11 @@ process_common_toolchain() {
|
|||||||
x86*)
|
x86*)
|
||||||
bits=32
|
bits=32
|
||||||
enabled x86_64 && bits=64
|
enabled x86_64 && bits=64
|
||||||
|
check_cpp <<EOF && bits=x32
|
||||||
|
#ifndef __ILP32__
|
||||||
|
#error "not x32"
|
||||||
|
#endif
|
||||||
|
EOF
|
||||||
soft_enable runtime_cpu_detect
|
soft_enable runtime_cpu_detect
|
||||||
soft_enable mmx
|
soft_enable mmx
|
||||||
soft_enable sse
|
soft_enable sse
|
||||||
|
@@ -88,6 +88,8 @@
|
|||||||
%define sym(x) x
|
%define sym(x) x
|
||||||
%elifidn __OUTPUT_FORMAT__,elf64
|
%elifidn __OUTPUT_FORMAT__,elf64
|
||||||
%define sym(x) x
|
%define sym(x) x
|
||||||
|
%elifidn __OUTPUT_FORMAT__,elfx32
|
||||||
|
%define sym(x) x
|
||||||
%elifidn __OUTPUT_FORMAT__,x64
|
%elifidn __OUTPUT_FORMAT__,x64
|
||||||
%define sym(x) x
|
%define sym(x) x
|
||||||
%else
|
%else
|
||||||
@@ -110,6 +112,8 @@
|
|||||||
%define PRIVATE :hidden
|
%define PRIVATE :hidden
|
||||||
%elifidn __OUTPUT_FORMAT__,elf64
|
%elifidn __OUTPUT_FORMAT__,elf64
|
||||||
%define PRIVATE :hidden
|
%define PRIVATE :hidden
|
||||||
|
%elifidn __OUTPUT_FORMAT__,elfx32
|
||||||
|
%define PRIVATE :hidden
|
||||||
%elifidn __OUTPUT_FORMAT__,x64
|
%elifidn __OUTPUT_FORMAT__,x64
|
||||||
%define PRIVATE
|
%define PRIVATE
|
||||||
%else
|
%else
|
||||||
@@ -223,6 +227,9 @@
|
|||||||
%ifidn __OUTPUT_FORMAT__,elf64
|
%ifidn __OUTPUT_FORMAT__,elf64
|
||||||
%define WRT_PLT wrt ..plt
|
%define WRT_PLT wrt ..plt
|
||||||
%define HIDDEN_DATA(x) x:data hidden
|
%define HIDDEN_DATA(x) x:data hidden
|
||||||
|
%elifidn __OUTPUT_FORMAT__,elfx32
|
||||||
|
%define WRT_PLT wrt ..plt
|
||||||
|
%define HIDDEN_DATA(x) x:data hidden
|
||||||
%else
|
%else
|
||||||
%define HIDDEN_DATA(x) x
|
%define HIDDEN_DATA(x) x
|
||||||
%endif
|
%endif
|
||||||
@@ -364,5 +371,8 @@ section .text
|
|||||||
%elifidn __OUTPUT_FORMAT__,elf64
|
%elifidn __OUTPUT_FORMAT__,elf64
|
||||||
section .note.GNU-stack noalloc noexec nowrite progbits
|
section .note.GNU-stack noalloc noexec nowrite progbits
|
||||||
section .text
|
section .text
|
||||||
|
%elifidn __OUTPUT_FORMAT__,elfx32
|
||||||
|
section .note.GNU-stack noalloc noexec nowrite progbits
|
||||||
|
section .text
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user