#pragma once #include "bits/stdc++.h" enum GateType { XOR, MAJ, AND, OR }; struct CircuitGate { GateType type; std::vector inputs; std::vector output; std::vector fanouts; int topo_index; }; extern const char* GateName[4]; extern CircuitGate* Gates; extern std::vector circuit_inputs; extern int circuit_output; void read_verilog_from_file(const char *); void print_circuit_structure(); void recalulate_fanouts(); void calulate_topo_index();