public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
       [not found] <175748C3EBBDE1AF.26280@groups.io>
@ 2023-04-21  0:25 ` Nickle Wang
  2023-04-21  2:51   ` 回复: " gaoliming
  0 siblings, 1 reply; 9+ messages in thread
From: Nickle Wang @ 2023-04-21  0:25 UTC (permalink / raw)
  To: devel@edk2.groups.io, Nickle Wang, Jian J Wang, Liming Gao
  Cc: Michael D Kinney, Nick Ramirez

[-- Attachment #1: Type: text/plain, Size: 4118 bytes --]

Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io

> Cc: Jian J Wang <jian.j.wang@intel.com>; Liming Gao

> <gaoliming@byosoft.com.cn>; Michael D Kinney <michael.d.kinney@intel.com>;

> Nick Ramirez <nramirez@nvidia.com>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

> 

>



[-- Attachment #2: Type: text/html, Size: 10545 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-21  0:25 ` [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error Nickle Wang
@ 2023-04-21  2:51   ` gaoliming
  2023-04-21  3:12     ` Nickle Wang
  0 siblings, 1 reply; 9+ messages in thread
From: gaoliming @ 2023-04-21  2:51 UTC (permalink / raw)
  To: devel, nicklew, 'Jian J Wang'
  Cc: 'Michael D Kinney', 'Nick Ramirez'

[-- Attachment #1: Type: text/plain, Size: 5041 bytes --]

Nickle:

 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

 

Thanks

Liming

发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io; Nickle Wang <nicklew@nvidia.com>; Jian J Wang <jian.j.wang@intel.com>; Liming Gao <gaoliming@byosoft.com.cn>
抄送: Michael D Kinney <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi  <mailto:jian.j.wang@intel.com> @Jian J Wang,  <mailto:gaoliming@byosoft.com.cn> @Liming Gao,

 

Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285  

 

Thanks,

Nickle

 

> -----Original Message-----

> From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> 

> Cc: Jian J Wang <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >; Liming Gao

> <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >; Michael D Kinney <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >;

> Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

> 

> External email: Use caution opening links or attachments

> 

> 

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

> 

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

> 

> Signed-off-by: Nickle Wang < <mailto:nicklew@nvidia.com> nicklew@nvidia.com>

> Cc: Jian J Wang < <mailto:jian.j.wang@intel.com> jian.j.wang@intel.com>

> Cc: Liming Gao < <mailto:gaoliming@byosoft.com.cn> gaoliming@byosoft.com.cn>

> Cc: Michael D Kinney < <mailto:michael.d.kinney@intel.com> michael.d.kinney@intel.com>

> Cc: Nick Ramirez < <mailto:nramirez@nvidia.com> nramirez@nvidia.com>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

> 

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

> 

> 

> 

> 

> 

 




[-- Attachment #2: Type: text/html, Size: 16829 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-21  2:51   ` 回复: " gaoliming
@ 2023-04-21  3:12     ` Nickle Wang
  2023-04-21  6:13       ` 回复: " gaoliming
  0 siblings, 1 reply; 9+ messages in thread
From: Nickle Wang @ 2023-04-21  3:12 UTC (permalink / raw)
  To: devel@edk2.groups.io, gaoliming@byosoft.com.cn,
	'Jian J Wang'
  Cc: 'Michael D Kinney', Nick Ramirez

[-- Attachment #1: Type: text/plain, Size: 6015 bytes --]

Hi Liming,

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

Thanks,
Nickle

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io; Nickle Wang <nicklew@nvidia.com>; 'Jian J Wang' <jian.j.wang@intel.com>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
抄送: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error


Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao

> <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>;

> Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

>

>




[-- Attachment #2: Type: text/html, Size: 25823 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-21  3:12     ` Nickle Wang
@ 2023-04-21  6:13       ` gaoliming
  2023-04-21  6:22         ` Nickle Wang
       [not found]         ` <1757DEF7FD26598A.29498@groups.io>
  0 siblings, 2 replies; 9+ messages in thread
From: gaoliming @ 2023-04-21  6:13 UTC (permalink / raw)
  To: devel, nicklew, 'Jian J Wang'
  Cc: 'Michael D Kinney', 'Nick Ramirez'

[-- Attachment #1: Type: text/plain, Size: 7048 bytes --]

Nickle:

 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

 

Thanks

Liming

发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io; gaoliming@byosoft.com.cn; 'Jian J Wang' <jian.j.wang@intel.com>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi Liming,

 

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

 

Thanks,

Nickle

 

From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; Nickle Wang <nicklew@nvidia.com <mailto:nicklew@nvidia.com> >; 'Jian J Wang' <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 


External email: Use caution opening links or attachments 

 

Nickle:

 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

 

Thanks

Liming

发件人: devel@edk2.groups.io <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; Nickle Wang <nicklew@nvidia.com <mailto:nicklew@nvidia.com> >; Jian J Wang <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >; Liming Gao <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >
抄送: Michael D Kinney <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi  <mailto:jian.j.wang@intel.com> @Jian J Wang,  <mailto:gaoliming@byosoft.com.cn> @Liming Gao,

 

Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285  

 

Thanks,

Nickle

 

> -----Original Message-----

> From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> 

> Cc: Jian J Wang <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >; Liming Gao

> <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >; Michael D Kinney <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >;

> Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

> 

> External email: Use caution opening links or attachments

> 

> 

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

> 

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

> 

> Signed-off-by: Nickle Wang < <mailto:nicklew@nvidia.com> nicklew@nvidia.com>

> Cc: Jian J Wang < <mailto:jian.j.wang@intel.com> jian.j.wang@intel.com>

> Cc: Liming Gao < <mailto:gaoliming@byosoft.com.cn> gaoliming@byosoft.com.cn>

> Cc: Michael D Kinney < <mailto:michael.d.kinney@intel.com> michael.d.kinney@intel.com>

> Cc: Nick Ramirez < <mailto:nramirez@nvidia.com> nramirez@nvidia.com>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

> 

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

> 

> 

> 

> 

> 

 




[-- Attachment #2: Type: text/html, Size: 24043 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-21  6:13       ` 回复: " gaoliming
@ 2023-04-21  6:22         ` Nickle Wang
       [not found]         ` <1757DEF7FD26598A.29498@groups.io>
  1 sibling, 0 replies; 9+ messages in thread
From: Nickle Wang @ 2023-04-21  6:22 UTC (permalink / raw)
  To: devel@edk2.groups.io, gaoliming@byosoft.com.cn,
	'Jian J Wang'
  Cc: 'Michael D Kinney', Nick Ramirez

[-- Attachment #1: Type: text/plain, Size: 7695 bytes --]

Hi Liming,

Yes, let me try it and feedback to you.

Thanks,
Nickle

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 2:13 PM
To: devel@edk2.groups.io; Nickle Wang <nicklew@nvidia.com>; 'Jian J Wang' <jian.j.wang@intel.com>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
抄送: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error


Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao

> <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>;

> Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

>

>




[-- Attachment #2: Type: text/html, Size: 33655 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
       [not found]         ` <1757DEF7FD26598A.29498@groups.io>
@ 2023-04-21  9:11           ` Nickle Wang
  2023-04-24  5:06             ` 回复: " gaoliming
  0 siblings, 1 reply; 9+ messages in thread
From: Nickle Wang @ 2023-04-21  9:11 UTC (permalink / raw)
  To: devel@edk2.groups.io, Nickle Wang, gaoliming@byosoft.com.cn,
	'Jian J Wang'
  Cc: 'Michael D Kinney', Nick Ramirez

[-- Attachment #1: Type: text/plain, Size: 8703 bytes --]

Hi Liming,

After I change memset() implementation in RegularExpressionDxe, I only need to cover memcpy() with MDE_CPU_IA32. This is my change for your reference: https://github.com/tianocore/edk2/pull/4285/commits/15216e83198d7d422ae767833303d1979c8c0839

Please let me know if this makes sense to you or not.

Thanks,
Nickle

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Nickle Wang via groups.io
Sent: Friday, April 21, 2023 2:22 PM
To: devel@edk2.groups.io; gaoliming@byosoft.com.cn; 'Jian J Wang' <jian.j.wang@intel.com>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
Subject: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Hi Liming,

Yes, let me try it and feedback to you.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 2:13 PM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
抄送: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error


Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao

> <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>;

> Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

>

>




[-- Attachment #2: Type: text/html, Size: 37214 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-21  9:11           ` Nickle Wang
@ 2023-04-24  5:06             ` gaoliming
  2023-04-24  5:40               ` Nickle Wang
       [not found]               ` <1758C871228D4D0E.10313@groups.io>
  0 siblings, 2 replies; 9+ messages in thread
From: gaoliming @ 2023-04-24  5:06 UTC (permalink / raw)
  To: 'Nickle Wang', devel, 'Jian J Wang'
  Cc: 'Michael D Kinney', 'Nick Ramirez'

[-- Attachment #1: Type: text/plain, Size: 9735 bytes --]

Nickle:

 You only need to update memset() implementation in RegularExpressionDxe. You don’t need to add MDE_CPU_XXX macro.

 

Thanks

Liming

发件人: Nickle Wang <nicklew@nvidia.com> 
发送时间: 2023年4月21日 17:11
收件人: devel@edk2.groups.io; Nickle Wang <nicklew@nvidia.com>; gaoliming@byosoft.com.cn; 'Jian J Wang' <jian.j.wang@intel.com>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
主题: RE: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi Liming,

 

After I change memset() implementation in RegularExpressionDxe, I only need to cover memcpy() with MDE_CPU_IA32. This is my change for your reference: https://github.com/tianocore/edk2/pull/4285/commits/15216e83198d7d422ae767833303d1979c8c0839

 

Please let me know if this makes sense to you or not.

 

Thanks,

Nickle

 

From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of Nickle Wang via groups.io
Sent: Friday, April 21, 2023 2:22 PM
To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> ; 'Jian J Wang' <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
Subject: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 


External email: Use caution opening links or attachments 

 

Hi Liming,

 

Yes, let me try it and feedback to you.

 

Thanks,

Nickle

 

From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 2:13 PM
To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; Nickle Wang <nicklew@nvidia.com <mailto:nicklew@nvidia.com> >; 'Jian J Wang' <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 


External email: Use caution opening links or attachments 

 

Nickle:

 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

 

Thanks

Liming

发件人: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> ; 'Jian J Wang' <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi Liming,

 

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

 

Thanks,

Nickle

 

From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; Nickle Wang <nicklew@nvidia.com <mailto:nicklew@nvidia.com> >; 'Jian J Wang' <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 


External email: Use caution opening links or attachments 

 

Nickle:

 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

 

Thanks

Liming

发件人: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; Nickle Wang <nicklew@nvidia.com <mailto:nicklew@nvidia.com> >; Jian J Wang <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >; Liming Gao <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >
抄送: Michael D Kinney <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >; Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

 

Hi  <mailto:jian.j.wang@intel.com> @Jian J Wang,  <mailto:gaoliming@byosoft.com.cn> @Liming Gao,

 

Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285  

 

Thanks,

Nickle

 

> -----Original Message-----

> From: devel@edk2.groups.io <mailto:devel@edk2.groups.io>  <devel@edk2.groups.io <mailto:devel@edk2.groups.io> > On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> 

> Cc: Jian J Wang <jian.j.wang@intel.com <mailto:jian.j.wang@intel.com> >; Liming Gao

> <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >; Michael D Kinney <michael.d.kinney@intel.com <mailto:michael.d.kinney@intel.com> >;

> Nick Ramirez <nramirez@nvidia.com <mailto:nramirez@nvidia.com> >

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

> 

> External email: Use caution opening links or attachments

> 

> 

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

> 

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

> 

> Signed-off-by: Nickle Wang < <mailto:nicklew@nvidia.com> nicklew@nvidia.com>

> Cc: Jian J Wang < <mailto:jian.j.wang@intel.com> jian.j.wang@intel.com>

> Cc: Liming Gao < <mailto:gaoliming@byosoft.com.cn> gaoliming@byosoft.com.cn>

> Cc: Michael D Kinney < <mailto:michael.d.kinney@intel.com> michael.d.kinney@intel.com>

> Cc: Nick Ramirez < <mailto:nramirez@nvidia.com> nramirez@nvidia.com>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

> 

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

> 

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> 

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

> 

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

> 

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

> 

> 

> 

> 

> 

 




[-- Attachment #2: Type: text/html, Size: 33911 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
  2023-04-24  5:06             ` 回复: " gaoliming
@ 2023-04-24  5:40               ` Nickle Wang
       [not found]               ` <1758C871228D4D0E.10313@groups.io>
  1 sibling, 0 replies; 9+ messages in thread
From: Nickle Wang @ 2023-04-24  5:40 UTC (permalink / raw)
  To: devel@edk2.groups.io, gaoliming@byosoft.com.cn,
	'Jian J Wang'
  Cc: 'Michael D Kinney', Nick Ramirez


[-- Attachment #1.1: Type: text/plain, Size: 10605 bytes --]

Hi Liming,

There are two errors mentioned for both memset() and memcpy() in my first patch. After I updated memset() implementation in RegularExpressionDxe, the first error is gone. But I still see below error for memcpy()

multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from
plugin):(.text+0x0): first defined here

For fixing above error, I still need MDE_CPU_IA32.  Attach my latest patch for your reference.

Thanks,
Nickle

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of gaoliming via groups.io
Sent: Monday, April 24, 2023 1:07 PM
To: Nickle Wang <nicklew@nvidia.com>; devel@edk2.groups.io; 'Jian J Wang' <jian.j.wang@intel.com>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 You only need to update memset() implementation in RegularExpressionDxe. You don’t need to add MDE_CPU_XXX macro.

Thanks
Liming
发件人: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>
发送时间: 2023年4月21日 17:11
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: RE: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

After I change memset() implementation in RegularExpressionDxe, I only need to cover memcpy() with MDE_CPU_IA32. This is my change for your reference: https://github.com/tianocore/edk2/pull/4285/commits/15216e83198d7d422ae767833303d1979c8c0839

Please let me know if this makes sense to you or not.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle Wang via groups.io
Sent: Friday, April 21, 2023 2:22 PM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Hi Liming,

Yes, let me try it and feedback to you.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 2:13 PM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
抄送: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error


Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao

> <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>;

> Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

>

>




[-- Attachment #1.2: Type: text/html, Size: 44499 bytes --]

[-- Attachment #2: 0001-MdeModulePkg-RegularExpressionDxe-Fix-Arm-build-erro.patch --]
[-- Type: application/octet-stream, Size: 3454 bytes --]

From 4df84b083141a6aeea282c7a65e51ad63fe3b447 Mon Sep 17 00:00:00 2001
From: Nickle Wang <nicklew@nvidia.com>
Date: Fri, 21 Apr 2023 14:48:30 +0800
Subject: [PATCH v2 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Arm CI build error:
- ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of
‘memset’ does not match original declaration [-Wlto-type-mismatch]
MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:
note: type ‘char’ should match type ‘int’
- multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from
plugin):(.text+0x0): first defined here

Fix:
- Update memset() implementation to match memset() definition in
ArmPkg/Library/CompilerIntrinsicsLib.
- memcpy() is supported by ArmPkg/Library/CompilerIntrinsicsLib. Exclude
it in OnigurumaUefiPort.c.

Signed-off-by: Nickle Wang <nicklew@nvidia.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Nick Ramirez <nramirez@nvidia.com>
---
 .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h    | 7 +++++--
 .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c    | 8 ++++++--
 2 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h
index 248109b0c96e..8931f8ec50a9 100644
--- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h
+++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h
@@ -4,7 +4,7 @@
 
   (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>
   Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>
-  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
+  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
 
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
@@ -107,6 +107,7 @@ realloc (
   size_t  size
   );
 
+#if !defined (MDE_CPU_ARM)
 void *
 memcpy (
   void          *dest,
@@ -114,10 +115,12 @@ memcpy (
   unsigned int  count
   );
 
+#endif
+
 void *
 memset (
   void          *dest,
-  char          ch,
+  int           ch,
   unsigned int  count
   );
 
diff --git a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c
index 6661c67f976e..0d8984dde091 100644
--- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c
+++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c
@@ -4,6 +4,7 @@
 
   (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>
   Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>
+  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
 
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
@@ -109,6 +110,7 @@ realloc (
   return NULL;
 }
 
+#if !defined (MDE_CPU_ARM)
 void *
 memcpy (
   void          *dest,
@@ -119,14 +121,16 @@ memcpy (
   return CopyMem (dest, src, (UINTN)count);
 }
 
+#endif
+
 void *
 memset (
   void          *dest,
-  char          ch,
+  int           ch,
   unsigned int  count
   )
 {
-  return SetMem (dest, count, ch);
+  return SetMem (dest, (UINTN)count, (UINT8)ch);
 }
 
 void
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error
       [not found]               ` <1758C871228D4D0E.10313@groups.io>
@ 2023-04-27 10:21                 ` Nickle Wang
  0 siblings, 0 replies; 9+ messages in thread
From: Nickle Wang @ 2023-04-27 10:21 UTC (permalink / raw)
  To: devel@edk2.groups.io, Nickle Wang, gaoliming@byosoft.com.cn,
	'Jian J Wang'
  Cc: 'Michael D Kinney', Nick Ramirez

[-- Attachment #1: Type: text/plain, Size: 11548 bytes --]

Hi @Liming Gao<mailto:gaoliming@byosoft.com.cn>,

I send out version 2 patch for review. Could you please help me to review this?  https://edk2.groups.io/g/devel/message/103712  The pull request is here: https://github.com/tianocore/edk2/pull/4298

Thanks,
Nickle

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Nickle Wang via groups.io
Sent: Monday, April 24, 2023 1:41 PM
To: devel@edk2.groups.io; gaoliming@byosoft.com.cn; 'Jian J Wang' <jian.j.wang@intel.com>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; Nick Ramirez <nramirez@nvidia.com>
Subject: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Hi Liming,

There are two errors mentioned for both memset() and memcpy() in my first patch. After I updated memset() implementation in RegularExpressionDxe, the first error is gone. But I still see below error for memcpy()

multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from
plugin):(.text+0x0): first defined here

For fixing above error, I still need MDE_CPU_IA32.  Attach my latest patch for your reference.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Monday, April 24, 2023 1:07 PM
To: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 You only need to update memset() implementation in RegularExpressionDxe. You don’t need to add MDE_CPU_XXX macro.

Thanks
Liming
发件人: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>
发送时间: 2023年4月21日 17:11
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: RE: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

After I change memset() implementation in RegularExpressionDxe, I only need to cover memcpy() with MDE_CPU_IA32. This is my change for your reference: https://github.com/tianocore/edk2/pull/4285/commits/15216e83198d7d422ae767833303d1979c8c0839

Please let me know if this makes sense to you or not.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle Wang via groups.io
Sent: Friday, April 21, 2023 2:22 PM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Hi Liming,

Yes, let me try it and feedback to you.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 2:13 PM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 I check memset implementation in CryptoPkg\Library\IntrinsicLib and ArmPkg\Library\CompilerIntrinsicsLib. They both use int type for the second parameter. So, I suggest to update RegularExpressionDxe implementation to match them. Can you help to verify this solution?

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 11:13
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
抄送: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

Hi Liming,

I noticed the build error from this CI test: Build and Test NetworkPkg,RedfishPkg IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64. And after applying my patch, CI reports build pass. Since this CI test also cover AARCH64, RISCV64 and LOONGARCH64, I think that the failure only happens to MDE_CPU_ARM.

Thanks,
Nickle

From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of gaoliming via groups.io
Sent: Friday, April 21, 2023 10:52 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; 'Jian J Wang' <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>
Cc: 'Michael D Kinney' <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
Subject: 回复: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error

External email: Use caution opening links or attachments

Nickle:
 Is this only for MDE_CPU_ARM? I may propose to add the judgement of MDE_CPU_IA32 and MDE_CPU_X64 for memcpy & memset. memcpy & memset are for X86 only.

Thanks
Liming
发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表 Nickle Wang via groups.io
发送时间: 2023年4月21日 8:26
收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>; Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
抄送: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>
主题: Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error


Hi @Jian J Wang<mailto:jian.j.wang@intel.com>, @Liming Gao<mailto:gaoliming@byosoft.com.cn>,



Could you please help me to review this patch? There is CI build error, and it blocks my pull request here: https://github.com/tianocore/edk2/pull/4285



Thanks,

Nickle



> -----Original Message-----

> From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Nickle

> Wang via groups.io

> Sent: Wednesday, April 19, 2023 4:30 PM

> To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Liming Gao

> <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>;

> Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> Subject: [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix

> Arm build error

>

> External email: Use caution opening links or attachments

>

>

> Fix Arm CI build error:

> - ArmPkg/Library/CompilerIntrinsicsLib/memset.c:39:1: warning: type of

> ‘memset’ does not match original declaration [-Wlto-type-mismatch]

> MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c:123:1:

> note: type ‘char’ should match type ‘int’

> - multiple definition of `memcpy'; OnigurumaUefiPort.obj (symbol from

> plugin):(.text+0x0): first defined here

>

> There is intrinsics library for Arm so we don't need memset and memcpy

> function in OnigurumaUefiPort.c.

>

> Signed-off-by: Nickle Wang <nicklew@nvidia.com<mailto:nicklew@nvidia.com>>

> Cc: Jian J Wang <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>

> Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

> Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>

> Cc: Nick Ramirez <nramirez@nvidia.com<mailto:nramirez@nvidia.com>>

> ---

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.h       | 5 ++++-

>  .../Universal/RegularExpressionDxe/OnigurumaUefiPort.c       | 4 ++++

>  2 files changed, 8 insertions(+), 1 deletion(-)

>

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> index 248109b0c96e..8f8581df6783 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.h

> @@ -4,7 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> -  Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

> +  Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights

> reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -107,6 +107,7 @@

> realloc (

>    size_t  size

>    );

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -121,6 +122,8 @@ memset (

>    unsigned int  count

>    );

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> diff --git

> a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> index 6661c67f976e..8af57f3a93c7 100644

> --- a/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> +++ b/MdeModulePkg/Universal/RegularExpressionDxe/OnigurumaUefiPort.c

> @@ -4,6 +4,7 @@

>

>    (C) Copyright 2014-2021 Hewlett Packard Enterprise Development LP<BR>

>    Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>

> +  Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

>

>    SPDX-License-Identifier: BSD-2-Clause-Patent  **/ @@ -109,6 +110,7 @@

> realloc (

>    return NULL;

>  }

>

> +#if !defined (MDE_CPU_ARM)

>  void *

>  memcpy (

>    void          *dest,

> @@ -129,6 +131,8 @@ memset (

>    return SetMem (dest, count, ch);

>  }

>

> +#endif

> +

>  void

>  free (

>    void  *ptr

> --

> 2.17.1

>

>

>

>

>




[-- Attachment #2: Type: text/html, Size: 47893 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-04-27 10:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <175748C3EBBDE1AF.26280@groups.io>
2023-04-21  0:25 ` [edk2-devel] [PATCH 1/1] MdeModulePkg/RegularExpressionDxe: Fix Arm build error Nickle Wang
2023-04-21  2:51   ` 回复: " gaoliming
2023-04-21  3:12     ` Nickle Wang
2023-04-21  6:13       ` 回复: " gaoliming
2023-04-21  6:22         ` Nickle Wang
     [not found]         ` <1757DEF7FD26598A.29498@groups.io>
2023-04-21  9:11           ` Nickle Wang
2023-04-24  5:06             ` 回复: " gaoliming
2023-04-24  5:40               ` Nickle Wang
     [not found]               ` <1758C871228D4D0E.10313@groups.io>
2023-04-27 10:21                 ` Nickle Wang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox