From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12592 invoked by alias); 12 Aug 2005 11:07:10 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 12419 invoked by uid 22791); 12 Aug 2005 11:07:06 -0000 Received: from nproxy.gmail.com (HELO nproxy.gmail.com) (64.233.182.196) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Fri, 12 Aug 2005 11:07:06 +0000 Received: by nproxy.gmail.com with SMTP id h2so131082nfe for ; Fri, 12 Aug 2005 04:07:03 -0700 (PDT) Received: by 10.48.143.1 with SMTP id q1mr32662nfd; Fri, 12 Aug 2005 04:07:03 -0700 (PDT) Received: by 10.48.143.6 with HTTP; Fri, 12 Aug 2005 04:07:03 -0700 (PDT) Message-ID: <84fc9c0005081204071177b70e@mail.gmail.com> Date: Fri, 12 Aug 2005 11:07:00 -0000 From: Richard Guenther To: Etienne Lorrain Subject: Re: GCC-4.0.2 20050811: should GCC consider inlining functions in between different sections? Cc: gcc@gcc.gnu.org In-Reply-To: <20050812104015.21689.qmail@web26904.mail.ukl.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <20050812104015.21689.qmail@web26904.mail.ukl.yahoo.com> X-SW-Source: 2005-08/txt/msg00334.txt.bz2 On 8/12/05, Etienne Lorrain wrote: > Hello, >=20 > Subject says it all - I do not know if that is new. I just have a bug > in Gujin-1.2 with this new compiler, because function: >=20 > __attribute__ ((section (".xcode_start"), noreturn)) > void xcodeseg_never_call_address_zero (void) >=20 > calls xcodeseg_BOOT1_putstr() generated by macro: >=20 > #define GENERATE_VOID_EXTRA2CODE_INDIRECT_STUB(fctname, fctadr, params...= ) \ > __attribute__ ((section (STRING(.Xxcode2text_ ## fctname)))) \ > void xcodeseg_ ## fctname (params) { \ > EXTRASEG_REVERSE_STUB (fctadr, STRING(.Xtext2xcode_ ## fctname));\ > } >=20 > Adding ", noinline" to the attribute list fix it all, I just was wonderi= ng > if inlining in between GCC sections is safe in the general case. Please explain the problem you're seeing. I can see nothing wrong with inl= ining functions within different sections in general. If you're trying to do things behind the compilers back, though, be prepared to change workarounds with compiler versions. Richard.