MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / abi_arg_slot

Method abi_arg_slot

winch/codegen/src/frame/mod.rs:235–249  ·  view source on GitHub ↗
(arg: &ABIOperand, next_stack: &mut u32, arg_base_offset: u32)

Source from the content-addressed store, hash-verified

233 }
234
235 fn abi_arg_slot(arg: &ABIOperand, next_stack: &mut u32, arg_base_offset: u32) -> LocalSlot {
236 match arg {
237 // Create a local slot, for input register spilling,
238 // with type-size aligned access.
239 ABIOperand::Reg { ty, size, .. } => {
240 *next_stack = align_to(*next_stack, *size) + *size;
241 LocalSlot::new(*ty, *next_stack)
242 }
243 // Create a local slot, with an offset from the arguments base in
244 // the stack; which is the frame pointer + return address.
245 ABIOperand::Stack { ty, offset, .. } => {
246 LocalSlot::stack_arg(*ty, offset + arg_base_offset)
247 }
248 }
249 }
250}
251
252impl Frame<Emission> {

Callers

nothing calls this directly

Calls 2

align_toFunction · 0.50
newFunction · 0.50

Tested by

no test coverage detected