Fast codegen marshal/unmarshal

This trades off some of the allocation reduction we got earlier for a bump in speed.