User probes on ppc64le are not returning the correct values of the probed function's arguments.

Bug #1659185 reported by bugproxy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
systemtap (Ubuntu)
New
Undecided
Unassigned

Bug Description

== Comment: #0 - David J. Wilder <email address hidden> - 2015-07-15 19:51:49 ==
---Problem Description---
User probes on ppc64le are not returning the correct values of the probed function's arguments.

Contact Information = <email address hidden>

---uname output---
Linux Daves-sandbox 3.19.0-21-generic #21-Ubuntu SMP Sun Jun 14 19:33:37 UTC 2015 ppc64le ppc64le ppc64le GNU/Linux

Machine Type = 8284-22A (power8, running on a VM on top of powerKVM)

---Debugger---
A debugger is not configured

---Steps to Reproduce---

$ cat doit.c
#include <stdio.h>

doit( int i )
{
 printf("%s: i=%d\n",__func__,i);
 pause();
}

main()
{
 doit(42);
}

$ cat doit.stp
probe process("doit").function("doit") {
 printf("function doit called with i=%ld\n",$i);
}

$ gcc -g -o doit doit.c

$ sudo stap doit.stp -c ./doit

doit: i=42
function doit called with i=16383 <<<< I expect 42
---------

If I run the same example on a x86-64 system I get the expected results. So I think this is a problem with ppc64 only.

$ uname -a
Linux ubuntu-15 3.19.0-15-generic #15-Ubuntu SMP Thu Apr 16 23:32:37 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
$ sudo stap doit.stp -c ./doit

doit: i=42
function doit called with i=42

Other information (from ppc64le system):

I build systemtap from upstream git. The version Canonical is shipping is broken.

$ stap --version
Systemtap translator/driver (version 2.9/0.160, commit release-2.8-19-ga7396f637e7c)
Copyright (C) 2005-2015 Red Hat, Inc. and others
This is free software; see the source for copying conditions.
enabled features: TR1_UNORDERED_MAP NLS

$ grep CONFIG_UPROBES /boot/config-`uname -r`
CONFIG_UPROBES=y

 ----------------------------------------------------
Userspace tool common name: stap

The userspace tool has the following bit modes: 64-bit

Userspace rpm: systemtap

Userspace tool obtained from project website: na

*Additional Instructions for <email address hidden>:
-Post a private note with access information to the machine that the bug is occuring on.
-Attach ltrace and strace of userspace application.

Please cherry pick the fix.

https://www.sourceware.org/git/?p=systemtap.git;a=commit;h=b0cfcdb4886be5654e94cd7893a01531345e961d

https://www.sourceware.org/git/?p=systemtap.git;a=commit;h=c3d8c09c03abd4b212a24b94601a7d5a2d9b74a1

bugproxy (bugproxy)
tags: added: architecture-ppc64le bugnameltc-127718 severity-medium targetmilestone-inin1704
Changed in ubuntu:
assignee: nobody → Taco Screen team (taco-screen-team)
affects: ubuntu → systemtap (Ubuntu)
Revision history for this message
Michael Hohnbaum (hohnbaum) wrote :

Systemtap is in universe and is community supported. Removing Taco Screen team.

Changed in systemtap (Ubuntu):
assignee: Taco Screen team (taco-screen-team) → nobody
bugproxy (bugproxy)
tags: removed: bugnameltc-127718 severity-medium
bugproxy (bugproxy)
tags: added: bugnameltc-127718 severity-medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.