[cfe-users] C++ lambdas more expensive than blocks?

2016-10-24 Thread Jens Alfke via cfe-users
I’ve started using C++11 lambdas in my code. A few of them are in performance-sensitive areas, so I was looking at (optimized) assembly code of some of my methods to see what goes on under the hood. I don’t entirely understand the code, but the code on the calling side (i.e. the part that creat

Re: [cfe-users] C++ lambdas more expensive than blocks?

2016-10-24 Thread Jens Alfke via cfe-users
> On Oct 24, 2016, at 12:00 PM, Benjamin Kramer wrote: > > a helper class such as llvm::function_ref[1] might come > in handy, which acts like a function pointer but also allows captures > to be passed around. Thanks. Is that class something I can just copy-and-paste into my code? Will it work