Properly decode method header
Make room for temps
Fix accessing primitive index