From patchwork Fri Jun 29 08:48:06 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nick Clifton X-Patchwork-Id: 168020 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 67F2BB7047 for ; Fri, 29 Jun 2012 18:53:05 +1000 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1341564786; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:Sender:Delivered-To; bh=aHS5djeOsbYr27mByesG VhTOmTw=; b=herkdaNT/KSjgS2dZyeKdMp7Jxxjmh10VY//LZr82OHNCAZum0Xy 4RHCgOqyYlmea6yku7plghsX0YOomYmm/vdjpZqLiKZJbcrTDXtQiSANyajlRO0v DCp7LIf2ZorCzLMmHurpvcfbTEFaFL+9pTnqDoTbqIyKUgbCwa2lHmU= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Received:From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=gv5xX3f7BOct0R1xjU9+YElUMZbthdonjMJIIqnAbgYuUSV02/K0qmZ2TF6Cxh bcf5SA5Fzphe8IdZbNUKUUDRj/Jo1YHvvKPag3ZrJJuRAvr2GuYDqqmfKkSod61k cBeNYTHZ35UQVWUXr8NhLkDU9TKzXrAtdoMpZjQ9TJXxo=; Received: (qmail 6960 invoked by alias); 29 Jun 2012 08:52:59 -0000 Received: (qmail 6951 invoked by uid 22791); 29 Jun 2012 08:52:58 -0000 X-SWARE-Spam-Status: No, hits=-6.1 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, RCVD_IN_DNSWL_HI, RCVD_IN_HOSTKARMA_W, SPF_HELO_PASS, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 29 Jun 2012 08:52:45 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q5T8qjqI008677 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 29 Jun 2012 04:52:45 -0400 Received: from Cadeux.redhat.com (vpn1-4-135.ams2.redhat.com [10.36.4.135]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q5T8qcO2030097 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Fri, 29 Jun 2012 04:52:43 -0400 From: Nick Clifton To: dj@redhat.com Cc: gcc-patches@gcc.gnu.org Subject: RFA: MEP: Fix use of delete_insn. Date: Fri, 29 Jun 2012 09:48:06 +0100 Message-ID: <87d34isdvd.fsf@redhat.com> MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi DJ, The delete_insn() function no longer returns the insn after the one that has been deleted, so gcc/config/mep/mep.c:mep_reorg_regmove() no longer compiles. The patch below is a simple fix for the problem, but I was not sure whether it would be better to use next_nonnote_nondebug_insn() instead. What do you think ? Cheers Nick gcc/ChangeLog 2012-06-29 Nick Clifton * config/mep/mep.c (mep_reorg_regmove): Get next insn before calling delete_insn. Index: gcc/config/mep/mep.c =================================================================== --- gcc/config/mep/mep.c (revision 189064) +++ gcc/config/mep/mep.c (working copy) @@ -5096,7 +5096,8 @@ follow, where)) { count ++; - next = delete_insn (insn); + next = NEXT_INSN (insn); + delete_insn (insn); if (dump_file) { fprintf (dump_file, "\n----- Success! new insn:\n\n");