https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113652
Kewen Lin <linkw at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[14 regression] Failed |Failed bootstrap on ppc
|bootstrap on ppc |unrecognized opcode:
|unrecognized opcode: |`lfiwzx' with -mcpu=7450
|`lfiwzx' with -mcpu=7450 |
--- Comment #9 from Kewen Lin <linkw at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #8)
> So t-float128 has this line:
> # Build the emulator without ISA 3.0 hardware support.
> FP128_CFLAGS_SW = -Wno-type-limits -mvsx -mfloat128 \
> ...
>
> Which gets added to some of the libgcc object files while compiling:
> $(fp128_softfp_obj) : INTERNAL_CFLAGS += $(FP128_CFLAGS_SW)
> $(fp128_ppc_obj) : INTERNAL_CFLAGS += $(FP128_CFLAGS_SW)
>
>
> The problem is CFLAGS gets added also. It seems like passing -mvsx enables
> some other instructions in GCC's code generation BUT does not enable it for
> the assembler ...
ah, just noticed that it's bootstrapping gcc. Stripping regression tag since I
don't think it's actually a regression as comments above.
I found that the libgcc_cv_powerpc_float128 checking can pass with -mcpu=7450
-mabi=altivec -mvsx -mfloat128, the assembler options are "-a32 -mppc -mvsx
-maltivec -mbig" is actually the same as what are used for the case #c5
compiling. So it looks that -mvsx is supposed to tell assembler to recognize
vsx instructions but somehow "lfiwzx" is not counted as vsx instruction.
More specifically "xvadddp" is recognized by assembler with -mvsx while
"lfiwzx" isn't.
$ cat t1.s
.machine "7450"
lfiwzx 1,0,9
$ cat t2.s
.machine "7450"
xvadddp 34,34,35
$ as -a32 -mppc -mvsx t1.s -o t1.o
t1.s: Assembler messages:
t1.s:2: Error: unrecognized opcode: `lfiwzx'
$ as -a32 -mppc -mvsx t2.s -o t2.o
$ echo $?
$ 0