Monthly Archives: March 2015

Still Better Than Mutexes

If you happened to watch my lightning talk from CppCon then you heard me talk about how there was a case where one could still get deadlock when using transactional memory. Specifically one could do something along the lines of1 a = 0 b = 0 //thread #1: atomic { if (a != 1) retry(); […]

Shared Overflow

I encountered my first stack overflow in a long time the other day. I’m going to name the situation that I ran into a shared_ptr cascade, a situation can probably best be illustrated by the following: struct Node { std::shared_ptr<Node> m_next_p; int m_data; }; void shared_ptr_cascade { const auto numNodes = 100000; auto head_p = […]