[cfe-commits] Patches for bootstrapping on armv7 linux

Daniel Dunbar daniel at zuster.org
Mon Aug 9 13:30:02 PDT 2010


On Mon, Aug 9, 2010 at 1:05 PM, Rafael Espindola <espindola at google.com> wrote:
>> The current behavior is by design. In my opinion, having Clang behave
>> consistently regardless of host build environment is less surprising.
>
> OK if I change this to use the value of --target? Currently it is
> impossible to build a clang that defaults to armv7.

No, I think what clang is currently doing is right, for some
definition of right.

The particular problem here is that Clang isn't picking the LLVM style
triple, or choosing the CPU based on the host. I agree those are
problems worth solving, but I don't think hardwiring it to something
from the build environment is the right solution.

As a short term solution, have you considered changing
llvm::sys::getHostTriple to just return the LLVM style triple name?

 - Daniel

>
>>> The second patch changes clang to run "as" and "ld" directly. It is
>>> not strictly required, but we have to pass to fpu flag to the
>>> assembler somehow. I think the change to call the assembler directly
>>> can be made complete. The change to use the use linker directly is
>>> harder as different distros have different dynamic linkers for example
>>> and more refactoring is needed. The patch includes an option for
>>> disabling the use of ld and if committing this I would keep it off by
>>> default. I can also just commit the assembler changes.
>>
>> I have no strong opinion about this part. Certainly it is long past
>> the time when we should have a real Linux toolchain definition.
>
> OK. I will first test the assembler part in isolation and commit that.
> Then the ld bits behind an option and then the slow refactoring to
> move this outwards so that it can set in a configuration.
>
>>  - Daniel
>>
>>> Cheers,
>
>
> Cheers,
> --
> Rafael Ávila de Espíndola
>




More information about the cfe-commits mailing list