| 340 | } |
| 341 | |
| 342 | fn store_arg( |
| 343 | &mut self, |
| 344 | arg_abi: &ArgAbi<'tcx, Ty<'tcx>>, |
| 345 | val: Self::Value, |
| 346 | dst: PlaceRef<'tcx, Self::Value>, |
| 347 | ) { |
| 348 | match arg_abi.mode { |
| 349 | PassMode::Ignore => {} |
| 350 | PassMode::Direct(_) | PassMode::Pair(..) => { |
| 351 | OperandValue::Immediate(val).store(self, dst); |
| 352 | } |
| 353 | PassMode::Cast(_, _) | PassMode::Indirect { .. } => span_bug!( |
| 354 | self.span(), |
| 355 | "query hooks should've made this `PassMode` impossible: {:#?}", |
| 356 | arg_abi |
| 357 | ), |
| 358 | } |
| 359 | } |
| 360 | |
| 361 | fn arg_memory_ty(&self, arg_abi: &ArgAbi<'tcx, Ty<'tcx>>) -> Self::Type { |
| 362 | arg_abi.layout.spirv_type(self.span(), self) |