Skip to content

Commit

Permalink
printing raw timestamps
Browse files Browse the repository at this point in the history
  • Loading branch information
John Owens committed Oct 9, 2024
1 parent 9ac46ec commit 84d5923
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion timing-mre.html
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,11 @@
const resultBuffer = this.#resultBuffer;
await resultBuffer.mapAsync(GPUMapMode.READ);
const times = new BigInt64Array(resultBuffer.getMappedRange());
console.log(
"Returned timestamps in result buffer:",
Number(times[1]),
Number(times[0])
);
const duration = Number(times[1] - times[0]);
resultBuffer.unmap();
this.#resultBuffers.push(resultBuffer);
Expand All @@ -148,7 +153,7 @@
}

const workgroupSize = 64;
const memsrcSize = 2 ** 20;
const memsrcSize = 2 ** 24;
const timingHelper = new TimingHelper(device);

const itemsPerWorkgroup = memsrcSize / workgroupSize;
Expand Down

0 comments on commit 84d5923

Please sign in to comment.