|
17 | 17 | import sys
|
18 | 18 | import zipfile
|
19 | 19 | import stat
|
| 20 | +import tempfile |
20 | 21 |
|
21 | 22 | from os import path
|
22 | 23 | from coreclr_arguments import *
|
@@ -124,39 +125,23 @@ def build_and_run(coreclr_args):
|
124 | 125 |
|
125 | 126 | checked_root = path.join(source_directory, "artifacts", "bin", "coreclr", target_os + "." + coreclr_args.arch + ".Checked")
|
126 | 127 | release_root = path.join(source_directory, "artifacts", "bin", "coreclr", target_os + "." + coreclr_args.arch + ".Release")
|
127 |
| - spmi_temp = path.join(source_directory, "artifacts", "spmi_aspnet_collection") |
128 |
| - |
129 |
| - # Set up/clean up temp dir |
130 |
| - if not os.path.exists(spmi_temp): |
131 |
| - os.makedirs(spmi_temp) |
132 |
| - |
133 |
| - def remove_readonly(func, path, _): |
134 |
| - "Clear the readonly bit and reattempt the removal" |
135 |
| - os.chmod(path, stat.S_IWRITE) |
136 |
| - func(path) |
137 |
| - |
138 |
| - spmi_temp_items = [os.path.join(spmi_temp, item) for item in os.listdir(spmi_temp)] |
139 |
| - for item in spmi_temp_items: |
140 |
| - if os.path.isdir(item): |
141 |
| - shutil.rmtree(item, onerror=remove_readonly) |
142 |
| - else: |
143 |
| - os.remove(item) |
144 | 128 |
|
145 | 129 | # We'll use repo script to install dotnet
|
146 | 130 | dotnet_install_script_name = "dotnet-install.cmd" if is_windows else "dotnet-install.sh"
|
147 | 131 | dotnet_install_script_path = path.join(source_directory, "eng", "common", dotnet_install_script_name)
|
148 | 132 |
|
149 |
| - with TempDir(spmi_temp, skip_cleanup=True) as temp_location: |
| 133 | + with tempfile.TemporaryDirectory() as temp_location: |
150 | 134 |
|
151 | 135 | print ("Executing in " + temp_location)
|
| 136 | + os.chdir(temp_location) |
152 | 137 |
|
153 |
| - # install dotnet 6.0 |
154 |
| - run_command([dotnet_install_script_path, "-Version", "7.0.2"], temp_location, _exit_on_fail=True) |
| 138 | + # install dotnet 8.0 |
| 139 | + run_command([dotnet_install_script_path, "-Version", "8.0.0"], temp_location, _exit_on_fail=True) |
155 | 140 | os.environ['DOTNET_MULTILEVEL_LOOKUP'] = '0'
|
156 | 141 | os.environ['DOTNET_SKIP_FIRST_TIME_EXPERIENCE'] = '1'
|
157 | 142 | dotnet_path = path.join(source_directory, ".dotnet")
|
158 | 143 | dotnet_exe = path.join(dotnet_path, "dotnet.exe") if is_windows else path.join(dotnet_path, "dotnet")
|
159 |
| - run_command([dotnet_exe, "--info"], temp_location, _exit_on_fail=True) |
| 144 | + # run_command([dotnet_exe, "--info"], temp_location, _exit_on_fail=True) |
160 | 145 | os.environ['DOTNET_ROOT'] = dotnet_path
|
161 | 146 |
|
162 | 147 | ## install crank as local tool
|
@@ -190,24 +175,27 @@ def remove_readonly(func, path, _):
|
190 | 175 | ("proxy", "proxy-yarp"),
|
191 | 176 | ("staticfiles", "static"),
|
192 | 177 | ("websocket", "websocket"),
|
193 |
| - ("orchard", "about-sqlite") |
| 178 | + ("orchard", "about-sqlite"), |
| 179 | + ("signalr", "signalr"), |
| 180 | + ("grpc", "grpcaspnetcoreserver-grpcnetclient"), |
| 181 | + ("efcore", "NavigationsQuery"), |
| 182 | + ("efcore", "Funcletization") |
194 | 183 | ]
|
195 | 184 |
|
196 |
| - # configname_scenario_list = [("platform", "plaintext")] |
| 185 | + # configname_scenario_list = [("quic", "read-write")] |
197 | 186 |
|
198 | 187 | # note tricks to get one element tuples
|
199 | 188 |
|
200 | 189 | runtime_options_list = [
|
201 | 190 | ("Dummy=0",),
|
202 | 191 | ("TieredCompilation=0", ),
|
203 |
| - ("TieredPGO=1",), |
| 192 | + ("TieredPGO=0",), |
204 | 193 | ("TieredPGO=1", "ReadyToRun=0"),
|
205 | 194 | ("ReadyToRun=0", "OSR_HitLimit=0", "TC_OnStackReplacement_InitialCounter=10"),
|
206 |
| - ("TieredPGO=1", "ReadyToRun=0", "OSR_HitLimit=0", "TC_OnStackReplacement_InitialCounter=10"), |
207 | 195 | ("TC_PartialCompilation=1",)
|
208 | 196 | ]
|
209 | 197 |
|
210 |
| - # runtime_options_list = [("TieredCompilation=0", )] |
| 198 | + # runtime_options_list = [("Dummy=0", )] |
211 | 199 |
|
212 | 200 | mch_file = path.join(coreclr_args.output_mch_path, "aspnet.run." + target_os + "." + target_arch + ".checked.mch")
|
213 | 201 | benchmark_machine = determine_benchmark_machine(coreclr_args)
|
@@ -288,6 +276,8 @@ def remove_readonly(func, path, _):
|
288 | 276 | command = [mcs_path, "-jitflags", mch_file]
|
289 | 277 | run_command(command, temp_location)
|
290 | 278 |
|
| 279 | + os.chdir(source_directory ) |
| 280 | + |
291 | 281 | def main(main_args):
|
292 | 282 | """ Main entry point
|
293 | 283 |
|
|
0 commit comments