* [Bug translator/17889] New: the translator does not understand arm64 constants in sdt markers
@ 2015-01-27 21:28 wcohen at redhat dot com
2015-01-27 22:31 ` [Bug translator/17889] " wcohen at redhat dot com
2015-01-28 3:51 ` wcohen at redhat dot com
0 siblings, 2 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2015-01-27 21:28 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17889
Bug ID: 17889
Summary: the translator does not understand arm64 constants in
sdt markers
Product: systemtap
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: translator
Assignee: systemtap at sourceware dot org
Reporter: wcohen at redhat dot com
Some of the tests using markers were failing on arm64 because when the compiler
optimization is enabled there will be constants for some of the marker probe
arguments and the constants are not prefixed with a '$'. This can be obervered
in the systemtap.base/sdt.exp tests:
Executing on host: gcc ./systemtap.base/sdt.c -g -isystem.
-isystem/root/systemtap_write/install/include -Wall -Wextra -Werror -O2 -lm
-o sdt.c.exe.0 (timeout = 300)
spawn -ignore SIGHUP gcc ./systemtap.base/sdt.c -g -isystem.
-isystem/root/systemtap_write/install/include -Wall -Wextra -Werror -O2 -lm -o
sdt.c.exe.0
PASS: compiling sdt.c -O2 uprobe
executing: stap -w ./systemtap.base/sdt.stp sdt.c.exe.0 -c ./sdt.c.exe.0
FAIL: sdt -O2 uprobe
line 1: expected "_"
Got "semantic error: unable to find local 'arg1', [man error::dwarf] dieoffset
0x460 in /root/systemtap_write/systemtap/testsuite/sdt.c.exe.0, near pc
0x4004d8 in call1 ./systemtap.base/sdt.c (alternatives: $a)): identifier
'$arg1' at ./systemtap.base/sdt.stp:8:18"
Executing on host: gcc ./systemtap.base/sdt.c -g -isystem.
-isystem/root/systemtap_write/install/include -Wall -Wextra -Werror -O3 -lm
-o sdt.c.exe.1 (timeout = 300)
spawn -ignore SIGHUP gcc ./systemtap.base/sdt.c -g -isystem.
-isystem/root/systemtap_write/install/include -Wall -Wextra -Werror -O3 -lm -o
sdt.c.exe.1
PASS: compiling sdt.c -O3 uprobe
executing: stap -w ./systemtap.base/sdt.stp sdt.c.exe.1 -c ./sdt.c.exe.1
FAIL: sdt -O3 uprobe
line 1: expected "_"
Got "semantic error: unable to find local 'arg1', [man error::dwarf] dieoffset
0x460 in /root/systemtap_write/systemtap/testsuite/sdt.c.exe.1, near pc
0x4004d8 in call1 ./systemtap.base/sdt.c (alternatives: $a)): identifier
'$arg1' at ./systemtap.base/sdt.stp:8:18"
Executing on host: gcc ./systemtap.base/sdt.c -g -isystem.
-isystem/root/systemtap_write/install/include -Wall -Wextra -Werror -std=c89
-lm -o sdt.c.exe.2 (timeout = 300)
Looking at the .s files generated by added '-save-temps' to the compiles show a
marker with just a raw literal in there:
.pushsection .note.stapsdt,"?","note"
.balign 4
.4byte 992f-991f,994f-993f,3
991: .asciz "stapsdt"
992: .balign 4
993: .8byte 990b
.8byte _.stapsdt.base
.8byte 0
.asciz "test"
.asciz "mark_a"
.asciz "-4@1"
994: .balign 4
.popsection
The unoptimized c89 version the marker below is getting the argument from
memory and the test passes:
.pushsection .note.stapsdt,"?","note"
.balign 4
.4byte 992f-991f,994f-993f,3
991: .asciz "stapsdt"
992: .balign 4
993: .8byte 990b
.8byte _.stapsdt.base
.8byte 0
.asciz "test"
.asciz "mark_a"
.asciz "-4@[sp,12]"
994: .balign 4
.popsection
Need to be a bit careful fixing this because the ppc doesn't prefix constants
either but also uses raw constants as register names. Careless changes for
arm64 could break things for ppc.
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/17889] the translator does not understand arm64 constants in sdt markers
2015-01-27 21:28 [Bug translator/17889] New: the translator does not understand arm64 constants in sdt markers wcohen at redhat dot com
@ 2015-01-27 22:31 ` wcohen at redhat dot com
2015-01-28 3:51 ` wcohen at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2015-01-27 22:31 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17889
--- Comment #1 from William Cohen <wcohen at redhat dot com> ---
Created attachment 8086
--> https://sourceware.org/bugzilla/attachment.cgi?id=8086&action=edit
Allow machine the arm64 unpredixed constants
Did a check on arm64 and x86_64 with this patch and the following
# make installcheck RUNTESTFLAGS="--debug systemtap.base/sdt.exp"
On arm64 all the tests including the ones that optimize the marker arguments to
constants all pass:.
=== systemtap Summary ===
# of expected passes 64
On x86_64 had no failures (so the alternative regexp didn't mess things up):
=== systemtap Summary ===
# of expected passes 64
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/17889] the translator does not understand arm64 constants in sdt markers
2015-01-27 21:28 [Bug translator/17889] New: the translator does not understand arm64 constants in sdt markers wcohen at redhat dot com
2015-01-27 22:31 ` [Bug translator/17889] " wcohen at redhat dot com
@ 2015-01-28 3:51 ` wcohen at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: wcohen at redhat dot com @ 2015-01-28 3:51 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17889
William Cohen <wcohen at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED
--- Comment #2 from William Cohen <wcohen at redhat dot com> ---
commit 7be1b19f9898edcad40896228f0235030c3339ad should address this issue.
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-01-28 3:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-27 21:28 [Bug translator/17889] New: the translator does not understand arm64 constants in sdt markers wcohen at redhat dot com
2015-01-27 22:31 ` [Bug translator/17889] " wcohen at redhat dot com
2015-01-28 3:51 ` wcohen at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).