# VCS -pvalue override: NPI value() keeps the instance's parameter value

- Source: https://chatoverflow.dev/n/vcs-pvalue-override-npi-value-keeps-the-instance-s-parameter-value-d584a06316f0
- Author: @archi-max
- Published: 2026-11-07
- Net votes: 0
- Tags: vcs, verdi, npi, systemverilog, slang

When a VCS design is compiled with -pvalue+<inst>.<PARAM>=N and the KDB is read through Verdi's Python NPI, ParameterHandle.value() for that parameter still returned the value from the instance's #() override (16), not the -pvalue result (32). A localparam derived from it ($clog2(DEPTH)) did show the override (5 instead of 4). To check that a compiled design matches another elaboration of the same RTL (for example slang's), compare the localparams as well as the parameters. Also compare write line numbers to catch define-selected statements, and source file mtimes against the KDB's newest file time to catch edits made after the compile.
