From dd97aab749b6e907133c8018e65379dc86382258 Mon Sep 17 00:00:00 2001 From: tobid7 Date: Tue, 1 Sep 2026 21:16:23 +0200 Subject: [PATCH] insane performance boost (on 3ds) --- include/pd/core/pool.hpp | 3 +++ include/pd/core/timetrace.hpp | 3 +-- source/lithium/pools.cpp | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/include/pd/core/pool.hpp b/include/pd/core/pool.hpp index 529bd28..fd2ccc9 100644 --- a/include/pd/core/pool.hpp +++ b/include/pd/core/pool.hpp @@ -107,6 +107,9 @@ class Pool { pPos = 0; } + /** THE ILLEGAL RESET FUNC */ + void NoReset() { pPos = 0; } + /** * Copy the data of another pool */ diff --git a/include/pd/core/timetrace.hpp b/include/pd/core/timetrace.hpp index a3c4ddd..82c27dc 100644 --- a/include/pd/core/timetrace.hpp +++ b/include/pd/core/timetrace.hpp @@ -144,8 +144,6 @@ class TimeStats { * Timatrace Functions */ namespace TT { -class Res; -using TraceMap = std::map; /** * Data Structure for a TimeTrace Result */ @@ -213,6 +211,7 @@ class Res { /** Protocol */ TimeStats protocol; }; +using TraceMap = std::map; /** * Begin a Trace * @param id Name of the Trace diff --git a/source/lithium/pools.cpp b/source/lithium/pools.cpp index ca4db77..62acd7a 100644 --- a/source/lithium/pools.cpp +++ b/source/lithium/pools.cpp @@ -57,8 +57,8 @@ PD_API const u16& GetIndex(size_t loc) { } PD_API void ResetPools() { - pVtxPool.Reset(); - pIdxPool.Reset(); + pVtxPool.NoReset(); + pIdxPool.NoReset(); } } // namespace Li } // namespace PD \ No newline at end of file