[cfe-commits] r62668 - /cfe/trunk/lib/Lex/PTHLexer.cpp

Chris Lattner clattner at apple.com
Wed Jan 21 10:37:14 PST 2009


On Jan 21, 2009, at 10:35 AM, steve naroff wrote:
>> They are intended to be portable.  We want a well-defined file  
>> format,
>> and we want them to be generatable on one system and sent (e.g.) over
>> NFS to another system.  PTH files currently do not encode any
>> architectural details of the host or target into them.  On the mac,
>> one use of this is that you can use one PTH file for both "-arch  
>> i386"
>> and "-arch ppc" builds.
>>
>
> Interesting (I didn't realize the format was designed to be portable).
>
> Is the format designed to be useable across clang releases? Don't  
> imagine this is critical...

If/when we have releases, we can worry about it.  :)  I'd be fine with  
just sticking a version number into the PTH file and ignoring ones  
that we don't understand.

When we eventually support lazy deserialization of ASTs we will lose  
some of these nice properties (e.g. target independence).

-Chris



More information about the cfe-commits mailing list