Skip to content

Commit 1f54ed0

Browse files
RealFYangyadongw
andcommitted
8264096: slowdebug jvm crashes when StrInflatedCopy match rule is not supported
Co-authored-by: Yadong Wang <yadonn.wang@huawei.com> Reviewed-by: thartmann
1 parent 447e0df commit 1f54ed0

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/hotspot/share/opto/c2compiler.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,11 +179,11 @@ bool C2Compiler::is_intrinsic_supported(const methodHandle& method, bool is_virt
179179
switch (id) {
180180
case vmIntrinsics::_compressStringC:
181181
case vmIntrinsics::_compressStringB:
182-
if (!Matcher::has_match_rule(Op_StrCompressedCopy)) return false;
182+
if (!Matcher::match_rule_supported(Op_StrCompressedCopy)) return false;
183183
break;
184184
case vmIntrinsics::_inflateStringC:
185185
case vmIntrinsics::_inflateStringB:
186-
if (!Matcher::has_match_rule(Op_StrInflatedCopy)) return false;
186+
if (!Matcher::match_rule_supported(Op_StrInflatedCopy)) return false;
187187
break;
188188
case vmIntrinsics::_compareToL:
189189
case vmIntrinsics::_compareToU:

src/hotspot/share/opto/graphKit.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4228,6 +4228,8 @@ void GraphKit::inflate_string_slow(Node* src, Node* dst, Node* start, Node* coun
42284228
* }
42294229
*/
42304230
add_empty_predicates();
4231+
C->set_has_loops(true);
4232+
42314233
RegionNode* head = new RegionNode(3);
42324234
head->init_req(1, control());
42334235
gvn().set_type(head, Type::CONTROL);

0 commit comments

Comments
 (0)