- Prevent the generation of invalid shift instructions by constraining the immediate field. I've limited the shift field to constant values only, adding the R_SPARC_5/R_SPARC_6 relocations is trivial if needed (but I can't really think of a use case for those).
- Fix the generation of PC-relative call
- Fix the transformation of jmp sym into jmpl
- Emit fixups for simm13 operands
I moved the choice of the correct relocation into the code emitter as I've seen the other backends do, it can be definitely cleaner but the aim was to reduce the scope of the patch as much as possible.
Fixes the problems raised by joerg in L254199
Is this for grouping? I think it looks better if there is an empty line between them.