OpenJDK / jdk / jdk
changeset 59263:581be80a50f1
8242188: [TESTBUG] error in jtreg test jdk/jfr/api/consumer/TestRecordedFrame.java on linux-aarch64
Reviewed-by: egahlin
author | ngasson |
---|---|
date | Wed, 29 Apr 2020 16:15:14 +0800 |
parents | 99fe4024af19 |
children | 7af05fae58cd |
files | test/jdk/jdk/jfr/api/consumer/TestRecordedFrame.java |
diffstat | 1 files changed, 9 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/test/jdk/jdk/jfr/api/consumer/TestRecordedFrame.java Tue May 12 19:34:59 2020 -0400 +++ b/test/jdk/jdk/jfr/api/consumer/TestRecordedFrame.java Wed Apr 29 16:15:14 2020 +0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2020, 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 @@ -50,10 +50,17 @@ public final class TestRecordedFrame { public static void main(String[] args) throws IOException { - System.out.println(); // Makes BCI for method larger than 0 + doSomething(); // Makes BCI for method larger than 0 test(); // Records the line number and BCI for the main method/frame } + static void doSomething() { + // Don't actually do anything: on platforms that do not support + // patching (AArch64) -Xcomp is very sensitive to class load + // order and calling other methods here might result in main() + // being deoptimized, failing the test below. + } + static void test() throws IOException { try (Recording recording = new Recording()) { recording.start();