This is an archive of the discontinued LLVM Phabricator instance.

[mips] Correct the invocation of GAS in several cases.
ClosedPublic

Authored by dsanders on Jul 15 2014, 3:26 AM.

Details

Summary

As a result of this patch, assembling an empty file with GCC and Clang now
produces identical objects.

-mfp32/-mfpxx/-mfp64 now form a trinity of options. -mfpxx is the default
when the triple vendor is 'img' or 'mti', the ABI is O32, and the CPU is
between mips2 and mips32r2/mips64r2 (inclusive).

-mno-shared is always given to the assembler to match the effect of
-mabicalls (currently unimplemented but Clang acts as if it is given).
Similarly, -call_nonpic is always given to match the effect of -mplt (also
unimplemented and acts as if given) except when the ABI is 64 in which case
-mplt has no effect so -KPIC is given instead.

-mhard-float/-msoft-float are now passed on.

-modd-spreg/-mno-odd-spreg are now passed on.

-mno-mips16 is correctly passed on. The assembler option is -no-mips16 not
-mno-mips16

Diff Detail

Event Timeline

dsanders updated this revision to Diff 11431.Jul 15 2014, 3:26 AM
dsanders retitled this revision from to [mips] Correct the invocation of GAS in several cases..
dsanders updated this object.
dsanders edited the test plan for this revision. (Show Details)
dsanders added a reviewer: atanasyan.
atanasyan accepted this revision.Jul 15 2014, 6:20 AM
atanasyan edited edge metadata.

LGTM

This revision is now accepted and ready to land.Jul 15 2014, 6:20 AM
dsanders closed this revision.Jul 16 2014, 5:01 AM
dsanders updated this revision to Diff 11496.

Closed by commit rL213138 (authored by @dsanders).