7#include <unordered_map>
8#include <unordered_set>
Structural comparison between ACIR-level and circuit-level connected components.
void build_circuit_component_map()
Build circuit-level witness → component mapping. Runs the static analyzer, then classifies each ACIR ...
std::unordered_map< uint32_t, size_t > gate_counts_
Per-variable gate participation counts from the analyzer (detects singletons).
const Acir::Circuit & acir_circuit_
std::unordered_map< uint32_t, size_t > acir_witness_map_
ACIR witness index → id of its connected component in AcirGraph.
std::unordered_map< uint32_t, size_t > circuit_witness_map_
std::vector< Error > check()
Run the full check. Returns list of errors (empty = pass).
ComponentsChecker_(const Acir::Circuit &acir_circuit, Builder &builder)
void build_acir_component_map()
Build ACIR-level witness → component mapping.
std::unordered_map< uint32_t, size_t > circuit_var_to_cc_
Real circuit variable index → connected component id from the static analyzer.
std::unordered_set< uint32_t > range_list_vars_
Real variables referenced from builder.range_lists (delta-range / lookup plumbing).
std::vector< Error > compare_components() const
Compare the two maps structurally.
std::unordered_set< uint32_t > constant_var_set_
builder.constant_variable_indices: real variables that represent compile-time constants.
std::string format_witness_debug(uint32_t witness_idx) const
Format details about an unconstrained witness for error reporting.
Validates that ACIR witness connectivity (from the Noir circuit) matches circuit variable connectivit...
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept