search for: datalayout

Displaying 20 results from an estimated 1340 matches for "datalayout".

2015 Jun 24
3
[LLVMdev] DataLayout
Hi all, We have multiple DataLayout object in flight during a compilation: at least the one owned by the Module and the one owned by the TargetMachine. There are two issues: 1) What if they differ? I guess we could assert at the beginning of CodeGen. 2) The DataLayout has internal mutable state (a cache of StructLayout). The latter...
2014 Jan 29
5
[LLVMdev] make DataLayout a mandatory part of Module
The LLVM Module has an optional target triple and target datalayout. Without them, an llvm::DataLayout can't be constructed with meaningful data. The benefit to making them optional is to permit optimization that would work across all possible DataLayouts, then allow us to commit to a particular one at a later point in time, thereby performing more optimization...
2016 May 05
2
MCJIT - missing DataLayout?
Hi everyone, I was happily using MCJIT for over a year until yesterday when I created a function call with an argument of a struct type. That caused a crash in SelectionDAG around DataLayout::getAlignment(). I remember the noise about the DataLayout started being mandatory. But I cannot find precise information. Should I set the DataLayout in every Module created? Where can I get the DataLayout for the host process from? Can a DataLayout instance be shared between modules? - Paweł...
2014 Aug 25
3
[LLVMdev] Module->getDataLayout returns std::string instead of DataLayout
hey, so I'm writing in cpp. the documentation says that TheModule -> getDataLayout should return const DataLayout, but instead it is returning std::string. I require it to return DataLayout, as I generalize my function pass manager to accept the DataLayout constant as an argument, it being the only thing in common amongst both the ExecutionEngine and the Module class. Any poin...
2017 Jul 13
2
RFC: Harvard architectures and default address spaces
...arl Peto <carl.peto at me.com> > Subject: Re: [llvm-dev] RFC: Harvard architectures and default address > spaces > > On 07/13/2017 05:38 AM, Björn Pettersson A via llvm-dev wrote: > > My experience of having the address space for functions (or function > pointers) in the DataLayout i that when the .ll file is parsed we need to parse > the DataLayout before any function declarations. That is needed because we > want to attribute the functions with correct address space (according to > DataLayout) when inserting them in the symbol table. An alternative would > be to...
2017 Jul 13
2
RFC: Harvard architectures and default address spaces
My experience of having the address space for functions (or function pointers) in the DataLayout i that when the .ll file is parsed we need to parse the DataLayout before any function declarations. That is needed because we want to attribute the functions with correct address space (according to DataLayout) when inserting them in the symbol table. An alternative would be to update address spac...
2015 Mar 11
3
[LLVMdev] DataLayout: Module vs Target
...es not embed this target-specific detail into the IR, then you don’t have to specify the string. This will disable some optimizations that require precise layout information, but this also prevents those optimizations from introducing target specificity into the IR.” I understand from this that the DataLayout present in the Module *must* match the DataLayout that the Target will use. There is no runtime check to enforce this at that time. My impression is that I can set the DataLayout on the Module to be big-endian and run the optimizer and the X86 backend. The IR-level passes will use the DataLayout...
2014 Oct 19
14
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
I've just wasted a day chasing my tail because of subtleties introduced to handle the optionality of the DataLayout. I would like to never do this again. =] We now have this attached to the Module with just a flimsy faked-up pass to keep APIs consistent. So, is there any problem with beginning down the path of: 1) Synthesizing a "default" boring DataLayout for all modules that don't specify one....
2018 Aug 13
2
Error: ‘class llvm::PassManager<llvm::Module>’ has no member named ‘add’
Hi, I am begineer to llvm, implementing a main.cpp from https://github.com/davidar/lljvm/blob/master/backend/main.cpp A) : When I am declaring a command: * PassManager PM* * PM.add(new DataLayout td)* It shows error: > *error: missing template arguments before ‘PM’* * PassManager PM;* ^ >*main_test.cpp:48:2: error: ‘PM’ was not declared in this scope* * PM.add(new DataLayout(td));* Keeping in mind the above error, I changed the code as: *PassManager<Module> PM*...
2012 Apr 16
3
[LLVMdev] datalayout optimization question
Hi all, We are developing our own compiler front-end and use LLVM as back-end. We generate .ll files and use opt/llc to generate target specific code. When I generate datalayout information in my .ll file it seems that it enables more optimization from LLVM opt. How can I determine which optimization are driven by datalayout information generation ? In other words, when I don't generate target specific datalayout information, what are the optimizations that are turned...
2015 Jun 22
2
[LLVMdev] How to Obtain a DataLayout Reference Given a Function & F
...ded from /Users/peterfinn/Desktop/build/projects/safecode/../../../llvm_trunk_2/projects/safecode/include/safecode/AllocatorInfo.h:21: In file included from /Users/peterfinn/Desktop/llvm_trunk_2/include/llvm/IR/Module.h:20: In file included from /Users/peterfinn/Desktop/llvm_trunk_2/include/llvm/IR/DataLayout.h:27: In file included from /Users/peterfinn/Desktop/llvm_trunk_2/include/llvm/Pass.h:378: /Users/peterfinn/Desktop/llvm_trunk_2/include/llvm/PassAnalysisSupport.h:201:53: error: no member named 'ID' in 'llvm::DataLayout' return getAnalysisID<AnalysisType>(&AnalysisType:...
2018 Aug 14
2
Error: ‘class llvm::PassManager<llvm::Module>’ has no member named ‘add’
...> llvm-dev at lists.llvm.org> wrote: > >> Hi, I am begineer to llvm, implementing a main.cpp from >> https://github.com/davidar/lljvm/blob/master/backend/main.cpp >> >> A) : When I am declaring a command: >> * PassManager PM* >> * PM.add(new DataLayout td)* >> >> It shows error: >> > >> *error: missing template arguments before ‘PM’* >> * PassManager PM;* >> ^ >> >*main_test.cpp:48:2: error: ‘PM’ was not declared in this scope* >> * PM.add(new DataLayout(td));* >> >&gt...
2014 Oct 19
5
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
...om> > To: "Chandler Carruth" <chandlerc at gmail.com> > Cc: "LLVM Developers Mailing List" <llvmdev at cs.uiuc.edu> > Sent: Sunday, October 19, 2014 3:34:59 PM > Subject: Re: [LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout? > > > > Sent from my iPhone > > > On Oct 19, 2014, at 1:22 AM, Chandler Carruth <chandlerc at gmail.com> > > wrote: > > > > I've just wasted a day chasing my tail because of subtleties > > introduced to handle the optionality of the DataL...
2014 Oct 21
3
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
On Mon, Oct 20, 2014 at 7:51 PM, Chris Lattner <clattner at apple.com> wrote: > Hi Eric, > > Can you elaborate on your goals and what problem you are trying to solve? As Chandler points out, DataLayout is part of module for a reason. Which is an interesting point - it's not really. (This was also going to be part of my talk next week, but since it's been brought up...) So the storage for DataLayout right now is on a per-subtarget basis. I.e. if you don't construct one in the module...
2015 Feb 09
2
[LLVMdev] DataLayout missing in isDereferenceablePointer()
Hi, I've been debugging this issue for many hours, and would like a sanity check. The issue is that DL (DataLayout) is nullptr inside isDereferenceablePointer() no matter what I try. Why is DataLayout ever nullptr (shouldn't it get defaults?), and what should I do to make it non-nullptr? Thanks. Ram
2014 Jan 30
4
[LLVMdev] make DataLayout a mandatory part of Module
...ithout a data layout, use the host machine as you suggest. > That’s consistent with what already happens with llc, so extending that to > opt and other such tools seems reasonable to me. > This is also what many clang tests do, where TUs get parsed using the host triple. If we keep target datalayout out of the test files and fill it in with the host's information, then our test coverage expands as our buildbot diversity grows, which is a neat property. Nick On Jan 29, 2014, at 3:40 PM, Nick Lewycky <nlewycky at google.com> wrote: > > > The LLVM Module has an optional targe...
2012 Apr 16
0
[LLVMdev] datalayout optimization question
...ties. Regards, Jim On Apr 16, 2012, at 9:06 AM, Sebastien DELDON-GNB <sebastien.deldon at st.com> wrote: > Hi all, > > We are developing our own compiler front-end and use LLVM as back-end. We generate .ll files and use opt/llc to generate target specific code. When I generate datalayout information in my .ll file it seems that it enables more optimization from LLVM opt. How can I determine which optimization are driven by datalayout information generation ? > In other words, when I don’t generate target specific datalayout information, what are the optimizations that are turned...
2014 Oct 20
2
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
...Oct 20, 2014 at 9:51 AM, Chris Lattner <clattner at apple.com> wrote: > > On Oct 19, 2014, at 1:22 AM, Chandler Carruth <chandlerc at gmail.com> wrote: > > > I've just wasted a day chasing my tail because of subtleties introduced > to handle the optionality of the DataLayout. I would like to never do this > again. =] > > > > We now have this attached to the Module with just a flimsy faked-up pass > to keep APIs consistent. So, is there any problem with beginning down the > path of: > > > > 1) Synthesizing a "default" boring Da...
2014 Oct 21
2
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
...Eric Christopher <echristo at gmail.com> wrote: > >> On Mon, Oct 20, 2014 at 7:51 PM, Chris Lattner <clattner at apple.com> wrote: >>> Hi Eric, >>> >>> Can you elaborate on your goals and what problem you are trying to solve? As Chandler points out, DataLayout is part of module for a reason. >> >> Which is an interesting point - it's not really. (This was also going >> to be part of my talk next week, but since it's been brought up...) >> >> So the storage for DataLayout right now is on a per-subtarget basis. >&gt...
2014 Oct 21
2
[LLVMdev] RFC: Are we ready to completely move away from the optionality of a DataLayout?
...er <echristo at gmail.com> wrote: > > > On Mon, Oct 20, 2014 at 7:51 PM, Chris Lattner <clattner at apple.com> > wrote: > >> Hi Eric, > >> > >> Can you elaborate on your goals and what problem you are trying to > solve? As Chandler points out, DataLayout is part of module for a reason. > > > > Which is an interesting point - it's not really. (This was also going > > to be part of my talk next week, but since it's been brought up...) > > > > So the storage for DataLayout right now is on a per-subtarget basis. &g...