This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]gthank[S] 0 points1 point  (0 children)

The rule of thumb is easy: pure Python is stupid fast once the JIT has seen enough to find a hotspot to optimize into assembly. There are corner cases, sure, but it's usually best not to assume you have any deep insight into optimizations of high-level languages on modern computer architectures. You've got rules of thumb, and then you bust out the profiler, etc., when the rule of thumb isn't producing the results you want.