From patchwork Wed Jun 1 10:17:21 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prathamesh Kulkarni X-Patchwork-Id: 69006 Delivered-To: patch@linaro.org Received: by 10.140.92.199 with SMTP id b65csp8290qge; Wed, 1 Jun 2016 03:17:46 -0700 (PDT) X-Received: by 10.36.93.139 with SMTP id w133mr4303575ita.6.1464776266882; Wed, 01 Jun 2016 03:17:46 -0700 (PDT) Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id os15si64216282pab.169.2016.06.01.03.17.46 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 01 Jun 2016 03:17:46 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-428747-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-428747-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-428747-patch=linaro.org@gcc.gnu.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:date:message-id:subject:from:to:content-type; q= dns; s=default; b=ETsIZOqp79Y8LeO2lmuYj0Lr+OaKOqPCMMWPyzFOhSNh+M BfIzdYqFFtn2V+hrILtvlZNdvmsR6CikxLX7W/Pwntz3PxtygsfiGGLEzn2hvmWI FZTFX4kzCPtY2epMUBH1Z9otuAoW3DmvnNE2AJjuEm6DQCwrfdZnejO2ItS3U= 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 :mime-version:date:message-id:subject:from:to:content-type; s= default; bh=8VruODKMSMeLNG23P0Ifag63dsc=; b=VpSe82kFeGduKYxN54mJ OkfWzbKecFN3IKo50m3GphfoVeMv54oZBE9tzgno/M7sktd7lSYCUNGOlit+qk6N DNTTHDWTmC7mXN0+GOOx9tQYs2HI2IPdgtrrIsJFlqwWUxKpo2T6nK7hiTYCyD9B MFSo5VRwkPcor2mO8z5WnVY= Received: (qmail 47307 invoked by alias); 1 Jun 2016 10:17:35 -0000 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 Received: (qmail 46625 invoked by uid 89); 1 Jun 2016 10:17:34 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy=opt_pass, sk:generat X-HELO: mail-io0-f181.google.com Received: from mail-io0-f181.google.com (HELO mail-io0-f181.google.com) (209.85.223.181) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 01 Jun 2016 10:17:23 +0000 Received: by mail-io0-f181.google.com with SMTP id p194so16600637iod.1 for ; Wed, 01 Jun 2016 03:17:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to; bh=FGsz3GejNk2kulRDiX9x+IzWDDTCooQd8ecvTP+M97s=; b=maC9WjOBqU5DOp2qKq2MKi8YCsZ/zp/NXJVvFAW5Ek2ZR7jsPoIf/NL+WPfXAxuhJQ o6lA9KzJoTU0r78vt1/SAAwFmIuYi7Ig+f/BeBv6la+B0xsD8f2ppk/3O0jogfReJadZ rLOMV3e8qscbkH+kfDXIObQDpcWw+WwRhLd4K6cx50n2I3VxJ+V2EImDlqIeD4U9AdTo FD99kaMCaILmOea/u7WRbNm3kQe/qlENDXoea+I5PhbVRwi2cYry4facoQwxj0EY2bee zISoszv1UXkdDxAT+N9BcYMQgecObmjJvVPsO5gOCenSqMhOIVSKZx0ECwIXnIFgPT5p auFQ== X-Gm-Message-State: ALyK8tLjaMLZ7z5B/2LpbQ/Yt46NGTgcAy3OCrD1Jh1Tvt6NC20xom/QF4QJ3I6cCtZjTvLWeYvKMxex1tlYKWQH MIME-Version: 1.0 X-Received: by 10.107.159.84 with SMTP id i81mr3964898ioe.29.1464776241337; Wed, 01 Jun 2016 03:17:21 -0700 (PDT) Received: by 10.36.236.5 with HTTP; Wed, 1 Jun 2016 03:17:21 -0700 (PDT) Date: Wed, 1 Jun 2016 15:47:21 +0530 Message-ID: Subject: move increase_alignment from simple to regular ipa pass From: Prathamesh Kulkarni To: Richard Biener , gcc Patches X-IsSubscribed: yes Hi Richard, This patch tries to move increase_alignment pass from small to regular ipa pass. Does the patch look correct ? Since we are only increasing alignment of varpool nodes, I am not sure if any ipa read/write hooks were necessary and passed NULL for them. Cross-tested on arm*-*-*, aarch64*-*-*, Bootstrap+test on aarch64-linux-gnu in progress. Thanks, Prathamesh diff --git a/gcc/passes.def b/gcc/passes.def index 993ed28..a841183 100644 --- a/gcc/passes.def +++ b/gcc/passes.def @@ -138,12 +138,12 @@ along with GCC; see the file COPYING3. If not see PUSH_INSERT_PASSES_WITHIN (pass_ipa_tree_profile) NEXT_PASS (pass_feedback_split_functions); POP_INSERT_PASSES () - NEXT_PASS (pass_ipa_increase_alignment); NEXT_PASS (pass_ipa_tm); NEXT_PASS (pass_ipa_lower_emutls); TERMINATE_PASS_LIST (all_small_ipa_passes) INSERT_PASSES_AFTER (all_regular_ipa_passes) + NEXT_PASS (pass_ipa_increase_alignment); NEXT_PASS (pass_ipa_whole_program_visibility); NEXT_PASS (pass_ipa_profile); NEXT_PASS (pass_ipa_icf); diff --git a/gcc/tree-pass.h b/gcc/tree-pass.h index 66e103a..2d2e8fc 100644 --- a/gcc/tree-pass.h +++ b/gcc/tree-pass.h @@ -482,7 +482,7 @@ extern simple_ipa_opt_pass *make_pass_local_optimization_passes (gcc::context *c extern ipa_opt_pass_d *make_pass_ipa_whole_program_visibility (gcc::context *ctxt); -extern simple_ipa_opt_pass *make_pass_ipa_increase_alignment (gcc::context +extern ipa_opt_pass_d *make_pass_ipa_increase_alignment (gcc::context *ctxt); extern ipa_opt_pass_d *make_pass_ipa_inline (gcc::context *ctxt); extern simple_ipa_opt_pass *make_pass_ipa_free_lang_data (gcc::context *ctxt); diff --git a/gcc/tree-vectorizer.c b/gcc/tree-vectorizer.c index 2669813..aeb5e0f 100644 --- a/gcc/tree-vectorizer.c +++ b/gcc/tree-vectorizer.c @@ -938,7 +938,7 @@ namespace { const pass_data pass_data_ipa_increase_alignment = { - SIMPLE_IPA_PASS, /* type */ + IPA_PASS, /* type */ "increase_alignment", /* name */ OPTGROUP_LOOP | OPTGROUP_VEC, /* optinfo_flags */ TV_IPA_OPT, /* tv_id */ @@ -949,11 +949,20 @@ const pass_data pass_data_ipa_increase_alignment = 0, /* todo_flags_finish */ }; -class pass_ipa_increase_alignment : public simple_ipa_opt_pass +class pass_ipa_increase_alignment : public ipa_opt_pass_d { public: pass_ipa_increase_alignment (gcc::context *ctxt) - : simple_ipa_opt_pass (pass_data_ipa_increase_alignment, ctxt) + : ipa_opt_pass_d (pass_data_ipa_increase_alignment, ctxt, + NULL, /* generate_summary */ + NULL, /* write summary */ + NULL, /* read summary */ + NULL, /* write optimization summary */ + NULL, /* read optimization summary */ + NULL, /* stmt fixup */ + 0, /* function_transform_todo_flags_start */ + NULL, /* transform function */ + NULL )/* variable transform */ {} /* opt_pass methods: */ @@ -968,7 +977,7 @@ public: } // anon namespace -simple_ipa_opt_pass * +ipa_opt_pass_d * make_pass_ipa_increase_alignment (gcc::context *ctxt) { return new pass_ipa_increase_alignment (ctxt);