summaryrefslogtreecommitdiff
path: root/talloc_guide.txt
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-09-28 14:37:28 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:59:27 -0500
commita93e366379eff56e886b0a7ee1f5db380a0db1b8 (patch)
treeaabfde50b8eccf94f3140838eef789e4ebf9f5f1 /talloc_guide.txt
parentab5a0d31a37930300470c6e0891ed700f9f42f08 (diff)
downloadsamba-a93e366379eff56e886b0a7ee1f5db380a0db1b8.tar.gz
samba-a93e366379eff56e886b0a7ee1f5db380a0db1b8.tar.bz2
samba-a93e366379eff56e886b0a7ee1f5db380a0db1b8.zip
r2733: added a note on performance
(This used to be commit 171fe8209794bb1e61283126ccc165b43fbcfa62)
Diffstat (limited to 'talloc_guide.txt')
-rw-r--r--talloc_guide.txt12
1 files changed, 12 insertions, 0 deletions
diff --git a/talloc_guide.txt b/talloc_guide.txt
index ae75f73d8e..24438ba722 100644
--- a/talloc_guide.txt
+++ b/talloc_guide.txt
@@ -39,6 +39,18 @@ source/torture/local/talloc.c to clarify how some particular situation
is handled.
+Performance
+-----------
+
+All the additional features of talloc() over malloc() do come at a
+price. We have a simple performance test in Samba4 that measures
+talloc() versus malloc() performance, and it seems that talloc() is
+about 10% slower than malloc() on my x86 Debian Linux box. For Samba,
+the great reduction in code complexity that we get by using talloc
+makes this worthwhile, especially as the total overhead of
+talloc/malloc in Samba is already quite small.
+
+
talloc API
----------