SPRAB89B September 2011 – August 2025
C64x and newer ISAs have an optimized instruction to implement PC-relative addressing for nearby labels:
ADDKPC label, B5 ; B5 := label, position independentThis form constrains the label to be within a signed 7-bit constant offset (+/- 64 words) of the fetch packet containing the ADDKPC instruction.
ADDKPC is useful for computing return addresses, which are typically only a few instructions away.