Changes

Jump to: navigation, search

OpenMP Debugging in Visual Studio / Team Debug

1,097 bytes added, 17:13, 6 December 2017
Case B - Using the Parallel Stacks and the Parallel Watch Window
And then in our Parallel Watch Window, we will check on the Flag icon in the top corner, which will only watch the threads we have flagged:
[[File:Parallelwatch-step4-flags-checked.PNG|300px|center|Foo(i)]]
 
Now, we can only focus on the i values for Main Thread and Worker 1. As we step through each breakpoint, the Parallel Watch Window will only show rows that have to do with any of our flagged threads.
[[File:Parallelwatch-step5-nothreads.PNG|300px|center|Foo(i)]]
We can see that in this stack frame, which is in method cough(i), nothing shows because our two flagged threads don't have that stack frame.
 
Following Main Thread and Worker 1:
 
Finally, when we hit the breakpoint where zoo(i) gets called, we can see Main Thread picking up the work, and the value of i upon entering the function is set to 1.
[[File:Parallelwatch-step6.PNG|300px|center|Foo(i)]]
The Parallel Stacks Window also shows just our flagged threads. The blue highlighted boxes are Main Thread's stack, and the right box is Worker 1' stack.
 
We keep stepping through the breakpoints. Next, we see Worker 1's next stack frame, which is the point where it calls vroom(i) from within doo(i).
[[File:Parallelwatch-step7.PNG|300px|center|Foo(i)]]
At this point, the value of i is 100. At doo(), it had been multiplied by 100.
==Case C==
92
edits

Navigation menu