Openj9: DDR support on OSX

Created on 30 Oct 2018  路  5Comments  路  Source: eclipse/openj9

Work to get DDR working on OSX should be made up of the following broad tasks:

  • [x] Get OMR's ddrgen working (PRs: https://github.com/eclipse/openj9/pull/3489 and https://github.com/eclipse/omr/pull/3136)
  • [x] Add a core file reader for Mach core files (#3444)
  • [x] Enable and get DDR tests working (#3366)
  • [x] Enable DDR by default on OSX (ibmruntimes/openj9-openjdk-jdk8#225, ibmruntimes/openj9-openjdk-jdk11#82, ibmruntimes/openj9-openjdk-jdk12#1, ibmruntimes/openj9-openjdk-jdk#61)

Part of https://github.com/eclipse/openj9/issues/378

Epic vm

Most helpful comment

A huge thank you to @mikezhang1234567890 and @keithc-ca for bringing DDR up on OSX! This will greatly simplify debugging on OSX!

Congrats on landing this major feature.

All 5 comments

Please fill in the issue/pr numbers when they are created, and I can add these to this Epic.

Discussed with @keithc-ca & @mikezhang1234567890 We're going to enable the ddr blob generation on osx so that the blobs will be in cores for the 0.12.0 release. This will allow us to read the 0.12.0 cores when the core reader becomes available as it doesn't need to ship with the release.

ddrgen is having trouble with openj9/runtime/gc_structs/ClassLoaderClassesIterator.hpp:

class GC_ClassLoaderClassesIterator
{
    enum { TABLE_CLASSES, SYSTEM_CLASSES, ANONYMOUS_CLASSES } _mode;
    // ...
};

That header file is included in multiple compilation units and the linker uses a single definition of the enum for the _mode field, but repeats the enum type declaration in j9gc29.dylib as if the source were (this illegal) code:

class GC_ClassLoaderClassesIterator
{
    enum { TABLE_CLASSES, SYSTEM_CLASSES, ANONYMOUS_CLASSES } _mode;
    enum { TABLE_CLASSES, SYSTEM_CLASSES, ANONYMOUS_CLASSES };
    // ...
};

If I manually remove the resulting duplicate constants from superset.dat, building the JDK can proceed and succeed. Hopefully only a small fix is required to ddrgen.

A huge thank you to @mikezhang1234567890 and @keithc-ca for bringing DDR up on OSX! This will greatly simplify debugging on OSX!

Congrats on landing this major feature.

Was this page helpful?
0 / 5 - 0 ratings