diff options
author | 2016-11-11 10:38:49 -0500 | |
---|---|---|
committer | 2016-11-11 16:42:57 +0000 | |
commit | 58b130681db4432c4937c2cb1b2529de628c6b19 (patch) | |
tree | 7ee14c8c5dd2f4d6e0e4527712ca2987dd8f31c7 /gn | |
parent | 8b9a725823fb195f24a85b5004b988e42fa82ef8 (diff) |
SkFixedAlloc
Looking at SkSmallAlloc hasn't left me terribly impressed. I think we can replace it with something a lot simpler to work with.
That simpler thing's core would be something like SkFixedAlloc, which allocates objects out of a fixed sized buffer, and cleans them up when done.
If needed, we can wrap that with logic to try to allocate out of an SkFixedAlloc, falling back on mallc() when exhausted.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4658
Change-Id: I8d94156ddf98802e42ec0890cff0f06b21f073b0
Reviewed-on: https://skia-review.googlesource.com/4658
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Reed <reed@google.com>
Diffstat (limited to 'gn')
-rw-r--r-- | gn/core.gni | 2 | ||||
-rw-r--r-- | gn/tests.gni | 1 |
2 files changed, 3 insertions, 0 deletions
diff --git a/gn/core.gni b/gn/core.gni index 643b71e0cc..80514c4fc1 100644 --- a/gn/core.gni +++ b/gn/core.gni @@ -124,6 +124,8 @@ skia_core_sources = [ "$_src/core/SkFilterProc.cpp", "$_src/core/SkFilterProc.h", "$_src/core/SkFindAndPlaceGlyph.h", + "$_src/core/SkFixedAlloc.cpp", + "$_src/core/SkFixedAlloc.h", "$_src/core/SkFlattenable.cpp", "$_src/core/SkFlattenableSerialization.cpp", "$_src/core/SkFont.cpp", diff --git a/gn/tests.gni b/gn/tests.gni index 4fa653a037..fb43d796a4 100644 --- a/gn/tests.gni +++ b/gn/tests.gni @@ -62,6 +62,7 @@ tests_sources = [ "$_tests/ExifTest.cpp", "$_tests/FillPathTest.cpp", "$_tests/FitsInTest.cpp", + "$_tests/FixedAllocTest.cpp", "$_tests/FlattenableCustomFactory.cpp", "$_tests/FlattenableFactoryToName.cpp", "$_tests/FlattenDrawableTest.cpp", |