diff mbox series

[4/5] arm: [MVE intrinsics] Add support for predicated contiguous loads and stores

Message ID 20240916093819.12740-5-christophe.lyon@arm.com
State New
Headers show
Series arm, MVE: Refactor the vst and vld intrinsics | expand

Commit Message

Christophe Lyon Sept. 16, 2024, 9:38 a.m. UTC
From: Alfie Richards <Alfie.Richards@arm.com>

This patch extends
function_expander::use_contiguous_load_insn and
function_expander::use_contiguous_store_insn functions to
support predicated versions.

2024-09-11  Alfie Richards  <Alfie.Richards@arm.com>
	    Christophe Lyon  <christophe.lyon@arm.com>

	gcc/

	* config/arm/arm-mve-builtins.cc
	(function_expander::use_contiguous_load_insn): Add support for
	PRED_z.
	(function_expander::use_contiguous_store_insn): Add support for
	PRED_p.
---
 gcc/config/arm/arm-mve-builtins.cc | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Richard Earnshaw (lists) Oct. 15, 2024, 2:15 p.m. UTC | #1
On 16/09/2024 10:38, Christophe Lyon wrote:
> From: Alfie Richards <Alfie.Richards@arm.com>
> 
> This patch extends
> function_expander::use_contiguous_load_insn and
> function_expander::use_contiguous_store_insn functions to
> support predicated versions.
> 
> 2024-09-11  Alfie Richards  <Alfie.Richards@arm.com>
> 	    Christophe Lyon  <christophe.lyon@arm.com>
> 
> 	gcc/
> 
> 	* config/arm/arm-mve-builtins.cc
> 	(function_expander::use_contiguous_load_insn): Add support for
> 	PRED_z.
> 	(function_expander::use_contiguous_store_insn): Add support for
> 	PRED_p.

OK.

R.

> ---
>  gcc/config/arm/arm-mve-builtins.cc | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/gcc/config/arm/arm-mve-builtins.cc b/gcc/config/arm/arm-mve-builtins.cc
> index 7e8217666fe..f519fded000 100644
> --- a/gcc/config/arm/arm-mve-builtins.cc
> +++ b/gcc/config/arm/arm-mve-builtins.cc
> @@ -2237,6 +2237,8 @@ function_expander::use_contiguous_load_insn (insn_code icode)
>  
>    add_output_operand (icode);
>    add_mem_operand (mem_mode, get_contiguous_base ());
> +  if (pred == PRED_z)
> +    add_input_operand (icode, args[1]);
>    return generate_insn (icode);
>  }
>  
> @@ -2249,6 +2251,8 @@ function_expander::use_contiguous_store_insn (insn_code icode)
>  
>    add_mem_operand (mem_mode, get_contiguous_base ());
>    add_input_operand (icode, args[1]);
> +  if (pred == PRED_p)
> +    add_input_operand (icode, args[2]);
>    return generate_insn (icode);
>  }
>
diff mbox series

Patch

diff --git a/gcc/config/arm/arm-mve-builtins.cc b/gcc/config/arm/arm-mve-builtins.cc
index 7e8217666fe..f519fded000 100644
--- a/gcc/config/arm/arm-mve-builtins.cc
+++ b/gcc/config/arm/arm-mve-builtins.cc
@@ -2237,6 +2237,8 @@  function_expander::use_contiguous_load_insn (insn_code icode)
 
   add_output_operand (icode);
   add_mem_operand (mem_mode, get_contiguous_base ());
+  if (pred == PRED_z)
+    add_input_operand (icode, args[1]);
   return generate_insn (icode);
 }
 
@@ -2249,6 +2251,8 @@  function_expander::use_contiguous_store_insn (insn_code icode)
 
   add_mem_operand (mem_mode, get_contiguous_base ());
   add_input_operand (icode, args[1]);
+  if (pred == PRED_p)
+    add_input_operand (icode, args[2]);
   return generate_insn (icode);
 }