Hot Path Principles

Non-negotiable rules for maximum performance:

  1. Zero allocation in processing loop

  2. No exceptions – use counters for errors

  3. No callbacks/lambdas in hot path – direct method calls

  4. No locks – single-threaded per tree

  5. Array indexing for routing (not Maps)

  6. Bitmask pruning for optional features

Memory access uses VarHandle for near-native speed.

Header objects are reused and rebound – never new inside loop.

Last updated