> Can you tell us a little bit more about inlining of virtual functions?
Virtual method inlining is the "mother of all optimizations". See:
* http://parleys.com/play/514892260364bc17fc56be1d/chapter6/ab...
* (more advanced) http://www.azulsystems.com/blog/cliff/2011-04-04-fixing-the-...
> if you're performance driven you're already not using virtual functions for places where that overhead is unacceptable
Well, that can only be true for some very localized computations. Virtual method calls are the basis for polymorphism (virtual method calls can even be used when implementing functional languages' pattern matching -- the functional form of polymorphism), and polymorphism is the basis for most programming abstractions. If your code is interesting enough, it will have lots of virtual calls. If it doesn't, then you're probably doing something very specific, and C/C++ might be a better option indeed.
> Can you expand on how GC would make my life easier in general?
Sure (I guess you mean re concurrent data structures; otherwise it simply saves you the pain of manual memory management). The basic principle of most (all?) lock-free data structures is that multiple threads might be reading a single node of the DS (which may contain stale data) and then try to CAS a new node into the DS. Without GC, it's very hard to determine when all threads have stopped examining a given node so that it can be safely deallocated.
See the following discussions on the difficulty of implementing lock-free data structures in C++ (b/c of lack of GC):
* http://www.drdobbs.com/lock-free-data-structures/184401865
* https://software.intel.com/en-us/forums/topic/295279
Without a GC, you'd need hazard pointers[1] or RCU[2], both are rife with issues, and are either not general enough or perform worse than a GC.
> Surely it depends on the nature of the task you're trying to solve, locks aren't always the bottleneck
True.
> and there's not always concurrent solutions.
Right, but if your code isn't concurrent/parallel there's a hard (and low) limit on how fast it can run.
[1]: http://en.wikipedia.org/wiki/Hazard_pointer
[2]: http://en.wikipedia.org/wiki/Read-copy-update