Message ID | 1464886438-17892-7-git-send-email-james.greenhalgh@arm.com |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 10.140.106.246 with SMTP id e109csp217615qgf; Thu, 2 Jun 2016 09:56:47 -0700 (PDT) X-Received: by 10.66.118.106 with SMTP id kl10mr6912088pab.78.1464886607009; Thu, 02 Jun 2016 09:56:47 -0700 (PDT) Return-Path: <gcc-patches-return-428929-patch=linaro.org@gcc.gnu.org> Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id j3si26277048pad.104.2016.06.02.09.56.46 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 02 Jun 2016 09:56:47 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-428929-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org; spf=pass (google.com: domain of gcc-patches-return-428929-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-428929-patch=linaro.org@gcc.gnu.org DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type; q=dns; s=default; b=rbjiqneWCvgy8Dds s17hhGP7JGh52oi17H29b39dewHywgLMa3+F+oOxlI715XkV5IIgOxcJuhToDuj8 ylQzQUbRmSQiHRZiJRcmoRWHy6ZDQ3jGzJQM5xSjU5yp5q36rUVPTkcfekV42Ppx HUErSfODarGpKOBFHvrVqT+xDK0= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type; s=default; bh=7pi7VdqZf6QjxcmLDErRJx kkBw8=; b=eh+QzTcnuZBuLaTdUKa8ddB6Sb1MhXwyLHf6ehLNJC0PVaZ/3gh2Dj u2Jtyz/eft6WDKvOmjumjUeK2Wpmt8uCnUokTEsBRj5WTI0HmIrppixCDqr7SN77 PxGSG5DNm7LcSCYEInZjxVZmhOXXoKB32x+uHQ8oU09KS/dt6y3tQ= Received: (qmail 28248 invoked by alias); 2 Jun 2016 16:56:20 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: <gcc-patches.gcc.gnu.org> List-Unsubscribe: <mailto:gcc-patches-unsubscribe-patch=linaro.org@gcc.gnu.org> List-Archive: <http://gcc.gnu.org/ml/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-help@gcc.gnu.org> Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 28201 invoked by uid 89); 2 Jun 2016 16:56:17 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL, BAYES_00, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:1671, H*RU:15.1.511.8, Hx-spam-relays-external:15.1.511.8 X-HELO: eu-smtp-delivery-143.mimecast.com Received: from eu-smtp-delivery-143.mimecast.com (HELO eu-smtp-delivery-143.mimecast.com) (207.82.80.143) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 02 Jun 2016 16:56:07 +0000 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01lp0181.outbound.protection.outlook.com [213.199.154.181]) (Using TLS) by eu-smtp-1.mimecast.com with ESMTP id uk-mta-15-CHEDc4eZQoGfn3pmPbayjA-1; Thu, 02 Jun 2016 17:54:39 +0100 Received: from DB5PR08CA0078.eurprd08.prod.outlook.com (10.166.166.174) by AM2PR08MB0386.eurprd08.prod.outlook.com (10.161.235.24) with Microsoft SMTP Server (TLS) id 15.1.506.9; Thu, 2 Jun 2016 16:54:37 +0000 Received: from AM1FFO11OLC001.protection.gbl (2a01:111:f400:7e00::100) by DB5PR08CA0078.outlook.office365.com (2a01:111:e400:c576::46) with Microsoft SMTP Server (TLS) id 15.1.511.8 via Frontend Transport; Thu, 2 Jun 2016 16:54:37 +0000 Received: from nebula.arm.com (217.140.96.140) by AM1FFO11OLC001.mail.protection.outlook.com (10.174.65.76) with Microsoft SMTP Server (TLS) id 15.1.497.8 via Frontend Transport; Thu, 2 Jun 2016 16:54:37 +0000 Received: from e107456-lin.cambridge.arm.com (10.1.2.79) by mail.arm.com (10.1.106.66) with Microsoft SMTP Server id 14.3.294.0; Thu, 2 Jun 2016 17:54:35 +0100 From: James Greenhalgh <james.greenhalgh@arm.com> To: <gcc-patches@gcc.gnu.org> CC: <nd@arm.com>, <ramana.radhakrishnan@arm.com>, <bernds_cb1@t-online.de>, <law@redhat.com>, <ebotcazou@libertysurf.fr>, <steven@gcc.gnu.org> Subject: [RFC: Patch 6/6] Remove second cost model from noce_try_store_flag_mask Date: Thu, 2 Jun 2016 17:53:58 +0100 Message-ID: <1464886438-17892-7-git-send-email-james.greenhalgh@arm.com> In-Reply-To: <1464886438-17892-1-git-send-email-james.greenhalgh@arm.com> References: <5617A4DE.6020004@redhat.com> <1464886438-17892-1-git-send-email-james.greenhalgh@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:217.140.96.140; IPV:CAL; SCL:-1; CTRY:GB; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(2980300002)(438002)(189002)(199003)(377424004)(33646002)(2906002)(8676002)(106466001)(5000100001)(568964002)(11100500001)(19580405001)(50986999)(189998001)(76176999)(86362001)(77096005)(2476003)(586003)(512874002)(4326007)(87936001)(4610100001)(19580395003)(36756003)(2950100001)(84326002)(5003600100002)(5890100001)(229853001)(8936002)(6806005)(92566002)(2351001)(104016004)(5008740100001)(110136002)(50226002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM2PR08MB0386; H:nebula.arm.com; FPR:; SPF:Pass; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; AM1FFO11OLC001; 1:CB8DpBgT27snCokXRpx+5pGKT2JXydjkVPE0Tq+/1lZK0u5QCRM/78WQaA7zaflW9O737GARVmR/ksGd5Bb9tKXDF71X9giz8aNC1FJ7oIfYwz/uX2K+Vfg5THibKhrntITuBvX5IwLY6ML6CVq3/7U8a5OLYRIH5eMFfu2la5/lZAj/NtldPxVMXGDCFHzx8RHRPL76wsq6Rvg9hTqiwLfZo8T6pPedeM/Kc/ETIuQGO4aEk7Y9AKN1m5td3cECnl2hnadG/O95oSfTD/P442hmjdnhWYTXitwPZU3vjFUqRKgYA86/lnxs6vEefGZxWizswmRy8GJE7UGP5hs2je6ouvGdu6GObDzY6cQWpMf3FjQXxF6CBLzByjHSeINn0ZSvyQemsh51Da360WiRuj5NqV+HzMfX4qWj6SWn1yh7wNW4zjRtFEG2UU5GgyEuaCrqsvUdkEEqldHwvZIpTvVpIPdx2DmizdcwA9SeLvioeB3ln3PFmAuuB+cyLJvXIl55b2eL7vBzaFewVMVygj1I7mZSo7CnfRul9PN7A+2P34MmeDGVWhhXusc4koil X-MS-Office365-Filtering-Correlation-Id: a24e7828-b6ea-4b5d-4691-08d38b069529 X-Microsoft-Exchange-Diagnostics: 1; AM2PR08MB0386; 2:QG2rZYGrW9OTRKscV9fOK7xITeQxvAgGd5tY4yQHX0WFtmKJqoePbWvhJhQhYVMuwVc4fdyUlREJm/2Jv3RU16aP1iRtMCVKxmwtXedpEbYziPH4hjSVSWLBTMacuWwPcKHro+FNH9AAwxyAbfpkgbwPlTcfca7OuuzxtY/uOxkrce7QlZWfKXGdCara1qgB; 3:GerN+f2xeOVhC/fA0cqwNIgqoYmqQ7YILpgREjys2uaYb3Lv3VAN3VgGi/EvA75N1slX4J5wEzHjoCYP0cuWxGW69/H2WDccpGrjVcjQydBs8WDLF+9xtcQbDY7+UGELV9kycUbaXpv0N9FJMksxtQmGfUNNBaBmkeZLNI1agXeyZIqdxu4FiibDNuG1K0R8UyfUd2XxCtnTEmarbtbOYCF4ku/reGB37CwvkxMMdA6eol8IE9TvjXUoTLutKmLcCZcHG0oZ+I8iR5+nIY2z3Q== X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(8251501002); SRVR:AM2PR08MB0386; X-Microsoft-Exchange-Diagnostics: 1; AM2PR08MB0386; 25:oyugfJnmMRZq14hWzecSdFMa/zIkqiWPIKga2wwD3V5XFGI2KaxvfoVFwKcpMX392NbzePoc7goCVtJxAJYcNKaaVJ0kTz5Ptfcgbi7I5f4qnll8MKFjauwEvNFuXPXDaIEq6dRrGjm+sqv1x/DkrOwhS30tXoROqkSBnN+PUqoOGAJOnFivjXAThaA9gXKn2yS7JW5nQIIwSLLIhrhTGj9HrLLw9Jl7Hp4k+ZyZ4fQ7QWCV4fal1UVI/kTVKplZyCvBX+cCOo82BWVOPI0WA1n8k4vs0Yusy2Ebz02BvdW9puRXjArBgcbjGcaQtOMCpjLRmTwpWvmf5nYFpwsQAjgU3DzNHx52Sw97usCrInaYq2uTDt8AlWFiM02lF+98LpW8smrDeJHXZCAS5ZrK7tpkBpBG4PT9KNpfvtdVJRHAFV230g6UG87Kqd/GSJkA6R1GwW62UyoWD6yeBJ3SsgWOeJWHZskiADilPXb0HJiq6Katf/4EF00jxK+YSYca; 20:eKTIdeZrmzJeEKzyVeUwFg8eTzKqOs3gPf3J2MvVQA+WfaXET0G3RUe2+ClwoHYM3V4Publ434DmzOGN1wtuzETZcAa4AiFw460p0JaDwMsX/mQsnhUyxXwuLjqggGJQS8lrseSXyiAjMQyugL6F0qrY320pOOgZytQL0cDasayidqYLJsOrepM57X9IhAft1UtaSWMjcI7Ojyn2oHDI3g1Ugc4toFP7Ds82U11LFCkpmUkbMerbQ18yBQtngwyM NoDisclaimer: True X-Microsoft-Antispam-PRVS: <AM2PR08MB038607D024693CCC796C771C84580@AM2PR08MB0386.eurprd08.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(180628864354917); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(102415321)(601004)(2401047)(13024025)(13023025)(13020025)(13013025)(8121501046)(5005006)(3002001)(10201501046)(6055026); SRVR:AM2PR08MB0386; BCL:0; PCL:0; RULEID:; SRVR:AM2PR08MB0386; X-Microsoft-Exchange-Diagnostics: 1; AM2PR08MB0386; 4:IgWBkKW72iGKxJOpAlhxfnCqvUpN6zW6BSEhgzAO6z/adOtVpxbrJJP9mQ0O/cOwuNEk2kKjay4xDRma8a6nEkS6TZDtG36fijWigJ5NWklEPeqdR+Cgx75XFgcz83tQcO55wa+pLUG5k3w4NyhT7HsVxLo9F0z0ZER/FUdh/o8i+26Z72qm3b9PjHb0EhpCcnqDPLPoUZon5upOvQibnoNpHICXrmebhQ3zJt7zzofSDf/Iarx9mfBk1GCGl1naW1/1GgyRjYAzygZcQwXEpPg5DKQMfhDgtNdWmqvHuDXmHyMjRF7GLouzXJeERk9FoaTuB2UDyZnsMd4QtHeIidzbSClUiwe/0U1IWgt60+vz/T28SpONT38a/DpeYdNb8mgQpzaEtjggUNKDA8loInAcNPzOdN5ecfuQB7xpsW5q66wF4LC43GtPn5ew+LMiAYanjAKKHnhl+HFk0l8BsJQSix4Ut8wwWrH5EG3wJtAN/vM1rBgEzy0rSoObxCxl1QTU9OPRzfwRURFVz4DAsA== X-Forefront-PRVS: 0961DF5286 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM2PR08MB0386; 23:ZvfhbEQBxkvTnf9PHrgNdqJOk3O2a8vcpEjnoOFZZ?= =?us-ascii?Q?DIUvEgFfRer68QL5F7zHaajlPJjus60liO6sQNMPpxkvsQlv7csbxBYxBpQ6?= =?us-ascii?Q?gIkh9V+HBp1o9d4HlWYVQbc14aT9FdpcmTaHvWtyw2JN4bFSK/dZOKf2qgwV?= =?us-ascii?Q?vqlJvn7R9hqSGvDX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?us-ascii?Q?H/gUHo=3D?= X-Microsoft-Exchange-Diagnostics: 1; AM2PR08MB0386; 5:xunYm4cQa+QsMbEWyn5vHBVmYLRPR2KPK40aoq7Wdt6TaCb13M9YNM1ZgFpgvFyZMrts1aYVaWeoD0aijWQoVEqQpRk9vRfZKqPgpPvcOkCSKnwlLEwHAEljVgCDo8ZgjSS5Q9Vbwa6BIpN/TOVKSQ==; 24:xZDO3ch5mbDGmwwCAjn6mqm+qs6PUH6+vnnaMsW+Kgtw+2EPsh8ehsCQWaBYglmAkfIDX7xEUwqYGA8So9qbTsl6/2YlvWoNsnj9CtxlowI=; 7:YEG8yXnzV58j0Y+RV5TsPFFEZqG/fJzlAOdTvYxznvayLlVZDarXnxoI21sd3upLQkTZm4joDxD7Q4ug3VUM1UdgwvRgx0vGP1jrph2RvXWkBKFmx+who0yrs6a56oTPJEAZ1zmxzzMza23ip4k6a1OIHrcusHqBhwpgTkoeMrUcKQj1IaD807JycFBgQVPn; 20:yurO31QmKTAnUA9XCVnRWvPrwy21PC5rEb4HW/22dm0oIw04e+FvRJs8sq7UJnGqPS1yCPLFbjbEVZYNoGUMaHxAeSFI0afrWNtr2qxxrJsWthfSvZnBTRtGlN9gjwbNvClNW1/O9sLCeNyI15vBvN4P00yWR8HGvaWwReI9g5k= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jun 2016 16:54:37.5606 (UTC) X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[217.140.96.140]; Helo=[nebula.arm.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM2PR08MB0386 X-MC-Unique: CHEDc4eZQoGfn3pmPbayjA-1 Content-Type: multipart/mixed; boundary="------------2.6.4.2.gae996d8" X-IsSubscribed: yes |
diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c index f71889e..6e9997e 100644 --- a/gcc/ifcvt.c +++ b/gcc/ifcvt.c @@ -1670,8 +1670,8 @@ noce_try_store_flag_mask (struct noce_if_info *if_info) reversep = 0; - /* Two insns, AND, NEG. */ - if ((noce_estimate_conversion_profitable_p (if_info, 2) + /* One insn, AND. */ + if ((noce_estimate_conversion_profitable_p (if_info, 1) || STORE_FLAG_VALUE == -1) && ((if_info->a == const0_rtx && rtx_equal_p (if_info->b, if_info->x)) @@ -1693,9 +1693,6 @@ noce_try_store_flag_mask (struct noce_if_info *if_info) if (target) { - int old_cost, new_cost, insn_cost; - int speed_p; - if (target != if_info->x) noce_emit_move_insn (if_info->x, target); @@ -1703,15 +1700,6 @@ noce_try_store_flag_mask (struct noce_if_info *if_info) if (!seq) return FALSE; - speed_p = optimize_bb_for_speed_p (BLOCK_FOR_INSN (if_info->insn_a)); - insn_cost = insn_rtx_cost (PATTERN (if_info->insn_a), speed_p); - /* TODO: Revisit this cost model. */ - old_cost = if_info->rtx_edge_cost + insn_cost; - new_cost = seq_cost (seq, speed_p); - - if (new_cost > old_cost) - return FALSE; - emit_insn_before_setloc (seq, if_info->jump, INSN_LOCATION (if_info->insn_a)); return TRUE;