r256468 - On {mips, mipsel, mips64, mips64el}-freebsd, we need to pass any -G option to the assembler.

Daniel Sanders via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 14 12:27:02 PST 2016


-G isn't handled there at the moment but ClangAs::AddMIPSTargetArgs() and Clang::AddMIPSTargetArgs() would be the right place to add it in the Linux toolchain when we add it.

The cleanup I'm referring to is that someone hoisted the bulk of the code out of the big switch-statement in Clang::ConstructJob() and ClangAs::ConstructJob() into Add<Target>TargetArgs() functions. The switch-statement in freebsd::Assembler::ConstructJob() isn't as big as either of those yet but it's already reached a couple screens long. I think freebsd::Assembler::ConstructJob() should take the same approach at some point in the near future.
________________________________________
From: Dimitry Andric [dimitry at andric.com]
Sent: 14 January 2016 19:20
To: Daniel Sanders
Cc: Joerg Sonnenberger; cfe-commits at lists.llvm.org
Subject: Re: r256468 - On {mips, mipsel, mips64, mips64el}-freebsd, we need to pass any -G option to the assembler.

Sorry, but I fail to see where in AddMIPSTargetArgs the -G options are handled?  What is the general idea about the "new style" cleanup?

-Dimitry

> On 14 Jan 2016, at 18:13, Daniel Sanders <Daniel.Sanders at imgtec.com> wrote:
>
> Did you get an answer to this question? I think it's just that the FreeBSD class hasn't refactored to that style yet.
> That switch statement is getting quite large so it would be a nice cleanup to switch to that style.
>
>> -----Original Message-----
>> From: cfe-commits [mailto:cfe-commits-bounces at lists.llvm.org] On Behalf
>> Of Joerg Sonnenberger via cfe-commits
>> Sent: 27 December 2015 11:59
>> To: cfe-commits at lists.llvm.org
>> Subject: Re: r256468 - On {mips, mipsel, mips64, mips64el}-freebsd, we need
>> to pass any -G option to the assembler.
>>
>> On Sun, Dec 27, 2015 at 10:36:44AM -0000, Dimitry Andric via cfe-commits
>> wrote:
>>> Author: dim
>>> Date: Sun Dec 27 04:36:44 2015
>>> New Revision: 256468
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=256468&view=rev
>>> Log:
>>> On {mips,mipsel,mips64,mips64el}-freebsd, we need to pass any -G option
>> to the assembler.
>>
>> Why is this reinventing the wheel and not using AddMIPSTargetArgs?
>>
>> Joerg
>> _______________________________________________
>> cfe-commits mailing list
>> cfe-commits at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits



More information about the cfe-commits mailing list