From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-in7.apple.com (mail-out7.apple.com [17.151.62.29]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 295401A1DEE for ; Thu, 11 Aug 2016 16:04:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; d=apple.com; s=mailout2048s; c=relaxed/simple; q=dns/txt; i=@apple.com; t=1470956660; x=2334870260; h=From:Sender:Reply-To:Subject:Date:Message-id:To:Cc:MIME-version:Content-type: Content-transfer-encoding:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-reply-to:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=wCcWO07lmzIZFpz7rkZgY26JUrUW5YjIVwIEimkqL5k=; b=ktqOvawxDi2xW4IE2KK42qRtep/B0plaWHVHL+Gt1oxA/zUxFDOG7hz9K4P3UrDO 2p703Xyq6yBznSCRVCqEUyEd89SP4kfuoW1ilk0V8zdXJqDuo7lySQ/BfYzuMVdc lDpHNXL73vgjCUb8oSWKZg2H4zxBnosEbE/pzDuV5DwyAbsaM/WKmQljzxvzV4JG ooq+iHuRbgoAGyCbGMrZHgg4V2UTa0Jt1EqLNtMuKzd+K/f/C34JGG/dsMERRpBp A32miCZRks4iWkxbgtQljBk/JNwtKzcemNxoOigTUq5b6FWYnghWg56plJBjS9BA tXDrJ5UmBW+WJcUJQ3zVVQ==; Received: from relay2.apple.com (relay2.apple.com [17.128.113.67]) by mail-in7.apple.com (Apple Secure Mail Relay) with SMTP id 4A.39.17422.4740DA75; Thu, 11 Aug 2016 16:04:20 -0700 (PDT) X-AuditID: 11973e16-f793f6d00000440e-c5-57ad0474797b Received: from nwk-mmpp-sz12.apple.com (nwk-mmpp-sz12.apple.com [17.128.115.204]) by relay2.apple.com (Apple SCV relay) with SMTP id 79.1D.01452.4740DA75; Thu, 11 Aug 2016 16:04:20 -0700 (PDT) MIME-version: 1.0 Received: from [17.153.29.18] by nwk-mmpp-sz12.apple.com (Oracle Communications Messaging Server 8.0.1.1.0 64bit (built Jun 15 2016)) with ESMTPSA id <0OBR00IQ9PF2W790@nwk-mmpp-sz12.apple.com>; Thu, 11 Aug 2016 16:04:20 -0700 (PDT) Sender: afish@apple.com From: Andrew Fish In-reply-to: Date: Thu, 11 Aug 2016 16:04:20 -0700 Cc: Ard Biesheuvel , "edk2-devel@lists.01.org" , "liming.gao@intel.com" , "leif.lindholm@linaro.org" Message-id: <93CB1B8B-8788-49FD-8FBE-9DF24F838FA6@apple.com> References: <1470939632-32198-1-git-send-email-ard.biesheuvel@linaro.org> To: Eugene Cohen X-Mailer: Apple Mail (2.3112) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrPLMWRmVeSWpSXmKPExsUi2FDorFvCsjbc4Pt1PYv/H3YzWuw5dJTZ ovXzGyaLT7v3sFisuLeB3YHVY9e2nUwei/e8ZPK4c20Pm0f37H8sASxRXDYpqTmZZalF+nYJ XBm7JoUVTOKqWPX3AHsD4wKOLkZODgkBE4kZ5z6wQdhiEhfurQeyuTiEBPYySvw7cRjI4QAr enk1BSJ+iFHi6aw2ZpAGXgFBiR+T77GA1DALyEscPC8LEmYW0JL4/qiVBcQWEnjLKLHrdSmI LSwgLvHuzCZmCDtV4vKMr2A2m4CyxIr5H9hBbE6BeIkbk3aCxVkEVCWunuxgAdnLLHCeUeL2 8l5GiL02Ei+erGWFOGgbk8TPZ2/APhARUJB403GECeIbWYl9GxaAfSMhcJtN4sajaewTGEVm ITl8FsLhs5AcvoCReRWjUG5iZo5uZp65XmJBQU6qXnJ+7iZGUIxMtxPbwfhwldUhRgEORiUe Xo4Va8KFWBPLiitzDzFKc7AoifNu3gwUEkhPLEnNTk0tSC2KLyrNSS0+xMjEwSnVwDjxEsdc l16zhp+e7pXrVu08uE1LVi5F+sTMmT7vg44t7q2V916hbM+z7Pb8SwuqwuXZvK5t5fepD+0X 9DRN4YmyObE83D56rtSOklUHFoW+CspRvPzKqtKXN9t7/WpzzfkPPlfOyT67unfq4mjJfTxu x/Zu+VCxJNy7WPHxts8vy0J7b664tEaJpTgj0VCLuag4EQB5dttAcgIAAA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprFIsWRmVeSWpSXmKPExsUi2FB8RreEZW24wdYebYv/H3YzWuw5dJTZ ovXzGyaLT7v3sFisuLeB3YHVY9e2nUwei/e8ZPK4c20Pm0f37H8sASxRXDYpqTmZZalF+nYJ XBm7JoUVTOKqWPX3AHsD4wKOLkYODgkBE4mXV1O6GDmBTDGJC/fWs3UxcnEICRxilHg6q40Z JMErICjxY/I9FpB6ZgF5iYPnZUHCzAJaEt8ftbKA2EICbxkldr0uBbGFBcQl3p3ZxAxhp0pc nvEVzGYTUJZYMf8DO4jNKRAvcWPSTrA4i4CqxNWTHSwge5kFzjNK3F7eywix10bixZO1rBAH bWOS+PnsDRtIQkRAQeJNxxEmiKtlJfZtWMA2gVFwFpJbZyHcOgvJrQsYmVcxChSl5iRWGukl FhTkpOol5+duYgSHdKHzDsZjy6wOMQpwMCrx8HKsWBMuxJpYVlyZCwwMDmYlEd6t/4FCvCmJ lVWpRfnxRaU5qcWHGJOBPpjILCWanA+Mt7ySeEMTEwMTY2MzY2NzE3PShJXEee0XA60QSE8s Sc1OTS1ILYLZwsTBKdXAOP1654PyoDp3kZbtD02SUor1RFTnRGu/Dppd5HHyUY6w4YEfnC+k X/6UPKg4dwr/wXXBj99KXLh1L5xvo/flpwJ1i+7NUqw6LRYewd5a8v61w2N//cYZPlUvC/8t eDXtyu3bwpZVL9b9/3poq3KMelSjwcMai/ZmfbE7c92ZuCJ4Zk0zqjg+VYmlOCPRUIu5qDgR AJ1EX6OtAgAA Subject: Re: [PATCH 1/3] ArmPkg/CompilerIntrinsicsLib: replace memcpy and memset with C code X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Aug 2016 23:04:21 -0000 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII > On Aug 11, 2016, at 2:50 PM, Cohen, Eugene wrote: > >>> Why does memcpy performance matter? In addition to the overall >> memcpy stuff scattered around C code we have an instance that is >> particularly sensitive to memcpy performance. For DMA operations >> when invoking double-buffering or access to portions of a buffer that >> is common mapped (i.e. uncached on non-coherent DMA systems) the >> impact of a non-optimized memcpy is enormous compared to the >> optimized ones because the penalty is amplified by orders of >> magnitude due to uncached memory access latency. >>> >> >> That code would be using CopyMem(), no? This only serves the >> compiler >> generated calls, which are few since Tianocore does not allow >> initialized locals. > > I see and agree that should minimize the impact. I guess I'll ask the naive question. Could the BaseMemoryLib and CompilerIntrinsicsLib share the same stuff? > Eugene, I think if a CompilerIntrinsicsLib implementation consumes the BaseMemoryLib class (lists it in the INF) then I think it should just work. Thanks, Andrew Fish > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel