| TIGCC Linker Binary Code Fixup

Previous | The TIGCC Linker | Next

The TIGCC linker can do many operations on binary code. If you want it to behave correctly in all cases, you need to make sure that no executable code is included in a data section, and no data is included in a code section. However, TIGCC usually merges all data into the code section to optimize references to it, so in rare cases it is possible for the linker to generate incorrect code.
Binary code fixup is divided into several categories:

- NOP Instruction Removal
- Return Sequence Optimization
- Branch Fixup and Optimization
- Move/Load/Push Instruction Optimization
- Compare/Test Instruction Optimization
- Calculation Instruction Optimization