Mercurial > hg > graal-compiler
diff src/share/vm/opto/memnode.cpp @ 420:a1980da045cc
6462850: generate biased locking code in C2 ideal graph
Summary: Inline biased locking code in C2 ideal graph during macro nodes expansion
Reviewed-by: never
author | kvn |
---|---|
date | Fri, 07 Nov 2008 09:29:38 -0800 |
parents | 8261ee795323 |
children | 82a980778b92 041fe019d769 |
line wrap: on
line diff
--- a/src/share/vm/opto/memnode.cpp Thu Nov 06 20:00:03 2008 -0800 +++ b/src/share/vm/opto/memnode.cpp Fri Nov 07 09:29:38 2008 -0800 @@ -227,6 +227,14 @@ const Type *t_adr = phase->type( address ); if( t_adr == Type::TOP ) return NodeSentinel; // caller will return NULL + PhaseIterGVN *igvn = phase->is_IterGVN(); + if( can_reshape && igvn != NULL && igvn->_worklist.member(address) ) { + // The address's base and type may change when the address is processed. + // Delay this mem node transformation until the address is processed. + phase->is_IterGVN()->_worklist.push(this); + return NodeSentinel; // caller will return NULL + } + // Avoid independent memory operations Node* old_mem = mem;