# HG changeset patch # User rkennke # Date 1542874985 -3600 # Node ID c88468bc7690b157bda8d34cbb5ff84da0a4157b # Parent 95ce45e0249fded7ef5a8f34c43d912bf0b7fe0c 8214057: GC/C2 abstraction for Node::has_special_unique_user() Reviewed-by: kvn, roland diff -r 95ce45e0249f -r c88468bc7690 src/hotspot/share/gc/shared/c2/barrierSetC2.hpp --- a/src/hotspot/share/gc/shared/c2/barrierSetC2.hpp Thu Nov 22 09:22:54 2018 +0100 +++ b/src/hotspot/share/gc/shared/c2/barrierSetC2.hpp Thu Nov 22 09:23:05 2018 +0100 @@ -281,6 +281,8 @@ // expanded later, then now is the time to do so. virtual bool expand_macro_nodes(PhaseMacroExpand* macro) const { return false; } + virtual bool has_special_unique_user(const Node* node) const { return false; } + enum CompilePhase { BeforeOptimize, /* post_parse = true */ BeforeExpand, /* post_parse = false */ diff -r 95ce45e0249f -r c88468bc7690 src/hotspot/share/opto/node.cpp --- a/src/hotspot/share/opto/node.cpp Thu Nov 22 09:22:54 2018 +0100 +++ b/src/hotspot/share/opto/node.cpp Thu Nov 22 09:23:05 2018 +0100 @@ -1142,8 +1142,9 @@ } else if (is_If() && (n->is_IfFalse() || n->is_IfTrue())) { // See IfProjNode::Identity() return true; + } else { + return BarrierSet::barrier_set()->barrier_set_c2()->has_special_unique_user(this); } - return false; }; //--------------------------find_exact_control---------------------------------