Mercurial > hg > truffle
comparison src/share/vm/opto/memnode.cpp @ 986:62001a362ce9
6827605: new String intrinsics may prevent EA scalar replacement
6875866: Intrinsic for String.indexOf() is broken on x86 with SSE4.2
Summary: Modify String intrinsic methods to pass char[] pointers instead of string oops.
Reviewed-by: never
author | kvn |
---|---|
date | Mon, 14 Sep 2009 12:14:20 -0700 |
parents | 685e959d09ea |
children | dcdcc8c16e20 |
comparison
equal
deleted
inserted
replaced
985:685e959d09ea | 986:62001a362ce9 |
---|---|
2512 } | 2512 } |
2513 | 2513 |
2514 //============================================================================= | 2514 //============================================================================= |
2515 // Do we match on this edge? No memory edges | 2515 // Do we match on this edge? No memory edges |
2516 uint StrCompNode::match_edge(uint idx) const { | 2516 uint StrCompNode::match_edge(uint idx) const { |
2517 return idx == 5 || idx == 6; | 2517 return idx == 2 || idx == 3; // StrComp (Binary str1 cnt1) (Binary str2 cnt2) |
2518 } | 2518 } |
2519 | 2519 |
2520 //------------------------------Ideal------------------------------------------ | 2520 //------------------------------Ideal------------------------------------------ |
2521 // Return a node which is more "ideal" than the current node. Strip out | 2521 // Return a node which is more "ideal" than the current node. Strip out |
2522 // control copies | 2522 // control copies |
2523 Node *StrCompNode::Ideal(PhaseGVN *phase, bool can_reshape){ | 2523 Node *StrCompNode::Ideal(PhaseGVN *phase, bool can_reshape){ |
2524 return remove_dead_region(phase, can_reshape) ? this : NULL; | 2524 return remove_dead_region(phase, can_reshape) ? this : NULL; |
2525 } | 2525 } |
2526 | 2526 |
2527 //============================================================================= | |
2527 // Do we match on this edge? No memory edges | 2528 // Do we match on this edge? No memory edges |
2528 uint StrEqualsNode::match_edge(uint idx) const { | 2529 uint StrEqualsNode::match_edge(uint idx) const { |
2529 return idx == 5 || idx == 6; | 2530 return idx == 2 || idx == 3; // StrEquals (Binary str1 str2) cnt |
2530 } | 2531 } |
2531 | 2532 |
2532 //------------------------------Ideal------------------------------------------ | 2533 //------------------------------Ideal------------------------------------------ |
2533 // Return a node which is more "ideal" than the current node. Strip out | 2534 // Return a node which is more "ideal" than the current node. Strip out |
2534 // control copies | 2535 // control copies |
2537 } | 2538 } |
2538 | 2539 |
2539 //============================================================================= | 2540 //============================================================================= |
2540 // Do we match on this edge? No memory edges | 2541 // Do we match on this edge? No memory edges |
2541 uint StrIndexOfNode::match_edge(uint idx) const { | 2542 uint StrIndexOfNode::match_edge(uint idx) const { |
2542 return idx == 5 || idx == 6; | 2543 return idx == 2 || idx == 3; // StrIndexOf (Binary str1 cnt1) (Binary str2 cnt2) |
2543 } | 2544 } |
2544 | 2545 |
2545 //------------------------------Ideal------------------------------------------ | 2546 //------------------------------Ideal------------------------------------------ |
2546 // Return a node which is more "ideal" than the current node. Strip out | 2547 // Return a node which is more "ideal" than the current node. Strip out |
2547 // control copies | 2548 // control copies |
2548 Node *StrIndexOfNode::Ideal(PhaseGVN *phase, bool can_reshape){ | 2549 Node *StrIndexOfNode::Ideal(PhaseGVN *phase, bool can_reshape){ |
2549 return remove_dead_region(phase, can_reshape) ? this : NULL; | 2550 return remove_dead_region(phase, can_reshape) ? this : NULL; |
2550 } | 2551 } |
2551 | 2552 |
2553 //============================================================================= | |
2554 // Do we match on this edge? No memory edges | |
2555 uint AryEqNode::match_edge(uint idx) const { | |
2556 return idx == 2 || idx == 3; // StrEquals ary1 ary2 | |
2557 } | |
2552 //------------------------------Ideal------------------------------------------ | 2558 //------------------------------Ideal------------------------------------------ |
2553 // Return a node which is more "ideal" than the current node. Strip out | 2559 // Return a node which is more "ideal" than the current node. Strip out |
2554 // control copies | 2560 // control copies |
2555 Node *AryEqNode::Ideal(PhaseGVN *phase, bool can_reshape){ | 2561 Node *AryEqNode::Ideal(PhaseGVN *phase, bool can_reshape){ |
2556 return remove_dead_region(phase, can_reshape) ? this : NULL; | 2562 return remove_dead_region(phase, can_reshape) ? this : NULL; |