PP: Non-functional: Remove custom allocator and related improvements.
Removed the preprocesser memory pool. Removed extra copies and unnecessary allocations of objects related to the ones that were using the pool. Replaced some allocated pointers with objects instead, generally using more modern techiques. There end up being fewer memory allocations/deletions to get right. Overall combined effect of all changes is to use slightly less memory and run slightly faster (< 1% for both, but noticable). As part of simplifying the code base, this change makes it easier to see PP symbol tracking, which I suspect has an even bigger run-time simplification to make.
This commit is contained in:
parent
bfff871dad
commit
b8387c87d0
7 changed files with 97 additions and 283 deletions
|
|
@ -90,17 +90,6 @@ NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
namespace glslang {
|
||||
|
||||
int TPpContext::InitScanner()
|
||||
{
|
||||
// Add various atoms needed by the CPP line scanner:
|
||||
if (!InitCPP())
|
||||
return 0;
|
||||
|
||||
previous_token = '\n';
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
/////////////////////////////////// Floating point constants: /////////////////////////////////
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue