Skip to content

Commit 2b8ebde

Browse files
committed
Merge branch 'main' of github.com:DataDog/java-profiler into r1viollet/thread_filter_squash
2 parents 0918008 + 98d0a12 commit 2b8ebde

File tree

2 files changed

+18
-5
lines changed

2 files changed

+18
-5
lines changed

ddprof-test/src/test/java/com/datadoghq/profiler/alloc/AllocationProfilerTest.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,14 @@ protected boolean isPlatformSupported() {
2222

2323
@RetryingTest(5)
2424
public void shouldGetObjectAllocationSamples() throws InterruptedException {
25+
26+
// We seem to hit issues on j9:
27+
// OSR (On stack replacement) creates crashes with the profiler.
28+
// ----------- Stack Backtrace -----------
29+
// prepareForOSR+0xbf (0x00007F51062A4DDF [libj9jit29.so+0x4a4ddf])
30+
if (Platform.isJ9() && !Platform.isJavaVersionAtLeast(8)) {
31+
return;
32+
}
2533
Assumptions.assumeFalse(isAsan() || isTsan());
2634

2735
AllocatingTarget target1 = new AllocatingTarget();

ddprof-test/src/test/java/com/datadoghq/profiler/wallclock/ContendedWallclockSamplesTest.java

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,18 @@ public void after() {
5151
@TestTemplate
5252
@ValueSource(strings = {"vm", "vmx", "fp", "dwarf"})
5353
public void test(@CStack String cstack) {
54-
String config = System.getProperty("ddprof_test.config");
55-
boolean isSanitizer = config.endsWith("san");
56-
boolean isJvmci = System.getProperty("java.vm.version", "").contains("jvmci");
57-
assumeFalse(Platform.isZing() || Platform.isJ9());
54+
// Skip test entirely on unsupported JVMs (don't use assumeFalse which gets retried)
55+
if (Platform.isZing() || Platform.isJ9()) {
56+
return;
57+
}
5858
// Running vm stackwalker tests on JVMCI (Graal), JDK 24, aarch64 and with a sanitizer is crashing in a weird place
5959
// This looks like the sanitizer instrumentation is breaking the longjump based crash recovery :(
60-
assumeFalse(Platform.isJavaVersionAtLeast(24) && isJvmci && Platform.isAarch64() && cstack.startsWith("vm") && isSanitizer);
60+
String config = System.getProperty("ddprof_test.config");
61+
boolean isJvmci = System.getProperty("java.vm.version", "").contains("jvmci");
62+
boolean isSanitizer = config.endsWith("san");
63+
if (Platform.isJavaVersionAtLeast(24) && isJvmci && Platform.isAarch64() && cstack.startsWith("vm") && isSanitizer) {
64+
return;
65+
}
6166

6267
long result = 0;
6368
for (int i = 0; i < 10; i++) {

0 commit comments

Comments
 (0)