GenBCode: cleanup optimizations

Method-level cleanup optimizations.

See individual commit messages.
typo "allHanlders"