mono
mono copied to clipboard
Investigate heavy stack from ConcurrentQueueSegment
Steps to Reproduce
Make the following change to mono/netcore/build.sh

Then run the following script by following the instructions in it. profileMonoScript.sh.zip
Current Behavior
Heavy stack from ConcurrentQueueSegment, according to the following flamegraph (the highlighted area)

January 8 LLVM AOT flamegraph with ConcurrentQueueSegment<T>.TryDequeue highlighted:

Expected Behavior
ConcurrentQueueSegment which does only few Volatile.Reads should take a small portion of time of the whole program.
On which platforms did you notice this
[ ] macOS [x] Linux [ ] Windows
Version Used:
mono master: 61eb2be2e10c228c5915d90a90b52e7d410c0f25 from Dec 30th, 2019
I'm not seeing this on the Jan 8 flame graph. Can you make sure I'm not missing something? @fanyang-mono
This was fixed by Zoltan's change as well
Fixed by #18377
I made a mistake. This issue still exists. :(