Mercurial > hg > graal-compiler
comparison src/share/vm/opto/ifnode.cpp @ 20329:fb971e09d20f
8054883: Segmentation error while running program
Summary: Fix pattern matching of range check
Reviewed-by: kvn
author | iveresov |
---|---|
date | Wed, 13 Aug 2014 17:37:11 -0700 |
parents | 968a17f18337 |
children | e3d0aaab84aa |
comparison
equal
deleted
inserted
replaced
20328:92baebeb744b | 20329:fb971e09d20f |
---|---|
501 // Look for index+offset form | 501 // Look for index+offset form |
502 Node* ind = l; | 502 Node* ind = l; |
503 jint off = 0; | 503 jint off = 0; |
504 if (l->is_top()) { | 504 if (l->is_top()) { |
505 return 0; | 505 return 0; |
506 } else if (l->is_Add()) { | 506 } else if (l->Opcode() == Op_AddI) { |
507 if ((off = l->in(1)->find_int_con(0)) != 0) { | 507 if ((off = l->in(1)->find_int_con(0)) != 0) { |
508 ind = l->in(2); | 508 ind = l->in(2); |
509 } else if ((off = l->in(2)->find_int_con(0)) != 0) { | 509 } else if ((off = l->in(2)->find_int_con(0)) != 0) { |
510 ind = l->in(1); | 510 ind = l->in(1); |
511 } | 511 } |