From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by ml01.01.org (Postfix) with ESMTP id 170AB1A1DFC for ; Wed, 17 Aug 2016 21:54:13 -0700 (PDT) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP; 17 Aug 2016 21:54:12 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,537,1464678000"; d="scan'208";a="750256437" Received: from shwdeopenpsi014.ccr.corp.intel.com ([10.239.9.34]) by FMSMGA003.fm.intel.com with ESMTP; 17 Aug 2016 21:54:11 -0700 From: Hao Wu To: edk2-devel@lists.01.org, liming.gao@intel.com Cc: Hao Wu Date: Thu, 18 Aug 2016 12:53:54 +0800 Message-Id: <1471496040-11796-1-git-send-email-hao.a.wu@intel.com> X-Mailer: git-send-email 1.9.5.msysgit.0 Subject: [PATCH v2 0/6] Add APIs IsZeroBuffer and IsZeroGuid in BaseMemoryLib 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, 18 Aug 2016 04:54:13 -0000 Changes made comparing V1: 1. Use assembly to implement the IsZeroBuffer() API for the following library instances: BaseMemoryLibMmx BaseMemoryLibOptDxe BaseMemoryLibOptPei BaseMemoryLibRepStr BaseMemoryLibSse2 2. Utilize XMM regesters and related instructions in assembly codes for BaseMemoryLibSse2 library instance. 3. Modify patches for SecurityPkg to avoid breaking bisection between patches. Hao Wu (6): MdePkg BaseMemoryLib: Add implementation of API IsZeroGuid() SecurityPkg Tcg2: Rename internal API IsZeroBuffer to InternalIsZeroBuffer MdePkg BaseMemoryLib: Add C implementation of API IsZeroBuffer() MdePkg BaseMemoryLib: Add assembly implementation of API IsZeroBuffer() MdePkg BaseMemoryLibSse2: Add SSE2 implementation of API IsZeroBuffer() SecurityPkg Tcg2: Remove use of module internal API InternalIsZeroBuffer() MdePkg/Include/Library/BaseMemoryLib.h | 45 ++++++++++++- MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf | 3 +- MdePkg/Library/BaseMemoryLib/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLib/MemLibGeneric.c | 31 ++++++++- MdePkg/Library/BaseMemoryLib/MemLibGuid.c | 31 ++++++++- MdePkg/Library/BaseMemoryLib/MemLibInternals.h | 19 +++++- .../Library/BaseMemoryLibMmx/BaseMemoryLibMmx.inf | 5 +- .../BaseMemoryLibMmx/Ia32/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../Library/BaseMemoryLibMmx/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLibMmx/MemLibGuid.c | 31 ++++++++- MdePkg/Library/BaseMemoryLibMmx/MemLibInternals.h | 19 +++++- .../Library/BaseMemoryLibMmx/X64/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibOptDxe/BaseMemoryLibOptDxe.inf | 6 +- .../BaseMemoryLibOptDxe/Ia32/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibOptDxe/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLibOptDxe/MemLibGuid.c | 31 ++++++++- .../Library/BaseMemoryLibOptDxe/MemLibInternals.h | 19 +++++- .../BaseMemoryLibOptDxe/X64/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibOptPei/BaseMemoryLibOptPei.inf | 6 +- .../BaseMemoryLibOptPei/Ia32/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibOptPei/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLibOptPei/MemLibGuid.c | 31 ++++++++- .../Library/BaseMemoryLibOptPei/MemLibInternals.h | 19 +++++- .../BaseMemoryLibOptPei/X64/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibRepStr/BaseMemoryLibRepStr.inf | 5 +- .../BaseMemoryLibRepStr/Ia32/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibRepStr/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLibRepStr/MemLibGuid.c | 31 ++++++++- .../Library/BaseMemoryLibRepStr/MemLibInternals.h | 19 +++++- .../BaseMemoryLibRepStr/X64/IsZeroBuffer.nasm | 55 ++++++++++++++++ .../BaseMemoryLibSse2/BaseMemoryLibSse2.inf | 5 +- .../BaseMemoryLibSse2/Ia32/IsZeroBuffer.nasm | 74 +++++++++++++++++++++ .../BaseMemoryLibSse2/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/BaseMemoryLibSse2/MemLibGuid.c | 31 ++++++++- MdePkg/Library/BaseMemoryLibSse2/MemLibInternals.h | 19 +++++- .../BaseMemoryLibSse2/X64/IsZeroBuffer.nasm | 76 ++++++++++++++++++++++ MdePkg/Library/PeiMemoryLib/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/PeiMemoryLib/MemLibGeneric.c | 31 ++++++++- MdePkg/Library/PeiMemoryLib/MemLibGuid.c | 31 ++++++++- MdePkg/Library/PeiMemoryLib/MemLibInternals.h | 19 +++++- MdePkg/Library/PeiMemoryLib/PeiMemoryLib.inf | 3 +- MdePkg/Library/UefiMemoryLib/IsZeroBufferWrapper.c | 54 +++++++++++++++ MdePkg/Library/UefiMemoryLib/MemLibGeneric.c | 31 ++++++++- MdePkg/Library/UefiMemoryLib/MemLibGuid.c | 31 ++++++++- MdePkg/Library/UefiMemoryLib/MemLibInternals.h | 19 +++++- MdePkg/Library/UefiMemoryLib/UefiMemoryLib.inf | 3 +- SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigImpl.c | 27 -------- SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c | 27 -------- SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c | 27 -------- 49 files changed, 1568 insertions(+), 109 deletions(-) create mode 100644 MdePkg/Library/BaseMemoryLib/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibMmx/Ia32/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibMmx/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibMmx/X64/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibOptDxe/Ia32/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibOptDxe/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibOptDxe/X64/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibOptPei/Ia32/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibOptPei/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibOptPei/X64/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibRepStr/Ia32/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibRepStr/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibRepStr/X64/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibSse2/Ia32/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/BaseMemoryLibSse2/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/BaseMemoryLibSse2/X64/IsZeroBuffer.nasm create mode 100644 MdePkg/Library/PeiMemoryLib/IsZeroBufferWrapper.c create mode 100644 MdePkg/Library/UefiMemoryLib/IsZeroBufferWrapper.c -- 1.9.5.msysgit.0