Skip to content

[GR-62716] Use smaller dacapo archive whenever possible. #11980

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 15, 2025
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
29 changes: 21 additions & 8 deletions sdk/mx.sdk/mx_sdk_benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -2055,9 +2055,15 @@ def jarPath(self, benchmark):
def dataLocation(self):
if self.version() == "23.11-MR2-chopin":
basePath = self.daCapoPath()
return os.path.join(basePath, "dacapo-23.11-MR2-chopin")
subdir = "dacapo-23.11-MR2-chopin"
if self.minimalArchive():
subdir += "-minimal"
return os.path.join(basePath, subdir)
else:
raise "data location is only supported for version 23.11-MR2-chopin"
raise f"data location is not supported for suite version '{self.version()}'"

def minimalArchive(self):
return False

def createCommandLineArgs(self, benchmarks, bmSuiteArgs):
if benchmarks is None:
Expand Down Expand Up @@ -2227,17 +2233,24 @@ def workloadSize(self):
def daCapoClasspathEnvVarName(self):
return "DACAPO_CP"

def minimalArchive(self):
# DaCapo Chopin archive is huge. A stripped version without large and huge sizes exists
# See dacapobench/dacapobench issue #345 on GitHub
return self.version() in ["23.11-MR2-chopin"] and self.workloadSize() in ["default", "tiny", "small"]

def daCapoLibraryName(self):
library = None
if self.version() == "9.12-bach": # 2009 release
return "DACAPO"
library = "DACAPO"
elif self.version() == "9.12-MR1-bach": # 2018 maintenance release (January 2018)
return "DACAPO_MR1_BACH"
library = "DACAPO_MR1_BACH"
elif self.version() == "9.12-MR1-git+2baec49": # commit from July 2018
return "DACAPO_MR1_2baec49"
library = "DACAPO_MR1_2baec49"
elif self.version() == "23.11-MR2-chopin":
return "DACAPO_23.11_MR2_chopin"
else:
return None
library = "DACAPO_23.11_MR2_chopin"
if library and self.minimalArchive():
library += "_minimal"
return library

def daCapoIterations(self):
iterations = _daCapoIterations.copy()
Expand Down
6 changes: 6 additions & 0 deletions sdk/mx.sdk/suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,12 @@
"packedResource": True,
},

"DACAPO_23.11_MR2_chopin_minimal" : {
"urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/dacapo-23.11-MR2-chopin-minimal.zip"],
"digest" : "sha512:51c04f81564f758e12c43dc44fc70fe2de15c5ea368e759b898a41bac3a458a421c1dbf557676533ba97c82283055fe73637cdc8c100b82384e5af9380113d40",
"packedResource": True,
},

"DACAPO_SCALA" : {
"urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/dacapo-scala-0.1.0-20120216.jar"],
"digest" : "sha512:9a3908f3a0f2937bbc7edcd78f7e7e229bea8dee566d5f2d922bd4dc3c5b02cf97de294e479200372ff90bfbdf80e88dc7fc9fda9cb294088346e4a5ff28893e",
Expand Down
6 changes: 0 additions & 6 deletions substratevm/mx.substratevm/mx_substratevm_benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -672,12 +672,6 @@ def name(self):
def benchSuiteName(self, bmSuiteArgs=None):
return 'dacapo'

def daCapoPath(self):
lib = mx.library(self.daCapoLibraryName(), False)
if lib:
return lib.get_path(True)
return None

def availableSuiteVersions(self):
# The version 9.12-MR1-git+2baec49 also ships a custom harness class to allow native image to find the entry point in the nested jar
return ["9.12-MR1-git+2baec49", "23.11-MR2-chopin"]
Expand Down
Loading