Bug 829247
Summary: | Internal compiler error compiling C++ code | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Thiago Macieira <thiago> | ||||||
Component: | gcc | Assignee: | Jakub Jelinek <jakub> | ||||||
Status: | CLOSED UPSTREAM | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | unspecified | ||||||||
Version: | 17 | CC: | jakub, law | ||||||
Target Milestone: | --- | ||||||||
Target Release: | --- | ||||||||
Hardware: | x86_64 | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2012-06-07 07:07:38 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: | |||||||||
Attachments: |
|
Description
Thiago Macieira
2012-06-06 10:09:33 UTC
Created attachment 589811 [details]
Preprocessed C++ source code
Created attachment 589813 [details] C++ source code compilede with regular C++98 Turns out that C++11 isn't necessary for this issue to happen. This new source code produces the error without the -std=c++0x option. E.g.: $ g++ -O2 -xc++ /tmp/ccu2bGoR.out ../../../../../../src/qt/creator/src/libs/languageutils/fakemetaobject.cpp: In member function ‘QString LanguageUtils::FakeMetaEnum::name() const’: ../../../../../../src/qt/creator/src/libs/languageutils/fakemetaobject.cpp:48:18: internal compiler error: in maybe_record_trace_start, at dwarf2cfi.c:2197 Please submit a full bug report, with preprocessed source if appropriate. See <http://bugzilla.redhat.com/bugzilla> for instructions. Tracking this upstream. Note that the Qt atomic code is broken, you really can't have the atomic insn in one asm stmt and the jz in another asm (asm goto) stmt, the compiler could schedule in between some other instruction that could modify flags. Either it should be a single asm goto that performs the atomic insn and jz afterwards (but then it can't have outputs), or much better you should just use GCC __sync_* intrinsics (or __atomic_* for 4.7+), as you are using asm goto you are requiring gcc much newer than what is guaranteed to have those. Oh, thanks for the pointer. That asm goto was just my own testing, it's unreleased. I didn't realise this would be the problem. Using __atomic_* in GCC 4.7 is my intention. |