Bug 406561 - mcinfcallWSRU gdbserver_test fails on ppc64
Summary: mcinfcallWSRU gdbserver_test fails on ppc64
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-04-15 10:22 UTC by Alexandra Hajkova
Modified: 2019-04-19 10:17 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
patch (1.36 KB, patch)
2019-04-15 13:35 UTC, Alexandra Hajkova
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandra Hajkova 2019-04-15 10:22:05 UTC
SUMMARY


STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Alexandra Hajkova 2019-04-15 10:32:35 UTC
ppc64 uses "function descriptors", their names starts with a dot "." prefix, the current regexp filters out only names without the "." prefix which makes mcinfcallWSRU gdb output different from what is expected 

https://www.ibm.com/developerworks/community/blogs/5894415f-be62-4bc0-81c5-3956e82276f3/entry/deeply_understand_64_bit_powerpc_elf_abi_function_descriptors?lang=en

perl tests/vg_regtest gdbserver_tests/mcinfcallWSRU.vgtest

diff:
--- mcinfcallWSRU.stderrB.exp	2019-04-14 16:37:51.920314033 -0400
+++ mcinfcallWSRU.stderrB.out	2019-04-15 06:03:15.547369429 -0400
@@ -21,7 +21,7 @@
 41	   for (i = 0; i < burn; i++) loopnr++;
 $1 = void
 [Switching to thread 2 (Thread ....)]
-#0  0x........ in syscall ...
+#0  0x........ in .__select () at ../sysdeps/unix/syscall-template.S:81
 Could not write register  "xxx"; remote failure reply 'E.
 ERROR changing register  xxx regno y
 gdb commands changing registers (pc, sp, ...) (e.g. 'jump',
@@ -30,7 +30,7 @@
 Thread status is VgTs_WaitSys
 '
 [Switching to thread 3 (Thread ....)]
-#0  0x........ in syscall ...
+#0  0x........ in .__select () at ../sysdeps/unix/syscall-template.S:81
 Could not write register  "xxx"; remote failure reply 'E.
 ERROR changing register  xxx regno y
 gdb commands changing registers (pc, sp, ...) (e.g. 'jump',
@@ -39,7 +39,7 @@
 Thread status is VgTs_WaitSys
 '
 [Switching to thread 4 (Thread ....)]
-#0  0x........ in syscall ...
+#0  0x........ in .__select () at ../sysdeps/unix/syscall-template.S:81
 Could not write register  "xxx"; remote failure reply 'E.
 ERROR changing register  xxx regno y
 gdb commands changing registers (pc, sp, ...) (e.g. 'jump',
Comment 2 Alexandra Hajkova 2019-04-15 13:35:34 UTC
Created attachment 119421 [details]
patch
Comment 3 Mark Wielaard 2019-04-19 10:17:16 UTC
Looks correct. Thanks.

commit b1cc37ddb660afc536131227a9fb452ac9328972
Author: Alexandra Hájková <ahajkova@redhat.com>
Date:   Mon Apr 15 15:34:12 2019 +0200

    filter_gdb: add regexp to filter out names which starts with a "."
    
    such names are used for "function descriptors" on ppc64
    
    https://bugs.kde.org/show_bug.cgi?id=406561