MSP430F4538 Assembly language interface
I have been upgrading some old mixed 'C' and assembler code to operate on the MSP430F4538.
I note that when calling an assembly routine from 'C' the compiler uses CALLA rather than the old CALL. This then requires a return via RETA rather than RET.
As all of my code is within the lower 64K either calling method should operate correctly provided the call matches the return.
Is there a way to control the instruction the compiler generates for the call or will it always use CALLA for this processor?
-
In the latest CrossWorks you can set the "Memory Size" option in the "Code Generation Options" group of the project properties to 64K. That causes the compiler to always use CALL and RET.
Note that CALLX and RETX are pseudos for CALL/CALLA and RET/RETA depending upon processor architecture selected for assembly.
Please sign in to leave a comment.
Comments
1 comment