search for: ifuncs

Displaying 20 results from an estimated 62 matches for "ifuncs".

Did you mean: funcs
2015 Dec 18
2
RFC: __attribute__((ifunc("resolver")) representation in LLVM IR
Hi Everyone, I would like to implement GCC ifunc attribute support in Clang and LLVM. At the moment Clang ignores the attribute with a warning. On LLVM IR level there is no support for ifunc. But there is some support for ELF symbol type `@gnu_indirect_function` in ELF reader/writer/target asm parser. This RFC is looking for thoughts and suggestions about representation of ifunc in LLVM IR.
2015 Dec 21
2
RFC: __attribute__((ifunc("resolver")) representation in LLVM IR
...e could look through it for compiler generated > resolver functions - something to keep in mind for the future. > > On Fri, Dec 18, 2015, 5:47 PM Reid Kleckner via llvm-dev < > llvm-dev at lists.llvm.org> wrote: > >> Are you going to have to teach LLVM how to look through ifuncs, or is it >> OK if they are totally opaque? >> >> For example, with __attribute__((target)), you might have one >> target-specialized function call another. Is it important that we be able >> to optimize away the dynamic dispatch there or not? >> >> Either...
2015 Dec 23
2
RFC: __attribute__((ifunc("resolver")) representation in LLVM IR
...of IRObjectFile. Cheers, Rafael On 22 December 2015 at 08:23, Dmitry Polukhin <dmitry.polukhin at gmail.com> wrote: > I start prototyping second approach that makes ifunc new type of > GlobalValue. And I would like to reconfirm how much we would like to share > between aliases and ifuncs. For example, should Module have separate lists > of aliases and ifuncs or they both should be in the same list of indirect > symbols? If ifuncs and aliases are in separate lists, common base class is > less useful and I found myself duplicating aliases code to support ifunc > (that is...
2015 Dec 19
2
RFC: __attribute__((ifunc("resolver")) representation in LLVM IR
Are you going to have to teach LLVM how to look through ifuncs, or is it OK if they are totally opaque? For example, with __attribute__((target)), you might have one target-specialized function call another. Is it important that we be able to optimize away the dynamic dispatch there or not? Either way, I think a new IR construct is the way to go. On Fri, De...
2018 Aug 21
7
[lld] avoid emitting PLT entries for ifuncs
Hello, We've recently started using ifuncs in the x86(_64) FreeBSD kernel. Currently lld will emit a PLT entry for each ifunc, so ifunc calls are more expensive that those of regular functions. In our kernel, this overhead isn't really necessary: if lld instead emits PC-relative relocations for each ifunc call site, where each relocati...
2020 Aug 10
3
resolve the name of an ifunc resolver function
Hi, I just spent 4 hours trying to find a way to get the name of the resolver function of a ifunc definition ... :-( and with all that time I didnt event get far: for (GlobalIFunc &IF : M.ifuncs()) { StringRef ifunc_name = IF.getName(); Constant *r = IF.getResolver(); But how do I get to the (Function*) or function name of the resolver from there? I tried everything with the Constant which seems to be a ConstantExpr type ... .... Example test program below: #include <stdio.h>...
2009 Jul 04
3
newby question
Hi, I work with bio-conductor, but this is probably a basic R question. I want to emulate the GOBPOFFSPRING$"GO:0008150" command: > allBP <- GOBPOFFSPRING$"GO:0008150" > class(allBP) [1] "character" > length(allBP) [1] 16066 > I want to create a function so that I can execute the command by passing as a parameter the portion in quotes in the above
2018 Aug 23
2
[lld] avoid emitting PLT entries for ifuncs
In the context of support not only IFunc but DTrace, what kind of features do you want to add to lld, if you have a chance to implement it in the linker instead of a post-processing tool? I wonder if we can solve both of your problems. On Thu, Aug 23, 2018 at 1:33 AM Mark Johnston <markj at freebsd.org> wrote: > On Wed, Aug 22, 2018 at 10:11:00AM -0400, Ed Maste wrote: > > On 22
2013 Oct 07
2
[LLVMdev] [lld][failing test] the reason of ifunc.test failing
Hi, It looks like the the ELFPassFile doesnot get an ordinal value assigned, as its added in a pass. Is there a way to assign a file ordinal for the files added by Passes ? Till that time, I am going to XFAIL the ifunc test. More tests should fail, and am not sure why they are not failing. Thanks Shankar Easwaran -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted
2020 Sep 07
3
[IR] Modelling of GlobalIFunc
I was working on https://reviews.llvm.org/D81911 to try and fix https://bugs.llvm.org/show_bug.cgi?id=46340 . Through the review process we happened upon a design limitation or perhaps a potential mis-modelling of GlobalIFunc in the IR object hierarchy, which leads to some problems in LTO flows. To summarize, as it currently stands (and in the hopes of faithfully representing the conclusions of
2013 Oct 07
0
[LLVMdev] [lld][failing test] the reason of ifunc.test failing
In addition I think the LayoutPass std::stable_sort be replaced with std::sort as total ordering is guaranteed as each File would get an ordinal and each atom would get an ordinal too, after the below problem is fixed. Thanks Shankar Easwaran On 10/6/2013 10:54 PM, Shankar Easwaran wrote: > Hi, > > It looks like the the ELFPassFile doesnot get an ordinal value > assigned, as its
2018 Aug 22
2
[lld] avoid emitting PLT entries for ifuncs
On 22 August 2018 at 04:27, Rui Ueyama via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > However, if you pass the -emit-relocs option to the linker, lld keeps all > relocations that have already been resolved in an output executable. By > analyzing a relocation table in a resulting executable, you could find all > locations where the ifunc PLT is called. Then, you can
2013 Oct 07
2
[LLVMdev] [lld][failing test] the reason of ifunc.test failing
Ping ? Do you think that we need to have an API in LinkingContext to return the next ordinal available, so that files created by passes can be assigned ordinals ? Thanks Shankar Easwaran On 10/6/2013 11:07 PM, Shankar Easwaran wrote: > In addition I think the LayoutPass std::stable_sort be replaced with > std::sort as total ordering is guaranteed as each File would get an >
2020 Sep 10
2
[IR] Modelling of GlobalIFunc
> * Calling getBaseObject() on a GlobalIFunc returns its resolver function. I still don't understand how it can happen looking to the code ( https://github.com/llvm/llvm-project/blob/master/llvm/lib/IR/Globals.cpp#L430). I believe it should return nullptr (the same as if you call it from GlobalAlias that refers to GlobalIFunc). I don't have a strong opinion here because deriving
2007 Jul 24
1
Passing equations as arguments
Friends, I'm trying to pass an equation as an argument to a function. The idea is as follows. Let us say i write an independent function Ideal Situation: ifunc <- function(x) { return((x*x)-2) } mainfunc <- function(a,b) { evala <- ifunc(a) evalb <- ifunc(b) if (evala>evalb){return(evala)} else return(evalb) } Now I want to try and write this entire program in a single
2013 Oct 07
0
[LLVMdev] [lld][failing test] the reason of ifunc.test failing
On Mon, Oct 7, 2013 at 11:51 AM, Shankar Easwaran <shankare at codeaurora.org>wrote: > Ping ? > > Do you think that we need to have an API in LinkingContext to return the > next ordinal available, so that files created by passes can be assigned > ordinals ? > That API may work, but I don't think you always want to assign the largest file ordinal for a file created in
2013 Oct 07
1
[LLVMdev] [lld][failing test] the reason of ifunc.test failing
On 10/7/2013 3:43 PM, Rui Ueyama wrote: > On Mon, Oct 7, 2013 at 11:51 AM, Shankar Easwaran > <shankare at codeaurora.org>wrote: > >> Ping ? >> >> Do you think that we need to have an API in LinkingContext to return the >> next ordinal available, so that files created by passes can be assigned >> ordinals ? >> > That API may work, but I
2020 Aug 21
3
[RFC][LLVM] New Constant type for representing function PLT entries
> -----Original Message----- > From: llvm-dev <llvm-dev-bounces at lists.llvm.org> On Behalf Of Fangrui > Song via llvm-dev > Sent: Thursday, August 20, 2020 10:18 PM > To: Leonard Chan <leonardchan at google.com> > Cc: llvm-dev <llvm-dev at lists.llvm.org> > Subject: [EXT] Re: [llvm-dev] [RFC][LLVM] New Constant type for > representing function PLT
2014 May 23
2
[LLVMdev] Changing the design of GlobalAliases to represent what is actually possible in object files.
On Fri, May 23, 2014 at 3:06 PM, Rafael Avila de Espindola <rafael.espindola at gmail.com> wrote: > > > Sent from my iPhone > >> On May 23, 2014, at 17:51, Eric Christopher <echristo at gmail.com> wrote: >> >> I'm not there yet, but at some point I'm going to need the notion of a >> global callable function like symbol that's resolved at
2007 Dec 02
3
creation date and OSX
Hi, I've been using rsync (OSX Tiger now Leopard) to backup my home folder daily using -a -H -A -X link-dest=dir to make incremental backups. There was a problem though since many files especially images, movies etc would be recopied each time instead of creating hard links. I have been testing the pre5 release and found that it seems to make hard links correctly for all files. I