Adding benchmark

This commit is contained in:
Dynamitos
2024-07-05 12:02:46 +02:00
parent 8418cdbd11
commit fd8dc5ed0f
47 changed files with 1071 additions and 1010 deletions
+1 -6
View File
@@ -150,14 +150,9 @@ Array<Gfx::Timestamp> TimestampQuery::getResults() {
tail = (tail + 1) % 512;
Array<Gfx::Timestamp> res;
for (uint64 i = 0; i < numTimestamps; ++i) {
if (results[i] < lastMeasure)
{
wrapping += 1ull << graphics->getTimestampValidBits();
}
lastMeasure = results[i];
res.add(Gfx::Timestamp{
.name = pendingTimestamps[firstQuery + i],
.time = std::chrono::nanoseconds(uint64((results[i] + wrapping) * graphics->getTimestampPeriod())),
.time = uint64((results[i] + wrapping) * graphics->getTimestampPeriod()),
});
}
return res;