[llvm-commits] [poolalloc] r44441 - in /poolalloc/trunk/lib: DSA/DataStructure.cpp DSA/Local.cpp PoolAllocate/Heuristic.cpp PoolAllocate/PointerCompress.cpp PoolAllocate/TransformFunctionBody.cpp

Duncan Sands baldrick at free.fr
Fri Nov 30 01:03:25 PST 2007


Hi John,

> Update use of TargetData->getTypeSize() to TargetData->getABITypeSize().
> I believe we want all of the sizes to including ABI padding.

you need to use getABITypeSize for GEP calculations, in particular for advancing
pointers or moving to the next array element (you shouldn't need this for moving
around in structs, because there is a special API for structs that does it all for
you).  Also, all memory allocations need to use getABITypeSize, including alloca's
and storage for globals.  You probably only want getTypeStoreSize if you are doing
alias analysis.

Ciao,

Duncan.



More information about the llvm-commits mailing list