From patchwork Fri Aug 30 15:09:21 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Will Newton X-Patchwork-Id: 19641 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f197.google.com (mail-vc0-f197.google.com [209.85.220.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id AAB3E24694 for ; Fri, 30 Aug 2013 15:09:26 +0000 (UTC) Received: by mail-vc0-f197.google.com with SMTP id ha11sf2105570vcb.8 for ; Fri, 30 Aug 2013 08:09:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:message-id:date:from:user-agent :mime-version:to:cc:subject:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe:content-type :content-transfer-encoding; bh=4oK/bLAXsdRgw0PeAWtRHG/BR0V2RjPyoylZ8gmbGjM=; b=B9XjLffpF0dUOKBf6LRHMBOOvfinfKrIhRxKGKWrgA3CTBWfW9GS6FI/M6oIdVvqD+ 883BINqDVf+Blm0JIl4A8Omjt9V39dHsl1WfczxdC33Rsq73Wl88e63clJONl90y5sRq fXhUuNGSSUudI84pdPjXhOr3SNFUTlC+8D+mUya994eP4zUZ7MhdAXSkjbU/NCxDUWnL 3gV27JLnn83qa32rFZjnNc/R6+WQIKkynvxnZM66JRDpyWLj/dCzbixm4AQ+q/p+WTuh oXvLrN3WXYMN+cd+9mWh8wkc5uOGJDXh5PJp6hlbAXnvveId39QESNN6EZnSoHoA9o22 v9zg== X-Received: by 10.236.53.70 with SMTP id f46mr3307741yhc.17.1377875365972; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.24.172 with SMTP id v12ls156230qef.91.gmail; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) X-Received: by 10.52.164.102 with SMTP id yp6mr6918413vdb.14.1377875365841; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) Received: from mail-ve0-f181.google.com (mail-ve0-f181.google.com [209.85.128.181]) by mx.google.com with ESMTPS id aj7si9845733vec.135.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 30 Aug 2013 08:09:25 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.181; Received: by mail-ve0-f181.google.com with SMTP id jz10so1463132veb.12 for ; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) X-Gm-Message-State: ALoCoQmjpwG8R9GoAc1mASft7aLbMTfdXU9XHr4umGoCsv/mQOKYrrVGXUEqBMuaosE3k9iE1bWI X-Received: by 10.52.34.10 with SMTP id v10mr6004445vdi.28.1377875365720; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp94524vcz; Fri, 30 Aug 2013 08:09:25 -0700 (PDT) X-Received: by 10.15.83.2 with SMTP id b2mr13550851eez.28.1377875364696; Fri, 30 Aug 2013 08:09:24 -0700 (PDT) Received: from mail-ee0-f51.google.com (mail-ee0-f51.google.com [74.125.83.51]) by mx.google.com with ESMTPS id 41si27563918eee.257.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 30 Aug 2013 08:09:24 -0700 (PDT) Received-SPF: neutral (google.com: 74.125.83.51 is neither permitted nor denied by best guess record for domain of will.newton@linaro.org) client-ip=74.125.83.51; Received: by mail-ee0-f51.google.com with SMTP id c1so960880eek.24 for ; Fri, 30 Aug 2013 08:09:24 -0700 (PDT) X-Received: by 10.15.82.135 with SMTP id a7mr15967eez.107.1377875364127; Fri, 30 Aug 2013 08:09:24 -0700 (PDT) Received: from localhost.localdomain (cpc6-seac21-2-0-cust453.7-2.cable.virginmedia.com. [82.1.113.198]) by mx.google.com with ESMTPSA id a43sm55438005eep.9.1969.12.31.16.00.00 (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 30 Aug 2013 08:09:23 -0700 (PDT) Message-ID: <5220B5A1.40903@linaro.org> Date: Fri, 30 Aug 2013 16:09:21 +0100 From: Will Newton User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8 MIME-Version: 1.0 To: libc-ports@sourceware.org CC: patches@linaro.org Subject: [PATCH v2] ARM: Improve armv7 memcpy performance. X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: will.newton@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Only enter the aligned copy loop with buffers that can be 8-byte aligned. This improves performance slightly on Cortex-A9 and Cortex-A15 cores for large copies with buffers that are 4-byte aligned but not 8-byte aligned. ports/ChangeLog.arm: 2013-08-30 Will Newton * sysdeps/arm/armv7/multiarch/memcpy_impl.S: Tighten check on entry to aligned copy loop to improve performance. --- ports/sysdeps/arm/armv7/multiarch/memcpy_impl.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Changes in v2: - Improved description diff --git a/ports/sysdeps/arm/armv7/multiarch/memcpy_impl.S b/ports/sysdeps/arm/armv7/multiarch/memcpy_impl.S index 3decad6..6e84173 100644 --- a/ports/sysdeps/arm/armv7/multiarch/memcpy_impl.S +++ b/ports/sysdeps/arm/armv7/multiarch/memcpy_impl.S @@ -369,8 +369,8 @@ ENTRY(memcpy) cfi_adjust_cfa_offset (FRAME_SIZE) cfi_rel_offset (tmp2, 0) cfi_remember_state - and tmp2, src, #3 - and tmp1, dst, #3 + and tmp2, src, #7 + and tmp1, dst, #7 cmp tmp1, tmp2 bne .Lcpy_notaligned