MCPcopy Create free account
hub / github.com/Amanieu/regalloc3 / invalidate_operand_group_mapping

Method invalidate_operand_group_mapping

src/internal/allocator/split.rs:1059–1081  ·  view source on GitHub ↗

Invalidate any existing operand to group mappings for a vreg: the group they point to will no longer be valid after it is spilled. New mappings will be created when building the new virtual registers for the split product.

(&mut self, vreg: V)

Source from the content-addressed store, hash-verified

1057 // will be created when building the new virtual registers for the split
1058 // product.
1059 fn invalidate_operand_group_mapping<V: AbstractVirtRegGroup>(&mut self, vreg: V) {
1060 if V::is_group() {
1061 let vreg = vreg.first_vreg(self.virt_regs);
1062 for segment in self.virt_regs.segments(vreg) {
1063 for &u in &self.uses[segment.use_list] {
1064 if let UseKind::GroupClassUse {
1065 slot,
1066 class: _,
1067 group_index: _,
1068 }
1069 | UseKind::GroupClassDef {
1070 slot,
1071 class: _,
1072 group_index: _,
1073 } = u.kind
1074 {
1075 self.virt_reg_builder
1076 .invalidate_value_group_mapping(u.pos, slot);
1077 }
1078 }
1079 }
1080 }
1081 }
1082
1083 /// Isolates all group uses in the given register group by splitting them
1084 /// off into minimal segments that only cover a single instruction (or part

Callers 2

isolate_group_usesMethod · 0.80
spillMethod · 0.80

Calls 3

first_vregMethod · 0.80
segmentsMethod · 0.80

Tested by

no test coverage detected