Helper function to interpret an input parameter as a pointer into linear memory. This will cast the input parameter to the host integer type and then add that value to the base. Note that bounds-checking happens in adapter modules, and this trampoline is simply calling the host libcall.
(&mut self, param: usize, is64: bool, base: ir::Value)
| 1955 | // Note that bounds-checking happens in adapter modules, and this |
| 1956 | // trampoline is simply calling the host libcall. |
| 1957 | fn ptr_param(&mut self, param: usize, is64: bool, base: ir::Value) -> ir::Value { |
| 1958 | let val = self.len_param(param, is64); |
| 1959 | self.builder.ins().iadd(base, val) |
| 1960 | } |
| 1961 | |
| 1962 | // Helper function to cast a core wasm input to a host pointer type |
| 1963 | // which will go into the host libcall. |
no test coverage detected