Tidy up interface between basic an machine code in terms of zero page usage

Change-Id: I07ea0c432c17e6cb660a7ea0c72ad3bfe5c55e5b