From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24671 invoked by alias); 25 Jul 2014 09:33:56 -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 24526 invoked by uid 48); 25 Jul 2014 09:33:51 -0000 From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/61904] Incorrect stack red-zoning on x86-64 code generation Date: Fri, 25 Jul 2014 09:33: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: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: RESOLVED 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: bug_status resolution 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: 2014-07/txt/msg01682.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61904 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE --- Comment #6 from Richard Biener --- Reduced set of options to reproduce with 4.9.1 are -mno-red-zone -mcmodel=kernel -maccumulate-outgoing-args -mno-sse -g -Os -fno-omit-frame-pointer if you use -fno-var-tracking the bug goes away, similar if you update to the 4.9 branch head. If you use -fno-schedule-insns2 you see a similar pattern to the mentioned PR: subq $424, %rsp .LCFI427: movl %edi, -400(%rbp) movq %rdx, %rbx movl %ecx, -396(%rbp) movq %r8, -464(%rbp) .LVL1306: .loc 2 6489 0 movq (%rdx), %rax movq %rax, -440(%rbp) .LVL1307: .LBB2616: .loc 2 6493 0 movq $load_balance_mask, -384(%rbp) movq -384(%rbp), %rax .LVL1308: #APP # 6493 "kernel/sched/fair.c" 1 add %gs:this_cpu_off, %rax so that spill is right before the asm and we immediately re-load it into a register required by an asm constraint (stupid register allocator). *** This bug has been marked as a duplicate of bug 61801 ***