On Aug 6, 2007, at 3:05 PM, Dale Johannesen wrote:
>
> On Aug 6, 2007, at 2:57 PM, Chris Lattner wrote:
>
>>> Move lengthy conditional down 1 level per review comment.
>>
>> Thanks!
>>
>>>
>>> + std::string getDataLayout() const { return
>>> + is64Bit() ? std::string("e-p:64:64-f64:32:64-i64:32:64-
>>> f80:128:128") :
>>> + isTargetDarwin() ? std::string("e-p:32:32-f64:32:64-i64:32:64-
>>> f80:128:128") :
>>> + std::string("e-p:32:32-f64:32:64-i64:32:64-f80:32:32"); }
>>
>> Can you make this use if/then/else for clarity? :)
>
> I think it is clearer this way, but OK.
The main reason for doing this is that it makes it easy to add these
comments:
// x86-64 uses the same data layout conventions for all subtargets
// darwin-x86-32 has special feature XYZ
// linux, freebsd and others on x86-32 use ABC
-Chris
_______________________________________________
llvm-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits