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]

[Bug translator/2252] New: stap generated code does not compile on RHEL4 UP kernel


When using a RHEL4 UP kernel on an i686 machine the code generated by the stap
translator does not compile. The problem is not observed with the RHEL4 SMP i686
kernel. This problem is doesn't happen on FC4 UP kernel either. This problem can
be observed on most all of the tests/testsuite/systemtap.base tests. 

The kernel:

$ uname -a
Linux slingshot.devel.redhat.com 2.6.9-27.EL #1 Tue Dec 20 19:13:33 EST 2005
i686 athlon i386 GNU/Linux

System version

$ /usr/local/bin/stap -V SystemTap translator/driver (version 0.5.3 built
2006-01-31)
Copyright (C) 2005-2006 Red Hat, Inc. and others
This is free software; see the source for copying conditions.

Example of the problem:

$ /usr/local/bin/stap -v -v systemtap.base/add.stp -k
[... snip...]
make -f scripts/Makefile.build obj=/tmp/stapkKAj36
  gcc -Wp,-MD,/tmp/stapkKAj36/.stap_4016.o.d -nostdinc -iwithprefix include
-D__KERNEL__ -Iinclude  -Wall -Wstrict-prototypes -Wno-trigraphs
-fno-strict-aliasing -fno-common -Os -fomit-frame-pointer -g
-Wdeclaration-after-statement -pipe -msoft-float -m32 -fno-builtin-sprintf
-fno-builtin-log2 -fno-builtin-puts  -mpreferred-stack-boundary=2
-fno-unit-at-a-time -march=i686 -mregparm=3 -Iinclude/asm-i386/mach-default
-Wno-unused -Werror -I "/usr/local/share/systemtap/runtime" -I
"/usr/local/share/systemtap/runtime/relayfs"   -DMODULE
-DKBUILD_BASENAME=stap_4016 -DKBUILD_MODNAME=stap_4016 -c -o
/tmp/stapkKAj36/.tmp_stap_4016.o /tmp/stapkKAj36/stap_4016.c
/tmp/stapkKAj36/stap_4016.c: In function `probe_1':
/tmp/stapkKAj36/stap_4016.c:305: error: syntax error before "do"
/tmp/stapkKAj36/stap_4016.c:305: error: syntax error before ',' token
/tmp/stapkKAj36/stap_4016.c:307: error: `numtrylock' undeclared (first use in
this function)
/tmp/stapkKAj36/stap_4016.c:307: error: (Each undeclared identifier is reported
only once
/tmp/stapkKAj36/stap_4016.c:307: error: for each function it appears in.)
/tmp/stapkKAj36/stap_4016.c:311: error: syntax error before "do"
/tmp/stapkKAj36/stap_4016.c:303: error: label `unlock_' used but not defined
/tmp/stapkKAj36/stap_4016.c:309: error: label `unlock_x3' used but not defined
/tmp/stapkKAj36/stap_4016.c: At top level:
/tmp/stapkKAj36/stap_4016.c:311: error: syntax error before "while"
/tmp/stapkKAj36/stap_4016.c:331: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:331: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:331: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:331: error: conflicting types for 'strlcpy'
include/linux/string.h:33: error: previous declaration of 'strlcpy' was here
/tmp/stapkKAj36/stap_4016.c:331: error: conflicting types for 'strlcpy'
include/linux/string.h:33: error: previous declaration of 'strlcpy' was here
/tmp/stapkKAj36/stap_4016.c:331: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:339: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:339: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:339: error: conflicting types for 'function_log'
/tmp/stapkKAj36/stap_4016.c:127: error: previous definition of 'function_log'
was here
/tmp/stapkKAj36/stap_4016.c:339: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:340: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:358: warning: type defaults to `int' in declaration
of `global_x3'
/tmp/stapkKAj36/stap_4016.c:358: error: conflicting types for 'global_x3'
/tmp/stapkKAj36/stap_4016.c:116: error: previous declaration of 'global_x3' was here
/tmp/stapkKAj36/stap_4016.c:358: error: `l' undeclared here (not in a function)
/tmp/stapkKAj36/stap_4016.c:358: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:359: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:387: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:387: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:387: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:387: warning: data definition has no type
or storage class
/tmp/stapkKAj36/stap_4016.c:395: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:395: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:395: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:396: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:423: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:423: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:423: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:423: warning: data definition has no type
or storage class
/tmp/stapkKAj36/stap_4016.c:431: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:431: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:431: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:432: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:458: warning: type defaults to `int' in declaration
of `_stp_exit'
/tmp/stapkKAj36/stap_4016.c:458: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:458: error: conflicting types for '_stp_exit'
/usr/local/share/systemtap/runtime/io.c:118: error: previous definition of
'_stp_exit' was here
/tmp/stapkKAj36/stap_4016.c:458: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:459: error: syntax error before '}' token
{standard input}: Assembler messages:
{standard input}:80258: Error: symbol `global_x3' is already defined
make[1]: *** [/tmp/stapkKAj36/stap_4016.o] Error 1
make -f scripts/Makefile.build obj=/tmp/stapkKAj36
  gcc -Wp,-MD,/tmp/stapkKAj36/.stap_4016.o.d -nostdinc -iwithprefix include
