Skip to content
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

Update net462 channel to use 10.0 branch. #4741

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
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
10 changes: 5 additions & 5 deletions scripts/channel_map.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ class ChannelMap():
'branch': '10.0',
'quality': 'daily'
},
'net462': {
'tfm': 'net462',
'branch': '10.0', # This needs to be kept up to date with main or whatever the global.json will require.
'quality': 'daily'
},
'10.0': {
'tfm': 'net10.0',
'branch': '10.0',
Expand Down Expand Up @@ -159,11 +164,6 @@ class ChannelMap():
'branch': '3.1.4xx',
'quality': 'daily'
},
'net462': {
'tfm': 'net462',
'branch': '9.0',
'quality': 'daily'
},
'net48': {
'tfm': 'net48', # For Full Framework download the LTS for dotnet cli.
'branch': 'LTS'
Expand Down
19 changes: 19 additions & 0 deletions scripts/performance/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,25 @@ def set_environment_variable(name: str, value: str, save_to_pipeline: bool = Tru
__write_pipeline_variable(name, value)
os.environ[name] = value

def get_target_framework_moniker_from_framework(framework: str) -> str:
'''
Translates framework name to target framework moniker (TFM)
This maps the frameworks to the TFMs to be used to build support tooling.
'''
if framework == 'nativeaot6.0':
return 'net6.0'
if framework == 'nativeaot7.0':
return 'net7.0'
if framework == 'nativeaot8.0':
return 'net8.0'
if framework == 'nativeaot9.0':
return 'net9.0'
if framework == 'nativeaot10.0':
return 'net10.0'
if framework == 'net462':
return 'net10.0' # This needs to be kept up to date with the version in channel_map.py, both should also be the latest version
return framework

class RunCommand:
'''
This is a class wrapper around `subprocess.Popen` with an additional set
Expand Down
15 changes: 8 additions & 7 deletions scripts/run_performance_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
from typing import Any, Dict, List, Optional

import ci_setup
from performance.common import RunCommand, set_environment_variable
from performance.common import RunCommand, set_environment_variable, get_target_framework_moniker_from_framework
from performance.logger import setup_loggers
from send_to_helix import PerfSendToHelixArgs, perf_send_to_helix

Expand Down Expand Up @@ -791,12 +791,13 @@ def run_performance_job(args: RunPerformanceJobArgs):
runtime_id = "linux" + (f"{args.os_sub_group.replace('_', '-')}" if args.os_sub_group else "") + f"-{args.architecture}"

dotnet_executable_path = os.path.join(ci_setup_arguments.dotnet_path, "dotnet") if ci_setup_arguments.dotnet_path else os.path.join(ci_setup_arguments.install_dir, "dotnet")

tool_framework = get_target_framework_moniker_from_framework(framework)

RunCommand([
dotnet_executable_path, "publish",
"-c", "Release",
"-o", os.path.join(payload_dir, "certhelper"),
"-f", framework,
"-f", tool_framework,
"-r", runtime_id,
"--self-contained",
os.path.join(args.performance_repo_dir, "src", "tools", "CertHelper", "CertHelper.csproj"),
Expand All @@ -819,7 +820,7 @@ def run_performance_job(args: RunPerformanceJobArgs):
dotnet_executable_path, "publish",
"-c", "Release",
"-o", os.path.join(payload_dir, "startup"),
"-f", framework,
"-f", tool_framework,
"-r", runtime_id,
"--self-contained",
os.path.join(args.performance_repo_dir, "src", "tools", "ScenarioMeasurement", "Startup", "Startup.csproj"),
Expand All @@ -832,7 +833,7 @@ def run_performance_job(args: RunPerformanceJobArgs):
dotnet_executable_path, "publish",
"-c", "Release",
"-o", os.path.join(payload_dir, "SOD"),
"-f", framework,
"-f", tool_framework,
"-r", runtime_id,
"--self-contained",
os.path.join(args.performance_repo_dir, "src", "tools", "ScenarioMeasurement", "SizeOnDisk", "SizeOnDisk.csproj"),
Expand All @@ -846,7 +847,7 @@ def run_performance_job(args: RunPerformanceJobArgs):
dotnet_executable_path, "publish",
"-c", "Release",
"-o", os.path.join(payload_dir, "MemoryConsumption"),
"-f", framework,
"-f", tool_framework,
"-r", runtime_id,
"--self-contained",
os.path.join(args.performance_repo_dir, "src", "tools", "ScenarioMeasurement", "MemoryConsumption", "MemoryConsumption.csproj"),
Expand All @@ -859,7 +860,7 @@ def run_performance_job(args: RunPerformanceJobArgs):
dotnet_executable_path, "publish",
"-c", "Release",
"-o", os.path.join(payload_dir, "PerfLabGenericEventSourceForwarder"),
"-f", framework,
"-f", tool_framework,
"-r", runtime_id,
os.path.join(args.performance_repo_dir, "src", "tools", "PerfLabGenericEventSourceForwarder", "PerfLabGenericEventSourceForwarder", "PerfLabGenericEventSourceForwarder.csproj"),
f"/bl:{os.path.join(args.performance_repo_dir, 'artifacts', 'log', build_config, 'PerfLabGenericEventSourceForwarder.binlog')}",
Expand Down
Loading