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

Always profile switches in interpreter profiler #20342

Merged
merged 1 commit into from
Oct 16, 2024

Conversation

mpirvu
Copy link
Contributor

@mpirvu mpirvu commented Oct 15, 2024

Before this commit, the interpreter profiler was not collecting data on switches during 'classLoadPhase'. This was done to reduce the overhead of interpreter profiler. However, we have seen cases where, for some methods compiled during 'classLoadPhase' there is no profiling data for some hot switches, making the compiler to infer the wrong block frequencies.
This commit always collects information for switches. We can afford to do so because:

  1. Typically switches are not that frequently executed compared to branches
  2. When using the shared class cache (SCC), IProfiler is turned off during start-up, relying on profiling info stored in SCC in the cold run.

Before this commit, the interpreter profiler was not collecting
data on switches during 'classLoadPhase'. This was done to reduce
the overhead of interpreter profiler. However, we have seen
cases where, for some methods compiled during 'classLoadPhase'
there is no profiling data for some hot switches, making the compiler
to infer the wrong block frequencies.
This commit always collects information for switches. We can afford
to do so because:
1. Typically switches are not that frequently executed compared to branches
2. When using the shared class cache (SCC), IProfiler is turned off during
   start-up, relying on profiling info stored in SCC in the cold run.

Signed-off-by: Marius Pirvu <[email protected]>
@mpirvu mpirvu requested a review from dsouzai as a code owner October 15, 2024 16:19
@mpirvu
Copy link
Contributor Author

mpirvu commented Oct 15, 2024

@dsouzai Could you please review/merge this simple PR? Thanks

@mpirvu
Copy link
Contributor Author

mpirvu commented Oct 15, 2024

jenkins test sanity xlinux jdk17

@dsouzai dsouzai self-assigned this Oct 15, 2024
@mpirvu
Copy link
Contributor Author

mpirvu commented Oct 15, 2024

Tests have passed

@dsouzai dsouzai merged commit f915a55 into eclipse-openj9:master Oct 16, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants