Bug 985109 - [RFE] Unconditionally enable SDT probes in glibc builds.
Summary: [RFE] Unconditionally enable SDT probes in glibc builds.
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: glibc
Version: rawhide
Hardware: All
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Carlos O'Donell
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1225490
TreeView+ depends on / blocked
 
Reported: 2013-07-16 19:40 UTC by Tom Tromey
Modified: 2016-11-24 12:22 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1225490 (view as bug list)
Environment:
Last Closed: 2014-09-30 18:14:19 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Tom Tromey 2013-07-16 19:40:11 UTC
ARM glibc does not include the SDT probes that are
available on other architectures.  These probes are used
by gdb to implement various features.

You can see whether the probes are available using
"readelf -n" on the .so.  Be sure to examine both
glibc and ld.so, as the latter has some needed probes
as well.

On x86-64 I get:

[... other stufff ...]

Notes at offset 0x001b28ac with length 0x00000294:
  Owner                 Data size       Description
  stapsdt              0x0000003a       NT_STAPSDT (SystemTap probe descriptors)
    Provider: libc
    Name: setjmp
    Location: 0x0000000000035a31, Base: 0x000000000017ccb0, Semaphore: 0x0000000000000000
    Arguments: 8@%rdi -4@%esi 8@%rax
[...]


Ordinarily the fix for missing probes is simply to ensure that
sys/sdt.h is available when the package is built.
This file is in systemtap-sdt-devel.

This should also be checked for aarch64.

Comment 1 Carlos O'Donell 2013-07-16 19:53:31 UTC
ARM is not in the list of %systemtaparches and therefore is not built with system tap probes in place.

Retitling as RFE.

Comment 2 Carlos O'Donell 2013-07-16 19:57:32 UTC
If someone feels like trying this out and testing the probes that would be great.

I expect the patch is simply:

diff --git a/glibc.spec b/glibc.spec
index 824f9f1..44dc593 100644
--- a/glibc.spec
+++ b/glibc.spec
@@ -20,7 +20,7 @@
 %define biarcharches %{ix86} x86_64 ppc %{power64} s390 s390x
 %define debuginfocommonarches %{biarcharches} alpha alphaev6
 %define multiarcharches ppc %{power64} %{ix86} x86_64 %{sparc}
-%define systemtaparches %{ix86} x86_64
+%define systemtaparches %{ix86} x86_64 %{arm}
 # Add -s for a less verbose build output.
 %define silentrules PARALLELMFLAGS=
 
However, you have to test out the resulting build.

Comment 3 Frank Ch. Eigler 2013-07-16 20:24:34 UTC
BTW, for systemtaparches, is there a reason not to make this
unconditional to all arches?

Comment 4 Carlos O'Donell 2013-07-16 21:13:46 UTC
(In reply to Frank Ch. Eigler from comment #3)
> BTW, for systemtaparches, is there a reason not to make this
> unconditional to all arches?

No reason at all. Expanding scope of issue.

I'm going to unconditionally enable SDT probe usage in glibc.

Comment 6 Siddhesh Poyarekar 2014-09-30 18:14:19 UTC
I've done this in glibc-2.20.90-6.fc22


Note You need to log in before you can comment on or make changes to this bug.