2018-04-24 Jakub Jelinek <jakub@redhat.com>
+ PR target/85511
+ * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
+ __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
+ if TARGET_64BIT.
+
PR target/85503
* config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
IX86_BUILTIN_SBB64);
/* Read/write FLAGS. */
- def_builtin (0, "__builtin_ia32_readeflags_u32",
- UNSIGNED_FTYPE_VOID, IX86_BUILTIN_READ_FLAGS);
- def_builtin (OPTION_MASK_ISA_64BIT, "__builtin_ia32_readeflags_u64",
- UINT64_FTYPE_VOID, IX86_BUILTIN_READ_FLAGS);
- def_builtin (0, "__builtin_ia32_writeeflags_u32",
- VOID_FTYPE_UNSIGNED, IX86_BUILTIN_WRITE_FLAGS);
- def_builtin (OPTION_MASK_ISA_64BIT, "__builtin_ia32_writeeflags_u64",
- VOID_FTYPE_UINT64, IX86_BUILTIN_WRITE_FLAGS);
+ if (TARGET_64BIT)
+ {
+ def_builtin (OPTION_MASK_ISA_64BIT, "__builtin_ia32_readeflags_u64",
+ UINT64_FTYPE_VOID, IX86_BUILTIN_READ_FLAGS);
+ def_builtin (OPTION_MASK_ISA_64BIT, "__builtin_ia32_writeeflags_u64",
+ VOID_FTYPE_UINT64, IX86_BUILTIN_WRITE_FLAGS);
+ }
+ else
+ {
+ def_builtin (0, "__builtin_ia32_readeflags_u32",
+ UNSIGNED_FTYPE_VOID, IX86_BUILTIN_READ_FLAGS);
+ def_builtin (0, "__builtin_ia32_writeeflags_u32",
+ VOID_FTYPE_UNSIGNED, IX86_BUILTIN_WRITE_FLAGS);
+ }
/* CLFLUSHOPT. */
def_builtin (OPTION_MASK_ISA_CLFLUSHOPT, "__builtin_ia32_clflushopt",