Professional Documents
Culture Documents
1111111111
1111111111
// Variable declarations
logic flag = 0;
string hdl_path = $psprintf("%m.");
if (diff != 0) begin
if (freq inside {[0.99*exp_freq : 1.01*exp_freq]}) begin
`uvm_info("FREQ_CHECK", $sformatf("%0s Harshit frequency
matches expected value with 1 percent tolerance. Actual = %0d MHz, Expected = %0d
MHz, HDL_PATH = %s", name, freq, exp_freq, hdl_path), UVM_LOW);
end
else begin
if(!($test$plusargs("NO_POR_CHKS_NOW"))) begin
`uvm_error("FREQ_CHECK", $sformatf("%0s Harshit
frequency doesn't match expected value. Actual = %7.4f MHz, Expected = %7.4f MHz,
HDL_PATH = %s", name, freq, exp_freq, hdl_path));
end
end
end
else begin
`uvm_info("FREQ_CHECK", $sformatf("%0s Harshit frequency
exactly matches with expected value. Actual = %0d MHz, Expected = %0d MHz, HDL_PATH
= %s", name, freq, exp_freq, hdl_path), UVM_LOW);
end