mirror of
https://github.com/YosysHQ/yosys
synced 2025-09-13 21:21:27 +00:00
Use C++11 final/override keywords.
This commit is contained in:
parent
dfde1cf1c5
commit
7191dd16f9
220 changed files with 540 additions and 548 deletions
|
@ -326,7 +326,7 @@ struct MuxpackWorker
|
|||
|
||||
struct MuxpackPass : public Pass {
|
||||
MuxpackPass() : Pass("muxpack", "$mux/$pmux cascades to $pmux") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -341,7 +341,7 @@ struct MuxpackPass : public Pass {
|
|||
log("certain that their select inputs are mutually exclusive.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing MUXPACK pass ($mux cell cascades to $pmux).\n");
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ PRIVATE_NAMESPACE_BEGIN
|
|||
|
||||
struct OptPass : public Pass {
|
||||
OptPass() : Pass("opt", "perform simple optimizations") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -64,7 +64,7 @@ struct OptPass : public Pass {
|
|||
log("\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
std::string opt_clean_args;
|
||||
std::string opt_expr_args;
|
||||
|
|
|
@ -526,7 +526,7 @@ void rmunused_module(RTLIL::Module *module, bool purge_mode, bool verbose, bool
|
|||
|
||||
struct OptCleanPass : public Pass {
|
||||
OptCleanPass() : Pass("opt_clean", "remove unused cells and wires") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -543,7 +543,7 @@ struct OptCleanPass : public Pass {
|
|||
log(" also remove internal nets if they have a public name\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
bool purge_mode = false;
|
||||
|
||||
|
@ -592,7 +592,7 @@ struct OptCleanPass : public Pass {
|
|||
|
||||
struct CleanPass : public Pass {
|
||||
CleanPass() : Pass("clean", "remove unused cells and wires") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -607,7 +607,7 @@ struct CleanPass : public Pass {
|
|||
log("in -purge mode between the commands.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
bool purge_mode = false;
|
||||
|
||||
|
|
|
@ -169,7 +169,7 @@ void demorgan_worker(
|
|||
|
||||
struct OptDemorganPass : public Pass {
|
||||
OptDemorganPass() : Pass("opt_demorgan", "Optimize reductions with DeMorgan equivalents") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -179,7 +179,7 @@ struct OptDemorganPass : public Pass {
|
|||
log("overall gate count of the circuit\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_DEMORGAN pass (push inverters through $reduce_* cells).\n");
|
||||
|
||||
|
|
|
@ -2009,7 +2009,7 @@ skip_alu_split:
|
|||
|
||||
struct OptExprPass : public Pass {
|
||||
OptExprPass() : Pass("opt_expr", "perform const folding and simple expression rewriting") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -2043,7 +2043,7 @@ struct OptExprPass : public Pass {
|
|||
log(" replaced by 'a'. the -keepdc option disables all such optimizations.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
bool mux_undef = false;
|
||||
bool mux_bool = false;
|
||||
|
|
|
@ -520,7 +520,7 @@ static void split(std::vector<std::string> &tokens, const std::string &text, cha
|
|||
|
||||
struct OptLutPass : public Pass {
|
||||
OptLutPass() : Pass("opt_lut", "optimize LUT cells") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -538,7 +538,7 @@ struct OptLutPass : public Pass {
|
|||
log(" only perform the first N combines, then stop. useful for debugging.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_LUT pass (optimize LUTs).\n");
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ PRIVATE_NAMESPACE_BEGIN
|
|||
|
||||
struct OptLutInsPass : public Pass {
|
||||
OptLutInsPass() : Pass("opt_lut_ins", "discard unused LUT inputs") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -42,7 +42,7 @@ struct OptLutInsPass : public Pass {
|
|||
log(" to the given technology. Valid values are: xilinx, ecp5, gowin.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_LUT_INS pass (discard unused LUT inputs).\n");
|
||||
string techname;
|
||||
|
|
|
@ -97,7 +97,7 @@ struct OptMemWorker
|
|||
|
||||
struct OptMemPass : public Pass {
|
||||
OptMemPass() : Pass("opt_mem", "optimize memories") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -106,7 +106,7 @@ struct OptMemPass : public Pass {
|
|||
log("This pass performs various optimizations on memories in the design.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_MEM pass (optimize memories).\n");
|
||||
|
||||
|
|
|
@ -326,7 +326,7 @@ struct OptMergeWorker
|
|||
|
||||
struct OptMergePass : public Pass {
|
||||
OptMergePass() : Pass("opt_merge", "consolidate identical cells") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -342,7 +342,7 @@ struct OptMergePass : public Pass {
|
|||
log(" Operate on all cell types, not just built-in types.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_MERGE pass (detect identical cells).\n");
|
||||
|
||||
|
|
|
@ -473,7 +473,7 @@ struct OptMuxtreeWorker
|
|||
|
||||
struct OptMuxtreePass : public Pass {
|
||||
OptMuxtreePass() : Pass("opt_muxtree", "eliminate dead trees in multiplexer trees") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -486,7 +486,7 @@ struct OptMuxtreePass : public Pass {
|
|||
log("This pass only operates on completely selected modules without processes.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing OPT_MUXTREE pass (detect dead branches in mux trees).\n");
|
||||
extra_args(args, 1, design);
|
||||
|
|
|
@ -332,7 +332,7 @@ struct OptReduceWorker
|
|||
|
||||
struct OptReducePass : public Pass {
|
||||
OptReducePass() : Pass("opt_reduce", "simplify large MUXes and AND/OR gates") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -353,7 +353,7 @@ struct OptReducePass : public Pass {
|
|||
log(" alias for -fine\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
bool do_fine = false;
|
||||
|
||||
|
|
|
@ -540,7 +540,7 @@ delete_dff:
|
|||
|
||||
struct OptRmdffPass : public Pass {
|
||||
OptRmdffPass() : Pass("opt_rmdff", "remove DFFs with constant inputs") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -554,7 +554,7 @@ struct OptRmdffPass : public Pass {
|
|||
log(" non-constant inputs) that can also be replaced with a constant driver\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
int total_count = 0, total_initdrv = 0;
|
||||
log_header(design, "Executing OPT_RMDFF pass (remove dff with constant values).\n");
|
||||
|
|
|
@ -473,7 +473,7 @@ dict<RTLIL::SigSpec, OpMuxConn> find_valid_op_mux_conns(RTLIL::Module *module, d
|
|||
|
||||
struct OptSharePass : public Pass {
|
||||
OptSharePass() : Pass("opt_share", "merge mutually exclusive cells of the same type that share an input signal") {}
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -488,7 +488,7 @@ struct OptSharePass : public Pass {
|
|||
log("multiplexing its output to multiplexing the non-shared input signals.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
|
||||
log_header(design, "Executing OPT_SHARE pass.\n");
|
||||
|
|
|
@ -198,7 +198,7 @@ struct OnehotDatabase
|
|||
|
||||
struct Pmux2ShiftxPass : public Pass {
|
||||
Pmux2ShiftxPass() : Pass("pmux2shiftx", "transform $pmux cells to $shiftx cells") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -225,7 +225,7 @@ struct Pmux2ShiftxPass : public Pass {
|
|||
log(" disable $sub inference for \"range decoders\"\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
int min_density = 50;
|
||||
int min_choices = 3;
|
||||
|
@ -737,7 +737,7 @@ struct Pmux2ShiftxPass : public Pass {
|
|||
|
||||
struct OnehotPass : public Pass {
|
||||
OnehotPass() : Pass("onehot", "optimize $eq cells for onehot signals") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -749,7 +749,7 @@ struct OnehotPass : public Pass {
|
|||
log(" verbose output\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
bool verbose = false;
|
||||
bool verbose_onehot = false;
|
||||
|
|
|
@ -28,7 +28,7 @@ PRIVATE_NAMESPACE_BEGIN
|
|||
|
||||
struct RmportsPassPass : public Pass {
|
||||
RmportsPassPass() : Pass("rmports", "remove module ports with no connections") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -39,7 +39,7 @@ struct RmportsPassPass : public Pass {
|
|||
log("\n");
|
||||
}
|
||||
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
log_header(design, "Executing RMPORTS pass (remove ports with no connections).\n");
|
||||
|
||||
|
|
|
@ -1444,7 +1444,7 @@ struct ShareWorker
|
|||
|
||||
struct SharePass : public Pass {
|
||||
SharePass() : Pass("share", "perform sat-based resource sharing") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -1476,7 +1476,7 @@ struct SharePass : public Pass {
|
|||
log(" Only perform the first N merges, then stop. This is useful for debugging.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
ShareWorkerConfig config;
|
||||
|
||||
|
|
|
@ -482,7 +482,7 @@ struct WreduceWorker
|
|||
|
||||
struct WreducePass : public Pass {
|
||||
WreducePass() : Pass("wreduce", "reduce the word size of operations if possible") { }
|
||||
void help() YS_OVERRIDE
|
||||
void help() override
|
||||
{
|
||||
// |---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|---v---|
|
||||
log("\n");
|
||||
|
@ -505,7 +505,7 @@ struct WreducePass : public Pass {
|
|||
log(" Do not optimize explicit don't-care values.\n");
|
||||
log("\n");
|
||||
}
|
||||
void execute(std::vector<std::string> args, Design *design) YS_OVERRIDE
|
||||
void execute(std::vector<std::string> args, Design *design) override
|
||||
{
|
||||
WreduceConfig config;
|
||||
bool opt_memx = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue