Tarantool development patches archive
 help / color / mirror / Atom feed
From: "Максим Корякшин via Tarantool-patches" <tarantool-patches@dev.tarantool.org>
To: "Maxim Kokryashkin" <max.kokryashkin@gmail.com>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches]  [PATCH luajit v2 0/3] memprof: add demangling capabilities for C functions
Date: Wed, 25 Aug 2021 13:01:07 +0300	[thread overview]
Message-ID: <1629885667.869893665@f466.i.mail.ru> (raw)
In-Reply-To: <cover.1629457244.git.m.kokryashkin@tarantool.org>

[-- Attachment #1: Type: text/plain, Size: 2597 bytes --]


So here are the benchmark results, and they are surprising.
It turns out that dumping all symbols from all shared objects  is 
actually much faster than dumping only the name and address  of
each shared object.
 
==========================================================
tested script:
  package.cpath = "./?.so"
  require "hello"
  for j=1,1e3 do
    misc.memprof.start('./memprof.test')
    misc.memprof.stop()
  end
----------------------------------------------------------
vanilla:
  0,03s user 0,05s system 50% cpu 0,158 total
  0,01s user 0,04s system 88% cpu 0,051 total
  0,01s user 0,05s system 79% cpu 0,071 total
  avg total: 0.093
  avg total per memprof.start/stop: 9.3e-5
  performance relative to vanilla: x1
----------------------------------------------------------
dump only shared objects addresses and names:
  18,83s user 0,36s system 99% cpu 19,285 total
  19,15s user 0,35s system 99% cpu 19,586 total
  18,75s user 0,39s system 99% cpu 19,244 total
  avg total: 19.371
  avg total per memprof.start/stop: 0.019
  performance relative to vanilla: x208.29
----------------------------------------------------------
dump all symbols:
  0,30s user 0,10s system 75% cpu 0,519 total
  0,41s user 0,20s system 52% cpu 1,173 total
  0,31s user 0,08s system 73% cpu 0,531 total
  avg total: 0.741
  avg total per memprof.start/stop: 7.4e-4
  performance relative to vanilla: x7.96
==========================================================
 
Best regards,
Maxim Kokryashkin
  
>Friday, 20.08.21Maxim Kokryashkin <max.kokryashkin@gmail.com>:
> 
>Changes in v2:
>  - Fixed comments as per review by Sergey
>
>
>Maxim Kokryashkin (3):
>  utils: add CRC32 hash implementation
>  memprof: extend symtab with information about .so libs
>  memprof: update memprof parser
>
> CMakeLists.txt | 2 +
> src/CMakeLists.txt | 1 +
> src/Makefile.dep.original | 3 +-
> src/Makefile.original | 2 +-
> src/lj_memprof.c | 60 +++++++++
> src/lj_memprof.h | 3 +-
> src/lj_utils.h | 29 +++++
> src/lj_utils_hash.c | 110 +++++++++++++++++
> src/ljamalg.c | 1 +
> .../misclib-memprof-lapi.test.lua | 5 +-
> tools/CMakeLists.txt | 2 +
> tools/utils/hash.lua | 99 +++++++++++++++
> tools/utils/symtab.lua | 114 +++++++++++++++++-
> 13 files changed, 420 insertions(+), 11 deletions(-)
> create mode 100644 src/lj_utils_hash.c
> create mode 100644 tools/utils/hash.lua
>
>---
>Github branch:  https://github.com/tarantool/luajit/tree/fckxorg/gh-5813-demangling-of-c-symbols
>Issue:  https://github.com/tarantool/tarantool/issues/5813
>
>2.32.0
> 
 

[-- Attachment #2: Type: text/html, Size: 4441 bytes --]

      parent reply	other threads:[~2021-08-25 10:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-20 11:10 Maxim Kokryashkin via Tarantool-patches
2021-08-20 11:10 ` [Tarantool-patches] [PATCH luajit v2 1/3] utils: add CRC32 hash implementation Maxim Kokryashkin via Tarantool-patches
2021-08-30 14:08   ` Sergey Kaplun via Tarantool-patches
2021-08-20 11:10 ` [Tarantool-patches] [PATCH luajit v2 2/3] memprof: extend symtab with information about .so libs Maxim Kokryashkin via Tarantool-patches
2021-08-30 14:10   ` Sergey Kaplun via Tarantool-patches
2021-08-20 11:10 ` [Tarantool-patches] [PATCH luajit v2 3/3] memprof: update memprof parser Maxim Kokryashkin via Tarantool-patches
2021-08-25 10:01 ` Максим Корякшин via Tarantool-patches [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1629885667.869893665@f466.i.mail.ru \
    --to=tarantool-patches@dev.tarantool.org \
    --cc=m.kokryashkin@tarantool.org \
    --cc=max.kokryashkin@gmail.com \
    --subject='Re: [Tarantool-patches]  [PATCH luajit v2 0/3] memprof: add demangling capabilities for C functions' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox