[LLVMdev] LLVM AllocaInst and StoreInst
Tim Northover
t.p.northover at gmail.com
Mon Aug 4 05:43:44 PDT 2014
>> Value *num = ConstantInt::get(Type::getInt64Ty(context), aTable.value,
>> true);
>> Value *alloc = new AllocaInst(IntegerType::get(context, 32),
>> aTable.variableName,entry);
>> StoreInst *ptr = new StoreInst(num,alloc,false,entry);
OK, try writing out the LLVM IR you expect to get for that final store
in full (assume num is named "%num" and alloc is named "%alloc").
Check each detail of it against the lines above; do you see any
discrepancies?
Cheers.
Tim.
More information about the llvm-dev
mailing list