8247762: [aarch64] Timeout in .../HeapDumpTestWithActiveProcess.java due to inf. loop in AARCH64CurrentFrameGuess.run()

Reviewed-by: cjplummer, aph
This commit is contained in:
Patric Hedlin 2020-06-17 19:53:48 +02:00
parent d7b097f117
commit 1d5ec8f363

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2003, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2019, Red Hat Inc. * Copyright (c) 2015, 2019, Red Hat Inc.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
@ -138,7 +138,16 @@ public class AARCH64CurrentFrameGuess {
setValues(curSP, null, pc); setValues(curSP, null, pc);
return true; return true;
} }
Frame oldFrame = frame;
frame = frame.sender(map); frame = frame.sender(map);
if (frame.getSP().lessThanOrEqual(oldFrame.getSP())) {
// Frame points to itself or to a location in the wrong direction.
// Break the loop and move on to next offset.
if (DEBUG) {
System.out.println("CurrentFrameGuess: frame <= oldFrame: " + frame);
}
break;
}
} }
} catch (Exception e) { } catch (Exception e) {
if (DEBUG) { if (DEBUG) {