Displaying 20 results from an estimated 1000 matches similar to: "How to create global symbol from record offset"
2005 Mar 23
2
0.11 problems
I''ve upgraded to 0.11 this morning specifically to test out the
pagination stuff. When that didn''t work (didn''t recognise the command)
I deleted my project and recreated from scratch. So in short
rails projectname
cd projectname
edit config/database.yml (my database is postgres by the way)
ruby scripts/generate model Recordtype
ruby
2010 Feb 01
6
Import fixed-format ascii file with mixed record types
I need to import several ascii files in fixed format with two different record types. The data comes from European Labor Force Surveys, wich is a household survey. The first record type is for people over 16 years, and the second much sorter is for people aged 15 or less (this record has a filler with several blanks to get the same record length).
The files tipically have 160000 records, with 176
2012 Aug 07
3
SMB+LDAP
Hi Folks,
A couple of questions about making SMB (3 or 4) authenticate to an
external (anonymous) LDAP server:
1) A typical LDAP user record is below. Is there anything lacking in
this record that would prevent Samba from authenticating against our
LDAP server? Note the sambaSID is as is, gobblygook info:
dsAttrTypeNative:eduPersonAffiliation: Employee Member
dsAttrTypeNative:givenName: David
2011 May 18
3
[LLVMdev] access array problem
Hi,
I want to access an array in my instrumentation code. For example:
GlobalVariable:
int *counter; //counter the number of load/store operations in run-time
int *counterArray; //record the load/store addresses
//increase the counter if a load/store is performed
std::vector<Constant *>index(2);
index[0] = Constant::getNullvalue(Type:getInt32Ty(Context));
index[1] =
2017 Apr 08
2
How to insert vector type input parameter for function in C/C++ API?
Thank you so much Craig!
I tried it. But still complaining. Here is the error message during
compilation.
HowToUseJIT_SIMD_FuncProto.cpp:94:55: error: expected unqualified-id
VectorType::(Type::getInt32Ty(Context),4),
THIS IS MY CODE:
LLVMContext Context;
std::unique_ptr<Module> Owner = make_unique<Module>("test", Context);
Module *M = Owner.get();
Function
2020 Mar 16
3
GSOC Projects
Hey, I am Swapnil Raj I am student in Trinity College Dublin and I am interested
in working on LLVM. I am really interested in two projects listed, the first
one is the extending the clang AST with template information and the second is
finding smart null pointer dereferences. I am passionate about compilers and
interpreters, I have written a few small language based on lambda calculus. I am
2011 May 18
2
[LLVMdev] access array problem
于 2011/5/18 14:29, Duncan Sands 写道:
> Hi Tan Guangming,
>
>> I want to access an array in my instrumentation code. For example:
>>
>> GlobalVariable:
>> int *counter; //counter the number of load/store operations in run-time
>> int *counterArray; //record the load/store addresses
> strictly speaking these are not arrays, they are pointers. Also, you have
2017 Apr 08
3
How to insert vector type input parameter for function in C/C++ API?
Fantastic! It's working! Thank you so much Craig!!!
On Fri, Apr 7, 2017 at 6:05 PM, Craig Topper <craig.topper at gmail.com> wrote:
> It should be VectorType::get(Type::getInt32Ty(Context),4). You need the
> word "get" after VectorType::
>
> ~Craig
>
> On Fri, Apr 7, 2017 at 6:01 PM, Michael Choi <choimichael103 at gmail.com>
> wrote:
>
2011 May 18
0
[LLVMdev] access array problem
Hi Tan Guangming,
> I want to access an array in my instrumentation code. For example:
>
> GlobalVariable:
> int *counter; //counter the number of load/store operations in run-time
> int *counterArray; //record the load/store addresses
strictly speaking these are not arrays, they are pointers. Also, you have
written them in some kind of C-style idiom. What are the declarations
2011 May 18
0
[LLVMdev] access array problem
Hi Guangming Tan,
>>> GlobalVariable:
>>> int *counter; //counter the number of load/store operations in run-time
>>> int *counterArray; //record the load/store addresses
>> strictly speaking these are not arrays, they are pointers. Also, you have
>> written them in some kind of C-style idiom. What are the declarations in
>> LLVM IR?
> const Type
2012 Nov 02
4
[LLVMdev] Instruction does not dominate all uses! <badref> ??
I'm having trouble figuring out what the error "Instruction does not
dominate all uses!" means. I'm trying to construct a call to a function
with two parameters. The printed IR, with error, looks like this:
define i32 @add(i32, i32) {
EntryBlock:
%2 = add i32 %0, %1
ret i32 %2
}
define i32 @eval_expr() {
EntryBlock:
ret i32 <badref>
}
Instruction does not dominate
2018 Aug 07
2
Create an Add Instruction in LLVM IR
I want to create an add instruction that takes two constant operands at the
LLVM IR level. I use the IRBuilder class, but nothing happens. Here is part
of the runOnFunction() method of my function pass:
...
LLVMContext &Context = F.getContext();
IRBuilder<> builder(&Instruction);
Value *Lef = ConstantInt::get(Type::getInt32Ty(Context), 4);
Value *Rig =
2013 Jul 25
2
[LLVMdev] Error for AllocaInst and Instruction
Hi,
For the following code
const Type * Int32Type =
IntegerType::getInt32Ty(getGlobalContext());
AllocaInst* newInst = new AllocaInst(Int32Type, 0, "flag", Bb);
Bb->getInstList().push_back(newInst);
It gives me the error
" error: no matching constructor for initialization of 'llvm::AllocaInst'
AllocaInst* newInst = new
2012 Feb 01
1
[LLVMdev] Function Insertion Error
Hi,
I am trying to insert a function into the LLVM IR. But i get a stack dump exception. My code is as follows.
#include "llvm/Pass.h"
#include "llvm/Function.h"
#include "llvm/Module.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/Support/IRBuilder.h"
using namespace llvm;
namespace {
2015 May 30
2
[LLVMdev] Linking modules across contexts crashes
I get a crash when I try to link multiple modules registered in their
individual contexts.
Documentation for Linker::LinkModules doesn't mention anything about
contexts, and the first link succeeds. But the second link crashes.
Is this not the right way to merge such modules? If not, then what is
the right way?
In any case, documentation for Linker::LinkModules should say if
contexts are
2010 Aug 18
2
[LLVMdev] clang: call extern function using JIT
gafferuk <gafferuk at gmail.com> writes:
> Can someone pease tell me what I am doing wrong?
It is hard to say because you don't say what the problem is, but let's
try.
> Im trying to register an external function with the JIT, so can call
> functions in my music
>
> application.
>
> Here my function
>
> int Execute(llvm::Module *Mod, char * const *envp)
2011 Mar 07
1
[LLVMdev] DW_TAG_lexical_block structure in debug information
Hello,
The documentation for debug information
(http://llvm.org/docs/SourceLevelDebugging.html) says the structure of
block descriptors metadata is:
!3 = metadata !{
i32, ;; Tag = 11 + LLVMDebugVersion (DW_TAG_lexical_block)
metadata,;; Reference to context descriptor
i32, ;; Line number
i32 ;; Column number
}
However, looking at the generated metadata, there are 2 extra
2011 May 13
3
[LLVMdev] IO intrinsics?
I found these lines in the BrainF example:
//declare i32 @getchar()
getchar_func = cast<Function>(module->
getOrInsertFunction("getchar", IntegerType::getInt32Ty(C), NULL));
//declare i32 @putchar(i32)
putchar_func = cast<Function>(module->
getOrInsertFunction("putchar", IntegerType::getInt32Ty(C),
2012 Feb 09
1
[LLVMdev] Difficulty inserting putchar in IR
Hi,
I have written a simple code to insert putchar() function into IR.
It compiled well but when I tried to run the generated .bc file with lli,
its not showing
proper output.
Function *putchar_func = cast<Function>(M->
getOrInsertFunction("putchar", IntegerType::getInt32Ty(Context),
IntegerType::getInt32Ty(Context), NULL));
Value *One =
2012 Apr 10
2
[LLVMdev] How to get the module handle of a .bc file??
Hi all,
I want to run a function pass on a certain .bc file. In the process, the pass will insert a check function into the .bc file.
I know the .bc file is regarded as a module in LLVM. So, there are two basic steps needed to be done,
1, Use the "getOrInsertFunction"API to add a declaration of the extern "check function".
2, Use the "insertBefore"API to insert the