Displaying 11 results from an estimated 11 matches similar to: "[LLVMdev] differences in IR and ELF?"
2011 Nov 24
1
[LLVMdev] differences in IR and ELF?
I'm trying to create a GlobalVariable that is a ConstantArray. Id like
each element to be a pointer to other things in the program(global
variables, functions). So that they all have the same type Id like to
make the elements void pointers.
I think I am going about this wrong, heres how I am doing it:
void writeArray(Module &M, GlobalVariable *shadow, Function *val,
2011 Nov 15
0
[LLVMdev] constructing global array of pointers?
I'm trying to create a GlobalVariable(that is a ConstantArray) in its
own section. I want each element to be a pointer to a global thats
already in the program(a variable or function). The follow code makes
sense to me and compiles fine, but gives me the wrong output. When I
look at the section in the ELF file it is larger than I expected and
appears to be wrong. The contents of the array do
2011 Oct 20
3
[LLVMdev] common type at compile time?
I'm trying to create a ConstantArray(whose contents will be of types
Function*, GlobalVariable *) so I can immediately create a new
GlobalVariable(that will be in its own section). I'm doing this so I
have these address stored. In order to create this ConstantArray I
need a valid ArrayType, but I'm not sure what to use for the element
type.
I want this to be done at compile time, so I
2011 Oct 20
0
[LLVMdev] common type at compile time?
On 10/20/11 10:43 AM, ret val wrote:
> I'm trying to create a ConstantArray(whose contents will be of types
> Function*, GlobalVariable *) so I can immediately create a new
> GlobalVariable(that will be in its own section). I'm doing this so I
> have these address stored. In order to create this ConstantArray I
> need a valid ArrayType, but I'm not sure what to use for
2011 Oct 20
2
[LLVMdev] common type at compile time?
I'm a bit confused. For the Type did you mean something like:
ArrayType *type = ArrayType::get(Type::getInt8PtrTy(M.getContext()), 4);
This does not work, it gives me ""Wrong type in array element
initializer" at runtime.
Also it doesn't look like ConstantExpr inherits ConstantArray, so I'm
not sure how I could use this instead.
Thanks
On Thu, Oct 20, 2011 at
2011 Oct 20
0
[LLVMdev] common type at compile time?
On 10/20/11 11:34 AM, ret val wrote:
> I'm a bit confused. For the Type did you mean something like:
> ArrayType *type = ArrayType::get(Type::getInt8PtrTy(M.getContext()), 4);
I assume that creates an ArrayType of 4 elements whose elements are
pointers to 8-bit values. If so, then this is what I meant.
> This does not work, it gives me ""Wrong type in array
2014 Mar 11
2
[LLVMdev] [RFC] Section Declarations in LLVM IR
Hi all,
I'd like to propose that LLVM IR have a mechanism to describe sections in a
more explicit way than we can today.
Currently, we provide an attribute called "section" on GlobalVariables and
Functions. This attribute will choose which section the Value will end up
in.
However, it does not describe the attributes of the section.
Without a way of describing the section, we try
2020 Mar 27
2
[lld] RFC: Allow custom sections to be under GNU_RELRO
Peter,
Thanks for the great feedback!
> The first is the use of a custom suffix, all other linker conventions,
that I know of, use prefixes as these are much easier and faster to match
against names.
> This can be important in large programs compiled -ffunction-sections as
there can be millions of sections to match.
I understand the reason of having these conventions in linkers. On the
2014 Aug 05
2
[LLVMdev] Create "appending" section that can be partially dead stripped
On 04 Aug 2014, at 09:27, Reid Kleckner wrote:
> On Sat, Aug 2, 2014 at 7:51 AM, Jonas Maebe
> <jonas.maebe at elis.ugent.be>
> wrote:
>
>> On 01/08/14 19:37, Reid Kleckner wrote:
>>
>>> What happens if you drop appending linkage? I think it will just
>>> work,
>>> since you are already using a custom section, which will ensure
2006 May 30
4
Limiting getElementsByClassName to specific nodes and entities
I''m currently using "The Ultimate getElementsByClassName"
(http://www.robertnyman.com/2005/11/07/the-ultimate-getelementsbyclassname/)
instead of the Prototype version. This version seems to be faster since it
lets you specify the starting node and the type of entity. For example:
var widgets = getElementsByClassName(document, "ol", "tree");
Is
2020 Mar 26
2
[lld] RFC: Allow custom sections to be under GNU_RELRO
Hey,
We would like to propose an idea that would help security harden
applications that define custom sections.
Motivation and Background
In Chromium we have a garbage collector that implements some RTTI machinery
in the form of a table. This table is used by the collector to trace and
finalize garbage collected objects. We're thinking of using
__attribute__((section(...))) so that the table