From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26048 invoked by alias); 29 May 2010 11:43:12 -0000 Received: (qmail 25877 invoked by uid 48); 29 May 2010 11:43:00 -0000 Date: Sat, 29 May 2010 11:43:00 -0000 Message-ID: <20100529114300.25876.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug target/44290] [4.5 Regression] arm linux kernel crahes when built with -fipa-sra, __naked attribute is broken In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "rguenth at gcc dot gnu dot org" 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: 2010-05/txt/msg03203.txt.bz2 ------- Comment #9 from rguenth at gcc dot gnu dot org 2010-05-29 11:42 ------- (In reply to comment #8) > (In reply to comment #6) > > I note that copypage-xscale.c:xscale_mc_copy_user_highpage() calls a __naked > > function to do the bulk copy. Converting that to a plain inline function > > (changing 'pc' to 'lr' in the final instruction that restores the scrach regs), > > does not prevent the crash. So I suspect a plain C code miscompilation. > > Actually that conversion away from __naked may have been flawed. What I'm > seeing is that r148981 causes gcc to clone the __naked function and change its > calling conventions in ways that don't match the proper function call ABI. > This breaks the body of the __naked function which is just a big asm() > statement. Well. The arm backend needs to mark the function as "used in non-visible ways" then. Thus this is a target bug. -- rguenth at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Component|tree-optimization |target Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2010-05-29 11:42:59 date| | Summary|[4.5 Regression] arm linux |[4.5 Regression] arm linux |kernel crahes when built |kernel crahes when built |with -fipa-sra |with -fipa-sra, __naked | |attribute is broken http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44290