[llvm-commits] [RFC/PATCH] PPCDoubleDouble compile-time arithmetic
Chris Lattner
clattner at apple.com
Mon Oct 29 21:35:34 PDT 2012
On Oct 29, 2012, at 5:15 AM, Duncan Sands <baldrick at free.fr> wrote:
> Hi Bill,
>
>> I think we should add the possibility of exposing the internals of long
>> double to the lengthy list of PowerPC tasks, but as Hal indicated, it
>> will be a rather large step and not simple; so it would be appropriate
>> to treat this as a longer term effort. Because "long double" is a
>> special entity at the ABI level and has its own rules for parameter
>> passing, structural layout, and so forth, care would have to be taken to
>> ensure the "long-doubleness" remains visible at function call boundaries
>> and when calculating alignment. Within structures, a pair of contiguous
>> doubles has 8-byte alignment, but a long double has 16-byte alignment.
>> I am sure all these issues can be solved with sufficient hackery, I mean
>> design ;), but it requires careful thought and nontrivial effort.
>
> hopefully we are agree that these are all front-end issues (clang) not
> something the LLVM ppc target has to take care of, as the front-end is
> responsible for taking care of ABI conformance, struct layout etc.
Right. This isn't stuff that LLVM IR has to care about right now.
On Oct 28, 2012, at 5:57 PM, Bill Schmidt <wschmidt at linux.vnet.ibm.com> wrote:
> Right now we are working hard just to get the PPC64 ELF backend into ABI
> compliance, and there is much remaining work before that will be
> completed. Having a functional long double implementation will be a big
> step for eventually getting LLVM/Clang to self-host on 64-bit PowerPC
> Linux. After we all have more experience with LLVM/Clang, optimizations
> such as you suggest here will be more feasible for us to implement.
>
> If it's OK with you, I'd like to record this discussion in our list of
> eventual work items, but for now Uli's patch will really be a
> significant milestone for us. I hope that seems reasonable.
Sure, seems like a perfectly reasonable intermediate step.
-Chris
More information about the llvm-commits
mailing list