[LLVMbugs] [Bug 17270] New: error: expected '@' or '%' before type

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Sep 17 12:10:20 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=17270

            Bug ID: 17270
           Summary: error: expected '@' or '%' before type
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: MC
          Assignee: unassignedbugs at nondot.org
          Reporter: martin at martincmartin.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 11227
  --> http://llvm.org/bugs/attachment.cgi?id=11227&action=edit
Preprocessed source that generates the error

Bug 17198 fixed the first problem when compiling SystemTap's DTRACE_PROBE()
macro.  My clang++ includes that fix:

$ clang++ --version
clang version 3.4 (trunk 190785)
Target: x86_64-unknown-linux-gnu
Thread model: posix

The next problem is:

dtrace_probe_preprocessed_stripped.cpp:125:49: error: expected '@' or '%'
before type
    do { __asm__ __volatile__ ("990: nop" "\n" ".pushsection .note.stapsdt" ","
"\"?\"" "," "\"note\"" "\n" ".ba...
                                                ^
<inline asm>:2:32: note: instantiated into assembly here
.pushsection .note.stapsdt,"?","note"
                               ^
dtrace_probe_preprocessed_stripped.cpp:125:378: error: .popsection without
corresponding .pushsection
  ...0" "\n" ".asciz \"a\"" "\n" ".asciz \"b\"" "\n" ".asciz \"\"" "\n" "994:
.balign 4" "\n" ".popsection" "\n" :: [...
                                                                               
               ^
<inline asm>:14:12: note: instantiated into assembly here
.popsection
           ^
dtrace_probe_preprocessed_stripped.cpp:125:476: error: expected '@' or '%'
before type
  ...".popsection" "\n" :: [__sdt_dummy] "g" (0)); __asm__ __volatile__
(".ifndef _.stapsdt.base" "\n" ".pushsection ...
                                                                               
                        ^
<inline asm>:2:33: note: instantiated into assembly here
.pushsection .stapsdt.base,"aG","progbits",.stapsdt.base,comdat
                                ^
dtrace_probe_preprocessed_stripped.cpp:125:701: error: .popsection without
corresponding .pushsection
  ..._.stapsdt.base" "\n" "_.stapsdt.base: .space 1" "\n" ".size
_.stapsdt.base" "," "1" "\n" ".popsection" "\n" ".en...
                                                                               
               ^
<inline asm>:7:12: note: instantiated into assembly here
.popsection
           ^
4 errors generated.

Source was simply:

#include <sys/sdt.h>

int main() {
    DTRACE_PROBE(a, b);
}

Relevant part of preprocessed source attached.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130917/f9b31ca5/attachment.html>


More information about the llvm-bugs mailing list