remove unused code
authorJacob Lifshay <programmerjake@gmail.com>
Tue, 10 Jan 2023 12:55:58 +0000 (04:55 -0800)
committerJacob Lifshay <programmerjake@gmail.com>
Tue, 10 Jan 2023 12:55:58 +0000 (04:55 -0800)
src/bigint_presentation_code/compiler_ir.py

index 7dd5aac199afa41474834fba54fdfb49c002cfec..45762700a92a9d686c758540e72cfa89d8bc1e0f 100644 (file)
@@ -872,37 +872,6 @@ class LocSet(OFSet[Loc], Interned):
             return None
         return self.ty.base_ty
 
-    def concat(self, *others):
-        # type: (*LocSet) -> LocSet
-        if self.ty is None:
-            return LocSet()
-        base_ty = self.ty.base_ty
-        reg_len = self.ty.reg_len
-        starts = {k: BitSet(v) for k, v in self.starts.items()}
-        for other in others:
-            if other.ty is None:
-                return LocSet()
-            if other.ty.base_ty != base_ty:
-                return LocSet()
-            for kind, other_starts in other.starts.items():
-                if kind not in starts:
-                    continue
-                starts[kind].bits &= other_starts.bits >> reg_len
-                if starts[kind] == 0:
-                    del starts[kind]
-                    if len(starts) == 0:
-                        return LocSet()
-            reg_len += other.ty.reg_len
-
-        def locs():
-            # type: () -> Iterable[Loc]
-            for kind, v in starts.items():
-                for start in v:
-                    loc = Loc.try_make(kind=kind, start=start, reg_len=reg_len)
-                    if loc is not None:
-                        yield loc
-        return LocSet(locs())
-
     @lru_cache(maxsize=None, typed=True)
     def max_conflicts_with(self, other):
         # type: (LocSet | Loc) -> int
@@ -2086,10 +2055,6 @@ class OpInputSeq(Sequence[_T], Generic[_T, _Desc]):
         self._verify_write_with_desc(idx, item, desc)
         return idx
 
-    def _on_set(self, idx, new_item, old_item):
-        # type: (int, _T, _T | None) -> None
-        pass
-
     @abstractmethod
     def _get_descriptors(self):
         # type: () -> tuple[_Desc, ...]
@@ -2169,10 +2134,6 @@ class OpInputVals(OpInputSeq[SSAVal, OperandDesc]):
             raise ValueError(f"assigned item's type {item.ty!r} doesn't match "
                              f"corresponding input's type {desc.ty!r}")
 
-    def _on_set(self, idx, new_item, old_item):
-        # type: (int, SSAVal, SSAVal | None) -> None
-        SSAUses._on_op_input_set(self, idx, new_item, old_item)  # type: ignore
-
     def __init__(self, items, op):
         # type: (Iterable[SSAVal], Op) -> None
         if hasattr(op, "inputs"):