Add IBC support to managed build (dotnet/coreclr#10180)
Add a new build switch, `ibcinstrument`, that adds `/Tuning` on the `crossgen`
command line when building System.Private.CoreLib and its peers. Automatically
consume IBC optdata during builds when these conditions are met:
1. `ibcinstrument` is *not* passed to the build,
2. optdata is available
3. ibcmerge is available
Note that `optdata` will not yet be restored with this change; once packages for
master are made available, a new package reference will still need to be added.
This PR attempts to unblock manually testing IBC, as well as surrounding
CI/infrastructure work.
To help produce an IBC-optimized build using manually generated profile data,
run the newly added `tests/scripts/optdata/bootstrap.py` script. It will
configure the build to consume IBC data from a path automatically, and print out
that path where profile data can be copied.
Commit migrated from https://github.com/dotnet/coreclr/commit/
1b64c03493a4b7e4336f0dabbdf4ed980f0d109c