Helpers and refactorings to prepare for interpreter optimizations (x64)
am: a00b54b74b

Change-Id: I95eaf48c6336c5e743515ac9a76cfa35f2d76860