16 ms·
Code paths introduced in order to execute any potential stack unrolling are inefficient and they make your code slow. Especially tight loops. This was common kn
by nurettin 7y ago
Code paths introduced in order to execute any potential stack unrolling are inefficient and they make your code slow. Especially tight loops. This was common knowledge back in 2000s.
- ncmncm 7y agoCommon knowledge, but not correct. Code to destroy objects has to be generated for regular function returns, and is jumped into by the exception handler too. Managing resources by hand, instead, would also require code, but you have to write it. Its expense arises from its fragility.
- nurettin 7y agoWhat I meant was inserting stack frames into assembly, which are dissimilar to calling free, slowing things down.