summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
authorfrsyuki <frsyuki@users.sourceforge.jp>2010-01-15 05:27:44 +0900
committerfrsyuki <frsyuki@users.sourceforge.jp>2010-01-15 05:27:44 +0900
commit8d365458d56cc3ac9ce74d8cc1470ede30465522 (patch)
tree3df7aa435364b49410699efb8ae5637b8b95b416 /cpp
parent55cfbf378e5fcf91d0dffe73f9cab3f3f7414233 (diff)
downloadmsgpack-python-8d365458d56cc3ac9ce74d8cc1470ede30465522.tar.gz
c,cpp: optimize msgpack_zone: variable-length array of chunk -> list of chunk
Diffstat (limited to 'cpp')
-rw-r--r--cpp/Makefile.am2
-rw-r--r--cpp/zone.hpp.erb5
2 files changed, 3 insertions, 4 deletions
diff --git a/cpp/Makefile.am b/cpp/Makefile.am
index 0923362..99f4a32 100644
--- a/cpp/Makefile.am
+++ b/cpp/Makefile.am
@@ -32,7 +32,7 @@ nobase_include_HEADERS = \
libmsgpack_la_LIBADD = -L../c -lmsgpackc
# -version-info CURRENT:REVISION:AGE
-libmsgpack_la_LDFLAGS = -version-info 1:0:0
+libmsgpack_la_LDFLAGS = -version-info 2:0:0
check_PROGRAMS = \
msgpack_test
diff --git a/cpp/zone.hpp.erb b/cpp/zone.hpp.erb
index f1e4624..48988ab 100644
--- a/cpp/zone.hpp.erb
+++ b/cpp/zone.hpp.erb
@@ -120,9 +120,8 @@ void zone::object_destructor(void* obj)
inline void zone::undo_malloc(size_t size)
{
- msgpack_zone_chunk* chunk = base::chunk_array.tail;
- chunk->ptr -= size;
- chunk->free += size;
+ base::chunk_list.ptr -= size;
+ base::chunk_list.free += size;
}
<%0.upto(GENERATION_LIMIT) {|i|%>