From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15439 invoked by alias); 10 May 2006 15:06:21 -0000 Received: (qmail 15414 invoked by uid 48); 10 May 2006 15:06:11 -0000 Date: Wed, 10 May 2006 15:06:00 -0000 Message-ID: <20060510150611.15413.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug middle-end/27528] compiling linux kernels 2.6.16.14/15 2.6.17-rc3 on powerpc (7450) get error on long exixting code In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "pinskia at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-05/txt/msg01002.txt.bz2 List-Id: ------- Comment #7 from pinskia at gcc dot gnu dot org 2006-05-10 15:06 ------- (In reply to comment #5) > To A Pinski > While I am _not_ a C lawyer, the following seems pertinent: Why do you think this is related to the C standard? > > 1 __FUNCTION__ is _not_ a predefined macro. However __func__ a predefined > identifier and I will take this up with the kernel people. However, even > changing__FUNCTION__ to __func__ still produces an error. Let the language > lawyer sort this out. So what? > 2 Taking __FUNCTION__ entirely out of the original Macro Definition and using > all of the kernel paraphernalia produces valid code. Out of that context I can > not get even __FILE__ to work properly; only __line__ > > 3 Your "Hi" misses the point because it is certainly not a predefined macro > and not even a predefined identifier. Therefore the comparison seems invalid to > me. HUH? Look at how __FILE__ gets subsituted. > > I am reopening this because I believe that the raised by "__func__" should be > addressed. Also it is not the first time that the kernel people found ways to > get GCC closer to the standards. __func__ is a static variable and that is how the C standard defines it. It will be put into the section anchor. You will also have issues with: static int t; void f(void) { asm ("" : : "I"(&t)); } ===== But all of that is undefined as explained by how the documentation is defined. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC|dje at gcc dot gnu dot org | Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27528