Skip to content

Commit 7f36519

Browse files
committed
local_bitvector_analysist::merge: use bitwise or
This avoids a jump. On a goto function of 160822 instructions, the total time required by local bitvector analysis decreases from 72 seconds to 65 seconds (averaged over three runs, the difference between the slowest and longest run is below 0.2 seconds).
1 parent bde5c49 commit 7f36519

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/analyses/local_bitvector_analysis.cpp

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,7 @@ bool local_bitvector_analysist::merge(points_tot &a, points_tot &b)
4545
std::max(a.size(), b.size());
4646

4747
for(std::size_t i=0; i<max_index; i++)
48-
{
49-
if(a[i].merge(b[i]))
50-
result=true;
51-
}
48+
result |= a[i].merge(b[i]);
5249

5350
return result;
5451
}

0 commit comments

Comments
 (0)