Mercurial > hg > graal-jvmci-8
diff src/share/vm/c1/c1_Canonicalizer.cpp @ 23822:626f594dffa6
8139040: Fix initializations before ShouldNotReachHere() etc. and enable -Wuninitialized on linux.
Reviewed-by: stuefe, coleenp, roland
author | csahu |
---|---|
date | Tue, 01 Mar 2016 12:50:37 +0530 |
parents | a60a1309a03a |
children | d109bda16490 |
line wrap: on
line diff
--- a/src/share/vm/c1/c1_Canonicalizer.cpp Thu Feb 18 16:15:28 2016 +0100 +++ b/src/share/vm/c1/c1_Canonicalizer.cpp Tue Mar 01 12:50:37 2016 +0530 @@ -639,7 +639,7 @@ if (l == r && !lt->is_float_kind()) { // pattern: If (a cond a) => simplify to Goto - BlockBegin* sux; + BlockBegin* sux = NULL; switch (x->cond()) { case If::eql: sux = x->sux_for(true); break; case If::neq: sux = x->sux_for(false); break; @@ -647,6 +647,7 @@ case If::leq: sux = x->sux_for(true); break; case If::gtr: sux = x->sux_for(false); break; case If::geq: sux = x->sux_for(true); break; + default: ShouldNotReachHere(); } // If is a safepoint then the debug information should come from the state_before of the If. set_canonical(new Goto(sux, x->state_before(), is_safepoint(x, sux))); @@ -684,7 +685,7 @@ } else { // two successors differ and two successors are the same => simplify to: If (x cmp y) // determine new condition & successors - If::Condition cond; + If::Condition cond = If::eql; BlockBegin* tsux = NULL; BlockBegin* fsux = NULL; if (lss_sux == eql_sux) { cond = If::leq; tsux = lss_sux; fsux = gtr_sux; }