Add crossgen2 automated SuperPMI collection of Core_Root libraries (#47818)
authorBruce Forstall <brucefo@microsoft.com>
Sat, 6 Feb 2021 20:45:46 +0000 (10:45 -1000)
committerGitHub <noreply@github.com>
Sat, 6 Feb 2021 20:45:46 +0000 (12:45 -0800)
commit4bc032eb8e348ef61cb1fd813ad274a29bc7a4c8
tree925878adb6bdc09256e534f8f2b803d9f08b1617
parent7081c8e543c0fc1b7ef3dadd83750a39a0017353
Add crossgen2 automated SuperPMI collection of Core_Root libraries (#47818)

* Add crossgen2 automated SuperPMI collection of Core_Root libraries

Linux is excluded; there are uninvestigated crashes doing crossgen2 Linux collections.

I added logic to copy the runtime ".dotnet" directory to Helix machines to use as the
driver for crossgen2, but that doesn't work for cross-platform scenarios (e.g., Windows
x64 .dotnet, x86 Core_Root), so it's commented out for now and the same-Core_Root corerun.exe
is used as the crossgen2 driver.

Add `-collection_type` argument to superpmi-setup.py

Allow copying of .json files to Helix; needed by crossgen2.

Changed superpmi pipeline to run with DEBUG level logging from superpmi.py so it's
easier to see what happened when looking at Helix logs (without having to find and separately
download the superpmi.log file).

Changed superpmi.py to write stdout/stderr files to log on failure, so we can see why
crossgen2 failed.

Fix creation of log file directories when `-log_file` argument specified

Excluded many more native files from superpmi collection setup.

Fixes #47541

Extra:
1. If `-temp_dir` is specified to superpmi.py, normalize it to
an absolute path.
2. Add a superpmi.py collect `-exclude` option to avoid collecting
assemblies known to fail (and cause pop-up failures: see #47552).
(This isn't used by the automated collection, but is generally useful.)
3. Stop logging too-verbose message about CORINFO_SIG_INST handle
array illegal values, since it's "by design" for crossgen2
4. Force lower-casing of JIT-EE version string, for consistency.
eng/pipelines/coreclr/superpmi.yml
eng/pipelines/coreclr/templates/run-superpmi-job.yml
src/coreclr/ToolBox/superpmi/superpmi-shared/spmirecordhelper.h
src/coreclr/scripts/superpmi-setup.py
src/coreclr/scripts/superpmi.proj
src/coreclr/scripts/superpmi.py