[cc65] register usage when mixing assembler and C with cc65?

From: Frank Buss <fb1frank-buss.de>
Date: 2014-07-17 04:22:52
When I call external assembler functions from my C code, what are the rules for preserving the registers? I couldn't find it in the documentation.

- does the C environment expect the assembler code to save the A/X/Y/flags register values?

Is there a difference between fastcall and normal defined functions with and without parameters?

- only one char parameter for A in a fastcall function, do I need to save X and Y?

- a fastcall function without parameters and void return, do I need to save the registers?

- a normal assembler function, void return, do I need to save the registers?

To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Thu Jul 17 04:23:13 2014

This archive was generated by hypermail 2.1.8 : 2014-07-17 04:23:15 CEST