1903 Node* yplus1 = _gvn.transform(new AddDNode(y, makecon(TypeD::make(1)))); |
1903 Node* yplus1 = _gvn.transform(new AddDNode(y, makecon(TypeD::make(1)))); |
1904 Node *cmpyplus1= _gvn.transform(new CmpDNode(yplus1, y)); |
1904 Node *cmpyplus1= _gvn.transform(new CmpDNode(yplus1, y)); |
1905 Node *bolyplus1 = _gvn.transform(new BoolNode( cmpyplus1, BoolTest::eq )); |
1905 Node *bolyplus1 = _gvn.transform(new BoolNode( cmpyplus1, BoolTest::eq )); |
1906 Node* correctedsign = NULL; |
1906 Node* correctedsign = NULL; |
1907 if (ConditionalMoveLimit != 0) { |
1907 if (ConditionalMoveLimit != 0) { |
1908 correctedsign = _gvn.transform( CMoveNode::make(C, NULL, bolyplus1, signnode, longcon(0), TypeLong::LONG)); |
1908 correctedsign = _gvn.transform(CMoveNode::make(NULL, bolyplus1, signnode, longcon(0), TypeLong::LONG)); |
1909 } else { |
1909 } else { |
1910 IfNode *ifyplus1 = create_and_xform_if(ylong_path,bolyplus1, PROB_FAIR, COUNT_UNKNOWN); |
1910 IfNode *ifyplus1 = create_and_xform_if(ylong_path,bolyplus1, PROB_FAIR, COUNT_UNKNOWN); |
1911 RegionNode *r = new RegionNode(3); |
1911 RegionNode *r = new RegionNode(3); |
1912 Node *phi = new PhiNode(r, TypeLong::LONG); |
1912 Node *phi = new PhiNode(r, TypeLong::LONG); |
1913 r->init_req(1, _gvn.transform(new IfFalseNode(ifyplus1))); |
1913 r->init_req(1, _gvn.transform(new IfFalseNode(ifyplus1))); |
1932 // -abs(x)^y |
1932 // -abs(x)^y |
1933 Node *negabsxpowy = _gvn.transform(new NegDNode (absxpowy)); |
1933 Node *negabsxpowy = _gvn.transform(new NegDNode (absxpowy)); |
1934 // (1&(long)y)==1?-DPow(abs(x), y):DPow(abs(x), y) |
1934 // (1&(long)y)==1?-DPow(abs(x), y):DPow(abs(x), y) |
1935 Node *signresult = NULL; |
1935 Node *signresult = NULL; |
1936 if (ConditionalMoveLimit != 0) { |
1936 if (ConditionalMoveLimit != 0) { |
1937 signresult = _gvn.transform( CMoveNode::make(C, NULL, bol3, absxpowy, negabsxpowy, Type::DOUBLE)); |
1937 signresult = _gvn.transform(CMoveNode::make(NULL, bol3, absxpowy, negabsxpowy, Type::DOUBLE)); |
1938 } else { |
1938 } else { |
1939 IfNode *ifyeven = create_and_xform_if(ylong_path,bol3, PROB_FAIR, COUNT_UNKNOWN); |
1939 IfNode *ifyeven = create_and_xform_if(ylong_path,bol3, PROB_FAIR, COUNT_UNKNOWN); |
1940 RegionNode *r = new RegionNode(3); |
1940 RegionNode *r = new RegionNode(3); |
1941 Node *phi = new PhiNode(r, Type::DOUBLE); |
1941 Node *phi = new PhiNode(r, Type::DOUBLE); |
1942 r->init_req(1, _gvn.transform(new IfFalseNode(ifyeven))); |
1942 r->init_req(1, _gvn.transform(new IfFalseNode(ifyeven))); |
2266 |
2266 |
2267 // Use a flow-free graph structure, to avoid creating excess control edges |
2267 // Use a flow-free graph structure, to avoid creating excess control edges |
2268 // which could hinder other optimizations. |
2268 // which could hinder other optimizations. |
2269 // Since Math.min/max is often used with arraycopy, we want |
2269 // Since Math.min/max is often used with arraycopy, we want |
2270 // tightly_coupled_allocation to be able to see beyond min/max expressions. |
2270 // tightly_coupled_allocation to be able to see beyond min/max expressions. |
2271 Node* cmov = CMoveNode::make(C, NULL, best_bol, |
2271 Node* cmov = CMoveNode::make(NULL, best_bol, |
2272 answer_if_false, answer_if_true, |
2272 answer_if_false, answer_if_true, |
2273 TypeInt::make(lo, hi, widen)); |
2273 TypeInt::make(lo, hi, widen)); |
2274 |
2274 |
2275 return _gvn.transform(cmov); |
2275 return _gvn.transform(cmov); |
2276 |
2276 |