Returns the allocations for an instruction's operands.
(&self, inst: Inst)
| 70 | |
| 71 | /// Returns the allocations for an instruction's operands. |
| 72 | pub fn inst_allocations(&self, inst: Inst) -> &[Allocation] { |
| 73 | let start = self.operands_offset[inst.index()] as usize; |
| 74 | let end = self.operands_offset[inst.index() + 1] as usize; |
| 75 | &self.allocations[start..end] |
| 76 | } |
| 77 | |
| 78 | /// Returns a mutable slice of allocations for an instruction's operands. |
| 79 | pub fn inst_allocations_mut(&mut self, inst: Inst) -> &mut [Allocation] { |
no test coverage detected