More and more working?

This commit is contained in:
mcrcortex
2024-09-23 03:02:18 +10:00
parent 7eaa8483b8
commit ad7660e4d6
4 changed files with 24 additions and 12 deletions

View File

@@ -27,9 +27,12 @@ void addRequest(inout UnpackedNode node) {
printf("Put node decend request");
if (!hasRequested(node)) {
if (requestQueueIndex.x < requestQueueMaxSize) {
//Mark node as having a request submitted to prevent duplicate submissions
requestQueue[atomicAdd(requestQueueIndex.x, 1)] = getRawPos(node);
markRequested(node);
uint atomRes = atomicAdd(requestQueueIndex.x, 1);
if (atomRes < requestQueueMaxSize) {
//Mark node as having a request submitted to prevent duplicate submissions
requestQueue[atomRes] = getRawPos(node);
markRequested(node);
}
}
}
}