Bug 811749

Summary: tapsets provided by qemu contain errors
Product: [Fedora] Fedora Reporter: Richard W.M. Jones <rjones>
Component: qemuAssignee: Fedora Virtualization Maintainers <virt-maint>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 17CC: amit.shah, berrange, cfergeau, crobinso, dsmith, dwmw2, ehabkost, fche, itamar, jistone, knoel, mjw, pbonzini, pmuller, scottt.tw, scox, virt-maint, wcohen
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-07-10 11:23:27 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Richard W.M. Jones 2012-04-11 21:15:55 UTC
Description of problem:

Not sure if this is a qemu bug or a systemtap bug.  Please
feel to reassign.

When you have qemu installed and you start 'stap' it prints
lots of warnings:

parse error: expected statement
	saw: keyword at /usr/share/systemtap/tapset/qemu-kvm.stp:1139:3
     source:   in = $arg3;
               ^
parse error: expected literal string or number
	saw: operator '=' at /usr/share/systemtap/tapset/qemu-kvm.stp:2078:8
     source:   next = $arg1;
                    ^
2 parse errors.
WARNING: tapset '/usr/share/systemtap/tapset/qemu-kvm.stp' has errors, and will be skipped.
parse error: expected statement
	saw: keyword at /usr/share/systemtap/tapset/qemu-system-i386.stp:1139:3
     source:   in = $arg3;
               ^
parse error: expected literal string or number
	saw: operator '=' at /usr/share/systemtap/tapset/qemu-system-i386.stp:2078:8
     source:   next = $arg1;
                    ^
2 parse errors.
WARNING: tapset '/usr/share/systemtap/tapset/qemu-system-i386.stp' has errors, and will be skipped.
parse error: expected statement
	saw: keyword at /usr/share/systemtap/tapset/qemu-system-x86_64.stp:1139:3
     source:   in = $arg3;
               ^
parse error: expected literal string or number
	saw: operator '=' at /usr/share/systemtap/tapset/qemu-system-x86_64.stp:2078:8
     source:   next = $arg1;
                    ^
2 parse errors.
WARNING: tapset '/usr/share/systemtap/tapset/qemu-system-x86_64.stp' has errors, and will be skipped.

Version-Release number of selected component (if applicable):

qemu-kvm-1.0-11.fc17.x86_64
systemtap-1.7-5.fc17.x86_64

How reproducible:

100%

Steps to Reproduce:
1. Run stap on any valid systemtap input file.
2.
3.
  
Actual results:

Lots of warnings, although it seems otherwise unaffected.

Expected results:

Shouldn't be any warnings.

Additional info:

Comment 1 Josh Stone 2012-04-11 21:56:38 UTC
(In reply to comment #0)
> Not sure if this is a qemu bug or a systemtap bug.  Please
> feel to reassign.

I think this belongs to qemu.

> parse error: expected statement
>  saw: keyword at /usr/share/systemtap/tapset/qemu-kvm.stp:1139:3
>      source:   in = $arg3;
>                ^
> parse error: expected literal string or number
>  saw: operator '=' at /usr/share/systemtap/tapset/qemu-kvm.stp:2078:8
>      source:   next = $arg1;
>                     ^

The issue is that "in" and "next" are stap keywords (for quite some time), so they can't be used as local variable names.  AFAICT these .stp files are generated from the source file "trace-events", so the keyword clash is not directly evident. (And it was likely authored by someone using a different tracing infrastructure.)

> WARNING: tapset '/usr/share/systemtap/tapset/qemu-kvm.stp' has errors, and will be skipped.
> WARNING: tapset '/usr/share/systemtap/tapset/qemu-system-i386.stp' has errors, and will be skipped.
> WARNING: tapset '/usr/share/systemtap/tapset/qemu-system-x86_64.stp' has errors, and will be skipped.
...
> Lots of warnings, although it seems otherwise unaffected.

The only tangible side effect is that you'll be unable to used any aliases from the skipped files.

Comment 2 Cole Robinson 2012-07-10 11:23:27 UTC

*** This bug has been marked as a duplicate of bug 831763 ***