Returns the corresponding cranelift type for the provided wasm type.
(isa: &dyn TargetIsa, ty: WasmValType)
| 133 | |
| 134 | /// Returns the corresponding cranelift type for the provided wasm type. |
| 135 | fn value_type(isa: &dyn TargetIsa, ty: WasmValType) -> ir::types::Type { |
| 136 | match ty { |
| 137 | WasmValType::I32 => ir::types::I32, |
| 138 | WasmValType::I64 => ir::types::I64, |
| 139 | WasmValType::F32 => ir::types::F32, |
| 140 | WasmValType::F64 => ir::types::F64, |
| 141 | WasmValType::V128 => ir::types::I8X16, |
| 142 | WasmValType::Ref(rt) => reference_type(rt.heap_type, isa.pointer_type()), |
| 143 | } |
| 144 | } |
| 145 | |
| 146 | /// Get the Cranelift signature for all array-call functions, that is: |
| 147 | /// |
no test coverage detected