Commit 942db516 authored by Christian Fibich's avatar Christian Fibich Committed by Stefan Tauner
Browse files

Changes according to PR review

parent cae09848
......@@ -31,8 +31,8 @@ use warnings;
use constant DEFAULT_TIMER_VALUE => 1000000;
my @synthesis_modes = qw(AUTO OPTIMIZATION_OFF FIX_PLACEMENT);
use constant SYNTHESIS_MODES => \@synthesis_modes;
my @optimization_settings = qw(ALLOW OPTIMIZATION_OFF FIX_PLACEMENT);
use constant OPTIMIZATION_SETTINGS => \@optimization_settings;
#** @var public %designmap Hash containing all FIJI::Settings
......@@ -137,6 +137,15 @@ BEGIN {
unit => 'bps',
group => 'general_control',
order => 10,
depends_on => "FREQUENCY",
values => sub {
my ($baud, $old, $fclk) = @_;
if (defined $fclk) {
return $baud < $fclk;
} else {
return 1;
}
}
},
ID => {
description => "Design ID",
......@@ -180,9 +189,11 @@ BEGIN {
ini_name => "LFSR_POLY",
default => 0x2D,
type => 'hexadecimal',
depends_on => 'LFSR_WIDTH',
values => sub {
my $val = shift; # @FIXME: depends on LFSR_WIDTH
return $val > 0 && $val <= (2**64 - 1);
my ($val, $old, $top) = @_;
$top = 64 if !defined $top;
return $val > 0 && $val <= (2**($top) - 1);
},
group => 'lfsr',
order => 20,
......@@ -193,9 +204,11 @@ BEGIN {
ini_name => "LFSR_SEED",
default => 0xCAFE,
type => 'hexadecimal',
depends_on => 'LFSR_WIDTH',
values => sub {
my $val = shift; # @FIXME: depends on LFSR_WIDTH
return $val >= 0 && $val <= (2**64 - 1);
my ($val, $old, $top) = @_;
$top = 64 if !defined $top;
return $val > 0 && $val <= (2**($top) - 1);
},
group => 'lfsr',
order => 30,
......@@ -323,15 +336,7 @@ BEGIN {
group => 'trigger',
order => 10,
},
TRIGGER_DUT_NAME => {
description => "Source net for DUT-to-FIJI trigger",
help => "Select the net in the DUT which shall be used to trigger fault injection operations.",
ini_name => "TRIGGER_DUT_NAME",
depends_on => 'TRIGGER_DUT_EN',
type => 'net',
group => 'trigger',
order => 20,
},
TRIGGER_DUT_ACTIVE => {
description => "Active level for DUT-to-FIJI trigger",
ini_name => "TRIGGER_DUT_ACTIVE",
......@@ -341,6 +346,16 @@ BEGIN {
default => '1',
depends_on => 'TRIGGER_DUT_EN',
group => 'trigger',
order => 20,
},
TRIGGER_DUT_NAME => {
description => "Source net for DUT-to-FIJI trigger",
help => "Select the net in the DUT which shall be used to trigger fault injection operations.",
ini_name => "TRIGGER_DUT_NAME",
depends_on => 'TRIGGER_DUT_EN',
type => 'net',
group => 'trigger',
order => 30,
},
......@@ -435,7 +450,7 @@ BEGIN {
},
RX_IN_NAME => {
description => "RX port name",
help => "Specify the name of the Host-to-FIC serial RX port in the wrapper.",
help => "Specify the name of the Host-to-FIJI serial RX port in the wrapper.",
ini_name => "RX_IN_NAME",
type => "external_port",
default => "s_fiji_rx_i",
......@@ -445,7 +460,7 @@ BEGIN {
},
TX_OUT_NAME => {
description => "TX port name",
help => "Specify the name of the FIC-to-Host serial TX port in the wrapper.",
help => "Specify the name of the FIJI-to-Host serial TX port in the wrapper.",
ini_name => "TX_OUT_NAME",
type => "external_port",
phases_opt => [qw(instrument download)],
......@@ -453,17 +468,39 @@ BEGIN {
group => "general_control",
order => 40,
},
SYNTHESIS_MODE => {
description => "Synthesis mode",
OPTIMIZATIONS => {
description => "Optimizations",
help => "Specifies which set of constraints to use in synthesis/P&R to\n- prevent optimizations and/or\n- fix physical placement.",
ini_name => "SYNTHESIS_MODE",
ini_name => "OPTIMIZATIONS",
type => "dropdown",
values => \@synthesis_modes,
values => \@optimization_settings,
default => "AUTO",
phases_opt => [qw(setup instrument download)],
phases_opt => [qw(setup)],
group => "general_control",
order => 50,
},
SYNTHESIS_TOOL => {
description => "Synthesis Tool",
help => "The FPGA synthesis tool that will be used. Needed for generating appropriate constraints.",
ini_name => "SYNTHESIS_TOOL",
type => "dropdown",
values => ["SYNPLIFY_PRO"],
default => "SYNPLIFY_PRO",
phases_opt => [qw(setup)],
group => "general_control",
order => 60,
},
IMPLEMENTATION_TOOL => {
description => "Implementation Tool",
help => "The FPGA implementation tool that will be used. Needed for generating appropriate constraints.",
ini_name => "IMPLEMENTATION_TOOL",
type => "dropdown",
values => ["ALTERA_QUARTUS"],
default => "ALTERA_QUARTUS",
phases_opt => [qw(setup)],
group => "general_control",
order => 70,
},
);
}
......@@ -494,13 +531,13 @@ BEGIN {
order => 70,
},
reset_to_dut => {
title => "Reset from FIC to DUT",
title => "Reset from FIJI to DUT",
subtitle => "",
description => "Settings concerning FIJI's ability to reset the DUT",
order => 60,
},
reset_from_dut => {
title => "Reset from DUT to FIC",
title => "Reset from DUT to FIJI",
subtitle => "",
description => "Settings concerning FIJI's internal (from DUT) reset feature",
order => 50,
......@@ -711,6 +748,7 @@ BEGIN {
gui_modes => [qw (random)],
type => "min_duration",
matching => "MAX_DURATION_T1",
unit => "cycles",
order => 20,
},
MIN_DURATION_T2 => {
......@@ -721,32 +759,35 @@ BEGIN {
gui_modes => [qw (random)],
type => "min_duration",
matching => "MAX_DURATION_T2",
unit => "cycles",
order => 40,
},
MAX_DURATION_T1 => {
description => "Maximum Duration T1",
ini_name => "MAX_DURATION_T1",
default => DEFAULT_TIMER_VALUE,
default => (10*DEFAULT_TIMER_VALUE),
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
type => "max_duration",
matching => "MIN_DURATION_T1",
unit => "cycles",
order => 30,
},
MAX_DURATION_T2 => {
description => "Maximum Duration T2",
ini_name => "MAX_DURATION_T2",
default => DEFAULT_TIMER_VALUE,
default => (10*DEFAULT_TIMER_VALUE),
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
type => "max_duration",
matching => "MIN_DURATION_T2",
unit => "cycles",
order => 50,
},
PROB_STUCK_AT_0 => {
description => "Probability of stuck-at-0 fault",
ini_name => "PROB_STUCK_AT_0",
default => 0,
default => 0.1,
type => 'prob',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
......@@ -756,7 +797,7 @@ BEGIN {
PROB_STUCK_AT_1 => {
description => "Probability of stuck-at-1 fault",
ini_name => "PROB_STUCK_AT_1",
default => 0,
default => 0.1,
type => 'prob',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
......@@ -766,7 +807,7 @@ BEGIN {
PROB_DELAY => {
description => "Probability of delay fault",
ini_name => "PROB_DELAY",
default => 0,
default => 0.1,
type => 'prob',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
......@@ -776,7 +817,7 @@ BEGIN {
PROB_SEU => {
description => "Probability of single event upset",
ini_name => "PROB_SEU",
default => 0,
default => 0.1,
type => 'prob',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
......@@ -786,13 +827,33 @@ BEGIN {
PROB_STUCK_OPEN => {
description => "Probability of stuck-open fault",
ini_name => "PROB_STUCK_OPEN",
default => 0,
default => 0.1,
type => 'prob',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
fault => "STUCK_OPEN",
order => 110,
},
INITIAL_RESET => {
description => "Initial test: Apply FIJI-to-DUT reset?",
ini_name => "INITIAL_RESET",
default => 0,
type => 'boolean',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
order => 15,
},
INITIAL_TRIGGER => {
description => "Initial test: Wait for trigger?",
ini_name => "INITIAL_TRIGGER",
default => 'NONE',
values => [qw(INT EXT NONE)],
type => 'dropdown',
phases_opt => [qw(manual auto)],
gui_modes => [qw (random)],
order => 16,
},
);
}
use constant \%testconstmap;
......@@ -888,7 +949,7 @@ sub REVERSE_FIU_ENUM {
return "NONE";
}
use constant {HOST_TO_FIC_LATENCY => 1.0e-3}; # 1 ms minimum latency
use constant {HOST_TO_FIJI_LATENCY => 1.0e-3}; # 1 ms minimum latency
## @function ini2constkey ($ini_name, %$map_ref)
#
......@@ -912,7 +973,7 @@ sub ini2constkey {
use base 'Exporter';
our @EXPORT = (keys(%designmap), keys(%fiumap), keys(%testpatmap), keys(%testconstmap), keys(%fiuenum), keys(%displaygroups), keys(%testguimodes));
our @EXPORT_OK = (keys(%designmap), 'DESIGNMAP', keys(%fiumap), 'FIUMAP', keys(%testpatmap), 'TESTPATMAP', keys(%testconstmap), 'TESTCONSTMAP', keys(%fiuenum), 'FIUENUM', 'REVERSE_FIU_ENUM', 'DISPLAYGROUPS', keys(%displaygroups), 'TESTGUIMODES', keys(%testguimodes), 'HOST_TO_FIC_LATENCY', 'DEFAULT_TIMER_VALUE', 'SYNTHESIS_MODES');
our @EXPORT_OK = (keys(%designmap), 'DESIGNMAP', keys(%fiumap), 'FIUMAP', keys(%testpatmap), 'TESTPATMAP', keys(%testconstmap), 'TESTCONSTMAP', keys(%fiuenum), 'FIUENUM', 'REVERSE_FIU_ENUM', 'DISPLAYGROUPS', keys(%displaygroups), 'TESTGUIMODES', keys(%testguimodes), 'HOST_TO_FIJI_LATENCY', 'DEFAULT_TIMER_VALUE', 'OPTIMIZATIONS');
## @var @EXPORT_TAGS Export Tags
#
......
......@@ -461,6 +461,29 @@ sub _send_bitstream {
value => $$str_ref
}
);
# CTS timeout
if($port->handshake eq "rts") {
my $bits=Device::SerialPort::Bits::get_hash();
my $IOCTL_VALUE_CTS = pack('L', $bits->{'TIOCM_CTS'} || 0);
my $t = 0;
my $s;
do {
my $status = pack('i',0);
$port->ioctl('TIOCMGET', \$status);
$s = unpack('i',$status);
usleep(100);
$t++;
} while (($s & $bits->{'TIOCM_CTS'}) == 0 && $t < 10);
if($t == 10) {
$logger->warn("CTS timeout.");
return 0;
}
}
my $wrn = $port->write($str);
if (!defined($wrn)) {
$wrn = 0;
......
......@@ -183,7 +183,7 @@ END_LOCK
$txt .= $no_optimization;
} elsif ($cfg->{'mode'} eq "FIX_PLACEMENT") {
$txt .= $no_optimization . $area;
} elsif ($cfg->{'mode'} ne "AUTO") {
} elsif ($cfg->{'mode'} ne "ALLOW") {
$logger->error("Unknown SYNTHESIS_MODE ".$cfg->{'mode'});
return undef;
}
......@@ -192,9 +192,9 @@ END_LOCK
## @var %$toolhash stores which sub to execute for which tool
my $toolhash = {
synplify_pro => {
quartus => \&_synplify_quartus_optimization_physical,
xise => \&_synplify_xise_optimization_physical,
SYNPLIFY_PRO => {
ALTERA_QUARTUS => \&_synplify_quartus_optimization_physical,
XILINX_ISE => \&_synplify_xise_optimization_physical,
},
};
......
......@@ -272,7 +272,7 @@ sub download_random ($$$;$) {
my $cont;
do {
my $temp_test = $self->{'fiji_tests'}->make_random_test($self->{'fiji_settings'});
my $temp_test = $self->{'fiji_tests'}->make_random_test($self->{'fiji_settings'},($ti == 0));
return $temp_test if (!ref($temp_test));
$tests[$ti] = $temp_test;
$logger->info("=== Test $ti ===");
......
......@@ -372,12 +372,13 @@ sub validate_fiu_value {
# \param map_ref reference to FIJI Settings mappings
# \param k key identifying the respective setting
# \param v_ref scalar reference to the proposed value (that may be modified)
# \param dep_ref scalar reference to a value the proposed value depends on
# \param old (optional) previously valid value
# \param log_func (optional) the (log4perl) log function to use
# (defaul is \&Log::Log4perl::Logger::trace)
sub validate_value ($$$;$$) {
my $logger = get_logger("");
my ($map_ref, $k, $v_ref, $old, $log_func) = @_;
my ($map_ref, $k, $v_ref, $dep_ref, $old, $log_func) = @_;
$log_func = \&Log::Log4perl::Logger::trace if !defined($log_func);
if (defined($map_ref->{$k}->{'type'})) {
my $orig = ${$v_ref};
......@@ -447,6 +448,11 @@ sub validate_value ($$$;$$) {
if (defined($map_ref->{$k}->{'values'})) {
my $values_ref = $map_ref->{$k}->{'values'};
my $dep_val;
if (ref $dep_ref eq 'SCALAR') {
$dep_val = $dep_ref;
}
if (ref($values_ref) eq 'ARRAY') {
# Look for given value in allowed values
......@@ -455,7 +461,7 @@ sub validate_value ($$$;$$) {
return 0;
}
} elsif (ref($values_ref) eq 'CODE') {
if (!$values_ref->(${$v_ref}, $old)) {
if (!$values_ref->(${$v_ref}, $old, $$dep_val)) {
$log_func->($logger, "$k: ${$v_ref} is not allowed.");
return 0;
}
......
......@@ -989,7 +989,7 @@ END_RST
# - 'FIU_(1...m)_FAULT_(1...n)' fault configuration for the respective FIU in the respective phase
#
sub make_random_test {
my ($self, $global_settings_ref) = @_;
my ($self, $global_settings_ref, $is_initial) = @_;
my $msg;
my $test = {};
......@@ -1007,8 +1007,13 @@ sub make_random_test {
}
}
$test->{'RESET_DUT_AFTER_CONFIG'} = 0;
$test->{'TRIGGER'} = "NONE";
if (defined $is_initial && $is_initial) {
$test->{'RESET_DUT_AFTER_CONFIG'} = $self->{'design'}->{'INITIAL_RESET'};
$test->{'TRIGGER'} = $self->{'design'}->{'INITIAL_TRIGGER'};
} else {
$test->{'RESET_DUT_AFTER_CONFIG'} = 0;
$test->{'TRIGGER'} = "NONE";
}
for (my $pi = 1 ; $pi <= $global_settings_ref->{'design'}->{'CFGS_PER_MSG'} ; $pi++) {
$test->{"TIMER_VALUE_${pi}"} = int(rand($self->{'design'}->{'MAX_DURATION_T' . $pi} - $self->{'design'}->{'MIN_DURATION_T' . $pi}) + $self->{'design'}->{'MIN_DURATION_T' . $pi});
......
......@@ -138,7 +138,7 @@ sub _draw() {
DUT_BASE_X + DUT_WIDTH, DUT_BASE_Y + DUT_HEIGHT, -fill => "grey"
),
text => $self->createText(DUT_BASE_X + DUT_WIDTH / 2, DUT_BASE_Y + DUT_HEIGHT / 2, -text => "Instrumented\nNetlist Under Test", -justify => "center"),
text => $self->createText(DUT_BASE_X + DUT_WIDTH / 2, DUT_BASE_Y + DUT_HEIGHT / 2, -text => "Instrumented\nNetlist of DUT", -justify => "center"),
input => $self->createLine(
DUT_BASE_X + 0.5 * DUT_WIDTH - 5, DUT_BASE_Y + DUT_HEIGHT,
......
......@@ -112,12 +112,6 @@ sub Populate {
$image = $self->Photo(-file => File::Spec->catpath($vol, File::Spec->catdir($basedir, "..", "lib"), 'delete_48x48.xpm'), -format => 'XPM');
}
sub set_state_as_original {
my $self = shift;
$self->{'original_settings'} = clone($self->{'settings'});
$self->{'original_settings'}->{'fius'} = clone($self->{'settings'}->{'fius'});
${$self->{'change_indicator_ref'}} = $self->{'change_indicator_values'}->{'unchanged'};
}
sub netlist {
my $logger = get_logger("");
......@@ -593,13 +587,14 @@ sub _populate_widget {
$entry = $config_frame->Optionmenu(
'-options' => DESIGNMAP->{$k}->{'values'},
'-textvariable' => \$self->{'settings'}->{'design'}->{$k},
'-width' => -1,
# '-width' =>
'-anchor' => 'w',
'-justify' => 'left'
);
$entry->grid(
-row => $row,
-column => 2,
'-sticky' => 'w'
'-sticky' => 'ew',
);
} elsif (defined($type) && ($type eq 'dir' || $type eq 'file')) {
......@@ -1272,7 +1267,14 @@ sub _validate_fiu_entry {
sub _validate_entry {
my ($map, $self, $widget, $name, $old_ref, $new_ref, $diff, $old_str, $char_idx, $brokentype) = @_;
my $ok = FIJI::Settings::validate_value($map, $name, $new_ref, $$old_ref);
my $dep_ref;
if (defined($map->{$name}->{'depends_on'})) {
$dep_ref = \$self->{'settings'}->{'design'}->{$map->{$name}->{'depends_on'}};
}
my $ok = FIJI::Settings::validate_value($map, $name, $new_ref, $dep_ref, $$old_ref);
_highlight_widget($widget, (!$ok));
# The following line is needed to re-enable validation IFF the value is
......@@ -1304,6 +1306,14 @@ sub _highlight_widget ($$) {
}
}
sub set_state_as_original {
my $self = shift;
$self->{'original_settings'} = clone($self->{'settings'});
$self->{'original_settings'}->{'fius'} = clone($self->{'settings'}->{'fius'});
${$self->{'change_indicator_ref'}} = $self->{'change_indicator_values'}->{'unchanged'};
}
sub _check_change {
my $self = shift;
......
......@@ -122,24 +122,30 @@ sub _populate_widget ($) {
);
my $balloon = $tf->Balloon();
my $NAME_COL = 0;
my $UNIT_COL = 1;
my $VAL1_COL = 2;
my $VAL2_COL = 3;
$tf->gridColumnconfigure(1, -weight => 1);
$tf->gridColumnconfigure(2, -weight => 1);
$tf->gridColumnconfigure($VAL1_COL, -weight => 1);
$tf->gridColumnconfigure($VAL2_COL, -weight => 1);
$tf->Label(-text => "Duration t1")->grid(-column => 0, -row => 0, -sticky => "w");
$tf->Label(-text => "Duration t2")->grid(-column => 0, -row => 1, -sticky => "w");
$tf->Label(-text => "Trigger")->grid(-column => 0, -row => 2, -sticky => "w");
$tf->Label(-text => "Reset DUT after config")->grid(-column => 0, -row => 3, -sticky => "w");
$tf->Label(-text => "Duration t1")->grid(-column => $NAME_COL, -row => 0, -sticky => "w");
$tf->Label(-text => "cycles")->grid(-column => $UNIT_COL, -row => 0, -sticky => "w", -ipadx => ".5c",);
$tf->Label(-text => "Duration t2")->grid(-column => $NAME_COL, -row => 1, -sticky => "w");
$tf->Label(-text => "cycles")->grid(-column => $UNIT_COL, -row => 1, -sticky => "w", -ipadx => ".5c",);
$tf->Label(-text => "Wait for trigger?")->grid(-column => $NAME_COL, -row => 2, -sticky => "w");
$tf->Label(-text => "Reset DUT after config")->grid(-column => $NAME_COL, -row => 3, -sticky => "w");
my @to = qw(NONE INT EXT);
my $t1 = $tf->Entry(-textvariable => \$self->{'test'}->{'TIMER_VALUE_1'})->grid(-column => 1, -row => 0, -sticky => "ew", -columnspan => 1);
my $t2 = $tf->Entry(-textvariable => \$self->{'test'}->{'TIMER_VALUE_2'})->grid(-column => 1, -row => 1, -sticky => "ew", -columnspan => 1);
my $t1 = $tf->Entry(-textvariable => \$self->{'test'}->{'TIMER_VALUE_1'})->grid(-column => $VAL1_COL, -row => 0, -sticky => "ew", -columnspan => 1);
my $t2 = $tf->Entry(-textvariable => \$self->{'test'}->{'TIMER_VALUE_2'})->grid(-column => $VAL1_COL, -row => 1, -sticky => "ew", -columnspan => 1);
$widget_background = $tf->cget(-bg);
my $warn_t1 = $tf->Label(-width => 2, -borderwidth => 1)->grid(-column => 2, -row => 0, -sticky => "w", -columnspan => 1, -padx => 5);
my $warn_t2 = $tf->Label(-width => 2, -borderwidth => 1)->grid(-column => 2, -row => 1, -sticky => "w", -columnspan => 1, -padx => 5);
my $warn_t1 = $tf->Label(-width => 2, -borderwidth => 1)->grid(-column => $VAL2_COL, -row => 0, -sticky => "w", -columnspan => 1, -padx => 5);
my $warn_t2 = $tf->Label(-width => 2, -borderwidth => 1)->grid(-column => $VAL2_COL, -row => 1, -sticky => "w", -columnspan => 1, -padx => 5);
$warn_t1->configure(-text => '', -relief => "flat", -bg => $widget_background);
$warn_t2->configure(-text => '', -relief => "flat", -bg => $widget_background);
......@@ -156,14 +162,15 @@ sub _populate_widget ($) {
'-options' => \@to,
'-width' => 15,
'-variable' => \$self->{'test'}->{"TRIGGER"}
)->grid(-column => 1, -row => 2, -sticky => "w");
my $cb = $tf->Checkbutton(-variable => \$self->{'test'}->{'RESET_DUT_AFTER_CONFIG'})->grid(-column => 1, -row => 3, -sticky => "w", -columnspan => 2);
)->grid(-column => $VAL1_COL, -row => 2, -sticky => "w");
my $cb = $tf->Checkbutton(-variable => \$self->{'test'}->{'RESET_DUT_AFTER_CONFIG'})->grid(-column => $VAL1_COL, -row => 3, -sticky => "w", -columnspan => 2);
$cb->select() if ($self->{'test'}->{'RESET_DUT_AFTER_CONFIG'});
$tf->Label(-text => "FIU #")->grid(-column => 0, -row => 4, -sticky => "w");
$tf->Label(-text => "Fault 1")->grid(-column => 1, -row => 4, -sticky => "w");
$tf->Label(-text => "Fault 2")->grid(-column => 2, -row => 4, -sticky => "w");
$tf->Label(-text => "FIU #")->grid(-column => $NAME_COL, -row => 4, -sticky => "w");
$tf->Label(-text => "Fault 1")->grid(-column => $VAL1_COL, -row => 4, -sticky => "w");
$tf->Label(-text => "Fault 2")->grid(-column => $VAL2_COL, -row => 4, -sticky => "w");
my $fe_ref = FIUENUM;
......@@ -173,7 +180,7 @@ sub _populate_widget ($) {
my $ri = $fi + 5;
my $lab = $tf->Label(-text => "FIU $fi")->grid(-column => 0, -row => $ri, -sticky => "w");
my $lab = $tf->Label(-text => "FIU $fi")->grid(-column => $NAME_COL, -row => $ri, -sticky => "w");
my @optionlist;
if ($supported_model eq "RUNTIME") {
......@@ -186,13 +193,13 @@ sub _populate_widget ($) {
'-options' => \@optionlist,
'-width' => 15,
'-variable' => \$self->{'test'}->{"FIU_${fi}_FAULT_1"}
)->grid(-column => 1, -row => ($ri), -sticky => "ew");
)->grid(-column => $VAL1_COL, -row => ($ri), -sticky => "ew");
my $f2 = $tf->Optionmenu(
'-options' => \@optionlist,
'-width' => 15,
'-variable' => \$self->{'test'}->{"FIU_${fi}_FAULT_2"}
)->grid(-column => 2, -row => ($ri), -sticky => "ew");
)->grid(-column => $VAL2_COL, -row => ($ri), -sticky => "ew");
$balloon->attach($lab, -msg => @{$self->{'settings'}->{'fius'}}[$fi]->{'FIU_NET_NAME'});
$balloon->attach($f1, -msg => @{$self->{'settings'}->{'fius'}}[$fi]->{'FIU_NET_NAME'});
......@@ -230,7 +237,7 @@ sub _check_latency {
} else {
my $absolute_duration = $new / $self->{'settings'}->{'design'}->{'FREQUENCY'};
my $lat = HOST_TO_FIC_LATENCY;
my $lat = HOST_TO_FIJI_LATENCY;
if ($absolute_duration < $lat) {
$logger->warn("Duration $new (absolute: $absolute_duration) is shorter than latency ($lat).");
$balloon->attach($warn, -msg => "Duration $new (absolute: $absolute_duration sec) is shorter than latency ($lat sec).");
......
......@@ -45,6 +45,18 @@ use Tk::FIJITestFrame;
use Tk::DynaMouseWheelBind;
use base qw(Tk::Frame);
use Data::Dumper;
# Test::Deep::NoTest exports Test::Deep which exports
# an undocumented blessed() which clashes with Scalar::Util's blessed().
# see http://stackoverflow.com/a/2837016
BEGIN {
require Test::Deep;
@Test::Deep::EXPORT = grep { $_ ne 'blessed' } @Test::Deep::EXPORT;
}
use Test::Deep::NoTest;
Construct Tk::Widget 'FIJITestsViewer';
# Constants
......@@ -90,6 +102,8 @@ sub Populate {
my ($self, $args) = @_;
my $settings = delete $args->{'-settings'};
my $tests = delete $args->{'-tests'};
$self->{'change_indicator_ref'} = delete $args->{'-change_indicator_ref'};
$self->{'change_indicator_values'} = delete $args->{'-change_indicator_values'};
$self->{'worker'} = delete $args->{'-worker