Skip to content

Commit

Permalink
Test
Browse files Browse the repository at this point in the history
  • Loading branch information
loicottet committed Sep 30, 2024
1 parent 8798480 commit eb1a52a
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
12 changes: 11 additions & 1 deletion .github/workflows/reachability-metadata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -134,6 +136,14 @@ jobs:
sudo systemctl daemon-reload
sudo systemctl restart docker
- name: "Run '${{ matrix.coordinates }}' tests"
id: run
run: |
./gradlew test -Pcoordinates=${{ matrix.coordinates }}
echo "build_stats=$PWD/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 }}
Original file line number Diff line number Diff line change
Expand Up @@ -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();
Expand Down Expand Up @@ -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);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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<Boolean> CollectImageBuildStatistics = new OptionKey<>(false);
public static final OptionKey<Boolean> CollectImageBuildStatistics = new OptionKey<>(true);
}

public enum CheckCountLocation {
Expand Down

0 comments on commit eb1a52a

Please sign in to comment.