File tree Expand file tree Collapse file tree
Samples/Desktop/D3D12HelloWorld/src/HelloWorkGraphs Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ void firstNode(
8080}
8181
8282// --------------------------------------------------------------------------------------------------------------------------------
83- // seconcNode is thread launch, so one thread per input record.
83+ // secondNode is thread launch, so one thread per input record.
8484//
8585// Logs to the UAV and then sends a task to thirdNode
8686// --------------------------------------------------------------------------------------------------------------------------------
@@ -121,7 +121,7 @@ void thirdNode(
121121 // flushing the current work.
122122 if (threadIndex >= inputData.Count ())
123123 return ;
124-
124+
125125 for (uint i = 0 ; i < c_numEntryRecords; i++)
126126 {
127127 g_sum[i] = 0 ;
@@ -141,6 +141,6 @@ void thirdNode(
141141 for (uint l = 0 ; l < c_numEntryRecords; l++)
142142 {
143143 uint recordIndex = c_numEntryRecords + l;
144- UAV[recordIndex] = g_sum[l];
144+ InterlockedAdd ( UAV[recordIndex], g_sum[l]) ;
145145 }
146- }
146+ }
You can’t perform that action at this time.
0 commit comments