diff mbox series

[v2,07/11] aarch64: Add explicit bool cast to return value

Message ID 43f58fba-8237-5b7c-c750-012810ef3071@e124511.cambridge.arm.com
State New
Headers show
Series aarch64: Extend aarch64_feature_flags to 128 bits | expand

Commit Message

Andrew Carlotti July 11, 2024, 12:14 p.m. UTC
gcc/ChangeLog:

	* config/aarch64/aarch64.cc
	(aarch64_valid_sysreg_name_p): Add bool cast.

Comments

Richard Sandiford July 11, 2024, 5:16 p.m. UTC | #1
Andrew Carlotti <andrew.carlotti@arm.com> writes:
> gcc/ChangeLog:
>
> 	* config/aarch64/aarch64.cc
> 	(aarch64_valid_sysreg_name_p): Add bool cast.

OK, thanks.

Richard

> diff --git a/gcc/config/aarch64/aarch64.cc b/gcc/config/aarch64/aarch64.cc
> index 69f481ecfc848e6c5b61516c2f7b8bff5cd4f8b8..229e438115c268f876c6d77e1fcc4faa2f7d231b 100644
> --- a/gcc/config/aarch64/aarch64.cc
> +++ b/gcc/config/aarch64/aarch64.cc
> @@ -30284,7 +30284,7 @@ aarch64_valid_sysreg_name_p (const char *regname)
>    if (sysreg == NULL)
>      return aarch64_is_implem_def_reg (regname);
>    if (sysreg->arch_reqs)
> -    return (aarch64_isa_flags & sysreg->arch_reqs);
> +    return bool (aarch64_isa_flags & sysreg->arch_reqs);
>    return true;
>  }
>
diff mbox series

Patch

diff --git a/gcc/config/aarch64/aarch64.cc b/gcc/config/aarch64/aarch64.cc
index 69f481ecfc848e6c5b61516c2f7b8bff5cd4f8b8..229e438115c268f876c6d77e1fcc4faa2f7d231b 100644
--- a/gcc/config/aarch64/aarch64.cc
+++ b/gcc/config/aarch64/aarch64.cc
@@ -30284,7 +30284,7 @@  aarch64_valid_sysreg_name_p (const char *regname)
   if (sysreg == NULL)
     return aarch64_is_implem_def_reg (regname);
   if (sysreg->arch_reqs)
-    return (aarch64_isa_flags & sysreg->arch_reqs);
+    return bool (aarch64_isa_flags & sysreg->arch_reqs);
   return true;
 }