Skip to content

Commit 8393d16

Browse files
committed
Hoist repeated call to transform
1 parent e61836b commit 8393d16

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

src/goto-analyzer/taint_summary.cpp

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1431,6 +1431,21 @@ taint_summary_ptrt taint_summarise_function(
14311431
taint_map_from_lvalues_to_svaluest const& src_value =
14321432
domain->at(src_instr_it);
14331433

1434+
taint_map_from_lvalues_to_svaluest const transformed =
1435+
transform(
1436+
src_value,
1437+
src_instr_it,
1438+
function_id,
1439+
functions,
1440+
database,
1441+
lvsa,
1442+
ns,
1443+
log,
1444+
children_with_summaries,
1445+
nsummary_uses,
1446+
ndistinct_summary_inputs
1447+
);
1448+
14341449
goto_programt::const_targetst successors;
14351450
fn_iter->second.body.get_successors(src_instr_it, successors);
14361451
for(auto succ_it = successors.begin();
@@ -1461,20 +1476,6 @@ taint_summary_ptrt taint_summarise_function(
14611476
taint_dump_lvalues_to_svalues_in_html(old_dst_value,ns,*log);
14621477
}
14631478

1464-
taint_map_from_lvalues_to_svaluest const transformed =
1465-
transform(
1466-
src_value,
1467-
src_instr_it,
1468-
function_id,
1469-
functions,
1470-
database,
1471-
lvsa,
1472-
ns,
1473-
log,
1474-
children_with_summaries,
1475-
nsummary_uses,
1476-
ndistinct_summary_inputs
1477-
);
14781479
dst_value = join(transformed,old_dst_value);
14791480

14801481
if (log != nullptr)

0 commit comments

Comments
 (0)