arm¶
Arm machine specifics. The arm target has several options:
- thumb: enable thumb mode, emits thumb code
-
class
ppci.arch.arm.
ArmArch
(options=None)¶ Arm machine class.
-
between_blocks
(frame)¶ Generate any instructions here if needed between two blocks
-
determine_arg_locations
(arg_types)¶ Given a set of argument types, determine location for argument ABI: pass arg1 in R1 pass arg2 in R2 pass arg3 in R3 pass arg4 in R4 return value in R0
-
determine_rv_location
(ret_type)¶ Determine the location of a return value of a function given the type of return value
-
gen_call
(frame, label, args, rv)¶ Generate instructions for a function call.
-
gen_epilogue
(frame)¶ Return epilogue sequence for a frame.
Adjust frame pointer and add constant pool.
Also free up space on stack for:
- Space for parameters passed to called functions.
- Space for save registers
- Space for local variables
-
gen_function_enter
(args)¶ Generate code to extract arguments from the proper locations
The default implementation tries to use registers and move instructions.
Parameters: args – an iterable of virtual registers in which the arguments must be placed.
-
gen_prologue
(frame)¶ Returns prologue instruction sequence.
Reserve stack for this calling frame for:
- local variables
- save registers
- parameters to called functions
-
get_runtime
()¶ Implement compiler runtime functions
-
litpool
(frame)¶ Generate instruction for the current literals
-
move
(dst, src)¶ Generate a move from src to dst
-