Skip to content

Commit b7a8a7a

Browse files
committed
[GR-62716] Use smaller dacapo archive whenever possible.
PullRequest: graal/21844
2 parents 462a5b3 + 0c734ec commit b7a8a7a

File tree

3 files changed

+27
-14
lines changed

3 files changed

+27
-14
lines changed

sdk/mx.sdk/mx_sdk_benchmark.py

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2055,9 +2055,15 @@ def jarPath(self, benchmark):
20552055
def dataLocation(self):
20562056
if self.version() == "23.11-MR2-chopin":
20572057
basePath = self.daCapoPath()
2058-
return os.path.join(basePath, "dacapo-23.11-MR2-chopin")
2058+
subdir = "dacapo-23.11-MR2-chopin"
2059+
if self.minimalArchive():
2060+
subdir += "-minimal"
2061+
return os.path.join(basePath, subdir)
20592062
else:
2060-
raise "data location is only supported for version 23.11-MR2-chopin"
2063+
raise f"data location is not supported for suite version '{self.version()}'"
2064+
2065+
def minimalArchive(self):
2066+
return False
20612067

20622068
def createCommandLineArgs(self, benchmarks, bmSuiteArgs):
20632069
if benchmarks is None:
@@ -2227,17 +2233,24 @@ def workloadSize(self):
22272233
def daCapoClasspathEnvVarName(self):
22282234
return "DACAPO_CP"
22292235

2236+
def minimalArchive(self):
2237+
# DaCapo Chopin archive is huge. A stripped version without large and huge sizes exists
2238+
# See dacapobench/dacapobench issue #345 on GitHub
2239+
return self.version() in ["23.11-MR2-chopin"] and self.workloadSize() in ["default", "tiny", "small"]
2240+
22302241
def daCapoLibraryName(self):
2242+
library = None
22312243
if self.version() == "9.12-bach": # 2009 release
2232-
return "DACAPO"
2244+
library = "DACAPO"
22332245
elif self.version() == "9.12-MR1-bach": # 2018 maintenance release (January 2018)
2234-
return "DACAPO_MR1_BACH"
2246+
library = "DACAPO_MR1_BACH"
22352247
elif self.version() == "9.12-MR1-git+2baec49": # commit from July 2018
2236-
return "DACAPO_MR1_2baec49"
2248+
library = "DACAPO_MR1_2baec49"
22372249
elif self.version() == "23.11-MR2-chopin":
2238-
return "DACAPO_23.11_MR2_chopin"
2239-
else:
2240-
return None
2250+
library = "DACAPO_23.11_MR2_chopin"
2251+
if library and self.minimalArchive():
2252+
library += "_minimal"
2253+
return library
22412254

22422255
def daCapoIterations(self):
22432256
iterations = _daCapoIterations.copy()

sdk/mx.sdk/suite.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -315,6 +315,12 @@
315315
"packedResource": True,
316316
},
317317

318+
"DACAPO_23.11_MR2_chopin_minimal" : {
319+
"urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/dacapo-23.11-MR2-chopin-minimal.zip"],
320+
"digest" : "sha512:51c04f81564f758e12c43dc44fc70fe2de15c5ea368e759b898a41bac3a458a421c1dbf557676533ba97c82283055fe73637cdc8c100b82384e5af9380113d40",
321+
"packedResource": True,
322+
},
323+
318324
"DACAPO_SCALA" : {
319325
"urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/dacapo-scala-0.1.0-20120216.jar"],
320326
"digest" : "sha512:9a3908f3a0f2937bbc7edcd78f7e7e229bea8dee566d5f2d922bd4dc3c5b02cf97de294e479200372ff90bfbdf80e88dc7fc9fda9cb294088346e4a5ff28893e",

substratevm/mx.substratevm/mx_substratevm_benchmark.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -672,12 +672,6 @@ def name(self):
672672
def benchSuiteName(self, bmSuiteArgs=None):
673673
return 'dacapo'
674674

675-
def daCapoPath(self):
676-
lib = mx.library(self.daCapoLibraryName(), False)
677-
if lib:
678-
return lib.get_path(True)
679-
return None
680-
681675
def availableSuiteVersions(self):
682676
# 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
683677
return ["9.12-MR1-git+2baec49", "23.11-MR2-chopin"]

0 commit comments

Comments
 (0)