LImiting Mix to certain thread

LImiting Mix to certain thread

If your application used several threads but you knew for instance that you were only interested in thread 1, is there a way to tell mix and/or pin not to collect statistics on the other threads, with the goal of speeding things up?

2 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Because of the way mix works you don't really save anything by doing just one thread. The algorithm scans each block for events once at JIT-ing time. At runtime we increment one counter per block execution. Then at the end of execution, we multiply the block execution counts by the block event observations from JIT time, and sum everything up and print it out. The block execution counts have to be per-thread. And since they all share the same code-cache there is no way to count for some and not others. It might actually be slower if we had to check for thread ids and count conditionally.

Leave a Comment

Please sign in to add a comment. Not a member? Join today