Add optimization tiers to the Linux perf maps for perfcollect (dotnet/coreclr#24967)
Add optimization tiers to the Linux perf maps for perfcollect
Fixes https://github.com/dotnet/coreclr/issues/23222:
- It looks like module unloads are currently not taken into account. Once they would be taken into account, Although we have method JIT events from `lttng` with the code address and optimization tier, samples can only be associated with method JIT events by associating the time range when the module is loaded with times of samples, and the event times from `lttng` would not necessarily correspond with times from samples taken by `perf`.
- Updated to include the optimization tier in the perf map for each jitted or R2R method code address
- Refactored common code between eventtrace and perfmap for getting jit tiers
Commit migrated from https://github.com/dotnet/coreclr/commit/
d5906ecce405c8ff9476a1ea3d9a297bf5d9991c