end // loop
valid_token = `true;
wk_cmd[incode1:incode2] = `get_cmd;
end
endtask // get_get_cmd
task get_get_addr_cmd;
input [1:`token_size*8*10] inline;
output valid_token;
output [31:0] token_number;
input [31:0] msg_level;
reg valid_f [2 : 4];
reg status_f [2 : 4];
integer i;
reg [1:`token_size*8] cmd_name;
reg [`token_size-1:0] token_2;
reg [`token_size-1:0] token_3;
reg [`token_size-1:0] token_4;
begin : block_get
for (i=2; i<=4; i=i+1) begin
valid_f[i] = `false;
status_f[i] = `false;
end // loop
cmd_name = "GET_ADDR";
valid_token = `false;
token_number = 0;
token_2= "";
token_3= "";
token_4= "";
$lmv_tokenize(inline, 1, 128, token_2, status_f[2]);
pcl_to_mem_types(wk_cmd[inmtype1:inmtype2],token_2,valid_f[2],msg_level,cmd_name);
$lmv_tokenize(inline, 2, 128, token_3, status_f[3]);
wk_cmd[insaddr1:insaddr2] = token_3;
valid_f[3] = `true;
$lmv_tokenize(inline, 2, 128, token_4, status_f[4]);
wk_cmd[inexpected_data1:inexpected_data2] = token_4;
valid_f[4] = `true;
for (i = 2; i <= 4; i = i + 1) begin
if (!(valid_f[i] && status_f[i])) begin
valid_token = `false;
token_number = i;
disable block_get;
end // if
end // loop
valid_token = `true;
wk_cmd[incode1:incode2] = `get_addr_cmd;
end
endtask // get_get_addr_cmd
task get_reload_cmd;
input [1:`token_size*8*10] inline;
output valid_token;
output [31:0] token_number;
input [31:0] msg_level;
reg valid_f [2 : 4];
reg status_f [2 : 4];
integer i;
reg [1:`token_size*8] cmd_name;
reg [`token_size-1:0] token_2;
reg [(`token_size-1)*8:0] token_3;
reg [`token_size-1:0] token_4;
begin : block_get
for (i=2; i<=4; i=i+1) begin
valid_f[i] = `false;
status_f[i] = `false;
end // loop
cmd_name = "RELOAD";
valid_token = `false;
token_number = 0;
token_2= "";
token_3= "";
token_4= "";
$lmv_tokenize(inline, 1, 128, token_2, status_f[2]);
pcl_to_mem_types(wk_cmd[inmtype1:inmtype2],token_2,valid_f[2],msg_level,cmd_name);
$lmv_tokenize(inline, 1, 128, token_3, status_f[3]);
wk_cmd[indfile1:indfile2] = token_3;
valid_f[3] = `true;
$lmv_tokenize(inline, 1, 128, token_4, status_f[4]);
pcl_to_boolean(wk_cmd[inflush_f],token_4,valid_f[4],msg_level,cmd_name);
for (i = 2; i <= 4; i = i + 1) begin
if (!(valid_f[i] && status_f[i])) begin
valid_token = `false;
token_number = i;
disable block_get;
end // if
end // loop
valid_token = `true;
wk_cmd[incode1:incode2] = `reload_cmd;
end
endtask // get_reload_cmd
task get_dump_cmd;
input [1:`token_size*8*10] inline;
output valid_token;
output [31:0] token_number;
input [31:0] msg_level;
reg valid_f [2 : 5];
reg status_f [2 : 5];
integer i;
reg [1:`token_size*8] cmd_name;
reg [`token_size-1:0] token_2;
reg [`token_size-1:0] token_3;
reg [`token_size-1:0] token_4;
reg [(`token_size-1)*8:0] token_5;
begin : block_get
for (i=2; i<=5; i=i+1) begin
valid_f[i] = `false;
status_f[i] = `false;
end // loop
cmd_name = "DUMP";
valid_token = `false;
token_number = 0;
token_2= "";
token_3= "";
token_4= "";
token_5= "";
$lmv_tokenize(inline, 1, 128, token_2, status_f[2]);
pcl_to_mem_types(wk_cmd[inmtype1:inmtype2],token_2,valid_f[2],msg_level,cmd_name);
$lmv_tokenize(inline, 2, 128, token_3, status_f[3]);
wk_cmd[instart_addr1:instart_addr2] = token_3;
valid_f[3] = `true;
$lmv_tokenize(inline, 2, 128, token_4, status_f[4]);
wk_cmd[inend_addr1:inend_addr2] = token_4;
valid_f[4] = `true;
$lmv_tokenize(inline, 1, 128, token_5, status_f[5]);
wk_cmd[indfile1:indfile2] = token_5;
valid_f[5] = `true;
for (i = 2; i <= 5; i = i + 1) begin
if (!(valid_f[i] && status_f[i])) begin
valid_token = `false;
token_number = i;
disable block_get;
end // if
end // loop
valid_token = `true;
wk_cmd[incode1:incode2] = `dump_cmd;
end
endtask // get_dump_cmd
task get_remote_cmd;
input [1:`token_size*8*10] inline;
output valid_token;
output [31:0] token_number;
input [31:0] msg_level;
reg valid_f [2:6];
reg status_f [2:6];
reg [1:6*8] cmd_name;
reg [`token_size-1:0] token_2;
reg [(`token_size-1)*8:0] token_3;
reg [`token_size-1:0] token_4;
reg [`token_size-1:0] token_5;
reg [`token_size-1:0] token_6;
integer i;
begin : block_get
for (i=2; i <= 6; i = i + 1) begin
valid_f[i] = `false;
status_f[i] = `false;
end // loop
cmd_name = "REMOTE";
valid_token = `false;
token_number = 0;
$lmv_tokenize(inline, 0, 0, token_2, status_f[2]);
wk_cmd[intarget_id1:intarget_id2] = token_2;
valid_f[2] = `true;
$lmv_tokenize(inline, 4, 1024, token_3, status_f[3]);
wk_cmd[inmsg1:inmsg2] = token_3;
valid_f[3] = `true;
$lmv_tokenize(inline, 1, 1, token_4, status_f[4]);
pcl_to_boolean(wk_cmd[inbuffer_f],token_4,valid_f[4],msg_level,cmd_name);
$lmv_tokenize(inline, 1, 1, token_5, status_f[5]);
pcl_to_boolean(wk_cmd[innotify_f],token_5,valid_f[5],msg_level,cmd_name);
$lmv_tokenize(inline, 1, 1, token_6, status_f[6]);
pcl_to_boolean(wk_cmd[inreturn_data_f],token_6,valid_f[6],msg_level,cmd_name);
for (i=2; i <= 6; i = i + 1) begin
if (!(valid_f[i] && status_f[i])) begin
valid_token = `false;
token_number = i;
disable block_get;
end // if
end // loop
valid_token = `true;
wk_cmd[incode1:incode2] = `remote_cmd;
end
endtask // get_remote_cmd
task decode_cmd;
input [1:`token_size*8] cmd;
input [1:`token_size*8*10] inline;
output status;
output [31:0] para_number;
input [31:0] msg_level;
reg valid_token;
integer token_number;
begin
case (cmd)
"configure" : get_configure_cmd(inline, valid_token, token_number, msg_level);
"configure_delay" : get_configure_delay_cmd(inline, valid_token, token_number, msg_level);
"request" : get_request_cmd(inline, valid_token, token_number, msg_level);
"idle" : get_idle_cmd(inline, valid_token, token_number, msg_level);
"trigger" : get_trigger_cmd(inline, valid_token, token_number, msg_level);
"wait_on" : get_wait_on_cmd(inline, valid_token, token_number, msg_level);
"print_msg" : get_print_msg_cmd(inline, valid_token, token_number, msg_level);
"set_msg_level" : get_set_msg_level_cmd(inline, valid_token, token_number, msg_level);
"call" : get_call_cmd(inline, valid_token, token_number, msg_level);
"func_beg" : get_func_beg_cmd(inline, valid_token, token_number, msg_level);
"func_end" : get_func_end_cmd(inline, valid_token, token_number, msg_level);
"sequential" : get_sequential_cmd(inline, valid_token, token_number, msg_level);
"stop_sim" : get_stop_sim_cmd(inline, valid_token, token_number, msg_level);
"wait_on_node" : get_wait_on_node_cmd(inline, valid_token, token_number, msg_level);
"open_buffer" : get_open_buffer_cmd(inline, valid_token, token_number, msg_level);
"close_buffer" : get_close_buffer_cmd(inline, valid_token, token_number, msg_level);
"set" : get_set_cmd(inline, valid_token, token_number, msg_level);
"set_addr" : get_set_addr_cmd(inline, valid_token, token_number, msg_level);
"get" : get_get_cmd(inline, valid_token, token_number, msg_level);
"get_addr" : get_get_addr_cmd(inline, valid_token, token_number, msg_level);
"reload" : get_reload_cmd(inline, valid_token, token_number, msg_level);
"dump" : get_dump_cmd(inline, valid_token, token_number, msg_level);
"remote" : get_remote_cmd(inline, valid_token, token_number, msg_level);
default : begin
if ((!(msg_level < `warnings))) begin
$display("WARNING at t from m", $time);
$display(" \"Syntax Error: remote is invalid for this model", cmd);
end // if
end
endcase
status = valid_token;
para_number = token_number;
end
endtask // decode_cmd
task to_fm_data_in;
input [1:`token_size*10*8] inline;
input [31:0] msg_level; // default = warnings
integer type;
integer size;
reg [(`token_size-1)*8:0] token_1;
reg [1:`token_size*10*8] tmp_inline;
reg status [1:1];
reg cmd_status;
integer para_number;
begin : block_1
type = 3; // command
size = 0; // default
tmp_inline = inline;
status[1] = `false;
cmd_status = `false;
para_number = 0;
token_1 = "";
//get command name
$lmv_tokenize(inline, type, size, token_1, status[1]);
if (!status[1]) begin
$display("WARNING at %0t from %m", $time);
$display("Syntax Error: Command \" %0s \" is invalid for this model", tmp_inline);
$display("Command Ignored");
wk_cmd[incode1:incode2] = `null_cmd;
disable block_1;
end // if
//decode token_1
decode_cmd(token_1, inline, cmd_status, para_number, msg_level);
if (!cmd_status) begin
$display("WARNING at %0t from %m", $time);
$display("Syntax Error: Parameter No. %0d is invalid for this command", (para_number-1));
$display(" Command \" %0s \" Ignored", tmp_inline);
wk_cmd[incode1:incode2] = `null_cmd;
disable block_1;
end // if
end
endtask // to_fm_data_in
task configure;
input [31 : 0] ctype; // enum type config_types
input [64:1] generic_value;
begin
wk_cmd[inctype1:inctype2] = ctype;
case (ctype)
dev_id , ven_id , rev_id , h_type , cls_code , mem_l_0 , mem_u_0 , mem_l_1 , mem_u_1 , mem_l_2 , mem_u_2 ,
io_l_0 , io_u_0 , io_l_1 , io_u_1 , io_l_2 , io_u_2 , c_line_size , int_ack_vector :
wk_cmd[invalue_vector1:invalue_vector2] = generic_value;
transfer_limit , abort_limit , termination_style , pci_error , decode :
wk_cmd[invalue1:invalue2] = generic_value;
addr_64 , data_64 , int_ack ,type1_access :
wk_cmd[invalue_boolean] = generic_value;
endcase
wk_cmd[incode1:incode2] = `configure_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // configure
task configure_delay;
input [64:1] index_value;
input [64:1] delay_value;
begin
wk_cmd[inctype1:inctype2] = delays;
wk_cmd[indelay_index1:indelay_index2] = index_value;
wk_cmd[indelay1:indelay2] = delay_value;
wk_cmd[incode1:incode2] = `configure_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // configure_delay
task request;
input [31 : 0] request_limit;
input [31 : 0] decode;
input [31 : 0] delay;
begin
wk_cmd[inrequest_limit1:inrequest_limit2] = request_limit;
wk_cmd[indecode1:indecode2] = decode;
wk_cmd[indelay1:indelay2] = delay;
wk_cmd[incode1:incode2] = `request_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // request
task idle;
input [31 : 0] cycles;
begin
wk_cmd[incycles1:incycles2] = cycles;
wk_cmd[incode1:incode2] = `idle_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // idle
task trigger;
input [31 : 0] tvalue;
begin
wk_cmd[intvalue1:intvalue2] = tvalue;
wk_cmd[incode1:incode2] = `trigger_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // trigger
task wait_on;
input [31 : 0] tvalue;
begin
wk_cmd[intvalue1:intvalue2] = tvalue;
wk_cmd[incode1:incode2] = `wait_on_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // wait_on
task print_msg;
input [1 : `token_size*8] message;
begin
wk_cmd[inmessage1:inmessage2] = message;
wk_cmd[incode1:incode2] = `print_msg_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // print_msg
task set_msg_level;
input [31 : 0] mlevel; // enum type msg_level_types
begin
wk_cmd[inmlevel1:inmlevel2] = mlevel;
wk_cmd[incode1:incode2] = `set_msg_level_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // set_msg_level
task call;
input [1 : `token_size*8] function_name;
begin
wk_cmd[infunction_name1:infunction_name2] = function_name;
wk_cmd[incode1:incode2] = `call_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // call
task func_beg;
input [1 : `token_size*8] function_name;
begin
wk_cmd[infunction_name1:infunction_name2] = function_name;
wk_cmd[incode1:incode2] = `func_beg_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // func_beg
task func_end;
input [1 : `token_size*8] function_name;
begin
wk_cmd[infunction_name1:infunction_name2] = function_name;
wk_cmd[incode1:incode2] = `func_end_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // func_end
task sequential;
begin
wk_cmd[incode1:incode2] = `sequential_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // sequential
task stop_sim;
begin
wk_cmd[incode1:incode2] = `stop_sim_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // stop_sim
task wait_on_node;
input [1:`token_size*8] node_name;
input [1:`token_size] node_value;
input [1:`token_size] node_mask;
begin
wk_cmd[innode_name1:innode_name2] = node_name;
wk_cmd[innode_value1:innode_value2] = node_value;
wk_cmd[innode_mask1:innode_mask2] = node_mask;
wk_cmd[incode1:incode2] = `wait_on_node_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // wait_on_node
task open_buffer;
input [1 : `token_size*8] function_name;
begin
wk_cmd[infunction_name1:infunction_name2] = function_name;
wk_cmd[incode1:incode2] = `open_buffer_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // open_buffer
task close_buffer;
input [1 : `token_size*8] function_name;
begin
wk_cmd[infunction_name1:infunction_name2] = function_name;
wk_cmd[incode1:incode2] = `close_buffer_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // close_buffer
task set;
input [31 : 0] stype; // enum type set_types
input [31 : 0] object_name; // enum type object_name_types
input [`slv_size-1 : 0] object_value;
input [31 : 0] delay_val;
begin
wk_cmd[instype1:instype2] = stype;
wk_cmd[inobject_name1:inobject_name2] = object_name;
wk_cmd[inobject_value1:inobject_value2] = object_value;
wk_cmd[indelay_val1:indelay_val2] = delay_val;
wk_cmd[incode1:incode2] = `set_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // set
task set_addr;
input [31 : 0] mtype; // enum type mem_types
input [`slv_size-1 : 0] saddr;
input [`slv_size-1 : 0] object_value;
begin
wk_cmd[inmtype1:inmtype2] = mtype;
wk_cmd[insaddr1:insaddr2] = saddr;
wk_cmd[inobject_value1:inobject_value2] = object_value;
wk_cmd[incode1:incode2] = `set_addr_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // set_addr
task get;
input [31 : 0] stype; // enum type set_types
input [31 : 0] object_name; // enum type object_name_types
input [`slv_size-1 : 0] expected_data;
begin
wk_cmd[instype1:instype2] = stype;
wk_cmd[inobject_name1:inobject_name2] = object_name;
wk_cmd[inexpected_data1:inexpected_data2] = expected_data;
wk_cmd[incode1:incode2] = `get_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // get
task get_addr;
input [31 : 0] mtype; // enum type mem_types
input [`slv_size-1 : 0] saddr;
input [`slv_size-1 : 0] expected_data;
begin
wk_cmd[inmtype1:inmtype2] = mtype;
wk_cmd[insaddr1:insaddr2] = saddr;
wk_cmd[inexpected_data1:inexpected_data2] = expected_data;
wk_cmd[incode1:incode2] = `get_addr_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // get_addr
task reload;
input [31 : 0] mtype; // enum type mem_types
input [1 : `token_size*8] dfile;
input flush_f;
begin
wk_cmd[inmtype1:inmtype2] = mtype;
wk_cmd[indfile1:indfile2] = dfile;
wk_cmd[inflush_f] = flush_f;
wk_cmd[incode1:incode2] = `reload_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // reload
task dump;
input [31 : 0] mtype; // enum type mem_types
input [`slv_size-1 : 0] start_addr;
input [`slv_size-1 : 0] end_addr;
input [1 : `token_size*8] dfile;
begin
wk_cmd[inmtype1:inmtype2] = mtype;
wk_cmd[instart_addr1:instart_addr2] = start_addr;
wk_cmd[inend_addr1:inend_addr2] = end_addr;
wk_cmd[indfile1:indfile2] = dfile;
wk_cmd[incode1:incode2] = `dump_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // dump
task remote;
input [31 : 0] target_id; // enum type natural
input [1 : `token_size*8] msg;
input buffer_f;
input notify_f;
input return_data_f;
begin
wk_cmd[intarget_id1:intarget_id2] = target_id;
wk_cmd[inmsg1:inmsg2] = msg;
wk_cmd[inbuffer_f] = buffer_f;
wk_cmd[innotify_f] = notify_f;
wk_cmd[inreturn_data_f] = return_data_f;
wk_cmd[incode1:incode2] = `remote_cmd;
wk_cmd[instrobe] = ~wk_cmd[instrobe];
end
endtask // remote
//--**--**--**--**--**--**--**--**-- USER CODE BEGIN
//--**--**--**--**--**--**--**--**-- USER CODE END
function [31:0] calc_curve;
input [31:0] x, c2, c1, c0;
begin
calc_curve = c2*(lmcver.power(x,2))/100 + c1*x + c0;
end
endfunction
task get_timing;
inout [31:0] local_times_trs_pad_pclk;
inout [31:0] local_times_trh_pad_pclk;
inout [31:0] local_times_twd_pad_31;
inout [31:0] local_times_twd_pad_30;
inout [31:0] local_times_twd_pad_29;
inout [31:0] local_times_twd_pad_28;
inout [31:0] local_times_twd_pad_27;
inout [31:0] local_times_twd_pad_26;
inout [31:0] local_times_twd_pad_25;
inout [31:0] local_times_twd_pad_24;
inout [31:0] local_times_twd_pad_23;
inout [31:0] local_times_twd_pad_22;
inout [31:0] local_times_twd_pad_21;
inout [31:0] local_times_twd_pad_20;
inout [31:0] local_times_twd_pad_19;
inout [31:0] local_times_twd_pad_18;
inout [31:0] local_times_twd_pad_17;
inout [31:0] local_times_twd_pad_16;
inout [31:0] local_times_twd_pad_15;
inout [31:0] local_times_twd_pad_14;
inout [31:0] local_times_twd_pad_13;
inout [31:0] local_times_twd_pad_12;
inout [31:0] local_times_twd_pad_11;
inout [31:0] local_times_twd_pad_10;
inout [31:0] local_times_twd_pad_9;
inout [31:0] local_times_twd_pad_8;
inout [31:0] local_times_twd_pad_7;
inout [31:0] local_times_twd_pad_6;
inout [31:0] local_times_twd_pad_5;
inout [31:0] local_times_twd_pad_4;
inout [31:0] local_times_twd_pad_3;
inout [31:0] local_times_twd_pad_2;
inout [31:0] local_times_twd_pad_1;
inout [31:0] local_times_twd_pad_0;
inout [31:0] local_times_tpr_pclk_pad_0;
inout [31:0] local_times_tpr_pclk_pad_1;
inout [31:0] local_times_tpr_pclk_pad_x;
inout [31:0] local_times_tpr_pclk_pad_z;
inout [31:0] local_times_tld_pad_31;
inout [31:0] local_times_tld_pad_30;
inout [31:0] local_times_tld_pad_29;
inout [31:0] local_times_tld_pad_28;
inout [31:0] local_times_tld_pad_27;
inout [31:0] local_times_tld_pad_26;
inout [31:0] local_times_tld_pad_25;
inout [31:0] local_times_tld_pad_24;
inout [31:0] local_times_tld_pad_23;
inout [31:0] local_times_tld_pad_22;
inout [31:0] local_times_tld_pad_21;
inout [31:0] local_times_tld_pad_20;
inout [31:0] local_times_tld_pad_19;
inout [31:0] local_times_tld_pad_18;
inout [31:0] local_times_tld_pad_17;
inout [31:0] local_times_tld_pad_16;
inout [31:0] local_times_tld_pad_15;
inout [31:0] local_times_tld_pad_14;
inout [31:0] local_times_tld_pad_13;
inout [31:0] local_times_tld_pad_12;
inout [31:0] local_times_tld_pad_11;
inout [31:0] local_times_tld_pad_10;
inout [31:0] local_times_tld_pad_9;
inout [31:0] local_times_tld_pad_8;
inout [31:0] local_times_tld_pad_7;
inout [31:0] local_times_tld_pad_6;
inout [31:0] local_times_tld_pad_5;
inout [31:0] local_times_tld_pad_4;
inout [31:0] local_times_tld_pad_3;
inout [31:0] local_times_tld_pad_2;
inout [31:0] local_times_tld_pad_1;
inout [31:0] local_times_tld_pad_0;
inout [31:0] local_times_trs_pcxbenn_pclk;
inout [31:0] local_times_trh_pcxbenn_pclk;
inout [31:0] local_times_twd_pcxbenn_3;
inout [31:0] local_times_twd_pcxbenn_2;
inout [31:0] local_times_twd_pcxbenn_1;
inout [31:0] local_times_twd_pcxbenn_0;
inout [31:0] local_times_trs_ppar_pclk;
inout [31:0] local_times_trh_ppar_pclk;
inout [31:0] local_times_twd_ppar;
inout [31:0] local_times_tpr_pclk_ppar_0;
inout [31:0] local_times_tpr_pclk_ppar_1;
inout [31:0] local_times_tpr_pclk_ppar_x;
inout [31:0] local_times_tpr_pclk_ppar_z;
inout [31:0] local_times_tld_ppar;
inout [31:0] local_times_trs_pframenn_pclk;
inout [31:0] local_times_trh_pframenn_pclk;
inout [31:0] local_times_twd_pframenn;
inout [31:0] local_times_trs_ptrdynn_pclk;
inout [31:0] local_times_trh_ptrdynn_pclk;
inout [31:0] local_times_twd_ptrdynn;
inout [31:0] local_times_tpr_pclk_ptrdynn_0;
inout [31:0] local_times_tpr_pclk_ptrdynn_1;
inout [31:0] local_times_tpr_pclk_ptrdynn_x;
inout [31:0] local_times_tpr_pclk_ptrdynn_z;
inout [31:0] local_times_tld_ptrdynn;
inout [31:0] local_times_trs_pirdynn_pclk;
inout [31:0] local_times_trh_pirdynn_pclk;
inout [31:0] local_times_twd_pirdynn;
inout [31:0] local_times_trs_pstopnn_pclk;
inout [31:0] local_times_trh_pstopnn_pclk;
inout [31:0] local_times_twd_pstopnn;
inout [31:0] local_times_tpr_pclk_pstopnn_0;
inout [31:0] local_times_tpr_pclk_pstopnn_1;
inout [31:0] local_times_tpr_pclk_pstopnn_x;
inout [31:0] local_times_tpr_pclk_pstopnn_z;
inout [31:0] local_times_tld_pstopnn;
inout [31:0] local_times_tpr_pclk_pdevselnn_0;
inout [31:0] local_times_tpr_pclk_pdevselnn_1;
inout [31:0] local_times_tpr_pclk_pdevselnn_x;
inout [31:0] local_times_tpr_pclk_pdevselnn_z;
inout [31:0] local_times_tld_pdevselnn;
inout [31:0] local_times_trs_pidsel_pclk;
inout [31:0] local_times_trh_pidsel_pclk;
inout [31:0] local_times_twd_pidsel;
inout [31:0] local_times_trs_psbonn_pclk;
inout [31:0] local_times_trh_psbonn_pclk;
inout [31:0] local_times_twd_psbonn;
inout [31:0] local_times_trs_psdone_pclk;
inout [31:0] local_times_trh_psdone_pclk;
inout [31:0] local_times_twd_psdone;
inout [31:0] local_times_tcy_min_pclk;
inout [31:0] local_times_tcy_max_pclk;
inout [31:0] local_times_tpwh_min_pclk;
inout [31:0] local_times_tpwh_max_pclk;
inout [31:0] local_times_tpwl_min_pclk;
inout [31:0] local_times_tpwl_max_pclk;
inout [31:0] local_times_twd_pclk;
inout [31:0] local_times_tcy_min_prstnn;
inout [31:0] local_times_tcy_max_prstnn;
inout [31:0] local_times_tpwh_min_prstnn;
inout [31:0] local_times_tpwh_max_prstnn;
inout [31:0] local_times_tpwl_min_prstnn;
inout [31:0] local_times_tpwl_max_prstnn;
inout [31:0] local_times_twd_prstnn;
inout [31:0] local_times_trs_pd_pclk;
inout [31:0] local_times_trh_pd_pclk;
inout [31:0] local_times_twd_pd_63;
inout [31:0] local_times_twd_pd_62;
inout [31:0] local_times_twd_pd_61;
inout [31:0] local_times_twd_pd_60;
inout [31:0] local_times_twd_pd_59;
inout [31:0] local_times_twd_pd_58;
inout [31:0] local_times_twd_pd_57;
inout [31:0] local_times_twd_pd_56;
inout [31:0] local_times_twd_pd_55;
inout [31:0] local_times_twd_pd_54;
inout [31:0] local_times_twd_pd_53;
inout [31:0] local_times_twd_pd_52;
inout [31:0] local_times_twd_pd_51;
inout [31:0] local_times_twd_pd_50;
inout [31:0] local_times_twd_pd_49;
inout [31:0] local_times_twd_pd_48;
inout [31:0] local_times_twd_pd_47;
inout [31:0] local_times_twd_pd_46;
inout [31:0] local_times_twd_pd_45;
inout [31:0] local_times_twd_pd_44;
inout [31:0] local_times_twd_pd_43;
inout [31:0] local_times_twd_pd_42;
inout [31:0] local_times_twd_pd_41;
inout [31:0] local_times_twd_pd_40;
inout [31:0] local_times_twd_pd_39;
inout [31:0] local_times_twd_pd_38;
inout [31:0] local_times_twd_pd_37;
inout [31:0] local_times_twd_pd_36;
inout [31:0] local_times_twd_pd_35;
inout [31:0] local_times_twd_pd_34;
inout [31:0] local_times_twd_pd_33;
inout [31:0] local_times_twd_pd_32;
inout [31:0] local_times_tpr_pclk_pd_0;
inout [31:0] local_times_tpr_pclk_pd_1;
inout [31:0] local_times_tpr_pclk_pd_x;
inout [31:0] local_times_tpr_pclk_pd_z;
inout [31:0] local_times_tld_pd_63;
inout [31:0] local_times_tld_pd_62;
inout [31:0] local_times_tld_pd_61;
inout [31:0] local_times_tld_pd_60;
inout [31:0] local_times_tld_pd_59;
inout [31:0] local_times_tld_pd_58;
inout [31:0] local_times_tld_pd_57;
inout [31:0] local_times_tld_pd_56;
inout [31:0] local_times_tld_pd_55;
inout [31:0] local_times_tld_pd_54;
inout [31:0] local_times_tld_pd_53;
inout [31:0] local_times_tld_pd_52;
inout [31:0] local_times_tld_pd_51;
inout [31:0] local_times_tld_pd_50;
inout [31:0] local_times_tld_pd_49;
inout [31:0] local_times_tld_pd_48;
inout [31:0] local_times_tld_pd_47;
inout [31:0] local_times_tld_pd_46;
inout [31:0] local_times_tld_pd_45;
inout [31:0] local_times_tld_pd_44;
inout [31:0] local_times_tld_pd_43;
inout [31:0] local_times_tld_pd_42;
inout [31:0] local_times_tld_pd_41;
inout [31:0] local_times_tld_pd_40;
inout [31:0] local_times_tld_pd_39;
inout [31:0] local_times_tld_pd_38;
inout [31:0] local_times_tld_pd_37;
inout [31:0] local_times_tld_pd_36;
inout [31:0] local_times_tld_pd_35;
inout [31:0] local_times_tld_pd_34;
inout [31:0] local_times_tld_pd_33;
inout [31:0] local_times_tld_pd_32;
inout [31:0] local_times_trs_pbenn_pclk;
inout [31:0] local_times_trh_pbenn_pclk;
inout [31:0] local_times_twd_pbenn_7;
inout [31:0] local_times_twd_pbenn_6;
inout [31:0] local_times_twd_pbenn_5;
inout [31:0] local_times_twd_pbenn_4;
inout [31:0] local_times_trs_ppar64_pclk;
inout [31:0] local_times_trh_ppar64_pclk;
inout [31:0] local_times_twd_ppar64;
inout [31:0] local_times_tpr_pclk_ppar64_0;
inout [31:0] local_times_tpr_pclk_ppar64_1;
inout [31:0] local_times_tpr_pclk_ppar64_x;
inout [31:0] local_times_tpr_pclk_ppar64_z;
inout [31:0] local_times_tld_ppar64;
inout [31:0] local_times_trs_preq64nn_pclk;
inout [31:0] local_times_trh_preq64nn_pclk;
inout [31:0] local_times_twd_preq64nn;
inout [31:0] local_times_tpr_pclk_pack64nn_0;
inout [31:0] local_times_tpr_pclk_pack64nn_1;
inout [31:0] local_times_tpr_pclk_pack64nn_x;
inout [31:0] local_times_tpr_pclk_pack64nn_z;
inout [31:0] local_times_tld_pack64nn;
inout [31:0] local_times_trs_plocknn_pclk;
inout [31:0] local_times_trh_plocknn_pclk;
inout [31:0] local_times_twd_plocknn;
inout [31:0] local_times_tpr_pclk_pperrnn_0;
inout [31:0] local_times_tpr_pclk_pperrnn_1;
inout [31:0] local_times_tpr_pclk_pperrnn_x;
inout [31:0] local_times_tpr_pclk_pperrnn_z;
inout [31:0] local_times_tld_pperrnn;
inout [31:0] local_times_tpr_pclk_pserrnn_0;
inout [31:0] local_times_tpr_pclk_pserrnn_1;
inout [31:0] local_times_tpr_pclk_pserrnn_x;
inout [31:0] local_times_tpr_pclk_pserrnn_z;
inout [31:0] local_times_tld_pserrnn;
inout [31:0] local_times_tpd_prstnn_pad_0;
inout [31:0] local_times_tpd_prstnn_pad_1;
inout [31:0] local_times_tpd_prstnn_pad_x;
inout [31:0] local_times_tpd_prstnn_pad_z;
inout [31:0] local_times_tpd_prstnn_ppar_0;
inout [31:0] local_times_tpd_prstnn_ppar_1;
inout [31:0] local_times_tpd_prstnn_ppar_x;
inout [31:0] local_times_tpd_prstnn_ppar_z;
inout [31:0] local_times_tpd_prstnn_ptrdynn_0;
inout [31:0] local_times_tpd_prstnn_ptrdynn_1;
inout [31:0] local_times_tpd_prstnn_ptrdynn_x;
inout [31:0] local_times_tpd_prstnn_ptrdynn_z;
inout [31:0] local_times_tpd_prstnn_pstopnn_0;
inout [31:0] local_times_tpd_prstnn_pstopnn_1;
inout [31:0] local_times_tpd_prstnn_pstopnn_x;
inout [31:0] local_times_tpd_prstnn_pstopnn_z;
inout [31:0] local_times_tpd_prstnn_pdevselnn_0;
inout [31:0] local_times_tpd_prstnn_pdevselnn_1;
inout [31:0] local_times_tpd_prstnn_pdevselnn_x;
inout [31:0] local_times_tpd_prstnn_pdevselnn_z;
inout [31:0] local_times_tpd_prstnn_pd_0;
inout [31:0] local_times_tpd_prstnn_pd_1;
inout [31:0] local_times_tpd_prstnn_pd_x;
inout [31:0] local_times_tpd_prstnn_pd_z;
inout [31:0] local_times_tpd_prstnn_ppar64_0;
inout [31:0] local_times_tpd_prstnn_ppar64_1;
inout [31:0] local_times_tpd_prstnn_ppar64_x;
inout [31:0] local_times_tpd_prstnn_ppar64_z;
inout [31:0] local_times_tpd_prstnn_pack64nn_0;
inout [31:0] local_times_tpd_prstnn_pack64nn_1;
inout [31:0] local_times_tpd_prstnn_pack64nn_x;
inout [31:0] local_times_tpd_prstnn_pack64nn_z;
inout [31:0] local_times_tpd_prstnn_pperrnn_0;
inout [31:0] local_times_tpd_prstnn_pperrnn_1;
inout [31:0] local_times_tpd_prstnn_pperrnn_x;
inout [31:0] local_times_tpd_prstnn_pperrnn_z;
inout [31:0] local_times_tpd_prstnn_pserrnn_0;
inout [31:0] local_times_tpd_prstnn_pserrnn_1;
inout [31:0] local_times_tpd_prstnn_pserrnn_x;
inout [31:0] local_times_tpd_prstnn_pserrnn_z;
input [31:0] local_flags_option;
input local_flags_annotated;
input [31:0] local_flags_vlt;
input [31:0] local_flags_tmp;
input [31:0] local_flags_DF;
input [1:20*8] version;
integer KV, KT, KU, derating, i, zz;
reg [1:20*8] cversion;
begin
cversion = lmcver.tolower(version);
zz = 1;
// Calculate the Derating factors
KT = calc_curve(local_flags_tmp/3,0,0,100);
KV = calc_curve(local_flags_vlt/50,0,0,100);
KU = local_flags_DF;
derating = (KT*KV*KU)/10000;
if (derating < 10) begin
$display("WARNING at time %0t from %m",$time);
$display(" \"Derating factor is less than 10.\"");
end
// SELECT SIMULATION TIMING DELAY VALUES
case (cversion)
"pci33" : begin
case (local_flags_option)
`lmv_maximum : begin
local_times_trs_pad_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pad_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_pad_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pad_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pad_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pad_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_pcxbenn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pcxbenn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_ppar_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_ppar_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_ppar_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_pframenn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pframenn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_ptrdynn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trh_ptrdynn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_ptrdynn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ptrdynn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ptrdynn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ptrdynn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_pirdynn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pirdynn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_pstopnn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trh_pstopnn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_pstopnn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pstopnn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pstopnn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pstopnn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pdevselnn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pdevselnn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pdevselnn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pdevselnn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_pidsel_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pidsel_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_psbonn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_psbonn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_psdone_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_psdone_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tcy_min_pclk = 30.000*`time_scale_multiplier*zz;
local_times_tcy_max_pclk = 125.000*`time_scale_multiplier*zz;
local_times_tpwh_min_pclk = 11.000*`time_scale_multiplier*zz;
local_times_tpwh_max_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpwl_min_pclk = 11.000*`time_scale_multiplier*zz;
local_times_tpwl_max_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tcy_min_prstnn = 0.000*`time_scale_multiplier*zz;
local_times_tcy_max_prstnn = 0.000*`time_scale_multiplier*zz;
local_times_tpwh_min_prstnn = 0.000*`time_scale_multiplier*zz;
local_times_tpwh_max_prstnn = 0.000*`time_scale_multiplier*zz;
local_times_tpwl_min_prstnn = 1000000.000*`time_scale_multiplier*zz;
local_times_tpwl_max_prstnn = 0.000*`time_scale_multiplier*zz;
local_times_trs_pd_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pd_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_pd_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pd_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pd_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pd_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_pbenn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_pbenn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_trs_ppar64_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_ppar64_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_ppar64_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar64_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar64_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_ppar64_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_preq64nn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_preq64nn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_pack64nn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pack64nn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pack64nn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pack64nn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_trs_plocknn_pclk = 7.000*`time_scale_multiplier*zz;
local_times_trh_plocknn_pclk = 0.000*`time_scale_multiplier*zz;
local_times_tpr_pclk_pperrnn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pperrnn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pperrnn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pperrnn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pserrnn_z = 28.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pserrnn_x = 2.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pserrnn_0 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpr_pclk_pserrnn_1 = 11.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pad_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pad_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pad_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pad_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ptrdynn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ptrdynn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ptrdynn_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ptrdynn_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pstopnn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pstopnn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pstopnn_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pstopnn_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pdevselnn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pdevselnn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pdevselnn_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pdevselnn_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pd_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pd_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pd_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pd_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar64_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar64_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar64_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_ppar64_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pack64nn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pack64nn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pack64nn_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pack64nn_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pperrnn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pperrnn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pperrnn_0 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pperrnn_1 = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pserrnn_z = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pserrnn_x = 40.000*`time_scale_multiplier * derating / 100;
local_times_tpd_prstnn_pserrnn_0 = 40.000*`time_scale_multiplier * derating / 100;
This page: |
Created: | Thu Aug 19 11:57:49 1999 |
| From: |
../../../sparc_v8/system/lmc/rtl/pcislave_timing.v
|