Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ protected boolean isPlatformSupported() {

@RetryingTest(5)
public void shouldGetObjectAllocationSamples() throws InterruptedException {

// We seem to hit issues on j9:
// OSR (On stack replacement) creates crashes with the profiler.
// ----------- Stack Backtrace -----------
// prepareForOSR+0xbf (0x00007F51062A4DDF [libj9jit29.so+0x4a4ddf])
if (Platform.isJ9() && !Platform.isJavaVersionAtLeast(8)) {
return;
}
Assumptions.assumeFalse(isAsan() || isTsan());

AllocatingTarget target1 = new AllocatingTarget();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,18 @@ public void after() {
@TestTemplate
@ValueSource(strings = {"vm", "vmx", "fp", "dwarf"})
public void test(@CStack String cstack) {
String config = System.getProperty("ddprof_test.config");
boolean isSanitizer = config.endsWith("san");
boolean isJvmci = System.getProperty("java.vm.version", "").contains("jvmci");
assumeFalse(Platform.isZing() || Platform.isJ9());
// Skip test entirely on unsupported JVMs (don't use assumeFalse which gets retried)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't use assumeFalse which gets retried

Ouch. This should not be the case. I will take a look at the @TestTemplate engine ...

if (Platform.isZing() || Platform.isJ9()) {
return;
}
// Running vm stackwalker tests on JVMCI (Graal), JDK 24, aarch64 and with a sanitizer is crashing in a weird place
// This looks like the sanitizer instrumentation is breaking the longjump based crash recovery :(
assumeFalse(Platform.isJavaVersionAtLeast(24) && isJvmci && Platform.isAarch64() && cstack.startsWith("vm") && isSanitizer);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand the usage of assume here ?
we are triggering these tests here: https://github.com/DataDog/java-profiler/actions/runs/16116032610/job/45470209849?pr=238

Is this expected ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are running on JDK 17 - one of the conditions is Java >=24

So yes. This is expected.

String config = System.getProperty("ddprof_test.config");
boolean isJvmci = System.getProperty("java.vm.version", "").contains("jvmci");
boolean isSanitizer = config.endsWith("san");
if (Platform.isJavaVersionAtLeast(24) && isJvmci && Platform.isAarch64() && cstack.startsWith("vm") && isSanitizer) {
return;
}

long result = 0;
for (int i = 0; i < 10; i++) {
Expand Down
Loading