[llvm-commits] [llvm] r120201 - /llvm/trunk/include/llvm/ADT/InMemoryStruct.h

Chris Lattner clattner at apple.com
Sun Nov 28 14:02:36 PST 2010


On Nov 28, 2010, at 1:41 PM, Daniel Dunbar wrote:

>> However, I don't see how this is really a win.  You are avoiding a memcpy of a few smallish (~20-40 byte) structs, but this add a lot of complexity, and you have the have the same amount of stack space reserved.
>> 
>> It seems more straight-forward and cleaner to just use structs directly.  Is the complexity this introduces solving a measured performance issue?
> 
> Nope, it is experimental.
> 
> I generally agree with your points, except that I don't see it adding
> complexity on the client side.

It adds complexity to the methods that take an use it.  I had to go look up the class and try to reverse engineer what it was getting at.  Using a pointer to a struct would avoid this complexity.

-Chris



More information about the llvm-commits mailing list