From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9173 invoked by alias); 5 Aug 2017 10:07:28 -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 8848 invoked by uid 89); 5 Aug 2017 10:07:27 -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,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy= X-HELO: mail-wm0-f50.google.com Received: from mail-wm0-f50.google.com (HELO mail-wm0-f50.google.com) (74.125.82.50) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 05 Aug 2017 10:07:25 +0000 Received: by mail-wm0-f50.google.com with SMTP id k20so16601948wmg.0 for ; Sat, 05 Aug 2017 03:07:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:mail-followup-to:cc:subject:references :date:in-reply-to:message-id:user-agent:mime-version; bh=9eWk5i1fIbGhk/9kRCPqs4RCYiSW0P0/+hFTRC5m6y0=; b=QkitIDx9bAaMVOhvUVCNhBnC3Sui8u++W6iH2EcZmv2W6d+i/H8hu4Y1uVrZl8O6ss c6FqG9pvkMao+Mh9warVwaEIZPf8EGtpO8gxe7w1jgdjBqDY0qZDldBGJkdV509LX9fG vxvK6iqHltGaCbmyLlRk2lY2WbGTWdGMWHb94ue334/2dSOlshVhoHtN6CicKhAUAb71 ZvcSskz6QkR96P7gw+VoEaCPPMDfFawQBQIkN+mcnw6X8nugx5dZnf4mDm7lIWJNii3v h+SqbL6cEBogT1pzV0ZamuoGAvNkHUitRYD9t1fA9Gyf+p3EKJaCs5n/ooeQ1gjr5yL1 bmKA== X-Gm-Message-State: AHYfb5hMnyX7TE8/AI0ho8tiAXPMovK8Q1w2mddFyuttrHicXseTWsF5 KEGxfrLDPocl/aNxgFl86A== X-Received: by 10.28.238.218 with SMTP id j87mr2853349wmi.141.1501927643048; Sat, 05 Aug 2017 03:07:23 -0700 (PDT) Received: from localhost ([2.26.27.176]) by smtp.gmail.com with ESMTPSA id p76sm6359239wrc.15.2017.08.05.03.07.21 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 05 Aug 2017 03:07:22 -0700 (PDT) From: Richard Sandiford To: Segher Boessenkool Mail-Followup-To: Segher Boessenkool ,gcc-patches@gcc.gnu.org, richard.sandiford@linaro.org Cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH 0/5] RFC, WIP: RTL cost improvements References: Date: Sat, 05 Aug 2017 10:07:00 -0000 In-Reply-To: (Segher Boessenkool's message of "Mon, 31 Jul 2017 23:24:59 +0000") Message-ID: <87zibegwfb.fsf@linaro.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2017-08/txt/msg00445.txt.bz2 Segher Boessenkool writes: > This series creates pattern_cost and insn_cost functions that together > replace the existing insn_rtx_cost function. > > pattern_cost is like the old insn_rtx_cost function; insn_cost takes > an actual rtx_insn * as input, not just a pattern. > > Also a targetm.insn_cost is added, which targets can use to implement > a more exact cost more easily. > > The combine patch is pretty gross (but functional), it needs some > refactoring (to not call recog so often). The rs6000 patch is very > much a work in progress. > > How does this look? Is this the right direction? Seems good to me FWIW. Since this hook is entirely new, would it be worth standardising on attribute names for size and speed costs, a bit like "length" and "enabled"? I think otherwise the target hooks are going to end up with similar boilerplate. Thanks, Richard