Skip to content

Commit

Permalink
Fix 4 + fix bug in printing jcstress results
Browse files Browse the repository at this point in the history
  • Loading branch information
DLochmelis33 committed Jul 7, 2024
1 parent a7ea1dd commit cbc23b3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/run-litmus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,13 @@ jobs:
distribution: oracle
java-version: 17
- run: chmod +x gradlew
- name: Assemble all CLI artifacts
run: ./gradlew cli:assemble
- name: Run litmus tests via CLI (x64 + debug)
run: ./cli/build/bin/macosX64/debugExecutable/cli.kexe -r pthread ".*"
- name: Assemble CLI binary (x64 + release)
run: ./gradlew cli:linkReleaseExecutableMacosX64
- name: Run litmus tests via CLI (x64 + release)
run: ./cli/build/bin/macosX64/releaseExecutable/cli.kexe -r pthread ".*"
- name: Run a single test with JCStress
run: ./gradlew :cli:jvmRun --args="-r jcstress -j '-m quick' StoreBuffering.Plain"
- name: Run litmus tests via CLI (arm + debug)
run: ./cli/build/bin/macosArm64/debugExecutable/cli.kexe -r pthread ".*"
run: ./gradlew :cli:jvmRun --args="-r jcstress -j '-m quick' .*"
- name: Assemble CLI binary (arm + release)
run: ./gradlew cli:linkReleaseExecutableMacosArm64
- name: Run litmus tests via CLI (arm + release)
run: ./cli/build/bin/macosArm64/releaseExecutable/cli.kexe -r pthread ".*"

9 changes: 7 additions & 2 deletions cli/src/jvmMain/kotlin/org/jetbrains/litmuskt/CliJvm.kt
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,13 @@ class CliJvm : CliCommon() {
) JCStressRunner.DEFAULT_LITMUSKT_PARAMS else params // jcstress defaults are different

val jcsRunner = runner as JCStressRunner // use the correct runTests()!
val results = jcsRunner.runTests(tests, jcsParams).first()
echo("\n" + results.generateTable())
val results = jcsRunner.runTests(tests, jcsParams)

echo()
(tests zip results).forEach { (test, result) ->
echo("results for ${test.alias}:")
echo(result.generateTable() + "\n")
}
}
}
}

0 comments on commit cbc23b3

Please sign in to comment.