public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "manu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/61978] implement blacklist for sanitizer Date: Wed, 01 Apr 2015 09:43:00 -0000 [thread overview] Message-ID: <bug-61978-4-5eoeiSIwPm@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-61978-4@http.gcc.gnu.org/bugzilla/> [-- Warning: decoded text below may be mangled, UTF-8 assumed --] [-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 6100 bytes --] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61978 Manuel López-Ibáñez <manu at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |manu at gcc dot gnu.org --- Comment #10 from Manuel López-Ibáñez <manu at gcc dot gnu.org> --- (In reply to Stewart Martin-Haugh from comment #9) > Hi, > I see this marked as WONTFIX - still, the use-cases that Kostya identifies > are valid, I think. Would anyone be able to implement a patch, or suggest > roughly how this might work? Although existing GCC devs may not find this feature interesting enough to implement it themselves, a nice, small patch properly submitted together with a convincingly argued rationale may get accepted. It seems this feature is being used not only by Chromium but also by LibreOffice, and many GCC users would still like to keep using GCC for building those programs. Many features that were initially rejected have been later accepted (e.g., color diagnostics). It just needs someone to get behind the idea and push for it in the right way. >From gcc-bugs-return-482474-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Apr 01 09:44:39 2015 Return-Path: <gcc-bugs-return-482474-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org> Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 38388 invoked by alias); 1 Apr 2015 09:44:39 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: <gcc-bugs.gcc.gnu.org> List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/> List-Post: <mailto:gcc-bugs@gcc.gnu.org> List-Help: <mailto:gcc-bugs-help@gcc.gnu.org> Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 38056 invoked by uid 48); 1 Apr 2015 09:44:35 -0000 From: "terry.guo at arm dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/65648] New: [5 Regression] Bad code due to IRA fails to recognize the clobber in parallel Date: Wed, 01 Apr 2015 09:44:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new 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: terry.guo at arm dot com 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: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: <bug-65648-4@http.gcc.gnu.org/bugzilla/> 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-04/txt/msg00026.txt.bz2 Content-length: 3032 https://gcc.gnu.org/bugzilla/show_bug.cgi?ide648 Bug ID: 65648 Summary: [5 Regression] Bad code due to IRA fails to recognize the clobber in parallel Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: terry.guo at arm dot com Created attachment 35200 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id5200&actioníit test case When compile attached case with command: arm-none-eabi-gcc -march=armv6-m -mthumb -Os x.c -S The gcc generates bad code as below: main: push {r0, r1, r2, r4, r5, r6, r7, lr} ldr r4, .L5 movs r5, #0 ldr r0, [r4, #8] add r1, sp, #4 rsbs r2, r0, #0 adcs r2, r2, r0 subs r3, r2, r3 //r3 is used but not initialized The instruction to initialize r3 is removed due to IRA failed to recognize the clobber in reload pass. Before the reload pass, we have three instructions like below: (insn 12 11 14 2 (parallel [ (set (reg:SI 128) (eq:SI (reg:SI 110 [ D.4914 ]) (const_int 0 [0]))) (clobber (reg:SI 129)) ]) x.c:23 760 {*cstoresi_eq0_thumb1_insn} (expr_list:REG_UNUSED (reg:SI 129) (nil))) (insn 20 19 22 2 (set (reg:SI 135) (plus:SI (plus:SI (reg:SI 136) (reg:SI 137)) (geu:SI (reg:SI 131 [ D.4914 ]) (reg:SI 134 [ c ])))) x.c:23 764 {thumb1_addsi3_addgeu} (expr_list:REG_DEAD (reg:SI 137) (expr_list:REG_DEAD (reg:SI 136) (expr_list:REG_DEAD (reg:SI 134 [ c ]) (expr_list:REG_DEAD (reg:SI 131 [ D.4914 ]) (nil)))))) (insn 22 20 23 2 (set (reg:SI 138) (minus:SI (reg:SI 128) (reg:SI 135))) x.c:23 720 {thumb1_subsi3_insn} (expr_list:REG_DEAD (reg:SI 135) (expr_list:REG_DEAD (reg:SI 128) (nil)))) After the reload pass, those instructions are wrongly turned into: (insn 20 53 58 2 (set (reg:SI 3 r3 [135]) (plus:SI (plus:SI (reg:SI 3 r3 [137]) (reg:SI 2 r2 [136])) (geu:SI (reg:SI 7 r7 [orig:131 D.4914 ] [131]) (reg:SI 6 r6 [153])))) x.c:23 764 {thumb1_addsi3_addgeu} (nil)) (insn 58 20 55 2 (parallel [ (set (reg:SI 2 r2 [128]) (eq:SI (reg:SI 0 r0 [orig:110 D.4914 ] [110]) (const_int 0 [0]))) (clobber (reg:SI 3 r3 [129])) ]) x.c:23 760 {*cstoresi_eq0_thumb1_insn} (nil)) (note 55 58 22 2 NOTE_INSN_DELETED) (insn 22 55 23 2 (set (reg:SI 3 r3 [138]) (minus:SI (reg:SI 2 r2 [128]) (reg:SI 3 r3 [135]))) x.c:23 720 {thumb1_subsi3_insn} (nil)) However the later pass can recognize the clobber in insn 58 and will remove the insn 20 because the r3 defined in insn 20 is clobbered by insn 58.
prev parent reply other threads:[~2015-04-01 9:43 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-07-31 16:27 [Bug sanitizer/61978] New: " gcc at dpinol dot com 2014-07-31 20:34 ` [Bug sanitizer/61978] " jakub at gcc dot gnu.org 2014-08-01 8:28 ` kcc at gcc dot gnu.org 2014-08-01 10:59 ` gcc at dpinol dot com 2014-08-01 11:02 ` kcc at gcc dot gnu.org 2014-08-01 11:06 ` kcc at gcc dot gnu.org 2014-08-01 11:13 ` jakub at gcc dot gnu.org 2014-08-01 13:17 ` gcc at dpinol dot com 2014-08-01 14:08 ` kcc at gcc dot gnu.org 2015-04-01 9:43 ` manu at gcc dot gnu.org [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-61978-4-5eoeiSIwPm@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).