search for: _mergedglobalsptr

Displaying 1 result from an estimated 1 matches for "_mergedglobalsptr".

2012 Oct 13
1
[LLVMdev] Accessing merged globals through PointerType
...gt;foo[i] = merged_ptr->bar[i] * merged_ptr->baz[i]; } So I add something like this after line 153: PointerType *MergedPointerType = PointerType::get(MergedTy, 0); GlobalVariable *MergedPointer = new GlobalVariable(M, MergedPointerType, false, GlobalValue::ExternalLinkage, MergedGV, "_MergedGlobalsPtr"); This is where I'm stuck. How can I use replaceAllUsesWith() to replace uses of each global with accesses through the new MergedPointer instead of through indices into the MergedGV struct as is currently done? Is this possible? Thanks, Rob -------------- next part -------------- An HTM...