Package: google-perftools
Version: 2.1-2
Severity: normal

I compiled the program below and ran it with google-pprof
using
export LD_PRELOAD="/usr/lib/libprofiler.so.0:$LD_PRELOAD"
export CPUPROFILE="/tmp/prof.out"

and then analysed it using 

$ google-pprof ./a.out  /tmp/prof.out  --text
Using local file ./a.out.
Using local file /tmp/prof.out.
Removing killpg from all stack traces.
Total: 203 samples
     196  96.6%  96.6%      196  96.6% __nss_hosts_lookup
       7   3.4% 100.0%      203 100.0% main
       0   0.0% 100.0%      203 100.0% __libc_start_main
       0   0.0% 100.0%      203 100.0% _start


-- Program:

#include <string.h>
#include <stdio.h>
int main(void) {
    FILE *f = fopen("/dev/zero", "r");

    char buf1[1024 * 1024];
    char buf2[1024 * 1024];
    int i;
    int r;

    fread(buf1, sizeof(buf1), 1, f);
    fread(buf2, sizeof(buf2), 1, f);

    for (i = 0; i < sizeof(buf1); i++)
        buf1[i] = buf2[i] = i + 1;

    buf2[sizeof(buf2)-1]=buf1[sizeof(buf1)-1] = 0;
    
    for (i = 0; i < 1024 * 1024 * 10; i++)
        r |= strcmp(buf1, buf2);

    return r != 0;
}


-- System Information:
Debian Release: jessie/sid
  APT prefers unstable
  APT policy: (980, 'unstable'), (500, 'unstable'), (100, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 3.13-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages google-perftools depends on:
ii  curl                  7.36.0-1
ii  libgoogle-perftools4  2.1-2

Versions of packages google-perftools recommends:
ii  graphviz  2.26.3-16.2
ii  gv        1:3.7.4-1

google-perftools suggests no packages.

-- no debconf information

-- 
Julian Andres Klode  - Debian Developer, Ubuntu Member

See http://wiki.debian.org/JulianAndresKlode and http://jak-linux.org/.

Please do not top-post if possible.


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to