From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20769 invoked by alias); 29 Jan 2014 07:39:05 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 20734 invoked by uid 48); 29 Jan 2014 07:39:00 -0000 From: "chengniansun at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/59976] New: Spurious warning on converting const int variable to unsigned long Date: Wed, 29 Jan 2014 07:39:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: chengniansun at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-01/txt/msg02976.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D59976 Bug ID: 59976 Summary: Spurious warning on converting const int variable to unsigned long Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: chengniansun at gmail dot com I define a static global variable "g" of type "const int", with a value 0. = When assigning it to a variable of type unsigned long, Gcc emits a warning on the signedness conversion. As "g" is not modifiable and equivalent to "0", ther= e is no signedness conversion actually.=20 $: cat s.c static const int g =3D 0; void fn() { unsigned long l =3D g; } $: gcc-trunk -c -Wconversion s.c s.c: In function =E2=80=98fn=E2=80=99: s.c:3:3: warning: conversion to =E2=80=98long unsigned int=E2=80=99 from = =E2=80=98int=E2=80=99 may change the sign of the result [-Wsign-conversion] unsigned long l =3D g; ^ $: gcc-trunk -v Using built-in specs. COLLECT_GCC=3Dgcc-trunk COLLECT_LTO_WRAPPER=3D/home/chengniansun/tools/gcc-trunk-binaries/libexec/g= cc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../gcc-trunk/configure --enable-languages=3Dc,c++ --disable-multilib --prefix=3D/home/chengniansun/tools/gcc-trunk-binaries : (reconfigured) ../gcc-trunk/configure --enable-languages=3Dc,c++ --disable-multilib --prefix=3D/home/chengniansun/tools/gcc-trunk-binaries Thread model: posix gcc version 4.9.0 20140127 (experimental) (GCC) $: $: clang-trunk -c -Wconversion s.c $: >>From gcc-bugs-return-441835-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Jan 29 08:56:38 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 30819 invoked by alias); 29 Jan 2014 08:56:37 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 30804 invoked by uid 48); 29 Jan 2014 08:56:32 -0000 From: "nheghathivhistha at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/59977] New: lto1: internal compiler error: bytecode stream: expected tag real_type instead of error_mark Date: Wed, 29 Jan 2014 08:56:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: lto X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: nheghathivhistha at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-01/txt/msg02977.txt.bz2 Content-length: 3787 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59977 Bug ID: 59977 Summary: lto1: internal compiler error: bytecode stream: expected tag real_type instead of error_mark Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: lto Assignee: unassigned at gcc dot gnu.org Reporter: nheghathivhistha at gmail dot com Created attachment 31975 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=31975&action=edit un-reduced gzipped preprocessed file When I remove libraries it not ICEs. Creduce is stuck at beginning and not able to remove any line. When I ran cat testcase.i | grep -v '^# .*$' | grep -v '^[[:space:]]*$' > testcase.x on ii file and test the resulting files with comments removed it not ICEs with the same compilation command. gcc -v Using built-in specs. COLLECT_GCC=/usr/x86_64-pc-linux-gnu/gcc-bin/4.9.0-alpha20140128/gcc COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.9.0-alpha20140128/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /var/tmp/portage/sys-devel/gcc-4.9.0_alpha20140128/work/gcc-4.9-20140128/configure --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.9.0-alpha20140128 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.0-alpha20140128/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.0-alpha20140128 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.0-alpha20140128/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.0-alpha20140128/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.0-alpha20140128/include/g++-v4 --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.9.0-alpha20140128/python --enable-languages=c,c++,java,go,objc,obj-c++,fortran,ada --enable-obsolete --disable-werror --with-system-zlib --enable-nls --without-included-gettext --enable-checking=release --with-bugurl=https://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.9.0_alpha20140128' --enable-libstdcxx-time --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-multilib --disable-altivec --disable-fixed-point --enable-targets=all --enable-java-awt=gtk --enable-libgomp --enable-lto --without-cloog Thread model: posix gcc version 4.9.0-alpha20140128 20140129 (experimental) [trunk revision 207224] (Gentoo 4.9.0_alpha20140128) The command is: LC_ALL=C LANG=C /usr/bin/x86_64-pc-linux-gnu-g++ -fPIC -flto=4 -fuse-linker-plugin -O2 -ggdb -pipe -march=native -mtune=native -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -Wformat-security -fno-exceptions -DQT_NO_EXCEPTIONS -fno-check-new -fno-common -Woverloaded-virtual -fno-threadsafe-statics -fvisibility=hidden -fvisibility-inlines-hidden -march=core2 -msse2 -msse3 -mssse3 -msse4.1 -mno-sse4.2 -mno-sse4a -mno-avx -mno-xop -mno-fma4 -Wabi -fabi-version=0 -ffp-contract=fast -Wl,--enable-new-dtags -Wl,--no-undefined -lc -flto=4 -fuse-linker-plugin -Wl,--as-needed -Wl,-O2 -O2 -ggdb -pipe -march=native -mtune=native -shared -Wl,-soname,libpigmentcms.so.13 -o /dev/null /var/tmp/portage/app-office/calligra-2.7.91/work/calligra-2.7.91_build/libs/pigment/KoOptimizedCompositeOpFactoryPerArch_Scalar.ii -L/var/tmp/portage/app-office/calligra-2.7.91/work/calligra-2.7.91_build/lib -L/usr/lib64/qt4 /var/tmp/portage/app-office/calligra-2.7.91/work/calligra-2.7.91_build/lib/libkoplugin.so.13.0.0 -lImath -lIlmImf -lIex -lHalf -lIlmThread -Wl,-Bstatic -lVc -Wl,-Bdynamic /usr/lib64/qt4/libQtGui.so /usr/lib64/qt4/libQtXml.so /usr/lib64/libkdecore.so.5.12.1 /usr/lib64/qt4/libQtDBus.so /usr/lib64/qt4/libQtCore.so -lpthread How can I reduce it please?