It has to be hardcoded int. At least for lw. I don't know the entire instruction set, so there might be something in there, that lets you do what you want. Check out the MIPS simulator. In the book we ...