Files
verilator/test_regress/t/t_ast_dump_patterns.v
T
Geza Lore eafe9636cf Internals: Dump Ast expression pattern statistics like Dfg (#7818)
Remove the expression combination counts from the default stats file,
and add a new `--dump-ast-patterns` option, which will dump new
`*_ast_patterns_*.txt` files. These contain the expression combinations
in a similar S-expression format as Dfg already produces with
`--dump-dfg-stats`. These dumps are not produced by just `--stats` as
they are fairly expensive to compute. Currently the new option will dump
at two points: just before we change to C types via widthMin usage, and
just before emit.
2026-06-21 22:17:36 +01:00

27 lines
720 B
Systemverilog

// DESCRIPTION: Verilator: Verilog Test module
//
// This file ONLY is placed under the Creative Commons Public Domain.
// SPDX-FileCopyrightText: 2026 Wilson Snyder
// SPDX-License-Identifier: CC0-1.0
module t (
input wire [3:0] a,
input wire [3:0] b,
input wire [3:0] c,
output wire [10:0] o
);
wire [3:0] x = ~a & ~b;
wire [3:0] y = ~b & ~c;
wire [3:0] z = ~c & ~a;
wire [0:0] w1 = x[0];
wire [7:0] w8 = {8{x[1]}};
wire [15:0] w16 = {2{w8}};
wire [31:0] w32 = {2{w16}};
wire [63:0] w64a = {2{w32}};
wire [63:0] w64b = {2{~w32}};
wire [62:0] w63 = 63'({2{~w32}});
wire [95:0] w96 = 96'(w64a);
assign o = {^x, ^y, ^z, ^w1, ^w8, ^w16, ^w32, ^w64a, ^w64b, ^w63, ^w96};
endmodule