Skip to content

Conversation

smarter
Copy link
Member

@smarter smarter commented Jul 8, 2025

Previously when we had some code like:

def userCode: Unit =
...
val x = myExpensiveMacro()
...

The profiler reported the time spent executing the macro as «method userCode» which is misleading. This commit changes it to be reported as «method myExpensiveMacro». This is particularly useful in bottom-up profiling to find which macros we spend the most amount of time in.

Previously when we had some code like:

def userCode: Unit =
  ...
  val x = myExpensiveMacro()
  ...

The profiler reported the time spent executing the macro as `«method userCode»`
which is misleading. This commit changes it to be reported as `«method
myExpensiveMacro»`. This is particularly useful in bottom-up profiling to find
which macros we spend the most amount of time in.
@smarter smarter merged commit 2660b09 into scala:main Jul 8, 2025
29 checks passed
@smarter smarter deleted the profile-macros branch July 8, 2025 12:07
@WojciechMazur WojciechMazur added this to the 3.7.3 milestone Jul 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants