statements from NULL to IRStmt_NoOp screwed up the how-much-to-unroll
heuristics in iropt, resulting in iropt being significantly less
enthusiastic about unrolling than it was before the change. Gaaah!
This commit should fix it.
git-svn-id: svn://svn.valgrind.org/vex/trunk@1118
Int n_stmts, i;
n_stmts = 0;
- for (i = 0; i < bb->stmts_used; i++)
- if (bb->stmts[i])
- n_stmts++;
+ for (i = 0; i < bb->stmts_used; i++) {
+ if (bb->stmts[i]->tag != Ist_NoOp)
+ n_stmts++;
+ }
if (n_stmts <= vex_control.iropt_unroll_thresh/8) {
if (vex_control.iropt_verbosity > 0)