Details
Diff Detail
Event Timeline
With clang -target mipsel-unknown-linux -mcpu=octeon trival.s -fintegrated-as -c -o blah.o
objdump is giving me:
private flags = 808b0006: [no abi set] [mips64r2] [not32bitmode] [PIC] [CPIC]
The ISA (64r2) and machine type (E_MIPS_MACH_OCTEON) flags seem to be coming out correct, and the EF_MIPS_CPIC / EF_MIPS_PIC are expected.
However GCC / as is giving me:
private flags = 808b0026: [ABI=N32] [mips64r2] [not 32bitmode] [PIC] [CPIC]
The Is the missing ABI information a separate issue?
I'd leave the ABI issue as a separate change or this could easily end up covering a huge amount of work.
It did occur to me that the .MIPS.abiflags data also needs updating when targetting octeon to set the isa_ext field.
Matthew
I've had a quick look at this and I think it's caused by the way the ABI feature bits are tied to the processor. With a mipsel-* triple we end up with half-O32 half-N64 output but it should do the right thing with a mips64el-* triple.
I think we can leave this as a separate change since MIPS64 processors on a mipsel-* triple is known to be buggy at the moment.
It did occur to me that the .MIPS.abiflags data also needs updating when targetting octeon to set the isa_ext field.
Ok, I'll add that to this patch.
Implement the effect on the .MIPS.abiflags option too.
The ISA Extension field values are all mutually exclusive. Corrected the field
name accordingly.