AsmJit
Low-Latency Machine Code Generation
Function calling convention.
Function calling convention is a scheme that defines how function parameters are passed and how function returns its result. AsmJit defines a variety of architecture and OS specific calling conventions and also provides a compile time detection to make the code-generation easier.
Initializes this calling convention to the given ccId
based on the environment
.
See CallConvId and Environment for more details.
Resets this CallConv struct into a defined state.
It's recommended to reset the CallConv struct in case you would like create a custom calling convention as it prevents from using an uninitialized data (CallConv doesn't have a constructor that would initialize it, it's just a struct).
Returns the target architecture of this calling convention.
Sets the target architecture of this calling convention.
Returns the calling convention id.
Sets the calling convention id.
Returns the strategy used to assign registers to arguments.
Sets the strategy used to assign registers to arguments.
Tests whether the calling convention has the given flag
set.
Returns the calling convention flags, see Flags
.
Adds the calling convention flags, see Flags
.
Adds the calling convention flags, see Flags
.
Tests whether this calling convention specifies 'RedZone'.
Tests whether this calling convention specifies 'SpillZone'.
Returns size of 'RedZone'.
Returns size of 'SpillZone'.
Sets size of 'RedZone'.
Sets size of 'SpillZone'.
Returns a natural stack alignment.
Sets a natural stack alignment.
This function can be used to override the default stack alignment in case that you know that it's alignment is different. For example it allows to implement custom calling conventions that guarantee higher stack alignment.
Returns the size of a register (or its part) to be saved and restored of the given group
.
Sets the size of a vector register (or its part) to be saved and restored.
Returns the alignment of a save-restore area of the given group
.
Sets the alignment of a save-restore area of the given group
.
Returns the order of passed registers of the given group
.
Returns the mask of passed registers of the given group
.
Resets the order and mask of passed registers.
0xFF
, uint32_t a2 = 0xFF
, uint32_t a3 = 0xFF
, uint32_t a4 = 0xFF
, uint32_t a5 = 0xFF
, uint32_t a6 = 0xFF
, uint32_t a7 = 0xFF
)noexcept◆ Sets the order and mask of passed registers.
Returns preserved register mask of the given group
.
Sets preserved register mask of the given group
.
Maximum number of register arguments per register group.
Target architecture.
Calling convention id.
Register assignment strategy.
Red zone size (AMD64 == 128 bytes).
Spill zone size (WIN-X64 == 32 bytes).
Natural stack alignment as defined by OS/ABI.
Calling convention flags.
Size to save/restore per register group.
Alignment of save/restore groups.
Mask of all passed registers, per group.
Mask of all preserved registers, per group.
Passed registers' order, per register group.