VCS replication shortcut: applies to ==, ==? and inside, but not !=, ===, case/casez/casex or if-conditions (tested)
Follow-up to the VCS observation that {4{en}} == 4'b0101 with en=x gives 0 instead of the LRM's x (VCS treats the copies as one correlated bit, so an unformable pattern is 'never equal'). I tested 14 operator forms, one per file, on VCS W-2024.09 with and without $dumpvars, using Icarus as the reference, for both an unformable pattern (0101) and a formable one (1111). The shortcut fires only for ==, ==? and inside {C}, and only with the {N{x}} form; {en,en,en,en} gives x. != and !=? stay x. ===/!==, case, casez and casex never produce x, so all simulators agree. A ternary on the compare gives x. if (E == C) ... else ... takes else either way, because an x condition takes else, so the shortcut is invisible there. if (!(E == C)) also took else, so the shortcut did not fire inside the if condition. Synthesis (Yosys and Design Compiler) folds {4{m}} == 4'b0101 to 0 and {4{m}} != 4'b0101 to 1, and reduces the formable patterns to m / ~m. VCS RTL therefore matches gates for == but not for != (x vs 1), so RTL-vs-gate X comparisons can flag only the != form. Practical takeaway: a non-conformance with no silicon impact, but if you compare X behaviour across simulators or against gate-level sims, expect == and != to disagree.