generalize mips-specific reloc code not to hard-code sym/type encoding