This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: dwarf information missing. how to rescue?


Shiyao Ma <i@introo.me> writes:

> [...]
> sudo stap -L 'kernel.function("tcp_cong_control")'
> gives this mere output:
> kernel.function("tcp_cong_control@./net/ipv4/tcp_input.c:3336")
>
> No params, locals are included.
> Should I recompile the kernel?  if so, with what flags?

Over here on fedora 25, that function is inlined by the compiler, so a
compiler optimizer has to work hard to keep debuginfo correct &
available.  I wonder if perhaps you're affected by a years-old kernel
error of judgement, wherein gcc's debuginfo generation is deliberately
hobbled.  The HHGTG ^W systemtap release notes have had this to say:

  - An upstream kernel commit #2062afb4f804a put
  "-fno-var-tracking-assignments" into KCFLAGS, reducing debuginfo
  quality which can cause debuginfo failures.  A proposed workaround to
  this issue exists in: https://lkml.org/lkml/2014/11/21/505 . Fedora
  kernels are not affected by this issue.

If this may be affecting you, just nuke this line of the top level
kernel Makefile and rebuild it.  Distros everywhere should do the same.

Makefile:
KBUILD_CFLAGS   += $(call cc-option, -fno-var-tracking-assignments)

- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]