]>
Commit | Line | Data |
---|---|---|
f753fa7d L |
1 | # This file is generated from configure.ac by Autoconf. DO NOT EDIT! |
2 | # Local configure fragment for sysdeps/x86. | |
3 | ||
ecce11aa | 4 | # Check if linker supports x86 ISA level. |
c6cb8783 SP |
5 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linker x86 ISA level support" >&5 |
6 | printf %s "checking for linker x86 ISA level support... " >&6; } | |
7 | if test ${libc_cv_include_x86_isa_level+y} | |
8 | then : | |
9 | printf %s "(cached) " >&6 | |
10 | else $as_nop | |
ecce11aa L |
11 | cat > conftest1.S <<EOF |
12 | #ifdef __LP64__ | |
13 | # define P2ALIGN 3 | |
14 | #else | |
15 | # define P2ALIGN 2 | |
16 | #endif | |
17 | .section ".note.gnu.property", "a" | |
18 | .p2align P2ALIGN | |
19 | .long 1f - 0f /* name length. */ | |
20 | .long 4f - 1f /* data length. */ | |
21 | /* NT_GNU_PROPERTY_TYPE_0 */ | |
22 | .long 5 /* note type. */ | |
23 | 0: | |
24 | .asciz "GNU" /* vendor name. */ | |
25 | 1: | |
26 | .p2align P2ALIGN | |
27 | /* GNU_PROPERTY_X86_ISA_1_NEEDED */ | |
28 | .long 0xc0008002 /* pr_type. */ | |
29 | .long 3f - 2f /* pr_datasz. */ | |
30 | 2: | |
31 | .long 0x1 | |
32 | 3: | |
33 | .p2align P2ALIGN | |
34 | 4: | |
35 | EOF | |
36 | cat > conftest2.S <<EOF | |
37 | #ifdef __LP64__ | |
38 | # define P2ALIGN 3 | |
39 | #else | |
40 | # define P2ALIGN 2 | |
41 | #endif | |
42 | .section ".note.gnu.property", "a" | |
43 | .p2align P2ALIGN | |
44 | .long 1f - 0f /* name length. */ | |
45 | .long 4f - 1f /* data length. */ | |
46 | /* NT_GNU_PROPERTY_TYPE_0 */ | |
47 | .long 5 /* note type. */ | |
48 | 0: | |
49 | .asciz "GNU" /* vendor name. */ | |
50 | 1: | |
51 | .p2align P2ALIGN | |
52 | /* GNU_PROPERTY_X86_ISA_1_NEEDED */ | |
53 | .long 0xc0008002 /* pr_type. */ | |
54 | .long 3f - 2f /* pr_datasz. */ | |
55 | 2: | |
56 | .long 0x2 | |
57 | 3: | |
58 | .p2align P2ALIGN | |
59 | 4: | |
60 | EOF | |
61 | libc_cv_include_x86_isa_level=no | |
62 | if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -nostartfiles -nostdlib -r -o conftest conftest1.S conftest2.S' | |
63 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 | |
64 | (eval $ac_try) 2>&5 | |
65 | ac_status=$? | |
c6cb8783 | 66 | printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
ecce11aa L |
67 | test $ac_status = 0; }; }; then |
68 | count=`LC_ALL=C $READELF -n conftest | grep NT_GNU_PROPERTY_TYPE_0 | wc -l` | |
69 | if test "$count" = 1; then | |
70 | libc_cv_include_x86_isa_level=yes | |
0835c0f0 MW |
71 | fi |
72 | fi | |
73 | rm -f conftest* | |
74 | fi | |
c6cb8783 SP |
75 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $libc_cv_include_x86_isa_level" >&5 |
76 | printf "%s\n" "$libc_cv_include_x86_isa_level" >&6; } | |
0835c0f0 | 77 | if test $libc_cv_include_x86_isa_level = yes; then |
c6cb8783 | 78 | printf "%s\n" "#define INCLUDE_X86_ISA_LEVEL 1" >>confdefs.h |
0835c0f0 | 79 | |
c6cb8783 SP |
80 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LAHF/SAHF instruction support" >&5 |
81 | printf %s "checking for LAHF/SAHF instruction support... " >&6; } | |
82 | if test ${libc_cv_have_x86_lahf_sahf+y} | |
83 | then : | |
84 | printf %s "(cached) " >&6 | |
85 | else $as_nop | |
0835c0f0 MW |
86 | libc_cv_have_x86_lahf_sahf=no |
87 | if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -fverbose-asm -S -o - -x c /dev/null' | |
339bf918 L |
88 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
89 | (eval $ac_try) 2>&5 | |
90 | ac_status=$? | |
c6cb8783 | 91 | printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
5732a881 | 92 | test $ac_status = 0; }; } | grep -qE '(-msahf\b|-march=x86-64-v)'; then |
339bf918 L |
93 | libc_cv_have_x86_lahf_sahf=yes |
94 | fi | |
0835c0f0 | 95 | fi |
c6cb8783 SP |
96 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $libc_cv_have_x86_lahf_sahf" >&5 |
97 | printf "%s\n" "$libc_cv_have_x86_lahf_sahf" >&6; } | |
0835c0f0 | 98 | if test $libc_cv_have_x86_lahf_sahf = yes; then |
c6cb8783 | 99 | printf "%s\n" "#define HAVE_X86_LAHF_SAHF 1" >>confdefs.h |
0835c0f0 MW |
100 | |
101 | fi | |
c6cb8783 SP |
102 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MOVBE instruction support" >&5 |
103 | printf %s "checking for MOVBE instruction support... " >&6; } | |
104 | if test ${libc_cv_have_x86_movbe+y} | |
105 | then : | |
106 | printf %s "(cached) " >&6 | |
107 | else $as_nop | |
0835c0f0 MW |
108 | libc_cv_have_x86_movbe=no |
109 | if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -fverbose-asm -S -o - -x c /dev/null' | |
339bf918 L |
110 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
111 | (eval $ac_try) 2>&5 | |
112 | ac_status=$? | |
c6cb8783 | 113 | printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
5732a881 | 114 | test $ac_status = 0; }; } | grep -qE '(-mmovbe\b|-march=x86-64-v([3-9]|[1-9][0-9]))'; then |
339bf918 L |
115 | libc_cv_have_x86_movbe=yes |
116 | fi | |
339bf918 | 117 | fi |
c6cb8783 SP |
118 | { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $libc_cv_have_x86_movbe" >&5 |
119 | printf "%s\n" "$libc_cv_have_x86_movbe" >&6; } | |
0835c0f0 | 120 | if test $libc_cv_have_x86_movbe = yes; then |
c6cb8783 | 121 | printf "%s\n" "#define HAVE_X86_MOVBE 1" >>confdefs.h |
339bf918 | 122 | |
0835c0f0 | 123 | fi |
ecce11aa L |
124 | fi |
125 | config_vars="$config_vars | |
126 | enable-x86-isa-level = $libc_cv_include_x86_isa_level" | |
f9db5433 | 127 | |
c6cb8783 SP |
128 | printf "%s\n" "#define SUPPORT_STATIC_PIE 1" >>confdefs.h |
129 | ||
f9db5433 | 130 |