|
7 | 7 | from pathlib import Path |
8 | 8 | from typing import Any, Dict, List, Optional, Tuple |
9 | 9 |
|
10 | | -from flashinfer_bench.compile import Runnable, get_builder_registry |
| 10 | +from flashinfer_bench.compile import BuilderRegistry, Runnable |
11 | 11 | from flashinfer_bench.data import Trace, TraceSet |
12 | 12 | from flashinfer_bench.env import get_fib_cache_path |
13 | 13 |
|
@@ -115,7 +115,7 @@ def load_or_build(cls, trace_set: TraceSet, apply_config: ApplyConfig) -> "Apply |
115 | 115 | index[def_name] = bucket |
116 | 116 |
|
117 | 117 | def_best: Dict[str, str] = {} |
118 | | - reg = get_builder_registry() |
| 118 | + reg = BuilderRegistry.get_instance() |
119 | 119 |
|
120 | 120 | for def_name, sol_name in raw["def_best"].items(): |
121 | 121 | defn = trace_set.definitions.get(def_name) |
@@ -169,7 +169,7 @@ def _build(cls, trace_set: TraceSet, apply_config: ApplyConfig) -> "ApplyTable": |
169 | 169 | The newly built apply table. |
170 | 170 | """ |
171 | 171 | digest = cls._digest(trace_set, apply_config) |
172 | | - reg = get_builder_registry() |
| 172 | + reg = BuilderRegistry.get_instance() |
173 | 173 |
|
174 | 174 | index: Dict[str, Dict[ApplyKey, str]] = {} |
175 | 175 | def_best: Dict[str, Runnable] = {} |
@@ -267,7 +267,7 @@ def _prewarm_aot(cls, trace_set: TraceSet, config: ApplyConfig, table: "ApplyTab |
267 | 267 | """ |
268 | 268 | if not (config.aot_ratio and config.aot_ratio > 0.0): |
269 | 269 | return |
270 | | - reg = get_builder_registry() |
| 270 | + reg = BuilderRegistry.get_instance() |
271 | 271 |
|
272 | 272 | for def_name, bucket in table.index.items(): |
273 | 273 | if not bucket: |
|
0 commit comments