PP: Non-functional: Remove custom allocator and related improvements.
authorJohn Kessenich <cepheus@frii.com>
Tue, 20 Dec 2016 04:57:06 +0000 (21:57 -0700)
committerJohn Kessenich <cepheus@frii.com>
Tue, 20 Dec 2016 04:57:06 +0000 (21:57 -0700)
commitb8387c87d01fa903f97976c606755e922921c227
tree3e3026678f38dab0d2de64e2bcb79ede14bcaeaf
parentbfff871dad81be872d5585112933f91ee317f60b
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.
glslang/MachineIndependent/preprocessor/Pp.cpp
glslang/MachineIndependent/preprocessor/PpContext.cpp
glslang/MachineIndependent/preprocessor/PpContext.h
glslang/MachineIndependent/preprocessor/PpMemory.cpp
glslang/MachineIndependent/preprocessor/PpScanner.cpp
glslang/MachineIndependent/preprocessor/PpSymbols.cpp
glslang/MachineIndependent/preprocessor/PpTokens.cpp