読者です 読者をやめる 読者になる 読者になる

Linux 4.7の新機能「perf trace calls stack」めも

kernel linux

kernelnewbies.orgのLinux Changesを見てて良さげだなと思った「perf trace calls stack」のめもを。

基本的な使い方は説明が書かれているので、

perfでread、open、closeシステムコールを指定する場合。

masami@saga:~/tmp$ sudo perf trace -e read,open,close cat test.c
#include <stdio.h>

static void print_args(char **argv)
{
        while (*argv) {
                printf("%s\n", *argv++);
        }
}

int main(int argc, char **argv)
{
        print_args(argv);
        return 0;
}
     0.019 ( 0.019 ms): cat/8165 open(filename: 0xf9f9fc78, flags: CLOEXEC                             ) = 3
     0.038 ( 0.002 ms): cat/8165 close(fd: 3                                                           ) = 0
     0.065 ( 0.011 ms): cat/8165 open(filename: 0xfa1a7ed0, flags: CLOEXEC                             ) = 3
     0.070 ( 0.003 ms): cat/8165 read(fd: 3, buf: 0x7fff4703af68, count: 832                           ) = 832
     0.164 ( 0.002 ms): cat/8165 close(fd: 3                                                           ) = 0
     0.447 ( 0.015 ms): cat/8165 open(filename: 0xf9d4b910, flags: CLOEXEC                             ) = 3
     0.474 ( 0.002 ms): cat/8165 close(fd: 3                                                           ) = 0
     0.531 ( 0.012 ms): cat/8165 open(filename: 0x4703cd0b, mode: ISGID|0xfffe0000                     ) = 3
     0.563 ( 0.005 ms): cat/8165 read(fd: 3, buf: 0x7f29fa184000, count: 131072                        ) = 174
     0.581 ( 0.002 ms): cat/8165 read(fd: 3, buf: 0x7f29fa184000, count: 131072                        ) = 0
     0.594 ( 0.002 ms): cat/8165 close(fd: 3                                                           ) = 0
     0.608 ( 0.002 ms): cat/8165 close(fd: 1                                                           ) = 0
     0.612 ( 0.002 ms): cat/8165 close(fd: 2                                                           ) = 0

traceコマンドの場合。

masami@saga:~/tmp$ sudo trace --call dwarf cat ./test.c
#include <stdio.h>

static void print_args(char **argv)
{
        while (*argv) {
                printf("%s\n", *argv++);
        }
}

int main(int argc, char **argv)
{
        print_args(argv);
        return 0;
}
     0.066 ( 0.003 ms): cat/10174 brk(                                                                  ) = 0x13f0000
                                       brk+0x9 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x2c5 (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.106 ( 0.013 ms): cat/10174 access(filename: 0x82769f80, mode: R                                  ) = -1 ENOENT No such file or directory
                                       access+0x7 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1650 (/usr/lib/ld-2.23.so)
     0.130 ( 0.014 ms): cat/10174 open(filename: 0x82767c78, flags: CLOEXEC                             ) = 3
                                       open64+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_read_whole_file+0x26 (/usr/lib/ld-2.23.so)
                                       _dl_load_cache_lookup+0x2d6 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x550 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.138 ( 0.003 ms): cat/10174 fstat(fd: 3, statbuf: 0x7ffc46e20da0                                  ) = 0
                                       _fxstat+0x14 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_read_whole_file+0x3b (/usr/lib/ld-2.23.so)
                                       _dl_load_cache_lookup+0x2d6 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x550 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.157 ( 0.015 ms): cat/10174 mmap(len: 158913, prot: READ, flags: PRIVATE, fd: 3                   ) = 0x7f6882946000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_read_whole_file+0x85 (/usr/lib/ld-2.23.so)
                                       _dl_load_cache_lookup+0x2d6 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x550 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.163 ( 0.002 ms): cat/10174 close(fd: 3                                                           ) = 0
                                       close+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_read_whole_file+0x5b (/usr/lib/ld-2.23.so)
                                       _dl_load_cache_lookup+0x2d6 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x550 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.192 ( 0.011 ms): cat/10174 open(filename: 0x8296fed0, flags: CLOEXEC                             ) = 3
                                       open64+0x7 (/usr/lib/ld-2.23.so)
                                       open_verify.constprop.7+0x58 (/usr/lib/ld-2.23.so)
     0.199 ( 0.003 ms): cat/10174 read(fd: 3, buf: 0x7ffc46e20f48, count: 832                           ) = 832
                                       read+0x7 (/usr/lib/ld-2.23.so)
                                       open_verify.constprop.7+0x9c (/usr/lib/ld-2.23.so)
     0.206 ( 0.002 ms): cat/10174 fstat(fd: 3, statbuf: 0x7ffc46e20de0                                  ) = 0
                                       _fxstat+0x14 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0x5c (/usr/lib/ld-2.23.so)
     0.219 ( 0.009 ms): cat/10174 mmap(len: 4096, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1    ) = 0x7f6882945000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       __libc_memalign+0x7e (/usr/lib/ld-2.23.so)
                                       _dl_new_object+0x86 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0x16d (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x211 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.249 ( 0.015 ms): cat/10174 mmap(len: 3803440, prot: EXEC|READ, flags: PRIVATE|DENYWRITE, fd: 3   ) = 0x7f68823a9000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0x533 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x211 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.276 ( 0.023 ms): cat/10174 mprotect(start: 0x7f6882540000, len: 2097152                          ) = 0
                                       mprotect+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0xdf1 (/usr/lib/ld-2.23.so)
     0.302 ( 0.021 ms): cat/10174 mmap(addr: 0x7f6882740000, len: 24576, prot: READ|WRITE, flags: PRIVATE|DENYWRITE|FIXED, fd: 3, off: 1667072) = 0x7f6882740000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0xe5a (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x211 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.326 ( 0.009 ms): cat/10174 mmap(addr: 0x7f6882746000, len: 14640, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS|FIXED, fd: -1) = 0x7f6882746000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0xf37 (/usr/lib/ld-2.23.so)
                                       _dl_map_object+0x211 (/usr/lib/ld-2.23.so)
                                       openaux+0x30 (/usr/lib/ld-2.23.so)
                                       _dl_catch_error+0x74 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_deps+0x275 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1699 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.338 ( 0.002 ms): cat/10174 close(fd: 3                                                           ) = 0
                                       close+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_map_object_from_fd+0x9d2 (/usr/lib/ld-2.23.so)
     0.364 ( 0.005 ms): cat/10174 mmap(len: 4096, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1    ) = 0x7f6882944000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       __libc_memalign+0x7e (/usr/lib/ld-2.23.so)
                                       _dl_allocate_tls_storage+0x1c (/usr/lib/ld-2.23.so)
                                       init_tls+0xd0 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1cb3 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.376 ( 0.004 ms): cat/10174 mmap(len: 4096, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1    ) = 0x7f6882943000
                                       mmap64+0x3a (/usr/lib/ld-2.23.so)
                                       __libc_memalign+0x7e (/usr/lib/ld-2.23.so)
                                       allocate_dtv+0x22 (/usr/lib/ld-2.23.so)
                                       _dl_allocate_tls_storage+0x62 (/usr/lib/ld-2.23.so)
                                       init_tls+0xd0 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1cb3 (/usr/lib/ld-2.23.so)
                                       _dl_sysdep_start+0x40c (/usr/lib/ld-2.23.so)
                                       _dl_start+0x288 (/usr/lib/ld-2.23.so)
                                       _dl_start_user+0x0 (/usr/lib/ld-2.23.so)
     0.385 ( 0.002 ms): cat/10174 arch_prctl(option: 4098, arg2: 140086844081920, arg3: 140086844076048, arg4: 34, arg5: -1) = 0
                                       init_tls+0x118 (/usr/lib/ld-2.23.so)
                                       dl_main+0x1cb3 (/usr/lib/ld-2.23.so)
     0.474 ( 0.021 ms): cat/10174 mprotect(start: 0x7f6882740000, len: 16384, prot: READ                ) = 0
                                       mprotect+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_protect_relro+0x3d (/usr/lib/ld-2.23.so)
                                       _dl_relocate_object+0x32a (/usr/lib/ld-2.23.so)
     0.498 ( 0.015 ms): cat/10174 mprotect(start: 0x60b000, len: 4096, prot: READ                       ) = 0
                                       mprotect+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_protect_relro+0x3d (/usr/lib/ld-2.23.so)
                                       _dl_relocate_object+0x32a (/usr/lib/ld-2.23.so)
     0.525 ( 0.019 ms): cat/10174 mprotect(start: 0x7f688296d000, len: 4096, prot: READ                 ) = 0
                                       mprotect+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_protect_relro+0x3d (/usr/lib/ld-2.23.so)
                                       _dl_relocate_object+0x32a (/usr/lib/ld-2.23.so)
     0.542 ( 0.011 ms): cat/10174 munmap(addr: 0x7f6882946000, len: 158913                              ) = 0
                                       munmap+0x7 (/usr/lib/ld-2.23.so)
                                       _dl_unload_cache+0x28 (/usr/lib/ld-2.23.so)
                                       dl_main+0x21db (/usr/lib/ld-2.23.so)
no symbols found in /usr/bin/cat, maybe install a debug package?
     0.653 ( 0.002 ms): cat/10174 brk(                                                                  ) = 0x13f0000
                                       __brk+0x9 (/usr/lib/libc-2.23.so)
                                       __sbrk+0x5f (/usr/lib/libc-2.23.so)
                                       __default_morecore+0x9 (/usr/lib/libc-2.23.so)
                                       sysmalloc+0x3ef (/usr/lib/libc-2.23.so)
                                       _int_malloc+0x80d (/usr/lib/libc-2.23.so)
                                       malloc+0x54 (/usr/lib/libc-2.23.so)
                                       _nl_normalize_codeset+0x6a (/usr/lib/libc-2.23.so)
                                       _nl_load_locale_from_archive+0x352 (/usr/lib/libc-2.23.so)
                                       _nl_find_locale+0x43a (/usr/lib/libc-2.23.so)
                                       setlocale+0x48f (/usr/lib/libc-2.23.so)
                                       [0x1a51] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.668 ( 0.009 ms): cat/10174 brk(brk: 0x1411000                                                    ) = 0x1411000
                                       __brk+0x9 (/usr/lib/libc-2.23.so)
                                       __sbrk+0x79 (/usr/lib/libc-2.23.so)
                                       __default_morecore+0x9 (/usr/lib/libc-2.23.so)
                                       sysmalloc+0x3ef (/usr/lib/libc-2.23.so)
                                       _int_malloc+0x80d (/usr/lib/libc-2.23.so)
                                       malloc+0x54 (/usr/lib/libc-2.23.so)
                                       _nl_normalize_codeset+0x6a (/usr/lib/libc-2.23.so)
                                       _nl_load_locale_from_archive+0x352 (/usr/lib/libc-2.23.so)
                                       _nl_find_locale+0x43a (/usr/lib/libc-2.23.so)
                                       setlocale+0x48f (/usr/lib/libc-2.23.so)
                                       [0x1a51] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.706 ( 0.020 ms): cat/10174 open(filename: 0x82513910, flags: CLOEXEC                             ) = 3
                                       _nl_load_locale_from_archive+0x419 (/usr/lib/libc-2.23.so)
     0.713 ( 0.002 ms): cat/10174 fstat(fd: 3, statbuf: 0x7f6882745960                                  ) = 0
                                       __fxstat64+0x14 (/usr/lib/libc-2.23.so)
                                       _nl_load_locale_from_archive+0x443 (/usr/lib/libc-2.23.so)
     0.735 ( 0.016 ms): cat/10174 mmap(len: 2704400, prot: READ, flags: PRIVATE, fd: 3                  ) = 0x7f6882114000
                                       __mmap64+0x3a (/usr/lib/libc-2.23.so)
                                       _nl_load_locale_from_archive+0x46d (/usr/lib/libc-2.23.so)
                                       _nl_find_locale+0x43a (/usr/lib/libc-2.23.so)
                                       setlocale+0x48f (/usr/lib/libc-2.23.so)
                                       [0x1a51] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.748 ( 0.002 ms): cat/10174 close(fd: 3                                                           ) = 0
                                       _nl_load_locale_from_archive+0x4c6 (/usr/lib/libc-2.23.so)
     0.803 ( 0.003 ms): cat/10174 fstat(fd: 1, statbuf: 0x7ffc46e215d0                                  ) = 0
                                       __fxstat64+0x14 (/usr/lib/libc-2.23.so)
                                       [0x1bc7] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.823 ( 0.013 ms): cat/10174 open(filename: 0x46e22d12, mode: ISGID|0xfffe0000                     ) = 3
                                       __GI___libc_open+0x10 (/usr/lib/libc-2.23.so)
                                       [0x1c88] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.830 ( 0.002 ms): cat/10174 fstat(fd: 3, statbuf: 0x7ffc46e215d0                                  ) = 0
                                       __fxstat64+0x14 (/usr/lib/libc-2.23.so)
                                       [0x1cae] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.839 ( 0.002 ms): cat/10174 fadvise64(fd: 3, advice: 2                                            ) = 0
                                       posix_fadvise+0xd (/usr/lib/libc-2.23.so)
                                       [0x1cf1] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.855 ( 0.010 ms): cat/10174 mmap(len: 139264, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1  ) = 0x7f688294b000
                                       __mmap64+0x3a (/usr/lib/libc-2.23.so)
                                       sysmalloc+0x87e (/usr/lib/libc-2.23.so)
                                       _int_malloc+0x80d (/usr/lib/libc-2.23.so)
                                       malloc+0x54 (/usr/lib/libc-2.23.so)
                                       [0x5ed9] (/usr/bin/cat)
                                       [0x2412] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.877 ( 0.005 ms): cat/10174 read(fd: 3, buf: 0x7f688294c000, count: 131072                        ) = 174
                                       __GI___libc_read+0x10 (/usr/lib/libc-2.23.so)
                                       [0x5286] (/usr/bin/cat)
                                       [0x2463] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.900 ( 0.017 ms): cat/10174 write(fd: 1, buf: 0x7f688294c000, count: 174                          ) = 174
                                       __GI___libc_write+0x10 (/usr/lib/libc-2.23.so)
                                       [0x52e6] (/usr/bin/cat)
                                       [0x2c1e] (/usr/bin/cat)
                                       [0x2449] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.908 ( 0.002 ms): cat/10174 read(fd: 3, buf: 0x7f688294c000, count: 131072                        ) = 0
                                       __GI___libc_read+0x10 (/usr/lib/libc-2.23.so)
                                       [0x5286] (/usr/bin/cat)
                                       [0x2463] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.924 ( 0.010 ms): cat/10174 munmap(addr: 0x7f688294b000, len: 139264                              ) = 0
                                       __GI___munmap+0x7 (/usr/lib/libc-2.23.so)
                                       [0x21cd] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.932 ( 0.002 ms): cat/10174 close(fd: 3                                                           ) = 0
                                       __GI___libc_close+0x10 (/usr/lib/libc-2.23.so)
                                       [0x21e4] (/usr/bin/cat)
                                       __libc_start_main+0xf1 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.950 ( 0.002 ms): cat/10174 close(fd: 1                                                           ) = 0
                                       _IO_file_close+0xb (/usr/lib/libc-2.23.so)
                                       _IO_file_close_it@@GLIBC_2.2.5+0x120 (/usr/lib/libc-2.23.so)
                                       fclose@@GLIBC_2.2.5+0x19f (/usr/lib/libc-2.23.so)
                                       [0x61fa] (/usr/bin/cat)
                                       [0x2b02] (/usr/bin/cat)
                                       __run_exit_handlers+0xe8 (/usr/lib/libc-2.23.so)
                                       [0x35c35] (/usr/lib/libc-2.23.so)
                                       __libc_start_main+0xf8 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.959 ( 0.002 ms): cat/10174 close(fd: 2                                                           ) = 0
                                       _IO_file_close+0xb (/usr/lib/libc-2.23.so)
                                       _IO_file_close_it@@GLIBC_2.2.5+0x120 (/usr/lib/libc-2.23.so)
                                       fclose@@GLIBC_2.2.5+0x19f (/usr/lib/libc-2.23.so)
                                       [0x61fa] (/usr/bin/cat)
                                       [0x2b25] (/usr/bin/cat)
                                       __run_exit_handlers+0xe8 (/usr/lib/libc-2.23.so)
                                       [0x35c35] (/usr/lib/libc-2.23.so)
                                       __libc_start_main+0xf8 (/usr/lib/libc-2.23.so)
                                       [0x25d9] (/usr/bin/cat)
     0.966 ( 0.000 ms): cat/10174 exit_group(                                                           )

Working With Unix Processes (English Edition)

Working With Unix Processes (English Edition)