Define a weak linkage function in Assembler

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Define a weak linkage function in Assembler

1,324 Views
-dan_l
Contributor I

I am porting an interface to the Interrupt Vector Table.    The default handler function is aliased by two weakly defined functions written in assembler, so that they may be overridden by the client code.

I cannot determine from the documentation of from the community a way to declare the function aliases as weak symbols.

If I were writing in C, this would be easy enough.

In Kinetis Design Studio a .weak directive would do the trick, but the coldfire assembler doesn't support .weak.

How does one define a symbol in ColdFire V1 assembler (using the CodeWarrior Compilation System) as a weak (aka Overload) symbol?

Thank you for your consideration!

 

0 Kudos
Reply
1 Reply

1,293 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

We have very limited resource for CF V1 assembly. All our demo code is for C. assembly is not recommended.

If you would like check assembly, you can right click on c source code, "disassemble...", you will see the generated assemble code

the assembly related documents:

1. Coldfire assembly Instruction Set:

https://www.nxp.com.cn/docs/en/reference-manual/CFPRM.pdf

2. Under CodeWarrior install folder: Assembler_CFV1_Microcontrollers.pdf

 

Have a nice day,

Jun Zhang

 

 

 

 

0 Kudos
Reply