[cfe-dev] clang/Darwin/x86-64 status on the LLVM test & gcc "compat" test suites

Jean-Daniel Dupas devlists at shadowlab.org
Wed Feb 11 11:45:33 PST 2009


Le 11 févr. 09 à 19:25, Fariborz Jahanian a écrit :

>
> On Feb 11, 2009, at 10:00 AM, Jean-Daniel Dupas wrote:
>
>>
>> Le 11 févr. 09 à 18:12, Anders Carlsson a écrit :
>>
>>>
>>> 11 feb 2009 kl. 09.02 skrev Fariborz Jahanian:
>>>
>>>> They are the same, except for the 64bit-ness of types. Here it is:
>>>>
>>>> struct __builtin_CFString {
>>>>       const int *isa;          (will point at
>>>> __CFConstantStringClassReference)
>>>>       int flags;
>>>>       const char *str;
>>>>       long length;
>>>>     };
>>>>
>>>> - Fariborz
>>>
>>> I did some testing of constant CFString/NSString layout in 64-bit  
>>> and
>>> could not find any issues.
>>>
>>> Anders
>>
>> OK, Look like auto padding from the compiler give the good struct,  
>> but the CF declaration is not the same for 32 and 64 bits:
>>
>> typedef struct __CFRuntimeBase {
>>     uintptr_t _cfisa;
>>     uint8_t _cfinfo[4];
>> #if __LP64__
>>     uint32_t _rc;
>> #endif
>> } CFRuntimeBase;
>
> Where do you get this declaration? I don;t see it in clang, /usr/ 
> include, (or gcc) source tree?
>
> - fariborz

CF sources in the Darwin sources.

http://www.opensource.apple.com/darwinsource/10.5.6/CF-476.17/CFRuntime.h

But maybe the public sources (and declarations) does not match the  
real shipped CoreFoundation implementation, as CFLite is a slightly  
different version (stripped down version) of the official  
CoreFoundation.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20090211/bfb8c6a3/attachment-0001.html>


More information about the cfe-dev mailing list