diff --git a/.github/workflows/reachability-metadata.yml b/.github/workflows/reachability-metadata.yml index b19d621f51035..e0e98d9a58201 100644 --- a/.github/workflows/reachability-metadata.yml +++ b/.github/workflows/reachability-metadata.yml @@ -96,6 +96,8 @@ jobs: test-all-metadata: name: ${{ matrix.coordinates }} runs-on: ubuntu-latest + outputs: + build_stats: ${{ steps.run.outputs.build_stats }} env: GRAALVM_HOME: ${{ github.workspace }}/graalvm # identical to the one in ./.github/actions/build-graalvm timeout-minutes: 20 @@ -108,7 +110,8 @@ jobs: - name: "Checkout oracle/graalvm-reachability-metadata" uses: actions/checkout@v4 with: - repository: oracle/graalvm-reachability-metadata + repository: loicottet/graalvm-reachability-metadata + ref: lottet/update - name: Download GraalVM JDK build uses: actions/download-artifact@v4 with: @@ -134,6 +137,16 @@ jobs: sudo systemctl daemon-reload sudo systemctl restart docker - name: "Run '${{ matrix.coordinates }}' tests" + id: run run: | - ./gradlew test -Pcoordinates=${{ matrix.coordinates }} - \ No newline at end of file + ./gradlew test -Pcoordinates=${{ matrix.coordinates }} --continue + echo "Outputting stats" + coords=${{ matrix.coordinates }} + cat tests/src/${coords//:/\/}/build/native/nativeTestCompile/reports/image_build_statistics.json >> "$GITHUB_OUTPUT" + + gather-stats: + name: "Gather stats files" + runs-on: ubuntu/latest + needs: [test-all-metadata] + steps: + - run: echo ${{ needs.test-all-metadata.outputs }} diff --git a/substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/ProgressReporter.java b/substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/ProgressReporter.java index 96a6e449d3dff..55eae3942dcc7 100644 --- a/substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/ProgressReporter.java +++ b/substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/ProgressReporter.java @@ -103,7 +103,7 @@ import jdk.graal.compiler.options.OptionKey; import jdk.graal.compiler.options.OptionStability; import jdk.graal.compiler.options.OptionValues; -import jdk.graal.compiler.util.json.JsonWriter; +import jdk.graal.compiler.util.json.JsonPrettyWriter; public class ProgressReporter implements FeatureSingleton, UnsavedSingleton { private static final boolean IS_CI = SubstrateUtil.isRunningInCI(); @@ -811,7 +811,7 @@ private Path reportBuildOutput(Path jsonOutputFile) { String description = "image statistics in json"; return ReportUtils.report(description, jsonOutputFile.toAbsolutePath(), out -> { try { - jsonHelper.print(new JsonWriter(out)); + jsonHelper.print(new JsonPrettyWriter(out)); } catch (IOException e) { throw VMError.shouldNotReachHere("Failed to create " + jsonOutputFile, e); } diff --git a/substratevm/src/com.oracle.svm.util/src/com/oracle/svm/util/ImageBuildStatistics.java b/substratevm/src/com.oracle.svm.util/src/com/oracle/svm/util/ImageBuildStatistics.java index 88e3f9b359808..c8104066576a0 100644 --- a/substratevm/src/com.oracle.svm.util/src/com/oracle/svm/util/ImageBuildStatistics.java +++ b/substratevm/src/com.oracle.svm.util/src/com/oracle/svm/util/ImageBuildStatistics.java @@ -41,7 +41,7 @@ public class ImageBuildStatistics { public static class Options { @Option(help = "Collect information during image build about devirtualized invokes and bytecode exceptions.")// - public static final OptionKey CollectImageBuildStatistics = new OptionKey<>(false); + public static final OptionKey CollectImageBuildStatistics = new OptionKey<>(true); } public enum CheckCountLocation {