Chandler Carruth
2014-Oct-19 22:11 UTC
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
On Sun, Oct 19, 2014 at 2:32 PM, Sanjoy Das <sanjoy at playingwithpointers.com> wrote:> I have a question: > > > 1) Synthesizing a "default" boring DataLayout for all modules that don't > > specify one. > > What is a default boring value for endianness? >Little. Sorry, but LE won here. I mean, we could make the default big-endian just to test the less common scenario, but I think it would just result in bugs in people's test cases rather than teasing out actual bugs in their code. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20141019/4d0eadf1/attachment.html>
Hal Finkel
2014-Oct-19 22:23 UTC
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
----- Original Message -----> From: "Chandler Carruth" <chandlerc at gmail.com> > To: "Sanjoy Das" <sanjoy at playingwithpointers.com> > Cc: "LLVM Developers Mailing List" <llvmdev at cs.uiuc.edu> > Sent: Sunday, October 19, 2014 5:11:58 PM > Subject: Re: [LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout? > > On Sun, Oct 19, 2014 at 2:32 PM, Sanjoy Das < > sanjoy at playingwithpointers.com > wrote: > > > > I have a question: > > > 1) Synthesizing a "default" boring DataLayout for all modules that > > don't > > specify one. > > What is a default boring value for endianness? > Little. Sorry, but LE won here. > > > I mean, we could make the default big-endian just to test the less > common scenario, but I think it would just result in bugs in > people's test cases rather than teasing out actual bugs in their > code.No ;) -- little endian should be the default. -Hal> _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-- Hal Finkel Assistant Computational Scientist Leadership Computing Facility Argonne National Laboratory
Sanjoy Das
2014-Oct-19 22:48 UTC
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
>> What is a default boring value for endianness? >> Little. Sorry, but LE won here. >> >> >> I mean, we could make the default big-endian just to test the less >> common scenario, but I think it would just result in bugs in >> people's test cases rather than teasing out actual bugs in their >> code. > > No ;) -- little endian should be the default.Makes sense. I was curious because the current DataLayout analysis pass chooses big endian by default, and I've had at least one hard-to-diagnose miscompile because of that. :) -- Sanjoy