зеркало из https://github.com/dotnet/performance.git
Add support for specifying "experiment name". (#3489)
This commit is contained in:
Родитель
12049517b2
Коммит
2525ba2571
|
@ -78,6 +78,12 @@ def add_arguments(parser: ArgumentParser) -> ArgumentParser:
|
|||
action='store_const',
|
||||
const='nor2r'
|
||||
)
|
||||
parser.add_argument(
|
||||
'--experiment-name',
|
||||
dest='experiment_name',
|
||||
required=False,
|
||||
type=str
|
||||
)
|
||||
parser.add_argument(
|
||||
'--branch',
|
||||
dest='branch',
|
||||
|
@ -303,7 +309,8 @@ class CiSetupArgs:
|
|||
run_env_vars: Optional[List[str]] = None,
|
||||
target_windows: bool = True,
|
||||
physical_promotion_status: Optional[str] = None,
|
||||
r2r_status: Optional[str] = None):
|
||||
r2r_status: Optional[str] = None,
|
||||
experiment_name: Optional[str] = None):
|
||||
self.channel = channel
|
||||
self.quiet = quiet
|
||||
self.commit_sha = commit_sha
|
||||
|
@ -331,6 +338,7 @@ class CiSetupArgs:
|
|||
self.target_windows = target_windows
|
||||
self.physical_promotion_status = physical_promotion_status
|
||||
self.r2r_status = r2r_status
|
||||
self.experiment_name = experiment_name
|
||||
|
||||
def main(args: Any):
|
||||
verbose = not args.quiet
|
||||
|
@ -386,6 +394,7 @@ def main(args: Any):
|
|||
pgo_config = ''
|
||||
physical_promotion_config = ''
|
||||
r2r_config = ''
|
||||
experiment_config = ''
|
||||
showenv = 'set' if args.target_windows else 'printenv'
|
||||
|
||||
if args.pgo_status == 'nodynamicpgo':
|
||||
|
@ -451,6 +460,7 @@ def main(args: Any):
|
|||
out_file.write(pgo_config)
|
||||
out_file.write(physical_promotion_config)
|
||||
out_file.write(r2r_config)
|
||||
out_file.write(experiment_config)
|
||||
out_file.write(variable_format % ('PERFLAB_INLAB', '0' if args.not_in_lab else '1'))
|
||||
out_file.write(variable_format % ('PERFLAB_REPO', '/'.join([owner, repo])))
|
||||
out_file.write(variable_format % ('PERFLAB_BRANCH', branch))
|
||||
|
|
|
@ -45,6 +45,7 @@ class PerformanceSetupArgs:
|
|||
no_dynamic_pgo: bool = False
|
||||
physical_promotion: bool = False
|
||||
no_r2r: bool = False
|
||||
experiment_name: str | None = None
|
||||
ios_llvm_build: bool = False
|
||||
ios_strip_symbols: bool = False
|
||||
maui_version: str | None = None
|
||||
|
@ -197,6 +198,9 @@ def run(args: PerformanceSetupArgs):
|
|||
if args.no_r2r:
|
||||
args.configurations["R2RType"] = "nor2r"
|
||||
|
||||
if args.experiment_name:
|
||||
args.configurations["ExperimentName"] = args.experiment_name
|
||||
|
||||
runtime_type = ""
|
||||
|
||||
if args.ios_mono:
|
||||
|
@ -292,6 +296,8 @@ def run(args: PerformanceSetupArgs):
|
|||
if args.no_r2r:
|
||||
setup_arguments.r2r_status = "nor2r"
|
||||
|
||||
setup_arguments.experiment_name = args.experiment_name
|
||||
|
||||
if args.mono_aot:
|
||||
if args.mono_aot_path is None:
|
||||
raise Exception("Mono AOT Path must be provided for MonoAOT runs")
|
||||
|
|
|
@ -75,6 +75,7 @@ class RunPerformanceJobArgs:
|
|||
pgo_run_type: str | None = None
|
||||
physical_promotion_run_type: str | None = None
|
||||
r2r_run_type: str | None = None
|
||||
experiment_name: str | None = None
|
||||
codegen_type: str = "JIT"
|
||||
runtime_type: str = "coreclr"
|
||||
affinity: str | None = "0"
|
||||
|
@ -252,6 +253,7 @@ def run_performance_job(args: RunPerformanceJobArgs):
|
|||
no_dynamic_pgo=args.pgo_run_type == "nodynamicpgo",
|
||||
physical_promotion=args.physical_promotion_run_type == "physicalpromotion",
|
||||
no_r2r=args.r2r_run_type == "nor2r",
|
||||
experiment_name=args.experiment_name,
|
||||
internal=args.internal,
|
||||
mono_interpreter=mono_interpreter,
|
||||
framework=args.framework,
|
||||
|
|
Загрузка…
Ссылка в новой задаче