Skip to content

Commit

Permalink
8287840: Dead copy region node blocks IfNode's fold-compares
Browse files Browse the repository at this point in the history
Reviewed-by: kvn, thartmann
  • Loading branch information
Xin Liu committed Jun 7, 2022
1 parent c41a283 commit 3da7e39
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/hotspot/share/opto/node.cpp
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -1216,6 +1216,9 @@ bool Node::has_special_unique_user() const {
} else if (is_If() && (n->is_IfFalse() || n->is_IfTrue())) {
// See IfProjNode::Identity()
return true;
} else if ((is_IfFalse() || is_IfTrue()) && n->is_If()) {
// See IfNode::fold_compares
return true;
} else {
return false;
}
Expand Down

0 comments on commit 3da7e39

Please sign in to comment.