From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9403 invoked by alias); 23 Feb 2008 23:12:51 -0000 Received: (qmail 9343 invoked by uid 48); 23 Feb 2008 23:12:06 -0000 Date: Sat, 23 Feb 2008 23:12:00 -0000 Message-ID: <20080223231206.9342.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug target/32219] optimizer causes wrong code in pic/hidden/weak symbol checking. In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "hjl dot tools at gmail dot com" 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 X-SW-Source: 2008-02/txt/msg02509.txt.bz2 ------- Comment #6 from hjl dot tools at gmail dot com 2008-02-23 23:12 ------- Weak and hidden aren't really compatible. Linker should enforce it. I opened a linker bug: http://sourceware.org/bugzilla/show_bug.cgi?id=5789 As for gcc, I think it is OK since it is a user error and linker should issue an error. Besides, gcc doesn't know if the .o file will be used for PIE/shared library or normal executable. The runtime error only happens with PIE/shared library, not normal executable. -- hjl dot tools at gmail dot com changed: What |Removed |Added ---------------------------------------------------------------------------- URL| |http://sourceware.org/bugzil | |la/show_bug.cgi?id=5789 Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32219