[cfe-dev] preserving type signatures

Renato Golin rengolin at systemcall.org
Wed Mar 24 13:31:13 PDT 2010


On 24 March 2010 18:44, Daniel Dunbar <daniel at zuster.org> wrote:
>> It's completely wrong to convert { float, float } into double.
>
> No it isn't. Clang does this on occasion when it wants to satisfy an
> ABI constraint.

Hi Duncan,

It might make sense for some platforms (such as x86_64) but it doesn't
for all platforms, especially non-64bit ones.

I read the thread with your detailed explanations and I understand now
why it was done and also agree that it's quite ugly. Though, maybe
some metadata (instead of the whole C type system) could be passed
down to the codegen to avoid this.

It's "ok" to assume most people will be using intel with GCC 64 these
days, but IMHO, forcing (all?) other target codegens to work around a
specific x86_64 ABI is just wrong.


>> Just
>> because they have the same size doesn't mean they're identical.
>
> Just because it converts doesn't mean it is assuming they are identical.

Quite right, my mistake.

cheers,
--renato

http://systemcall.org/

Reclaim your digital rights, eliminate DRM, learn more at
http://www.defectivebydesign.org/what_is_drm



More information about the cfe-dev mailing list