Bug 910421 - Seeing "error: impossible constraint in ‘asm’" when building <sys/sdt.h>-based application with g++ -O0
Summary: Seeing "error: impossible constraint in ‘asm’" when building <sys/sdt.h>-base...
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-12 15:45 UTC by Darryl L. Pierce
Modified: 2015-06-22 00:08 UTC (History)
11 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-02-13 10:11:57 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
preprocessed input demonstrating problem, based on systemtap test case (238.08 KB, text/plain)
2013-02-13 03:46 UTC, Frank Ch. Eigler
no flags Details


Links
System ID Private Priority Status Summary Last Updated
GNU Compiler Collection 56302 0 None None None Never

Description Darryl L. Pierce 2013-02-12 15:45:05 UTC
Description of problem:

In building Qpid 0.20 on Fedora 19, the build fails due to systemtap-sdt-devel.


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

mcpierce@mcp-f19-x86:cmake (QPID-4579-FTBFS-with-gcc-4.8.0) $ rpm -q systemtap-sdt-devel
systemtap-sdt-devel-2.1-0.385.gab733d5.fc19.i686


How reproducible:

100%


Steps to Reproduce:
1. Attempt to build qpid-0.20 on Fedora 19
  
Actual results:

In file included from /home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/Probes.h:27:0,
                 from /home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp:26:
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp: In member function ‘void qpid::sys::posix::AsynchIO::readable(qpid::sys::DispatchHandle&)’:
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/Probes.h:41:44: error: impossible constraint in ‘asm’
 #define QPID_PROBE4(probe, p1, p2, p3, p4) DTRACE_PROBE4(qpid, probe, p1, p2, p3, p4)
                                            ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp:456:21: note: in expansion of macro ‘QPID_PROBE4’
                     QPID_PROBE4(asynchio_read_finished_done, &h, duration, total, readCalls);
                     ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/Probes.h:41:44: error: impossible constraint in ‘asm’
 #define QPID_PROBE4(probe, p1, p2, p3, p4) DTRACE_PROBE4(qpid, probe, p1, p2, p3, p4)
                                            ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp:462:21: note: in expansion of macro ‘QPID_PROBE4’
                     QPID_PROBE4(asynchio_read_finished_maxtime, &h, duration, total, readCalls);
                     ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/Probes.h:42:48: error: impossible constraint in ‘asm’
 #define QPID_PROBE5(probe, p1, p2, p3, p4, p5) DTRACE_PROBE5(qpid, probe, p1, p2, p3, p4, p5)
                                                ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp:471:17: note: in expansion of macro ‘QPID_PROBE5’
                 QPID_PROBE5(asynchio_read_finished_error, &h, duration, total, readCalls, errno);
                 ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/Probes.h:41:44: error: impossible constraint in ‘asm’
 #define QPID_PROBE4(probe, p1, p2, p3, p4) DTRACE_PROBE4(qpid, probe, p1, p2, p3, p4)
                                            ^
/home/mcpierce/Programming/Qpid/qpid/cpp/src/qpid/sys/posix/AsynchIO.cpp:497:17: note: in expansion of macro ‘QPID_PROBE4’
                 QPID_PROBE4(asynchio_read_finished_nobuffers, &h, Duration(readStartTime, AbsTime::now()), total, readCalls);
                 ^
make[2]: *** [src/CMakeFiles/qpidcommon.dir/qpid/sys/posix/AsynchIO.o] Error 1
make[1]: *** [src/CMakeFiles/qpidcommon.dir/all] Error 2
make: *** [all] Error 2


Expected results:

A successful build.


Additional info:

This issue does not exist on previous Fedora releases using systemtap-sdt-devel <= 2.0-6

Comment 1 Darryl L. Pierce 2013-02-12 19:27:55 UTC
It turns out this error, while showing up in the Qpid development environment, does not actually manifest in the Qpid package build. It still is blocking development.

Comment 2 Josh Stone 2013-02-13 03:22:57 UTC
(In reply to comment #0)
> This issue does not exist on previous Fedora releases using
> systemtap-sdt-devel <= 2.0-6

FWIW, sdt.h hasn't changed at all since systemtap 2.0, so this is more likely due to some change in gcc 4.8.  We still need to investigate before passing the buck though. :)

Comment 3 Frank Ch. Eigler 2013-02-13 03:36:51 UTC
Darryl, please check whether your developer builds were done with -O0 (and that with -O2, the problem disappears).  If so, one of the stap teststuite items reproduces your problem.

Comment 4 Frank Ch. Eigler 2013-02-13 03:46:36 UTC
Created attachment 696700 [details]
preprocessed input demonstrating problem, based on systemtap test case

/usr/libexec/gcc/x86_64-redhat-linux/4.8.0/cc1plus -fpreprocessed cast-scope.ii -quiet -dumpbase cast-scope.cxx -mtune=generic -march=x86-64 -auxbase cast-scope -g -O0 -version -o cast-scope.s

Note with -O1 and up, it works.  Previous gcc's work fine with -O0 and up.

Comment 5 Jakub Jelinek 2013-02-13 10:11:57 UTC
Tracking this upstream.

Comment 6 Darryl L. Pierce 2013-04-08 15:50:21 UTC
Has there been any progress on this bug? I see that, in the upstream bug, it says it's fixed.

Comment 7 Jakub Jelinek 2013-04-08 15:59:37 UTC
What progress would you expect?  Just look at the date where it has been fixed upstream (and which branch), then what date is current F19 or rawhide gcc based on.  If it is newer than the commit fix, it implies the fix is in.


Note You need to log in before you can comment on or make changes to this bug.