From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.31; helo=mga06.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 973A42202E480 for ; Wed, 14 Mar 2018 23:09:00 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Mar 2018 23:15:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,308,1517904000"; d="scan'208";a="182930559" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by orsmga004.jf.intel.com with ESMTP; 14 Mar 2018 23:15:23 -0700 Received: from FMSMSX109.amr.corp.intel.com (10.18.116.9) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 14 Mar 2018 23:15:23 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by fmsmsx109.amr.corp.intel.com (10.18.116.9) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 14 Mar 2018 23:15:22 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.226]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.108]) with mapi id 14.03.0319.002; Thu, 15 Mar 2018 14:15:21 +0800 From: "Gao, Liming" To: Pete Batard , "edk2-devel@lists.01.org" CC: "ard.biesheuvel@linaro.org" Thread-Topic: [PATCH 0/4] Add ARM64 support for VS2017 Thread-Index: AQHTrIu29dk9gfg5rESiLyKfZ75BZKPQ797A Date: Thu, 15 Mar 2018 06:15:20 +0000 Message-ID: <4A89E2EF3DFEDB4C8BFDE51014F606A14E1E7104@SHSMSX104.ccr.corp.intel.com> References: <20180223095003.6012-1-pete@akeo.ie> In-Reply-To: <20180223095003.6012-1-pete@akeo.ie> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH 0/4] Add ARM64 support for VS2017 X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Mar 2018 06:09:01 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Pete: For new added ASM file in BaseLib, could you use the same comment style f= or them? ASM use ; for the comment. Most of new files uses ; as the comment= , but switchstack is not. Besides, compared to Arm arch assembly file, I do= n't find CpuPause.asm. Is it required? Thanks Liming >-----Original Message----- >From: Pete Batard [mailto:pete@akeo.ie] >Sent: Friday, February 23, 2018 5:50 PM >To: edk2-devel@lists.01.org >Cc: Gao, Liming ; ard.biesheuvel@linaro.org >Subject: [PATCH 0/4] Add ARM64 support for VS2017 > >This is v2, which just removes a redundant #if defined(_MSC_EXTENSIONS) in >1/4. > >This series completes VS2017 support by enabling AARCH64 compilation. >* PATCH 1 targets the disabling of VS Level 4 warnings. The disabled > warnings for ARM64 are the same as the ones for IA32, X64 and ARM. >* PATCH 2 adds assembly source in MdePkg/Library/BaseLib for various low > level required functions. These new assembly files were converted from > their GCC version, with minor changes applied to make them palatable > to the MSFT assembler. >* PATCH 3 adds variable argument handlers for print output. This is > achieved without relying on any external toolchain headers. However > a call to the __va_start() compiler intrinsic function is now being > used for the VA_START macros, which we apply for ARM as well. >* PATCH 4 enables the selection of ARM64 in the conf templates. > One item of note is that the build options for ARM64 are the same as > for ARM, except for /BASE:0 which was removed to avoid error: > 'invalid base address 0x0; ARM64 image cannot have base address below >4GB' > >With these patches, VS2017 toolchain users should be able to compile >regular UEFI ARM64 applications using EDK2. > >Note however that ARM64 support requires the use of Visual Studio 2017 >Update 4 or later (a.k.a. v15.4), as native ARM64 compilation was not >included in any version of Visual Studio prior to that. > >Additional notes: > >We tested compiling and running the full UEFI Shell with this series, as >well as a small set of applications and drivers, and saw no issues. >Since we also modified the VA_START() macro for ARM, we also re-ran >similar tests for ARM, to confirm that there was no regression there. > >Finally, we did not test the generation of a complete QEMU ARM64 firmware >as it requires porting a handful of assembly sources, that don't exist >yet, and our focus is with the generation of working AARCH64 drivers or >applications. Hopefully, this can be tackled as VS2017/ARM64 sees more >usage... > >Regards, > >/Pete > >Pete Batard (4): > MdePkg: Disable some Level 4 warnings for VS2017/ARM64 > MdePkg/Library/BaseLib: Enable VS2017/ARM64 builds > MdePkg/Include: Add VA list support for VS2017/ARM64 > BaseTools/Conf: Add VS2017/ARM64 support > > BaseTools/Conf/build_rule.template | 2 +- > BaseTools/Conf/tools_def.template | 32 ++++++- > MdePkg/Include/AArch64/ProcessorBind.h | 53 +++++++++- > MdePkg/Include/Base.h | 7 +- > MdePkg/Library/BaseLib/AArch64/CpuBreakpoint.asm | 39 ++++++++ > MdePkg/Library/BaseLib/AArch64/DisableInterrupts.asm | 37 +++++++ > MdePkg/Library/BaseLib/AArch64/EnableInterrupts.asm | 37 +++++++ > MdePkg/Library/BaseLib/AArch64/GetInterruptsState.asm | 49 ++++++++++ > MdePkg/Library/BaseLib/AArch64/MemoryFence.asm | 38 ++++++++ > MdePkg/Library/BaseLib/AArch64/SetJumpLongJump.asm | 101 >++++++++++++++++++++ > MdePkg/Library/BaseLib/AArch64/SwitchStack.asm | 69 +++++++++++++ > MdePkg/Library/BaseLib/BaseLib.inf | 8 ++ > 12 files changed, 463 insertions(+), 9 deletions(-) > create mode 100644 MdePkg/Library/BaseLib/AArch64/CpuBreakpoint.asm > create mode 100644 >MdePkg/Library/BaseLib/AArch64/DisableInterrupts.asm > create mode 100644 MdePkg/Library/BaseLib/AArch64/EnableInterrupts.asm > create mode 100644 >MdePkg/Library/BaseLib/AArch64/GetInterruptsState.asm > create mode 100644 MdePkg/Library/BaseLib/AArch64/MemoryFence.asm > create mode 100644 >MdePkg/Library/BaseLib/AArch64/SetJumpLongJump.asm > create mode 100644 MdePkg/Library/BaseLib/AArch64/SwitchStack.asm > >-- >2.9.3.windows.2