search for: idxvec

Displaying 2 results from an estimated 2 matches for "idxvec".

Did you mean: idvec
2005 Jan 31
1
[LLVMdev] Question about Global Variable
...(), but this pointer is not the memory address of the initial value, it is a pointer of constant, like constant *. I cannot assign it to the AddrOfGstr[i]. How could I get memory address the initial vaule, not the pointer of constant? I tried to use the following way, std::vector <Value *> idxVec; Value *Zero1 = ConstantInt::get(Type::IntTy , 0); Value *Zero2 = ConstantInt::get(Type::IntTy , 0); idxVec.push_back(Zero1); idxVec.push_back(Zero2); Constant *pStr = ConstantExpr::getGetElementPtr(Cstr, idxVec); // trying to get pointer of initial value GetElementPtrInst *GEP = new GetElementP...
2005 Feb 02
1
[LLVMdev] RE: Question about Global Variable
...i ; <int> [#uses=1] %tmp.34 = getelementptr sbyte* %tmp.32, int %tmp.33 ; <sbyte*> [#uses=1] I am trying to construct all those IR instructions, for the first three, it is ok, as the following GetElementPtrInst *GEP = new GetElementPtrInst( pGVars, idxVec, "GetAryElement", InsertPos); Value *ldAddr = new LoadInst(GEP,"LdAryAddr",InsertPos); Value *ldAddr1 = new LoadInst(numidx, "idx_i", InsertPos); After this I need construct another getelementptr, and from the above IR code, the second getelementptr take the result...