search for: foo_ptr

Displaying 3 results from an estimated 3 matches for "foo_ptr".

Did you mean: bo_ptr
2015 Mar 24
2
[LLVMdev] IR blocks for calling function pointers
...ion = M.getOrInsertFunction(std::string("foo"), FunctionType::get(IRB.getVoidTy(), ArrayRef<Type*>(FooArgs), false)); IRB.CreateCall(FooFunction, IRB.CreateLoad(LenAlloca)); I want to create a similar call, but to the pointer of foo ("foo_ptr" is defined as "(void) *foo_ptr (int)"). In C code, I would just call "foo_ptr(var)", and it would just work. But, replacing the function name with the name of the function pointer, in the IRBlock does not work: std::vector<Type*> FooArgs; FooArgs.push_back(IRB.g...
2018 Mar 20
1
[RFC] Function pointer alignment
...ate information (i.e., the LSB is set for Thumb functions and cleared for ARM functions). The problem can be illustrated by the following test case: ; RUN: opt -instcombine -S < %s | FileCheck %s target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" ; CHECK-LABEL: @foo_ptr ; CHECK: and define i32 @foo_ptr() { entry: ret i32 and (i32 ptrtoint (void ()* @foo to i32), i32 -4) } define internal void @foo() align 16 { entry: ret void } LLVM eliminates the 'and' instruction because it incorrectly infers that the two least significant bits of the 'ptrto...
2002 Sep 06
3
explict sharing of symbols between packages
Hi everyone, I'm thinking about breaking up a large package I have to avoid loading some of the more specialised parts when it isn't necessary. The package is dependent on shared libraries. The base one will keep all of the core stuff like constructors etc and the specialised parts will need to access these. It is obviously possible to set the "local" flag to false, however