-D__KERNEL__ -Iinclude  -Wall -Wstrict-prototypes -Wno-trigraphs
-fno-strict-aliasing -fno-common -Os -fomit-frame-pointer -g
-Wdeclaration-after-statement -pipe -msoft-float -m32 -fno-builtin-sprintf
-fno-builtin-log2 -fno-builtin-puts  -mpreferred-stack-boundary=2
-fno-unit-at-a-time -march=i686 -mregparm=3 -Iinclude/asm-i386/mach-default
-Wno-unused -Werror -I "/usr/local/share/systemtap/runtime" -I
"/usr/local/share/systemtap/runtime/relayfs"   -DMODULE
-DKBUILD_BASENAME=stap_4016 -DKBUILD_MODNAME=stap_4016 -c -o
/tmp/stapkKAj36/.tmp_stap_4016.o /tmp/stapkKAj36/stap_4016.c
/tmp/stapkKAj36/stap_4016.c: In function `probe_1':
/tmp/stapkKAj36/stap_4016.c:305: error: syntax error before "do"
/tmp/stapkKAj36/stap_4016.c:305: error: syntax error before ',' token
/tmp/stapkKAj36/stap_4016.c:307: error: `numtrylock' undeclared (first use in
this function)
/tmp/stapkKAj36/stap_4016.c:307: error: (Each undeclared identifier is reported
only once
/tmp/stapkKAj36/stap_4016.c:307: error: for each function it appears in.)
/tmp/stapkKAj36/stap_4016.c:311: error: syntax error before "do"
/tmp/stapkKAj36/stap_4016.c:303: error: label `unlock_' used but not defined
/tmp/stapkKAj36/stap_4016.c:309: error: label `unlock_x3' used but not defined
/tmp/stapkKAj36/stap_4016.c: At top level:
/tmp/stapkKAj36/stap_4016.c:311: error: syntax error before "while"
/tmp/stapkKAj36/stap_4016.c:331: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:331: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:331: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:331: error: conflicting types for 'strlcpy'
include/linux/string.h:33: error: previous declaration of 'strlcpy' was here
/tmp/stapkKAj36/stap_4016.c:331: error: conflicting types for 'strlcpy'
include/linux/string.h:33: error: previous declaration of 'strlcpy' was here
/tmp/stapkKAj36/stap_4016.c:331: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:339: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:339: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:339: error: conflicting types for 'function_log'
/tmp/stapkKAj36/stap_4016.c:127: error: previous definition of 'function_log'
was here
/tmp/stapkKAj36/stap_4016.c:339: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:340: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:358: warning: type defaults to `int' in declaration
of `global_x3'
/tmp/stapkKAj36/stap_4016.c:358: error: conflicting types for 'global_x3'
/tmp/stapkKAj36/stap_4016.c:116: error: previous declaration of 'global_x3' was here
/tmp/stapkKAj36/stap_4016.c:358: error: `l' undeclared here (not in a function)
/tmp/stapkKAj36/stap_4016.c:358: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:359: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:387: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:387: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:387: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:387: warning: data definition has no type
or storage class
/tmp/stapkKAj36/stap_4016.c:395: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:395: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:395: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:396: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:423: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:423: warning: type defaults to `int' in declaration
of `strlcpy'
/tmp/stapkKAj36/stap_4016.c:423: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:423: warning: data definition has no type
or storage class
/tmp/stapkKAj36/stap_4016.c:431: warning: type defaults to `int' in declaration
of `function_log'
/tmp/stapkKAj36/stap_4016.c:431: warning: parameter names (without types) in
function declaration
/tmp/stapkKAj36/stap_4016.c:431: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:432: error: syntax error before '->' token
/tmp/stapkKAj36/stap_4016.c:458: warning: type defaults to `int' in declaration
of `_stp_exit'
/tmp/stapkKAj36/stap_4016.c:458: warning: function declaration isn't a
prototype/tmp/stapkKAj36/stap_4016.c:458: error: conflicting types for '_stp_exit'
/usr/local/share/systemtap/runtime/io.c:118: error: previous definition of
'_stp_exit' was here
/tmp/stapkKAj36/stap_4016.c:458: warning: data definition has no type or storage
class
/tmp/stapkKAj36/stap_4016.c:459: error: syntax error before '}' token
{standard input}: Assembler messages:
{standard input}:80258: Error: symbol `global_x3' is already defined
make[1]: *** [/tmp/stapkKAj36/stap_4016.o] Error 1

-- 
           Summary: stap generated code does not compile on RHEL4 UP kernel
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: wcohen at redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=2252

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


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