This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Where are function parameters/return values stored?

Hi,

I'm looking at calling an ASM routine from some C code. I'd like to pass some parameters into the ASM routine, and have it return a value. I don't believe function arguments are passed on the stack, but am not sure of the general mechanism that is used. Any advice?

Thanks

David


Parents
  • You're asking about the C51 ABI (application binary interface). I would like to know what the ABI is too. I seem to remember that parameters are always passed in registers or in fixed memory locations (if not a re-entrant function).

    - Mark

Reply
  • You're asking about the C51 ABI (application binary interface). I would like to know what the ABI is too. I seem to remember that parameters are always passed in registers or in fixed memory locations (if not a re-entrant function).

    - Mark

Children