Keil Logo


Information in this article applies to:

  • C251 Version 1.24
  • C251 Version 2.14


How do I enable the compiler to generate code that passes function arguments in registers to the callee?


The REGPARMS directive instructs the compiler to pass up to three function arguments in registers to the callee. This kind of parameter passing is similar to what you would use when writing assembly language code and is significantly faster than storing function arguments in static memory or on the stack. The NOREGPARMS directive forces the compiler to pass all function arguments in fixed memory locations.


  • Refer to REGPARMS in the Cx51 User's Guide.

Last Reviewed: Friday, July 15, 2005

Did this article provide the answer you needed?
Not Sure
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.