[PATCH] D21465: [llc+llvm-mc] Replace the hidden -target-abi option with a -mabi thats visible in --help.

Daniel Sanders via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 17 08:22:05 PDT 2016


> -----Original Message-----
> From: Rafael EspĂ­ndola [mailto:rafael.espindola at gmail.com]
> Sent: 17 June 2016 15:16
> To: reviews+D21465+public+92eb7897bc2cfded at reviews.llvm.org; Daniel
> Sanders
> Cc: llvm-commits; filcab+llvm.phabricator at gmail.com
> Subject: Re: [PATCH] D21465: [llc+llvm-mc] Replace the hidden -target-abi
> option with a -mabi thats visible in --help.
> 
> If it will be in the triple, why do you need the -mabi command line option?

If LLVM's backend tests always used -triple/-mtriple to specify a complete triple then I
wouldn't need it but a lot of tests specify the architecture using -march and take on
aspects of the host triple*. The -mabi option will apply the necessary (OS and
environment dependent) transformation to the triple to achieve the desired ABI.

*I've just realized that D21069 will encounter triples like mips-apple-macosx10.10.0 or
mips-pc-windows-msvc18.0.0 that it can't cope with at the moment. I'll fix this.

> On 17 June 2016 at 07:06, Daniel Sanders via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
> > dsanders created this revision.
> > dsanders added a subscriber: llvm-commits.
> > Herald added subscribers: dsanders, srhines, danalbert, tberghammer,
> aemerson.
> >
> > Although this patch is a cosmetic change, it is important for MIPS since it
> > is a prerequisite of moving the ABI to the environment component of the
> > triple (much like X86's and ARM's GNUX32, GNUEABI, and GNUEABIHF)
> which in
> > turn is important for both enabling IAS by default for the N64 ABI and for
> > distinguishing between the N32 and N64 in order to fix IAS for N32 and
> > prevent inappropriate interlinking in the IRLinker. Follow-up patches will try
> > to modify the triple according to -mabi for targets that prefer this instead of
> > passing it to MCTargetOptions::ABIName.
> >
> > See http://reviews.llvm.org/D20916 (which this patch has been extracted
> > from) for more detail on the wider context of this patch as well as an
> > explanation as to why having the ABI name in MCTargetOptions does not
> work
> > for Mips.
> >
> > The test changes are all switching -target-abi to -mabi.
> >
> > A similar patch will be posted for 'clang -cc1' and 'clang -cc1as' (the
> > latter currently accepts a -target-abi option but ignores it, I'll fix this
> > at the same time).
> >
> > http://reviews.llvm.org/D21465
> >
> > Files:
> >   include/llvm/MC/MCTargetOptionsCommandFlags.h
> >   test/CodeGen/ARM/arm-abi-attr.ll
> >   test/CodeGen/ARM/atomic-64bit.ll
> >   test/CodeGen/ARM/dagcombine-concatvector.ll
> >   test/CodeGen/ARM/emit-big-cst.ll
> >   test/CodeGen/ARM/tail-call.ll
> >   test/CodeGen/Mips/2008-08-01-AsmInline.ll
> >   test/CodeGen/Mips/2009-11-16-CstPoolLoad.ll
> >   test/CodeGen/Mips/abiflags32.ll
> >   test/CodeGen/Mips/atomicCmpSwapPW.ll
> >   test/CodeGen/Mips/blockaddr.ll
> >   test/CodeGen/Mips/cconv/arguments-float.ll
> >   test/CodeGen/Mips/cconv/arguments-fp128.ll
> >   test/CodeGen/Mips/cconv/arguments-hard-float-varargs.ll
> >   test/CodeGen/Mips/cconv/arguments-hard-float.ll
> >   test/CodeGen/Mips/cconv/arguments-hard-fp128.ll
> >   test/CodeGen/Mips/cconv/arguments-small-structures-bigger-than-
> 32bits.ll
> >   test/CodeGen/Mips/cconv/arguments-struct.ll
> >   test/CodeGen/Mips/cconv/arguments-varargs.ll
> >   test/CodeGen/Mips/cconv/arguments.ll
> >   test/CodeGen/Mips/cconv/callee-saved-float.ll
> >   test/CodeGen/Mips/cconv/callee-saved.ll
> >   test/CodeGen/Mips/cconv/memory-layout.ll
> >   test/CodeGen/Mips/cconv/reserved-space.ll
> >   test/CodeGen/Mips/cconv/return-float.ll
> >   test/CodeGen/Mips/cconv/return-hard-float.ll
> >   test/CodeGen/Mips/cconv/return-hard-fp128.ll
> >   test/CodeGen/Mips/cconv/return-hard-struct-f128.ll
> >   test/CodeGen/Mips/cconv/return-struct.ll
> >   test/CodeGen/Mips/cconv/return.ll
> >   test/CodeGen/Mips/cconv/roundl-call.ll
> >   test/CodeGen/Mips/cconv/stack-alignment.ll
> >   test/CodeGen/Mips/dynamic-stack-realignment.ll
> >   test/CodeGen/Mips/ehframe-indirect.ll
> >   test/CodeGen/Mips/fcopysign-f32-f64.ll
> >   test/CodeGen/Mips/fcopysign.ll
> >   test/CodeGen/Mips/fmadd1.ll
> >   test/CodeGen/Mips/fp-indexed-ls.ll
> >   test/CodeGen/Mips/fpxx.ll
> >   test/CodeGen/Mips/global-address.ll
> >   test/CodeGen/Mips/inlineasm-cnstrnt-reg64.ll
> >   test/CodeGen/Mips/inlineasm64.ll
> >   test/CodeGen/Mips/largeimmprinting.ll
> >   test/CodeGen/Mips/load-store-left-right.ll
> >   test/CodeGen/Mips/longbranch.ll
> >   test/CodeGen/Mips/mips64-sret.ll
> >   test/CodeGen/Mips/mips64directive.ll
> >   test/CodeGen/Mips/mips64ext.ll
> >   test/CodeGen/Mips/mips64extins.ll
> >   test/CodeGen/Mips/mips64fpimm0.ll
> >   test/CodeGen/Mips/mips64fpldst.ll
> >   test/CodeGen/Mips/mips64intldst.ll
> >   test/CodeGen/Mips/msa/basic_operations.ll
> >   test/CodeGen/Mips/msa/basic_operations_float.ll
> >   test/CodeGen/Mips/named-register-n32.ll
> >   test/CodeGen/Mips/remat-immed-load.ll
> >   test/CodeGen/Mips/start-asm-file.ll
> >   test/CodeGen/PowerPC/ppc64-elf-abi.ll
> >   test/MC/Mips/cpload.s
> >   test/MC/Mips/cprestore-noreorder-noat.s
> >   test/MC/Mips/cprestore-noreorder.s
> >   test/MC/Mips/cprestore-reorder.s
> >   test/MC/Mips/cpsetup.s
> >   test/MC/Mips/do_switch3.s
> >   test/MC/Mips/elf_eflags.s
> >   test/MC/Mips/elf_reginfo.s
> >   test/MC/Mips/expansion-jal-sym-pic.s
> >   test/MC/Mips/macro-la-bad.s
> >   test/MC/Mips/macro-la.s
> >   test/MC/Mips/macro-li-bad.s
> >   test/MC/Mips/mips-expansions-bad.s
> >   test/MC/Mips/mips-reginfo-fp64.s
> >   test/MC/Mips/mips64-register-names-n32-n64.s
> >   test/MC/Mips/mips64-register-names-o32.s
> >   test/MC/Mips/mips64extins.s
> >   test/MC/Mips/nabi-regs.s
> >   test/MC/Mips/nooddspreg-cmdarg.s
> >   test/MC/Mips/nooddspreg.s
> >   test/MC/Mips/oddspreg.s
> >   test/MC/Mips/reloc-directive-bad.s
> >   test/MC/Mips/reloc-directive-negative.s
> >   test/MC/Mips/reloc-directive.s
> >   tools/llc/llc.cpp
> >   tools/llvm-mc/llvm-mc.cpp
> >
> >
> > _______________________________________________
> > llvm-commits mailing list
> > llvm-commits at lists.llvm.org
> > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
> >


More information about the llvm-commits mailing list