Not a lot has changed in the realm of byte code run-time optimizations in the last ten years.
Things that can help the optimizer:
- Type invariance of arrays
- Non-sparse arrays
- Don’t use ‘eval’ or ‘with’ anywhere (and especially near your speed-sensitive code).
- Be aware of where you want optimal performance.