diff options
Diffstat (limited to 'gcc/config/i386/driver-i386.c')
-rw-r--r-- | gcc/config/i386/driver-i386.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/config/i386/driver-i386.c b/gcc/config/i386/driver-i386.c index c69149d7cb9..1c6c22172d4 100644 --- a/gcc/config/i386/driver-i386.c +++ b/gcc/config/i386/driver-i386.c @@ -413,7 +413,7 @@ const char *host_detect_local_cpu (int argc, const char **argv) unsigned int has_clflushopt = 0, has_xsavec = 0, has_xsaves = 0; unsigned int has_avx512dq = 0, has_avx512bw = 0, has_avx512vl = 0; unsigned int has_avx512vbmi = 0, has_avx512ifma = 0, has_clwb = 0; - unsigned int has_pcommit = 0; + unsigned int has_pcommit = 0, has_mwaitx = 0; bool arch; @@ -532,6 +532,7 @@ const char *host_detect_local_cpu (int argc, const char **argv) has_longmode = edx & bit_LM; has_3dnowp = edx & bit_3DNOWP; has_3dnow = edx & bit_3DNOW; + has_mwaitx = ecx & bit_MWAITX; } /* Get XCR_XFEATURE_ENABLED_MASK register with xgetbv. */ @@ -953,6 +954,7 @@ const char *host_detect_local_cpu (int argc, const char **argv) const char *avx512vbmi = has_avx512vbmi ? " -mavx512vbmi" : " -mno-avx512vbmi"; const char *clwb = has_clwb ? " -mclwb" : " -mno-clwb"; const char *pcommit = has_pcommit ? " -mpcommit" : " -mno-pcommit"; + const char *mwaitx = has_mwaitx ? " -mmwaitx" : " -mno-mwaitx"; options = concat (options, mmx, mmx3dnow, sse, sse2, sse3, ssse3, sse4a, cx16, sahf, movbe, aes, sha, pclmul, @@ -962,7 +964,7 @@ const char *host_detect_local_cpu (int argc, const char **argv) fxsr, xsave, xsaveopt, avx512f, avx512er, avx512cd, avx512pf, prefetchwt1, clflushopt, xsavec, xsaves, avx512dq, avx512bw, avx512vl, - avx512ifma, avx512vbmi, clwb, pcommit, NULL); + avx512ifma, avx512vbmi, clwb, pcommit, mwaitx, NULL); } done: |