Add missing magic to GLIBC_PROVIDES.
[platform/upstream/glibc.git] / sysdeps / x86_64 / configure
1
2 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
3 # -------------------------------------------------------
4 # Tests whether HEADER exists and can be compiled using the include files in
5 # INCLUDES, setting the cache variable VAR accordingly.
6 ac_fn_c_check_header_compile ()
7 {
8   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
9   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
10 $as_echo_n "checking for $2... " >&6; }
11 if eval \${$3+:} false; then :
12   $as_echo_n "(cached) " >&6
13 else
14   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15 /* end confdefs.h.  */
16 $4
17 #include <$2>
18 _ACEOF
19 if ac_fn_c_try_compile "$LINENO"; then :
20   eval "$3=yes"
21 else
22   eval "$3=no"
23 fi
24 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25 fi
26 eval ac_res=\$$3
27                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
28 $as_echo "$ac_res" >&6; }
29   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
30
31 } # ac_fn_c_check_header_compile
32 # This file is generated from configure.in by Autoconf.  DO NOT EDIT!
33  # Local configure fragment for sysdeps/x86_64.
34
35
36 ac_fn_c_check_header_compile "$LINENO" "cpuid.h" "ac_cv_header_cpuid_h" "/* No default includes.  */
37 "
38 if test "x$ac_cv_header_cpuid_h" = xyes; then :
39
40 else
41   as_fn_error $? "gcc must provide the <cpuid.h> header" "$LINENO" 5
42 fi
43
44
45
46 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSE4 support" >&5
47 $as_echo_n "checking for SSE4 support... " >&6; }
48 if ${libc_cv_cc_sse4+:} false; then :
49   $as_echo_n "(cached) " >&6
50 else
51   if { ac_try='${CC-cc} -msse4 -xc /dev/null -S -o /dev/null'
52   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
53   (eval $ac_try) 2>&5
54   ac_status=$?
55   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56   test $ac_status = 0; }; }; then :
57   libc_cv_cc_sse4=yes
58 else
59   libc_cv_cc_sse4=no
60 fi
61
62 fi
63 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_cc_sse4" >&5
64 $as_echo "$libc_cv_cc_sse4" >&6; }
65 if test $libc_cv_cc_sse4 = yes; then
66   $as_echo "#define HAVE_SSE4_SUPPORT 1" >>confdefs.h
67
68 fi
69
70 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVX support" >&5
71 $as_echo_n "checking for AVX support... " >&6; }
72 if ${libc_cv_cc_avx+:} false; then :
73   $as_echo_n "(cached) " >&6
74 else
75   if { ac_try='${CC-cc} -mavx -xc /dev/null -S -o /dev/null'
76   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
77   (eval $ac_try) 2>&5
78   ac_status=$?
79   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
80   test $ac_status = 0; }; }; then :
81   libc_cv_cc_avx=yes
82 else
83   libc_cv_cc_avx=no
84 fi
85
86 fi
87 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_cc_avx" >&5
88 $as_echo "$libc_cv_cc_avx" >&6; }
89 if test $libc_cv_cc_avx = yes; then
90   $as_echo "#define HAVE_AVX_SUPPORT 1" >>confdefs.h
91
92 fi
93
94 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVX encoding of SSE instructions" >&5
95 $as_echo_n "checking for AVX encoding of SSE instructions... " >&6; }
96 if ${libc_cv_cc_sse2avx+:} false; then :
97   $as_echo_n "(cached) " >&6
98 else
99   if { ac_try='${CC-cc} -msse2avx -xc /dev/null -S -o /dev/null'
100   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
101   (eval $ac_try) 2>&5
102   ac_status=$?
103   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
104   test $ac_status = 0; }; }; then :
105   libc_cv_cc_sse2avx=yes
106 else
107   libc_cv_cc_sse2avx=no
108 fi
109
110 fi
111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_cc_sse2avx" >&5
112 $as_echo "$libc_cv_cc_sse2avx" >&6; }
113 if test $libc_cv_cc_sse2avx = yes; then
114   $as_echo "#define HAVE_SSE2AVX_SUPPORT 1" >>confdefs.h
115
116 fi
117
118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FMA4 support" >&5
119 $as_echo_n "checking for FMA4 support... " >&6; }
120 if ${libc_cv_cc_fma4+:} false; then :
121   $as_echo_n "(cached) " >&6
122 else
123   if { ac_try='${CC-cc} -mfma4 -xc /dev/null -S -o /dev/null'
124   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
125   (eval $ac_try) 2>&5
126   ac_status=$?
127   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
128   test $ac_status = 0; }; }; then :
129   libc_cv_cc_fma4=yes
130 else
131   libc_cv_cc_fma4=no
132 fi
133
134 fi
135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_cc_fma4" >&5
136 $as_echo "$libc_cv_cc_fma4" >&6; }
137 if test $libc_cv_cc_fma4 = yes; then
138   $as_echo "#define HAVE_FMA4_SUPPORT 1" >>confdefs.h
139
140 fi
141
142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -mno-vzeroupper support" >&5
143 $as_echo_n "checking for -mno-vzeroupper support... " >&6; }
144 if ${libc_cv_cc_novzeroupper+:} false; then :
145   $as_echo_n "(cached) " >&6
146 else
147   if { ac_try='${CC-cc} -mno-vzeroupper -xc /dev/null -S -o /dev/null'
148   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
149   (eval $ac_try) 2>&5
150   ac_status=$?
151   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
152   test $ac_status = 0; }; }; then :
153   libc_cv_cc_novzeroupper=yes
154 else
155   libc_cv_cc_novzeroupper=no
156 fi
157
158 fi
159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_cc_novzeroupper" >&5
160 $as_echo "$libc_cv_cc_novzeroupper" >&6; }
161
162 $as_echo "#define PI_STATIC_AND_HIDDEN 1" >>confdefs.h
163
164 # work around problem with autoconf and empty lines at the end of files