From patchwork Tue Apr 10 09:55:35 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bin Cheng X-Patchwork-Id: 896567 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-476114-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="POcR5G1Z"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40L2c61YTXz9s1p for ; Tue, 10 Apr 2018 19:55:49 +1000 (AEST) 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:content-type:mime-version; q=dns; s=default; b=Y4q+LfkPvXJD/KqazzPogCc3qq00A/P6t7pqwAunpaZhN0Quxl 3xXxBGMBwNLZ4CxnzDmF7VExcRubHfkl9AcIYsZ7YHCZ5tmGt3JZFKCK8L7c5kwX yULdHDoJQoCvIHJ3W44UejJVz+BZQ0KyNJUswBmqO/iyD+3q08E+c+U04= 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:content-type:mime-version; s= default; bh=yxgUOSLkaS6h2MdwOsfFqJWjoHw=; b=POcR5G1ZIp3TNMx2feeK UNB9Kg460SmFsgAvDdroVwnDhYOKzmxZbQmdeySuI2/O3S8fNat/ixAjm7iaw0VM eyKXJyBxGAqtOvhSofhTS8bYkbtZJhtkziRZ3zarqwffiUqcPbthh5dJxzcjiBqg lRylLsaQMjXw62/z4QOjY5M= Received: (qmail 33060 invoked by alias); 10 Apr 2018 09:55:41 -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 32299 invoked by uid 89); 10 Apr 2018 09:55:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.0 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_PASS autolearn=ham version=3.3.2 spammy=pq, HAccept-Language:zh-CN, H*c:HHH X-HELO: EUR02-AM5-obe.outbound.protection.outlook.com Received: from mail-eopbgr00044.outbound.protection.outlook.com (HELO EUR02-AM5-obe.outbound.protection.outlook.com) (40.107.0.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 10 Apr 2018 09:55:39 +0000 Received: from DB6PR0802MB2504.eurprd08.prod.outlook.com (10.172.251.138) by DB6PR0802MB2344.eurprd08.prod.outlook.com (10.172.228.135) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.653.12; Tue, 10 Apr 2018 09:55:35 +0000 Received: from DB6PR0802MB2504.eurprd08.prod.outlook.com ([fe80::c1ce:2a66:3695:59b9]) by DB6PR0802MB2504.eurprd08.prod.outlook.com ([fe80::c1ce:2a66:3695:59b9%17]) with mapi id 15.20.0653.015; Tue, 10 Apr 2018 09:55:35 +0000 From: Bin Cheng To: "gcc-patches@gcc.gnu.org" CC: nd , "ro@cebitec.uni-bielefeld.de" Subject: [PATCH PR85190]Adjust pointer for aligned access Date: Tue, 10 Apr 2018 09:55:35 +0000 Message-ID: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Bin.Cheng@arm.com; x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DB6PR0802MB2344; 7:MmwwyKx22TkpeT7iN7sZzat60BCYO2sFhp5l10D/czoPjqFrOU8HdbuWmg7F15o5fzcp98TjJ+qZPIvYsr7+IL/IyAM7lmBbzBIXCZs7HHu/o5WIcwTrKYtFMCBDaq56LcMPEeNPNnDvzL+ioxQbvXf48wQilNNhQUbPjbv8/3IHjhe63s0++8o18AufVQzC22QHjyCK9iVJ2OhWO387g2ptcvdE1VcqySNF8zyzgTFtHUMCvHfzN5V3yhX+JGIZ x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-ht: Tenant X-MS-Office365-Filtering-Correlation-Id: efe2c714-1ae5-422f-a178-08d59ec9350d x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4604075)(3008032)(2017052603328)(7153060)(49563074)(7193020); SRVR:DB6PR0802MB2344; x-ms-traffictypediagnostic: DB6PR0802MB2344: nodisclaimer: True x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(180628864354917); x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(102415395)(6040522)(2401047)(8121501046)(5005006)(93006095)(93001095)(3002001)(10201501046)(3231221)(944501327)(52105095)(6055026)(6041310)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:DB6PR0802MB2344; BCL:0; PCL:0; RULEID:; SRVR:DB6PR0802MB2344; x-forefront-prvs: 0638FD5066 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(376002)(396003)(366004)(39860400002)(346002)(39380400002)(377424004)(189003)(53474002)(199004)(7736002)(97736004)(106356001)(14454004)(305945005)(74316002)(5660300001)(72206003)(105586002)(6916009)(86362001)(316002)(54906003)(6506007)(99286004)(59450400001)(7696005)(2906002)(3660700001)(102836004)(486006)(3280700002)(5250100002)(26005)(8936002)(33656002)(476003)(6116002)(81156014)(8676002)(99936001)(2501003)(3846002)(2351001)(4326008)(66066001)(25786009)(478600001)(6436002)(55016002)(9686003)(5640700003)(53936002)(2900100001)(68736007)(81166006); DIR:OUT; SFP:1101; SCL:1; SRVR:DB6PR0802MB2344; H:DB6PR0802MB2504.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: NCWvwLJ0TlO1raSRSk5Wvx1BX9shT+JhRmLfMkcn6umCfM1InAydPQoCsmsuY868e8kOHercTX8qaY82AIpWG8jMD0zgy0onhOCyB5/RlRR3qzoeW3PmcBrKUH2vBJHCF24oXSH94DdJ9TNjiaCvnL3cJG18EOfmh8RNjHZEC3ru0C3EoNOlWwI3O5qHZJOA6kS8oEkicaiZeu4OzvaKvL8ZD5tBZRgC0k9/lf/nPRjoHX2fmZtr8Res5Kr/L2JgGpuCM9wmL/MIZuWvXIIi80hHWjQcSzQpR+DXmzGg6w6GLehMp6j11fiu4CIReFGamRTSA7EPjSnntaMjek5x5WNEp2OkxLHtuO33TqadLx/ylGQwgk2VN6z5JzdgF8mxIOatuN6mL8bjAgYSEzePZpvonvY92TotYSGjbQenAjI= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-Network-Message-Id: efe2c714-1ae5-422f-a178-08d59ec9350d X-MS-Exchange-CrossTenant-originalarrivaltime: 10 Apr 2018 09:55:35.7712 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0802MB2344 X-IsSubscribed: yes Hi, Pointer q in gcc.dg/vect/pr81196.c is not aligned after vectorization, resulting test failure for some targets. This simple patch adjust it so that it's aligned. Is it OK? Hi Rainer, could you please help me double check that this solves the issue? Thanks, bin gcc/testsuite 2018-04-10 Bin Cheng PR testsuite/85190 * gcc.dg/vect/pr81196.c: Adjust pointer for aligned access. diff --git a/gcc/testsuite/gcc.dg/vect/pr81196.c b/gcc/testsuite/gcc.dg/vect/pr81196.c index 46d7a9e..15320ae 100644 --- a/gcc/testsuite/gcc.dg/vect/pr81196.c +++ b/gcc/testsuite/gcc.dg/vect/pr81196.c @@ -4,14 +4,14 @@ void f(short*p){ p=(short*)__builtin_assume_aligned(p,64); - short*q=p+256; + short*q=p+255; for(;p!=q;++p,--q){ short t=*p;*p=*q;*q=t; } } void b(short*p){ p=(short*)__builtin_assume_aligned(p,64); - short*q=p+256; + short*q=p+255; for(;p