Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
German Leon
Carol-fi
Commits
b3520f72
Commit
b3520f72
authored
Dec 11, 2020
by
German Leon
Browse files
Acceso pretty_print
parent
eb2e1fbf
Changes
1
Hide whitespace changes
Inline
Side-by-side
fault_injector.py
View file @
b3520f72
...
...
@@ -565,23 +565,23 @@ def fault_injection_by_signal(**kwargs):
# FI injection time
injection_time
=
fi_toc
-
fi_tic
if
fault_injected
:
output_str
=
"THREAD:{}, FAULT NUM:{}"
.
format
(
host_thread
,
num_rounds
)
if
len
(
crash
)
==
1
:
if
len
(
crash
)
==
1
:
tmp
=
"--"
else
:
else
:
tmp
=
crash
[
1
]
row
=
[
unique_id
,
register
,
num_rounds
,
fault_model
,
thread
,
row
=
[
unique_id
,
register
,
num_rounds
,
fault_model
,
thread
,
block
,
old_val
,
new_val
,
injection_site
,
fault_injected
,
hang
,
crash
[
0
],
sdc
,
masked
,
tmp
,
injection_time
,
signal_init_time
,
bits_to_flip
,
instruction
,
user_defined_val
]
for
name
,
value
in
zip
(
header
,
row
):
output_str
+=
" {}: {},"
.
format
(
name
,
value
)
if
fault_injected
:
# output_str = "THREAD:{}, FAULT NUM:{}".format(host_thread, num_rounds)
#output_str += " {}: {},".format(name, value)
#for name, value in zip(header, row):
# :-1 to remove the last comma
cf
.
printf
(
output_str
[:
-
1
])
#
cf.printf(output_str[:-1])
with
lock
:
summary_file
.
write_row
(
row
)
num_rounds
+=
1
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment