All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: Function Tracing Fails
       [not found] <CAOG=51zc2Xu2yNd-3YWhOXZiMb7_c1xYzN_ZS1x+PHP0kRz=LA@mail.gmail.com>
@ 2018-07-30 12:55 ` Mathieu Desnoyers
  2018-07-30 13:50 ` Geneviève Bastien
       [not found] ` <fc0a009e-da8e-8838-399a-b646b1ae088d@versatic.net>
  2 siblings, 0 replies; 5+ messages in thread
From: Mathieu Desnoyers @ 2018-07-30 12:55 UTC (permalink / raw)
  To: paramesh p; +Cc: lttng-dev


[-- Attachment #1.1: Type: text/plain, Size: 11433 bytes --]

----- On Jul 29, 2018, at 9:29 PM, paramesh p <params16jan@gmail.com> wrote: 

> Hi,
> I am trying to use Function Tracing for my application running in 32-bit ARM
> Platform. I have added below lines in my makefile for enabling Trace Data for
> function tracing

> AM_CFLAGS += -g -O0 -finstrument-functions
> AM_CXXFLAGS += -g -O0 -finstrument-functions

> **(My App have both C && CPP files, So I added CFLAGS & CXXFLAGS).

> I am running below commands,
> $lttng create session1
> $lttng enable-event -u -a --loglevel-only TRACE_DEBUG_FUNCTION
> $lttng start
> $LD_PRELOAD=liblttng-ust-cyg-profile.so.0.0.0 my_test_app
> $lttng start
> $babeltrace /home/root/lttng-traces/session1

> Its showing nothing.

> I tried with below event-enable command also. There is no data
> $lttng enable-event -u -a --loglevel TRACE_DEBUG_FUNCTION

> But If I use the command, "lttng enable-event -u -a" for enabling the event, I
> am getting below output from babeltrace,

> [22:25:30.812389281] (+?.?????????) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0xAD1A9000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:30.812496469] (+0.000107188) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DFF0000, sopath = "/usr/lib/xxx.so", size = 19540, mtime =
> 1532369202 }
> [22:25:30.812604177] (+0.000107708) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4E120000, sopath = "/usr/lib/libcutils.so.0.0.0", size = 48624,
> mtime = 1532323462 }
> [22:25:30.812655219] (+0.000051042) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DC80000, sopath = "/lib/ [ http://libpthread-2.22.so/ |
> libpthread-2.22.so ] ", size = 94976, mtime = 1532322845 }
> [22:25:30.812701677] (+0.000046458) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DB20000, sopath = "/lib/ [ http://libc-2.22.so/ | libc-2.22.so
> ] ", size = 1304484, mtime = 1532322845 }
> [22:25:30.812757927] (+0.000056250) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0xAD15B000, sopath = "/usr/lib/liblttng-ust.so.0.0.0", size =
> 315248, mtime = 1532324280 }
> [22:25:30.812814229] (+0.000056302) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0xAD149000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:30.812860635] (+0.000046406) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DEC0000, sopath = "/lib/ [ http://librt-2.22.so/ |
> librt-2.22.so ] ", size = 28380, mtime = 1532322845 }
> [22:25:30.812904438] (+0.000043803) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DCB0000, sopath = "/lib/ [ http://libdl-2.22.so/ |
> libdl-2.22.so ] ", size = 11236, mtime = 1532322845 }
> [22:25:30.812959125] (+0.000054687) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0", size = 29052,
> mtime = 1532323584 }
> [22:25:30.813013969] (+0.000054844) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0", size =
> 26152, mtime = 1532323584 }
> [22:25:30.813485479] (+0.000471510) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0", size =
> 13084, mtime = 1532323584 }
> [22:25:30.813600792] (+0.000115313) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DAE0000, sopath = "/lib/ [ http://ld-2.22.so/ | ld-2.22.so ] ",
> size = 139632, mtime = 1532322845 }
> [22:25:30.813663656] (+0.000062864) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DFC0000, sopath = "/usr/lib/xxx.so.1.0.0", size = 19456, mtime
> = 1532323510 }
> [22:25:30.813720635] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4E030000, sopath = "/usr/lib/xxx.so.1.6.0", size = 142164, mtime
> = 1532323441 }
> [22:25:30.813776990] (+0.000056355) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4E060000, sopath = "/usr/lib/xxx.so.0.0.0", size = 265304, mtime
> = 1532324468 }
> [22:25:30.813843917] (+0.000066927) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DEA0000, sopath = "/usr/lib/xxx.so.0.0.0", size = 84016, mtime
> = 1532324363 }
> [22:25:30.813884385] (+0.000040468) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DFE0000, sopath = "/usr/lib/xxx.so", size = 34204, mtime =
> 1532324426 }
> [22:25:30.813940479] (+0.000056094) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DFD0000, sopath = "/usr/lib/xxx.so", size = 7388, mtime =
> 1532324388 }
> [22:25:30.813993604] (+0.000053125) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4E000000, sopath = "/usr/lib/xxx.so", size = 33152, mtime =
> 1532323414 }
> [22:25:30.814049333] (+0.000055729) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DEE0000, sopath = "/usr/lib/libstdc++.so.6.0.20", size =
> 869236, mtime = 1532323320 }
> [22:25:30.814094177] (+0.000044844) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DCD0000, sopath = "/lib/ [ http://libm-2.22.so/ | libm-2.22.so
> ] ", size = 441372, mtime = 1532322845 }
> [22:25:30.814234177] (+0.000140000) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DE80000, sopath = "/lib/libgcc_s.so.1", size = 118608, mtime =
> 1532323098 }
> [22:25:30.814427615] (+0.000193438) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x8000, sopath = " /usr/bin/my_test_app ", size = 54540, mtime =
> 1532369202 }
> [22:25:30.828436677] (+0.014009062) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0xAEC57000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:30.828634958] (+0.000198281) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 1
> }, { baddr = 0x4DCD0000, sopath = "/lib/ [ http://libm-2.22.so/ | libm-2.22.so
> ] ", size = 441372, mtime = 1532322845 }
> [22:25:30.829786104] (+0.001151146) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DB20000, sopath = "/lib/ [ http://libc-2.22.so/ | libc-2.22.so
> ] ", size = 1304484, mtime = 1532322845 }
> [22:25:30.829910219] (+0.000124115) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0xAEC09000, sopath = "/usr/lib/liblttng-ust.so.0.0.0", size =
> 315248, mtime = 1532324280 }
> [22:25:30.829996000] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0xAEBF7000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:30.830067510] (+0.000071510) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DEC0000, sopath = "/lib/ [ http://librt-2.22.so/ |
> librt-2.22.so ] ", size = 28380, mtime = 1532322845 }
> [22:25:30.830118031] (+0.000050521) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DCB0000, sopath = "/lib/ [ http://libdl-2.22.so/ |
> libdl-2.22.so ] ", size = 11236, mtime = 1532322845 }
> [22:25:30.830175010] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0", size = 29052,
> mtime = 1532323584 }
> [22:25:30.830245271] (+0.000070261) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0", size =
> 26152, mtime = 1532323584 }
> [22:25:30.830316521] (+0.000071250) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 0
> }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0", size =
> 13084, mtime = 1532323584 }
> [22:25:34.384458499] (+3.554141978) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0xAF584000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:34.385048967] (+0.000590468) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DCD0000, sopath = "/lib/ [ http://libm-2.22.so/ | libm-2.22.so
> ] ", size = 441372, mtime = 1532322845 }
> [22:25:34.385146415] (+0.000097448) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DB20000, sopath = "/lib/ [ http://libc-2.22.so/ | libc-2.22.so
> ] ", size = 1304484, mtime = 1532322845 }
> [22:25:34.385251832] (+0.000105417) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0xAF536000, sopath = "/usr/lib/liblttng-ust.so.0.0.0", size =
> 315248, mtime = 1532324280 }
> [22:25:34.385354228] (+0.000102396) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0xAF524000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:34.385444384] (+0.000090156) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DEC0000, sopath = "/lib/ [ http://librt-2.22.so/ |
> librt-2.22.so ] ", size = 28380, mtime = 1532322845 }
> [22:25:34.385530165] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DCB0000, sopath = "/lib/ [ http://libdl-2.22.so/ |
> libdl-2.22.so ] ", size = 11236, mtime = 1532322845 }
> [22:25:34.385607613] (+0.000077448) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0", size = 29052,
> mtime = 1532323584 }
> [22:25:34.385677978] (+0.000070365) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0", size =
> 26152, mtime = 1532323584 }
> [22:25:34.385773655] (+0.000095677) ZZZ ust_baddr_statedump:soinfo: { cpu_id = 2
> }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0", size =
> 13084, mtime = 1532323584 }

> Note: I have changed the Target Name as 'ZZZ' and some of the library name as
> 'xxx' in the above log for some confidential issues.

> Please guide me where I am making mistake and Please give your input on how to
> check the application compiled with function instrument information for
> tracing. I verified that application compiled with debugging information, by
> running gdb command. Below is the output of gdb command,

> /usr/bin # gdb my_test_app
> GNU gdb (GDB) 7.9.1
> Copyright (C) 2015 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later < [ http://gnu.org/licenses/gpl.html
> | http://gnu.org/licenses/gpl.html ] >
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "arm-oe-linux-gnueabi".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> < [ http://www.gnu.org/software/gdb/bugs/ |
> http://www.gnu.org/software/gdb/bugs/ ] >.
> Find the GDB manual and other documentation resources online at:
> < [ http://www.gnu.org/software/gdb/documentation/ |
> http://www.gnu.org/software/gdb/documentation/ ] >.
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from my_test_app ...done.
> (gdb)
> (gdb) exit
> I am not sure whether it is compiled with finstrumentation information.

We would need the output of 

make clean 
make V=1 

when you compile your project, so we can effectively see how the compiler is invoked. 

Thanks, 

Mathieu 

> Thanks in Advance,
> Paramesh

> _______________________________________________
> lttng-dev mailing list
> lttng-dev@lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

-- 
Mathieu Desnoyers 
EfficiOS Inc. 
http://www.efficios.com 

[-- Attachment #1.2: Type: text/html, Size: 13835 bytes --]

[-- Attachment #2: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Function Tracing Fails
       [not found] <CAOG=51zc2Xu2yNd-3YWhOXZiMb7_c1xYzN_ZS1x+PHP0kRz=LA@mail.gmail.com>
  2018-07-30 12:55 ` Function Tracing Fails Mathieu Desnoyers
@ 2018-07-30 13:50 ` Geneviève Bastien
       [not found] ` <fc0a009e-da8e-8838-399a-b646b1ae088d@versatic.net>
  2 siblings, 0 replies; 5+ messages in thread
From: Geneviève Bastien @ 2018-07-30 13:50 UTC (permalink / raw)
  To: lttng-dev


[-- Attachment #1.1: Type: text/plain, Size: 12169 bytes --]

Hi Paramesh,


One way to know if your app is really compiled with
-finstrument-functions is doing


$ objdump -d my_test_app | grep cyg


You would typically see something like this:

0000000000001250 <__cyg_profile_func_enter@plt>:
    1250:    ff 25 fa 2d 20 00        jmpq   *0x202dfa(%rip)        #
204050 <__cyg_profile_func_enter@GLIBC_2.2.5>
0000000000001260 <__cyg_profile_func_exit@plt>:
    1260:    ff 25 f2 2d 20 00        jmpq   *0x202df2(%rip)        #
204058 <__cyg_profile_func_exit@GLIBC_2.2.5>
    14a8:    e8 a3 fd ff ff           callq  1250
<__cyg_profile_func_enter@plt>
    16d8:    e8 83 fb ff ff           callq  1260
<__cyg_profile_func_exit@plt>
    19c5:    e8 86 f8 ff ff           callq  1250
<__cyg_profile_func_enter@plt>
    19e2:    e9 79 f8 ff ff           jmpq   1260
<__cyg_profile_func_exit@plt>
    1a0d:    e8 3e f8 ff ff           callq  1250
<__cyg_profile_func_enter@plt>

If you see nothing, as Mathieu said, you can check the individual make
commands and see what flags are being used on the command line.

Geneviève


On 2018-07-29 09:29 PM, paramesh p wrote:
> Hi,
>    I am trying to use Function Tracing for my application running in
> 32-bit ARM Platform. I have added below lines in my makefile for
> enabling Trace Data for function tracing 
>
> AM_CFLAGS += -g -O0 -finstrument-functions
> AM_CXXFLAGS += -g -O0 -finstrument-functions 
>
> **(My App have both C && CPP files, So I added CFLAGS & CXXFLAGS). 
>
> I am running below commands,
> $lttng create session1
> $lttng enable-event -u -a --loglevel-only TRACE_DEBUG_FUNCTION
> $lttng start
> $LD_PRELOAD=liblttng-ust-cyg-profile.so.0.0.0 my_test_app 
> $lttng start
> $babeltrace /home/root/lttng-traces/session1
>
> Its showing nothing.
>
> I tried with below event-enable command also. There is no data
> $lttng enable-event -u -a --loglevel TRACE_DEBUG_FUNCTION 
>
> But If I use the command, "lttng enable-event -u -a"  for enabling the
> event, I am getting below output from babeltrace,
>
> [22:25:30.812389281] (+?.?????????) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD1A9000, sopath =
> "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
> 1532324280 }
> [22:25:30.812496469] (+0.000107188) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFF0000, sopath = "/usr/lib/xxx.so", size =
> 19540, mtime = 1532369202 }
> [22:25:30.812604177] (+0.000107708) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E120000, sopath =
> "/usr/lib/libcutils.so.0.0.0", size = 48624, mtime = 1532323462 }
> [22:25:30.812655219] (+0.000051042) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DC80000, sopath = "/lib/libpthread-2.22.so
> <http://libpthread-2.22.so>", size = 94976, mtime = 1532322845 }
> [22:25:30.812701677] (+0.000046458) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so
> <http://libc-2.22.so>", size = 1304484, mtime = 1532322845 }
> [22:25:30.812757927] (+0.000056250) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD15B000, sopath =
> "/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
> [22:25:30.812814229] (+0.000056302) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD149000, sopath =
> "/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
> 1532324280 }
> [22:25:30.812860635] (+0.000046406) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so
> <http://librt-2.22.so>", size = 28380, mtime = 1532322845 }
> [22:25:30.812904438] (+0.000043803) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so
> <http://libdl-2.22.so>", size = 11236, mtime = 1532322845 }
> [22:25:30.812959125] (+0.000054687) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE10000, sopath =
> "/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
> [22:25:30.813013969] (+0.000054844) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE00000, sopath =
> "/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
> [22:25:30.813485479] (+0.000471510) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DD60000, sopath =
> "/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }
> [22:25:30.813600792] (+0.000115313) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DAE0000, sopath = "/lib/ld-2.22.so
> <http://ld-2.22.so>", size = 139632, mtime = 1532322845 }
> [22:25:30.813663656] (+0.000062864) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFC0000, sopath = "/usr/lib/xxx.so.1.0.0",
> size = 19456, mtime = 1532323510 }
> [22:25:30.813720635] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E030000, sopath = "/usr/lib/xxx.so.1.6.0",
> size = 142164, mtime = 1532323441 }
> [22:25:30.813776990] (+0.000056355) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E060000, sopath = "/usr/lib/xxx.so.0.0.0",
> size = 265304, mtime = 1532324468 }
> [22:25:30.813843917] (+0.000066927) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEA0000, sopath = "/usr/lib/xxx.so.0.0.0",
> size = 84016, mtime = 1532324363 }
> [22:25:30.813884385] (+0.000040468) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFE0000, sopath = "/usr/lib/xxx.so", size =
> 34204, mtime = 1532324426 }
> [22:25:30.813940479] (+0.000056094) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFD0000, sopath = "/usr/lib/xxx.so", size =
> 7388, mtime = 1532324388 }
> [22:25:30.813993604] (+0.000053125) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E000000, sopath = "/usr/lib/xxx.so", size =
> 33152, mtime = 1532323414 }
> [22:25:30.814049333] (+0.000055729) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEE0000, sopath =
> "/usr/lib/libstdc++.so.6.0.20", size = 869236, mtime = 1532323320 }
> [22:25:30.814094177] (+0.000044844) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so
> <http://libm-2.22.so>", size = 441372, mtime = 1532322845 }
> [22:25:30.814234177] (+0.000140000) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE80000, sopath = "/lib/libgcc_s.so.1",
> size = 118608, mtime = 1532323098 }
> [22:25:30.814427615] (+0.000193438) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x8000, sopath = "/usr/bin/my_test_app", size
> = 54540, mtime = 1532369202 }
> [22:25:30.828436677] (+0.014009062) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAEC57000, sopath =
> "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
> 1532324280 }
> [22:25:30.828634958] (+0.000198281) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so
> <http://libm-2.22.so>", size = 441372, mtime = 1532322845 }
> [22:25:30.829786104] (+0.001151146) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so
> <http://libc-2.22.so>", size = 1304484, mtime = 1532322845 }
> [22:25:30.829910219] (+0.000124115) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0xAEC09000, sopath =
> "/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
> [22:25:30.829996000] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0xAEBF7000, sopath =
> "/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
> 1532324280 }
> [22:25:30.830067510] (+0.000071510) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so
> <http://librt-2.22.so>", size = 28380, mtime = 1532322845 }
> [22:25:30.830118031] (+0.000050521) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so
> <http://libdl-2.22.so>", size = 11236, mtime = 1532322845 }
> [22:25:30.830175010] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DE10000, sopath =
> "/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
> [22:25:30.830245271] (+0.000070261) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DE00000, sopath =
> "/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
> [22:25:30.830316521] (+0.000071250) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DD60000, sopath =
> "/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }
> [22:25:34.384458499] (+3.554141978) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF584000, sopath =
> "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
> 1532324280 }
> [22:25:34.385048967] (+0.000590468) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so
> <http://libm-2.22.so>", size = 441372, mtime = 1532322845 }
> [22:25:34.385146415] (+0.000097448) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so
> <http://libc-2.22.so>", size = 1304484, mtime = 1532322845 }
> [22:25:34.385251832] (+0.000105417) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF536000, sopath =
> "/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
> [22:25:34.385354228] (+0.000102396) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF524000, sopath =
> "/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
> 1532324280 }
> [22:25:34.385444384] (+0.000090156) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so
> <http://librt-2.22.so>", size = 28380, mtime = 1532322845 }
> [22:25:34.385530165] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so
> <http://libdl-2.22.so>", size = 11236, mtime = 1532322845 }
> [22:25:34.385607613] (+0.000077448) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DE10000, sopath =
> "/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
> [22:25:34.385677978] (+0.000070365) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DE00000, sopath =
> "/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
> [22:25:34.385773655] (+0.000095677) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DD60000, sopath =
> "/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }
>
> Note: I have changed the Target Name as 'ZZZ' and some of the library
> name as 'xxx' in the above log for some confidential issues.
>
>
> Please guide me where I am making mistake and Please give your input
> on how to check the application compiled with function instrument
> information for tracing. I verified that application compiled with
> debugging information, by running gdb command. Below is the output of
> gdb command,
>
> /usr/bin # gdb my_test_app
> GNU gdb (GDB) 7.9.1
> Copyright (C) 2015 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later
> <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "arm-oe-linux-gnueabi".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
> <http://www.gnu.org/software/gdb/documentation/>.
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from my_test_app...done.
> (gdb)
> (gdb) exit
> I am not sure whether it is compiled with finstrumentation information.
>
> Thanks in Advance,
> Paramesh 
>
>
>
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev@lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev


[-- Attachment #1.2: Type: text/html, Size: 21627 bytes --]

[-- Attachment #2: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Function Tracing Fails
       [not found] ` <fc0a009e-da8e-8838-399a-b646b1ae088d@versatic.net>
@ 2018-08-07 21:20   ` paramesh p
       [not found]   ` <CAOG=51wKyQN6Q1F=Qn_JYfu4aPjK1PnD79S0NJuxKei8o1e+HA@mail.gmail.com>
  1 sibling, 0 replies; 5+ messages in thread
From: paramesh p @ 2018-08-07 21:20 UTC (permalink / raw)
  To: Geneviève Bastien, mathieu.desnoyers; +Cc: lttng-dev


[-- Attachment #1.1: Type: text/plain, Size: 14340 bytes --]

Sorry for the delayed response,

@Mathieu,
    I have attached the build log.  The Project I am working is Yocto
Project based build system. My App uses the shared object "libhw.so". So,
it built first. As I said before,below are the flag I added

AM_CFLAGS += -g -O0 -finstrument-functions
AM_CXXFLAGS += -g -O0 -finstrument-functions


  From the log I found that "-finstrument-functions" flag included in
compiling all the source files, ' libhw.la'  file and  'my_test_app'
binary, but not included for compiling  'libhw.so'. I am not sure why? My
question is, as you see my shared object and binary includes following so's
"libtinyalsa.so libexpat.so libbinder.so libutils.so libhwwrapper.so
libhardware.so libcutils.so liblog.so". Are all these need to be compiled
with finstrument flag. In that case, it will increase my workload, since
some of them are custom build and some from the libs and each of them might
have their own dependents.


@gen,
    objdump doesn't support arm architecture. So, I used
"arm-linux-gnueabi-objdump" tool. I could see cyg information to all my
object files but I could not see for "libhw.so" and "my_test_app" files.
    cyg information of one of my source file,

$ arm-linux-gnueabi-objdump -d libhw_la-hw_api.o | grep cyg

      20:       ebfffffe        bl      0 <__cyg_profile_func_enter>

      30:       eafffffe        b       0 <__cyg_profile_func_exit>

      64:       ebfffffe        bl      0 <__cyg_profile_func_enter>

      a4:       ebfffffe        bl      0 <__cyg_profile_func_exit>

      .....................

      .....................

      2548:       ebfffffe        bl      0 <__cyg_profile_func_exit>

      258c:       ebfffffe        bl      0 <__cyg_profile_func_enter>

      25d0:       ebfffffe        bl      0 <__cyg_profile_func_exit>

      25e8:       ebfffffe        bl      0 <__cyg_profile_func_exit>



Please help me.

Thanks in Advance,
Paramesh





On Mon, Jul 30, 2018 at 6:50 AM, Geneviève Bastien <gbastien@versatic.net>
wrote:

> Hi Paramesh,
>
>
> One way to know if your app is really compiled with -finstrument-functions
> is doing
>
>
> $ objdump -d my_test_app | grep cyg
>
> You would typically see something like this:
>
> 0000000000001250 <__cyg_profile_func_enter@plt>:
>     1250:    ff 25 fa 2d 20 00        jmpq   *0x202dfa(%rip)        #
> 204050 <__cyg_profile_func_enter@GLIBC_2.2.5>
> <__cyg_profile_func_enter@GLIBC_2.2.5>
> 0000000000001260 <__cyg_profile_func_exit@plt>:
>     1260:    ff 25 f2 2d 20 00        jmpq   *0x202df2(%rip)        #
> 204058 <__cyg_profile_func_exit@GLIBC_2.2.5>
> <__cyg_profile_func_exit@GLIBC_2.2.5>
>     14a8:    e8 a3 fd ff ff           callq  1250
> <__cyg_profile_func_enter@plt>
>     16d8:    e8 83 fb ff ff           callq  1260
> <__cyg_profile_func_exit@plt>
>     19c5:    e8 86 f8 ff ff           callq  1250
> <__cyg_profile_func_enter@plt>
>     19e2:    e9 79 f8 ff ff           jmpq   1260
> <__cyg_profile_func_exit@plt>
>     1a0d:    e8 3e f8 ff ff           callq  1250
> <__cyg_profile_func_enter@plt>
>
> If you see nothing, as Mathieu said, you can check the individual make
> commands and see what flags are being used on the command line.
>
> Geneviève
>
>
>
> On 2018-07-29 09:29 PM, paramesh p wrote:
>
> Hi,
>    I am trying to use Function Tracing for my application running in
> 32-bit ARM Platform. I have added below lines in my makefile for enabling
> Trace Data for function tracing
>
> AM_CFLAGS += -g -O0 -finstrument-functions
> AM_CXXFLAGS += -g -O0 -finstrument-functions
>
> **(My App have both C && CPP files, So I added CFLAGS & CXXFLAGS).
>
> I am running below commands,
> $lttng create session1
> $lttng enable-event -u -a --loglevel-only TRACE_DEBUG_FUNCTION
> $lttng start
> $LD_PRELOAD=liblttng-ust-cyg-profile.so.0.0.0 my_test_app
> $lttng start
> $babeltrace /home/root/lttng-traces/session1
>
> Its showing nothing.
>
> I tried with below event-enable command also. There is no data
> $lttng enable-event -u -a --loglevel TRACE_DEBUG_FUNCTION
>
> But If I use the command, "lttng enable-event -u -a"  for enabling the
> event, I am getting below output from babeltrace,
>
> [22:25:30.812389281] (+?.?????????) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD1A9000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:30.812496469] (+0.000107188) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFF0000, sopath = "/usr/lib/xxx.so", size =
> 19540, mtime = 1532369202 }
> [22:25:30.812604177] (+0.000107708) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E120000, sopath = "/usr/lib/libcutils.so.0.0.0",
> size = 48624, mtime = 1532323462 }
> [22:25:30.812655219] (+0.000051042) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DC80000, sopath = "/lib/libpthread-2.22.so",
> size = 94976, mtime = 1532322845 }
> [22:25:30.812701677] (+0.000046458) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
> 1304484, mtime = 1532322845 }
> [22:25:30.812757927] (+0.000056250) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD15B000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
> size = 315248, mtime = 1532324280 }
> [22:25:30.812814229] (+0.000056302) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAD149000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:30.812860635] (+0.000046406) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
> 28380, mtime = 1532322845 }
> [22:25:30.812904438] (+0.000043803) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
> 11236, mtime = 1532322845 }
> [22:25:30.812959125] (+0.000054687) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
> size = 29052, mtime = 1532323584 }
> [22:25:30.813013969] (+0.000054844) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
> size = 26152, mtime = 1532323584 }
> [22:25:30.813485479] (+0.000471510) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
> size = 13084, mtime = 1532323584 }
> [22:25:30.813600792] (+0.000115313) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DAE0000, sopath = "/lib/ld-2.22.so", size =
> 139632, mtime = 1532322845 }
> [22:25:30.813663656] (+0.000062864) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFC0000, sopath = "/usr/lib/xxx.so.1.0.0", size
> = 19456, mtime = 1532323510 }
> [22:25:30.813720635] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E030000, sopath = "/usr/lib/xxx.so.1.6.0", size
> = 142164, mtime = 1532323441 }
> [22:25:30.813776990] (+0.000056355) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E060000, sopath = "/usr/lib/xxx.so.0.0.0", size
> = 265304, mtime = 1532324468 }
> [22:25:30.813843917] (+0.000066927) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEA0000, sopath = "/usr/lib/xxx.so.0.0.0", size
> = 84016, mtime = 1532324363 }
> [22:25:30.813884385] (+0.000040468) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFE0000, sopath = "/usr/lib/xxx.so", size =
> 34204, mtime = 1532324426 }
> [22:25:30.813940479] (+0.000056094) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DFD0000, sopath = "/usr/lib/xxx.so", size =
> 7388, mtime = 1532324388 }
> [22:25:30.813993604] (+0.000053125) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4E000000, sopath = "/usr/lib/xxx.so", size =
> 33152, mtime = 1532323414 }
> [22:25:30.814049333] (+0.000055729) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DEE0000, sopath = "/usr/lib/libstdc++.so.6.0.20",
> size = 869236, mtime = 1532323320 }
> [22:25:30.814094177] (+0.000044844) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
> 441372, mtime = 1532322845 }
> [22:25:30.814234177] (+0.000140000) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DE80000, sopath = "/lib/libgcc_s.so.1", size =
> 118608, mtime = 1532323098 }
> [22:25:30.814427615] (+0.000193438) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x8000, sopath = "/usr/bin/my_test_app", size =
> 54540, mtime = 1532369202 }
> [22:25:30.828436677] (+0.014009062) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0xAEC57000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:30.828634958] (+0.000198281) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
> 441372, mtime = 1532322845 }
> [22:25:30.829786104] (+0.001151146) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
> 1304484, mtime = 1532322845 }
> [22:25:30.829910219] (+0.000124115) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0xAEC09000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
> size = 315248, mtime = 1532324280 }
> [22:25:30.829996000] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0xAEBF7000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:30.830067510] (+0.000071510) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
> 28380, mtime = 1532322845 }
> [22:25:30.830118031] (+0.000050521) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
> 11236, mtime = 1532322845 }
> [22:25:30.830175010] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
> size = 29052, mtime = 1532323584 }
> [22:25:30.830245271] (+0.000070261) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
> size = 26152, mtime = 1532323584 }
> [22:25:30.830316521] (+0.000071250) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 0 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
> size = 13084, mtime = 1532323584 }
> [22:25:34.384458499] (+3.554141978) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF584000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
> size = 10004, mtime = 1532324280 }
> [22:25:34.385048967] (+0.000590468) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
> 441372, mtime = 1532322845 }
> [22:25:34.385146415] (+0.000097448) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
> 1304484, mtime = 1532322845 }
> [22:25:34.385251832] (+0.000105417) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF536000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
> size = 315248, mtime = 1532324280 }
> [22:25:34.385354228] (+0.000102396) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0xAF524000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
> size = 35624, mtime = 1532324280 }
> [22:25:34.385444384] (+0.000090156) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
> 28380, mtime = 1532322845 }
> [22:25:34.385530165] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
> 11236, mtime = 1532322845 }
> [22:25:34.385607613] (+0.000077448) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
> size = 29052, mtime = 1532323584 }
> [22:25:34.385677978] (+0.000070365) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
> size = 26152, mtime = 1532323584 }
> [22:25:34.385773655] (+0.000095677) ZZZ ust_baddr_statedump:soinfo: {
> cpu_id = 2 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
> size = 13084, mtime = 1532323584 }
>
> Note: I have changed the Target Name as 'ZZZ' and some of the library name
> as 'xxx' in the above log for some confidential issues.
>
>
> Please guide me where I am making mistake and Please give your input on
> how to check the application compiled with function instrument information
> for tracing. I verified that application compiled with debugging
> information, by running gdb command. Below is the output of gdb command,
>
> /usr/bin # gdb my_test_app
> GNU gdb (GDB) 7.9.1
> Copyright (C) 2015 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.h
> tml>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "arm-oe-linux-gnueabi".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
> <http://www.gnu.org/software/gdb/documentation/>.
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from my_test_app...done.
> (gdb)
> (gdb) exit
> I am not sure whether it is compiled with finstrumentation information.
>
> Thanks in Advance,
> Paramesh
>
>
>
>
> _______________________________________________
> lttng-dev mailing listlttng-dev@lists.lttng.orghttps://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>
>
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev@lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>
>

[-- Attachment #1.2: Type: text/html, Size: 29184 bytes --]

[-- Attachment #2: log.do_compile --]
[-- Type: application/octet-stream, Size: 12674 bytes --]

DEBUG: SITE files ['endian-little', 'bit-32', 'arm-common', 'arm-32', 'common-linux', 'common-glibc', 'arm-linux', 'arm-linux-gnueabi', 'common']
DEBUG: Executing shell function do_compile
NOTE: make -j 20 V=1 DEFAULT_INCLUDES= CPPFLAGS=-I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger 
(CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/sh /home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp/missing autoheader)
rm -f stamp-h1
touch config.h.in
cd . && /bin/sh ./config.status config.h
config.status: creating config.h
config.status: config.h is unchanged
make  all-recursive
make[1]: Entering directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp'
Making all in hw_api
make[2]: Entering directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp/hw_api'
../arm-oe-linux-gnueabi-libtool  --tag=CXX   --mode=compile arm-oe-linux-gnueabi-g++  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -DHAVE_CONFIG_H   -I ../hw_api/inc/ -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-server -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc -D__unused=__attribute__\(\(__unused__\)\) -g -O0 -finstrument-functions  -std=c++11 -DHAVE_PTHREADS -DDEBUG_REFS_CALLSTACK_ENABLED=0 -I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -g -O0 -finstrument-functions -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize   -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64  -fvisibility-inlines-hidden -c -o libhw_la-hw_api.lo `test -f 'src/hw_api.cpp' || echo './'`src/hw_api.cpp
arm-oe-linux-gnueabi-libtool: compile:  arm-oe-linux-gnueabi-g++ -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -DHAVE_CONFIG_H -I ../hw_api/inc/ -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-server -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc "-D__unused=__attribute__((__unused__))" -g -O0 -finstrument-functions -std=c++11 -DHAVE_PTHREADS -DDEBUG_REFS_CALLSTACK_ENABLED=0 -I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -g -O0 -finstrument-functions -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64 -fvisibility-inlines-hidden -c src/hw_api.cpp  -fPIC -DPIC -o .libs/libhw_la-hw_api.o
arm-oe-linux-gnueabi-libtool: compile:  arm-oe-linux-gnueabi-g++ -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -DHAVE_CONFIG_H -I ../hw_api/inc/ -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-server -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc "-D__unused=__attribute__((__unused__))" -g -O0 -finstrument-functions -std=c++11 -DHAVE_PTHREADS -DDEBUG_REFS_CALLSTACK_ENABLED=0 -I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -g -O0 -finstrument-functions -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64 -fvisibility-inlines-hidden -c src/hw_api.cpp -o libhw_la-hw_api.o >/dev/null 2>&1
../arm-oe-linux-gnueabi-libtool  --tag=CXX   --mode=link arm-oe-linux-gnueabi-g++  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -g -O0 -finstrument-functions -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize   -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64  -fvisibility-inlines-hidden -ltinyalsa -lhardware -lexpat -lcutils -llog -ldl -lbinder -shared -avoid-version -llog -lcutils -lpthread -lutils  -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o libhw.la -rpath /usr/lib libhw_la-hw_api.lo -lhwwrapper 
arm-oe-linux-gnueabi-libtool: link: arm-oe-linux-gnueabi-g++  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ  -fPIC -DPIC -shared -nostdlib /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/crti.o /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/arm-oe-linux-gnueabi/4.9.3/crtbeginS.o  .libs/libhw_la-hw_api.o   /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libtinyalsa.so -L/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libexpat.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libbinder.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libutils.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libhwwrapper.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libhardware.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libcutils.so -lpthread /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/liblog.so -ldl -L/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/x86_64-linux/usr/lib/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.9.3 -L/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/lib -L/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/arm-oe-linux-gnueabi/4.9.3 /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libstdc++.so -lm -lc -lgcc_s /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/arm-oe-linux-gnueabi/4.9.3/crtendS.o /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/crtn.o  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -g -O0 -O2 -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed   -Wl,-soname -Wl,libhw.so -o .libs/libhw.so
arm-oe-linux-gnueabi-libtool: link: ( cd ".libs" && rm -f "libhw.la" && ln -s "../libhw.la" "libhw.la" )
make[2]: Leaving directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp/hw_api'
Making all in hw_api/test
make[2]: Entering directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp/hw_api/test'
arm-oe-linux-gnueabi-gcc  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -DHAVE_CONFIG_H    -I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -Wno-sign-compare -Werror -D__unused=__attribute__\(\(__unused__\)\) -I ../../hw_api/inc -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc -g -O0 -finstrument-functions -DLINUX_ENABLED -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize   -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64   -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger  -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -c -o my_test_app-hw_playback_test.o `test -f 'hw_playback_test.c' || echo './'`hw_playback_test.c
arm-oe-linux-gnueabi-gcc  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -DHAVE_CONFIG_H    -I. -I/home/workdir/lttng-enable/poky/build/tmp-glibc/work-shared/ZZZ/kernel-build-artifacts/usr/include -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -Wno-sign-compare -Werror -D__unused=__attribute__\(\(__unused__\)\) -I ../../hw_api/inc -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc -g -O0 -finstrument-functions -DLINUX_ENABLED -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize   -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64   -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger  -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -c -o my_test_app-hw_effect_test.o `test -f 'hw_effect_test.c' || echo './'`hw_effect_test.c
../../arm-oe-linux-gnueabi-libtool  --tag=CC   --mode=link arm-oe-linux-gnueabi-gcc  -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -Wno-sign-compare -Werror -D__unused=__attribute__\(\(__unused__\)\) -I ../../hw_api/inc -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc -g -O0 -finstrument-functions -DLINUX_ENABLED -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize   -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64   -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger  -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3  -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o my_test_app my_test_app-hw_playback_test.o my_test_app-hw_effect_test.o -lutils ../libhw.la 
arm-oe-linux-gnueabi-libtool: link: arm-oe-linux-gnueabi-gcc -march=armv7-a -mfloat-abi=softfp -mfpu=neon --sysroot=/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ -Wno-sign-compare -Werror "-D__unused=__attribute__((__unused__))" -I ../../hw_api/inc -I /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/mm-audio/hw/inc -g -O0 -finstrument-functions -DLINUX_ENABLED -O2 -fexpensive-optimizations -frename-registers -fomit-frame-pointer -ftree-vectorize -Wno-error=maybe-uninitialized -finline-functions -finline-limit=64 -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/x_trigger -I/home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/include/surround_3 -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o .libs/my_test_app my_test_app-hw_playback_test.o my_test_app-hw_effect_test.o  ../.libs/libhw.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libtinyalsa.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libexpat.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libbinder.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libutils.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libhwwrapper.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libhardware.so /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libcutils.so -lpthread /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/liblog.so -ldl /home/workdir/lttng-enable/poky/build/tmp-glibc/sysroots/ZZZ/usr/lib/libstdc++.so -lm
make[2]: Leaving directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp/hw_api/test'
make[2]: Entering directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp'
make[2]: Leaving directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp'
make[1]: Leaving directory `/home/workdir/lttng-enable/poky/build/tmp-glibc/work/ZZZ-oe-linux-gnueabi/mytestapp/1.0-r0/testapp'
DEBUG: Shell function do_compile finished

[-- Attachment #3: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Function Tracing Fails
       [not found]   ` <CAOG=51wKyQN6Q1F=Qn_JYfu4aPjK1PnD79S0NJuxKei8o1e+HA@mail.gmail.com>
@ 2018-08-16  7:29     ` paramesh p
  0 siblings, 0 replies; 5+ messages in thread
From: paramesh p @ 2018-08-16  7:29 UTC (permalink / raw)
  To: Geneviève Bastien, Mathieu Desnoyers; +Cc: lttng-dev


[-- Attachment #1.1: Type: text/plain, Size: 14837 bytes --]

please give your suggestions on previous mail.

Thanks,
Paramesh

On Tue, Aug 7, 2018 at 2:20 PM, paramesh p <params16jan@gmail.com> wrote:

> Sorry for the delayed response,
>
> @Mathieu,
>     I have attached the build log.  The Project I am working is Yocto
> Project based build system. My App uses the shared object "libhw.so". So,
> it built first. As I said before,below are the flag I added
>
> AM_CFLAGS += -g -O0 -finstrument-functions
> AM_CXXFLAGS += -g -O0 -finstrument-functions
>
>
>   From the log I found that "-finstrument-functions" flag included in
> compiling all the source files, ' libhw.la'  file and  'my_test_app'
> binary, but not included for compiling  'libhw.so'. I am not sure why? My
> question is, as you see my shared object and binary includes following so's
> "libtinyalsa.so libexpat.so libbinder.so libutils.so libhwwrapper.so
> libhardware.so libcutils.so liblog.so". Are all these need to be compiled
> with finstrument flag. In that case, it will increase my workload, since
> some of them are custom build and some from the libs and each of them might
> have their own dependents.
>
>
> @gen,
>     objdump doesn't support arm architecture. So, I used
> "arm-linux-gnueabi-objdump" tool. I could see cyg information to all my
> object files but I could not see for "libhw.so" and "my_test_app" files.
>     cyg information of one of my source file,
>
> $ arm-linux-gnueabi-objdump -d libhw_la-hw_api.o | grep cyg
>
>       20:       ebfffffe        bl      0 <__cyg_profile_func_enter>
>
>       30:       eafffffe        b       0 <__cyg_profile_func_exit>
>
>       64:       ebfffffe        bl      0 <__cyg_profile_func_enter>
>
>       a4:       ebfffffe        bl      0 <__cyg_profile_func_exit>
>
>       .....................
>
>       .....................
>
>       2548:       ebfffffe        bl      0 <__cyg_profile_func_exit>
>
>       258c:       ebfffffe        bl      0 <__cyg_profile_func_enter>
>
>       25d0:       ebfffffe        bl      0 <__cyg_profile_func_exit>
>
>       25e8:       ebfffffe        bl      0 <__cyg_profile_func_exit>
>
>
>
> Please help me.
>
> Thanks in Advance,
> Paramesh
>
>
>
>
>
> On Mon, Jul 30, 2018 at 6:50 AM, Geneviève Bastien <gbastien@versatic.net>
> wrote:
>
>> Hi Paramesh,
>>
>>
>> One way to know if your app is really compiled with
>> -finstrument-functions is doing
>>
>>
>> $ objdump -d my_test_app | grep cyg
>>
>> You would typically see something like this:
>>
>> 0000000000001250 <__cyg_profile_func_enter@plt>:
>>     1250:    ff 25 fa 2d 20 00        jmpq   *0x202dfa(%rip)        #
>> 204050 <__cyg_profile_func_enter@GLIBC_2.2.5>
>> <__cyg_profile_func_enter@GLIBC_2.2.5>
>> 0000000000001260 <__cyg_profile_func_exit@plt>:
>>     1260:    ff 25 f2 2d 20 00        jmpq   *0x202df2(%rip)        #
>> 204058 <__cyg_profile_func_exit@GLIBC_2.2.5>
>> <__cyg_profile_func_exit@GLIBC_2.2.5>
>>     14a8:    e8 a3 fd ff ff           callq  1250
>> <__cyg_profile_func_enter@plt>
>>     16d8:    e8 83 fb ff ff           callq  1260
>> <__cyg_profile_func_exit@plt>
>>     19c5:    e8 86 f8 ff ff           callq  1250
>> <__cyg_profile_func_enter@plt>
>>     19e2:    e9 79 f8 ff ff           jmpq   1260
>> <__cyg_profile_func_exit@plt>
>>     1a0d:    e8 3e f8 ff ff           callq  1250
>> <__cyg_profile_func_enter@plt>
>>
>> If you see nothing, as Mathieu said, you can check the individual make
>> commands and see what flags are being used on the command line.
>>
>> Geneviève
>>
>>
>>
>> On 2018-07-29 09:29 PM, paramesh p wrote:
>>
>> Hi,
>>    I am trying to use Function Tracing for my application running in
>> 32-bit ARM Platform. I have added below lines in my makefile for enabling
>> Trace Data for function tracing
>>
>> AM_CFLAGS += -g -O0 -finstrument-functions
>> AM_CXXFLAGS += -g -O0 -finstrument-functions
>>
>> **(My App have both C && CPP files, So I added CFLAGS & CXXFLAGS).
>>
>> I am running below commands,
>> $lttng create session1
>> $lttng enable-event -u -a --loglevel-only TRACE_DEBUG_FUNCTION
>> $lttng start
>> $LD_PRELOAD=liblttng-ust-cyg-profile.so.0.0.0 my_test_app
>> $lttng start
>> $babeltrace /home/root/lttng-traces/session1
>>
>> Its showing nothing.
>>
>> I tried with below event-enable command also. There is no data
>> $lttng enable-event -u -a --loglevel TRACE_DEBUG_FUNCTION
>>
>> But If I use the command, "lttng enable-event -u -a"  for enabling the
>> event, I am getting below output from babeltrace,
>>
>> [22:25:30.812389281] (+?.?????????) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0xAD1A9000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
>> size = 10004, mtime = 1532324280 }
>> [22:25:30.812496469] (+0.000107188) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DFF0000, sopath = "/usr/lib/xxx.so", size =
>> 19540, mtime = 1532369202 }
>> [22:25:30.812604177] (+0.000107708) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4E120000, sopath = "/usr/lib/libcutils.so.0.0.0",
>> size = 48624, mtime = 1532323462 }
>> [22:25:30.812655219] (+0.000051042) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DC80000, sopath = "/lib/libpthread-2.22.so",
>> size = 94976, mtime = 1532322845 }
>> [22:25:30.812701677] (+0.000046458) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
>> 1304484, mtime = 1532322845 }
>> [22:25:30.812757927] (+0.000056250) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0xAD15B000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
>> size = 315248, mtime = 1532324280 }
>> [22:25:30.812814229] (+0.000056302) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0xAD149000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
>> size = 35624, mtime = 1532324280 }
>> [22:25:30.812860635] (+0.000046406) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size
>> = 28380, mtime = 1532322845 }
>> [22:25:30.812904438] (+0.000043803) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size
>> = 11236, mtime = 1532322845 }
>> [22:25:30.812959125] (+0.000054687) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
>> size = 29052, mtime = 1532323584 }
>> [22:25:30.813013969] (+0.000054844) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
>> size = 26152, mtime = 1532323584 }
>> [22:25:30.813485479] (+0.000471510) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
>> size = 13084, mtime = 1532323584 }
>> [22:25:30.813600792] (+0.000115313) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DAE0000, sopath = "/lib/ld-2.22.so", size =
>> 139632, mtime = 1532322845 }
>> [22:25:30.813663656] (+0.000062864) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DFC0000, sopath = "/usr/lib/xxx.so.1.0.0", size
>> = 19456, mtime = 1532323510 }
>> [22:25:30.813720635] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4E030000, sopath = "/usr/lib/xxx.so.1.6.0", size
>> = 142164, mtime = 1532323441 }
>> [22:25:30.813776990] (+0.000056355) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4E060000, sopath = "/usr/lib/xxx.so.0.0.0", size
>> = 265304, mtime = 1532324468 }
>> [22:25:30.813843917] (+0.000066927) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DEA0000, sopath = "/usr/lib/xxx.so.0.0.0", size
>> = 84016, mtime = 1532324363 }
>> [22:25:30.813884385] (+0.000040468) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DFE0000, sopath = "/usr/lib/xxx.so", size =
>> 34204, mtime = 1532324426 }
>> [22:25:30.813940479] (+0.000056094) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DFD0000, sopath = "/usr/lib/xxx.so", size =
>> 7388, mtime = 1532324388 }
>> [22:25:30.813993604] (+0.000053125) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4E000000, sopath = "/usr/lib/xxx.so", size =
>> 33152, mtime = 1532323414 }
>> [22:25:30.814049333] (+0.000055729) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DEE0000, sopath = "/usr/lib/libstdc++.so.6.0.20",
>> size = 869236, mtime = 1532323320 }
>> [22:25:30.814094177] (+0.000044844) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
>> 441372, mtime = 1532322845 }
>> [22:25:30.814234177] (+0.000140000) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DE80000, sopath = "/lib/libgcc_s.so.1", size =
>> 118608, mtime = 1532323098 }
>> [22:25:30.814427615] (+0.000193438) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x8000, sopath = "/usr/bin/my_test_app", size =
>> 54540, mtime = 1532369202 }
>> [22:25:30.828436677] (+0.014009062) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0xAEC57000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
>> size = 10004, mtime = 1532324280 }
>> [22:25:30.828634958] (+0.000198281) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
>> 441372, mtime = 1532322845 }
>> [22:25:30.829786104] (+0.001151146) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
>> 1304484, mtime = 1532322845 }
>> [22:25:30.829910219] (+0.000124115) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0xAEC09000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
>> size = 315248, mtime = 1532324280 }
>> [22:25:30.829996000] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0xAEBF7000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
>> size = 35624, mtime = 1532324280 }
>> [22:25:30.830067510] (+0.000071510) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size
>> = 28380, mtime = 1532322845 }
>> [22:25:30.830118031] (+0.000050521) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size
>> = 11236, mtime = 1532322845 }
>> [22:25:30.830175010] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
>> size = 29052, mtime = 1532323584 }
>> [22:25:30.830245271] (+0.000070261) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
>> size = 26152, mtime = 1532323584 }
>> [22:25:30.830316521] (+0.000071250) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 0 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
>> size = 13084, mtime = 1532323584 }
>> [22:25:34.384458499] (+3.554141978) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0xAF584000, sopath = "/usr/lib/liblttng-ust-cyg-profile.so.0.0.0",
>> size = 10004, mtime = 1532324280 }
>> [22:25:34.385048967] (+0.000590468) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
>> 441372, mtime = 1532322845 }
>> [22:25:34.385146415] (+0.000097448) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
>> 1304484, mtime = 1532322845 }
>> [22:25:34.385251832] (+0.000105417) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0xAF536000, sopath = "/usr/lib/liblttng-ust.so.0.0.0",
>> size = 315248, mtime = 1532324280 }
>> [22:25:34.385354228] (+0.000102396) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0xAF524000, sopath = "/usr/lib/liblttng-ust-tracepoint.so.0.0.0",
>> size = 35624, mtime = 1532324280 }
>> [22:25:34.385444384] (+0.000090156) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size
>> = 28380, mtime = 1532322845 }
>> [22:25:34.385530165] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size
>> = 11236, mtime = 1532322845 }
>> [22:25:34.385607613] (+0.000077448) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DE10000, sopath = "/usr/lib/liburcu-bp.so.2.0.0",
>> size = 29052, mtime = 1532323584 }
>> [22:25:34.385677978] (+0.000070365) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DE00000, sopath = "/usr/lib/liburcu-cds.so.2.0.0",
>> size = 26152, mtime = 1532323584 }
>> [22:25:34.385773655] (+0.000095677) ZZZ ust_baddr_statedump:soinfo: {
>> cpu_id = 2 }, { baddr = 0x4DD60000, sopath = "/usr/lib/liburcu-common.so.2.0.0",
>> size = 13084, mtime = 1532323584 }
>>
>> Note: I have changed the Target Name as 'ZZZ' and some of the library
>> name as 'xxx' in the above log for some confidential issues.
>>
>>
>> Please guide me where I am making mistake and Please give your input on
>> how to check the application compiled with function instrument information
>> for tracing. I verified that application compiled with debugging
>> information, by running gdb command. Below is the output of gdb command,
>>
>> /usr/bin # gdb my_test_app
>> GNU gdb (GDB) 7.9.1
>> Copyright (C) 2015 Free Software Foundation, Inc.
>> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.h
>> tml>
>> This is free software: you are free to change and redistribute it.
>> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
>> and "show warranty" for details.
>> This GDB was configured as "arm-oe-linux-gnueabi".
>> Type "show configuration" for configuration details.
>> For bug reporting instructions, please see:
>> <http://www.gnu.org/software/gdb/bugs/>.
>> Find the GDB manual and other documentation resources online at:
>> <http://www.gnu.org/software/gdb/documentation/>.
>> For help, type "help".
>> Type "apropos word" to search for commands related to "word"...
>> Reading symbols from my_test_app...done.
>> (gdb)
>> (gdb) exit
>> I am not sure whether it is compiled with finstrumentation information.
>>
>> Thanks in Advance,
>> Paramesh
>>
>>
>>
>>
>> _______________________________________________
>> lttng-dev mailing listlttng-dev@lists.lttng.orghttps://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>>
>>
>>
>> _______________________________________________
>> lttng-dev mailing list
>> lttng-dev@lists.lttng.org
>> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>>
>>
>

[-- Attachment #1.2: Type: text/html, Size: 30297 bytes --]

[-- Attachment #2: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Function Tracing Fails
@ 2018-07-30  1:29 paramesh p
  0 siblings, 0 replies; 5+ messages in thread
From: paramesh p @ 2018-07-30  1:29 UTC (permalink / raw)
  To: lttng-dev


[-- Attachment #1.1: Type: text/plain, Size: 10048 bytes --]

Hi,
   I am trying to use Function Tracing for my application running in 32-bit
ARM Platform. I have added below lines in my makefile for enabling Trace
Data for function tracing

AM_CFLAGS += -g -O0 -finstrument-functions
AM_CXXFLAGS += -g -O0 -finstrument-functions

**(My App have both C && CPP files, So I added CFLAGS & CXXFLAGS).

I am running below commands,
$lttng create session1
$lttng enable-event -u -a --loglevel-only TRACE_DEBUG_FUNCTION
$lttng start
$LD_PRELOAD=liblttng-ust-cyg-profile.so.0.0.0 my_test_app
$lttng start
$babeltrace /home/root/lttng-traces/session1

Its showing nothing.

I tried with below event-enable command also. There is no data
$lttng enable-event -u -a --loglevel TRACE_DEBUG_FUNCTION

But If I use the command, "lttng enable-event -u -a"  for enabling the
event, I am getting below output from babeltrace,

[22:25:30.812389281] (+?.?????????) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0xAD1A9000, sopath =
"/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
1532324280 }
[22:25:30.812496469] (+0.000107188) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DFF0000, sopath = "/usr/lib/xxx.so", size =
19540, mtime = 1532369202 }
[22:25:30.812604177] (+0.000107708) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4E120000, sopath = "/usr/lib/libcutils.so.0.0.0",
size = 48624, mtime = 1532323462 }
[22:25:30.812655219] (+0.000051042) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DC80000, sopath = "/lib/libpthread-2.22.so",
size = 94976, mtime = 1532322845 }
[22:25:30.812701677] (+0.000046458) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
1304484, mtime = 1532322845 }
[22:25:30.812757927] (+0.000056250) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0xAD15B000, sopath =
"/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
[22:25:30.812814229] (+0.000056302) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0xAD149000, sopath =
"/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
1532324280 }
[22:25:30.812860635] (+0.000046406) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
28380, mtime = 1532322845 }
[22:25:30.812904438] (+0.000043803) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
11236, mtime = 1532322845 }
[22:25:30.812959125] (+0.000054687) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DE10000, sopath =
"/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
[22:25:30.813013969] (+0.000054844) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DE00000, sopath =
"/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
[22:25:30.813485479] (+0.000471510) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DD60000, sopath =
"/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }
[22:25:30.813600792] (+0.000115313) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DAE0000, sopath = "/lib/ld-2.22.so", size =
139632, mtime = 1532322845 }
[22:25:30.813663656] (+0.000062864) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DFC0000, sopath = "/usr/lib/xxx.so.1.0.0", size
= 19456, mtime = 1532323510 }
[22:25:30.813720635] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4E030000, sopath = "/usr/lib/xxx.so.1.6.0", size
= 142164, mtime = 1532323441 }
[22:25:30.813776990] (+0.000056355) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4E060000, sopath = "/usr/lib/xxx.so.0.0.0", size
= 265304, mtime = 1532324468 }
[22:25:30.813843917] (+0.000066927) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DEA0000, sopath = "/usr/lib/xxx.so.0.0.0", size
= 84016, mtime = 1532324363 }
[22:25:30.813884385] (+0.000040468) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DFE0000, sopath = "/usr/lib/xxx.so", size =
34204, mtime = 1532324426 }
[22:25:30.813940479] (+0.000056094) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DFD0000, sopath = "/usr/lib/xxx.so", size =
7388, mtime = 1532324388 }
[22:25:30.813993604] (+0.000053125) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4E000000, sopath = "/usr/lib/xxx.so", size =
33152, mtime = 1532323414 }
[22:25:30.814049333] (+0.000055729) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DEE0000, sopath =
"/usr/lib/libstdc++.so.6.0.20", size = 869236, mtime = 1532323320 }
[22:25:30.814094177] (+0.000044844) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
441372, mtime = 1532322845 }
[22:25:30.814234177] (+0.000140000) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DE80000, sopath = "/lib/libgcc_s.so.1", size =
118608, mtime = 1532323098 }
[22:25:30.814427615] (+0.000193438) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x8000, sopath = "/usr/bin/my_test_app", size =
54540, mtime = 1532369202 }
[22:25:30.828436677] (+0.014009062) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0xAEC57000, sopath =
"/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
1532324280 }
[22:25:30.828634958] (+0.000198281) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 1 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
441372, mtime = 1532322845 }
[22:25:30.829786104] (+0.001151146) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
1304484, mtime = 1532322845 }
[22:25:30.829910219] (+0.000124115) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0xAEC09000, sopath =
"/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
[22:25:30.829996000] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0xAEBF7000, sopath =
"/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
1532324280 }
[22:25:30.830067510] (+0.000071510) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
28380, mtime = 1532322845 }
[22:25:30.830118031] (+0.000050521) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
11236, mtime = 1532322845 }
[22:25:30.830175010] (+0.000056979) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DE10000, sopath =
"/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
[22:25:30.830245271] (+0.000070261) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DE00000, sopath =
"/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
[22:25:30.830316521] (+0.000071250) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 0 }, { baddr = 0x4DD60000, sopath =
"/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }
[22:25:34.384458499] (+3.554141978) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0xAF584000, sopath =
"/usr/lib/liblttng-ust-cyg-profile.so.0.0.0", size = 10004, mtime =
1532324280 }
[22:25:34.385048967] (+0.000590468) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DCD0000, sopath = "/lib/libm-2.22.so", size =
441372, mtime = 1532322845 }
[22:25:34.385146415] (+0.000097448) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DB20000, sopath = "/lib/libc-2.22.so", size =
1304484, mtime = 1532322845 }
[22:25:34.385251832] (+0.000105417) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0xAF536000, sopath =
"/usr/lib/liblttng-ust.so.0.0.0", size = 315248, mtime = 1532324280 }
[22:25:34.385354228] (+0.000102396) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0xAF524000, sopath =
"/usr/lib/liblttng-ust-tracepoint.so.0.0.0", size = 35624, mtime =
1532324280 }
[22:25:34.385444384] (+0.000090156) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DEC0000, sopath = "/lib/librt-2.22.so", size =
28380, mtime = 1532322845 }
[22:25:34.385530165] (+0.000085781) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DCB0000, sopath = "/lib/libdl-2.22.so", size =
11236, mtime = 1532322845 }
[22:25:34.385607613] (+0.000077448) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DE10000, sopath =
"/usr/lib/liburcu-bp.so.2.0.0", size = 29052, mtime = 1532323584 }
[22:25:34.385677978] (+0.000070365) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DE00000, sopath =
"/usr/lib/liburcu-cds.so.2.0.0", size = 26152, mtime = 1532323584 }
[22:25:34.385773655] (+0.000095677) ZZZ ust_baddr_statedump:soinfo: {
cpu_id = 2 }, { baddr = 0x4DD60000, sopath =
"/usr/lib/liburcu-common.so.2.0.0", size = 13084, mtime = 1532323584 }

Note: I have changed the Target Name as 'ZZZ' and some of the library name
as 'xxx' in the above log for some confidential issues.


Please guide me where I am making mistake and Please give your input on how
to check the application compiled with function instrument information for
tracing. I verified that application compiled with debugging information,
by running gdb command. Below is the output of gdb command,

/usr/bin # gdb my_test_app
GNU gdb (GDB) 7.9.1
Copyright (C) 2015 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html
>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-oe-linux-gnueabi".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from my_test_app...done.
(gdb)
(gdb) exit
I am not sure whether it is compiled with finstrumentation information.

Thanks in Advance,
Paramesh

[-- Attachment #1.2: Type: text/html, Size: 13528 bytes --]

[-- Attachment #2: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-08-16  7:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAOG=51zc2Xu2yNd-3YWhOXZiMb7_c1xYzN_ZS1x+PHP0kRz=LA@mail.gmail.com>
2018-07-30 12:55 ` Function Tracing Fails Mathieu Desnoyers
2018-07-30 13:50 ` Geneviève Bastien
     [not found] ` <fc0a009e-da8e-8838-399a-b646b1ae088d@versatic.net>
2018-08-07 21:20   ` paramesh p
     [not found]   ` <CAOG=51wKyQN6Q1F=Qn_JYfu4aPjK1PnD79S0NJuxKei8o1e+HA@mail.gmail.com>
2018-08-16  7:29     ` paramesh p
2018-07-30  1:29 paramesh p

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.