From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 91498 invoked by alias); 13 Mar 2015 14:58:03 -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 84500 invoked by uid 48); 13 Mar 2015 14:57:59 -0000 From: "jcmvbkbc at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/65416] xtensa: memory allocated by alloca is used before the stack pointer is updated Date: Fri, 13 Mar 2015 14:58:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jcmvbkbc at gcc dot gnu.org 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: Message-ID: In-Reply-To: References: 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: 2015-03/txt/msg01442.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65416 --- Comment #1 from jcmvbkbc at gcc dot gnu.org --- It's ok up to sched2 pass, but sched2 does the following to it: ;; ====================================================== ;; -- basic block 62 from 252 to 295 -- after reload ;; ====================================================== ;; 0--> b 0: i 253 a3=[`*.LC13'] :nothing ;; 1--> b 0: i 252 a10=a2 :nothing ;; 2--> b 0: i 254 a10=call [a3] :nothing ;; 3--> b 0: i 257 a11=[`*.LC22'] :nothing ;; 4--> b 0: i 259 a3=[`*.LC13'] :nothing ;; 5--> b 0: i 258 a10=a2 :nothing ;; 6--> b 0: i 260 a10=call [a3] :nothing ;; 7--> b 0: i 261 a11=[a7+0x4] :nothing ;; 8--> b 0: i 262 a10=a2 :nothing ;; 9--> b 0: i 264 a10=call [a3] :nothing ;; 10--> b 0: i 265 a3=sp-0x20 :nothing ;; 11--> b 0: i 271 a4=[`*.LC23'] :nothing ;; 12--> b 0: i 276 [a3+0x8]=a2 :nothing ;; 13--> b 0: i 277 a2=0 :nothing ;; 14--> b 0: i 278 [a3+0xc]=a2 :nothing ;; 15--> b 0: i 279 a2=[`*.LC26'] :nothing ;; 16--> b 0: i 272 [a4]=a3 :nothing ;; 17--> b 0: i 626 a4=[a7] :nothing ;; 18--> b 0: i 280 a2=[a2] :nothing ;; 19--> b 0: i 273 [a3]=a4 :nothing ;; 20--> b 0: i 274 a4=[`*.LC25'] :nothing ;; 21--> b 0: i 627 [a7+0x14]=a2 :nothing ;; 22--> b 0: i 281 a10=[a7+0x18] :nothing ;; 23--> b 0: i 282 a2=[`*.LC27'] :nothing ;; 24--> b 0: i 625 sp=a3 :nothing ;; 25--> b 0: i 275 [a3+0x4]=a4 :nothing ;; 26--> b 0: i 283 call [a2] :nothing ;; 27--> b 0: i 285 a2=[`*.LC28'] :nothing ;; 29--> b 0: i 286 a10=[a2] :nothing ;; 30--> b 0: i 287 a2=[`*.LC29'] :nothing ;; 32--> b 0: i 288 call [a2] :nothing ;; 33--> b 0: i 290 a3=[`*.LC30'] :nothing ;; 35--> b 0: i 291 a10=[a3] :nothing ;; 37--> b 0: i 293 call [a2] :nothing ;; 38--> b 0: i 628 a2=[a7+0x10] :nothing ;; 39--> b 0: i 302 a10=[`*.LC31'] :nothing ;; 40--> b 0: i 295 pc={(a2==0)?L657:pc} :nothing ;; Ready list (final): ;; total time = 40 ;; new head = 253 ;; new tail = 295