From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23475 invoked by alias); 6 Aug 2014 17:42:56 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 23417 invoked by uid 89); 6 Aug 2014 17:42:55 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: eggs.gnu.org Received: from eggs.gnu.org (HELO eggs.gnu.org) (208.118.235.92) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Wed, 06 Aug 2014 17:42:54 +0000 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XF4uh-0001q4-Qc for gcc-patches@gcc.gnu.org; Wed, 06 Aug 2014 13:22:17 -0400 Received: from mx1.redhat.com ([209.132.183.28]:18039) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XF4uh-0001pp-J8 for gcc-patches@gcc.gnu.org; Wed, 06 Aug 2014 13:22:11 -0400 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s76HLBrK029385 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Wed, 6 Aug 2014 13:21:11 -0400 Received: from c64.redhat.com (vpn-239-139.phx2.redhat.com [10.3.239.139]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s76HJ2rH030913; Wed, 6 Aug 2014 13:21:10 -0400 From: David Malcolm To: gcc-patches@gcc.gnu.org Cc: David Malcolm Subject: [PATCH 221/236] Add insn method to rtx_expr_list Date: Wed, 06 Aug 2014 17:42:00 -0000 Message-Id: <1407345815-14551-222-git-send-email-dmalcolm@redhat.com> In-Reply-To: <1407345815-14551-1-git-send-email-dmalcolm@redhat.com> References: <1407345815-14551-1-git-send-email-dmalcolm@redhat.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 X-IsSubscribed: yes X-SW-Source: 2014-08/txt/msg00648.txt.bz2 gcc/ * rtl.h (rtx_expr_list::insn): New method. --- gcc/rtl.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gcc/rtl.h b/gcc/rtl.h index d028be1..d5811c2 100644 --- a/gcc/rtl.h +++ b/gcc/rtl.h @@ -414,6 +414,10 @@ public: /* Get at the underlying rtx. */ rtx element () const; + + /* Get at the rtx, casting to rtx_insn *. */ + rtx_insn *insn () const; + }; template <> @@ -1287,6 +1291,11 @@ inline rtx rtx_expr_list::element () const return XEXP (this, 0); } +inline rtx_insn *rtx_expr_list::insn () const +{ + return as_a (XEXP (this, 0)); +} + /* Methods of rtx_insn_list. */ inline rtx_insn_list *rtx_insn_list::next () const -- 1.8.5.3