[cfe-commits] [patch] Make ARM NEON polynomial types unsigned

Bob Wilson bob.wilson at apple.com
Mon Jan 14 16:21:39 PST 2013


On Jan 14, 2013, at 11:22 AM, Tim Northover <t.p.northover at gmail.com> wrote:

>> So you're more willing to change the 32-bit ABI(s) than
>> the 64-bit ABI?  That doesn't make sense to me.
> 
> The way I see it no 32-bit code should be relying on this behaviour
> since it's not specified in any ABI document. The only portable 32-bit
> choice (and the entire point of NEON intrinsics is portability) is to
> take care of the sign yourself and not put scalar polynomials at a
> public interface.
> 
> 64-bit code can rely on unsigned since it's required there; and the
> easiest way to write a compiler satisfying all documentation (as well
> as behaving sanely) is to make polynomials unsigned everywhere.
> 
> In reality, I can't imagine this patch being a real issue for anything
> except the complexity of our codebase. I'd be astonished if there was
> a single library with a public interface exposing a poly8_t or
> poly16_t. Or compiling half its code with GCC and half with Clang.
> 
> But that said, I will of course rewrite to make it AArch64 conditional
> (typing through gritted teeth) if required. Just say the word.

I'm not strongly opposed to it, just wary of ABI-breaking changes.

I'd say that if you can get GCC to make the change, then Clang should do the same.  If GCC continues to use signed polynomial types, then I'm not convinced that Clang should change to unsigned types.



More information about the cfe-commits mailing list