public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] rs6000: Fix misnamed built-in
@ 2020-09-16  1:38 Bill Schmidt
  2020-09-16 10:32 ` Segher Boessenkool
  0 siblings, 1 reply; 3+ messages in thread
From: Bill Schmidt @ 2020-09-16  1:38 UTC (permalink / raw)
  To: GCC Patches, Segher Boessenkool, David Edelsohn

The description	in rs6000-builtin.def provides for a builtin named
__builtin_altivec_xst_len_r.  However, it is hand-defined in
altivec_init_builtins as __builtin_xst_len_r, against the usual naming
practice.  Fix that.

Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no
regressions; committed as obvious.


2020-09-15  Bill Schmidt  <wschmidt@linux.ibm.com>

gcc/
         * config/rs6000/rs6000-call.c (altivec_init_builtins): Fix name
         of __builtin_altivec_xst_len_r.


diff --git a/gcc/config/rs6000/rs6000-call.c b/gcc/config/rs6000/rs6000-call.c
index 77c7a1149fb..a8b520834c7 100644
--- a/gcc/config/rs6000/rs6000-call.c
+++ b/gcc/config/rs6000/rs6000-call.c
@@ -13490,7 +13490,7 @@ altivec_init_builtins (void)
      {
        def_builtin ("__builtin_altivec_stxvl", void_ftype_v16qi_pvoid_long,
  		   P9V_BUILTIN_STXVL);
-      def_builtin ("__builtin_xst_len_r", void_ftype_v16qi_pvoid_long,
+      def_builtin ("__builtin_altivec_xst_len_r", void_ftype_v16qi_pvoid_long,
  		   P9V_BUILTIN_XST_LEN_R);
      }
  


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

* Re: [PATCH] rs6000: Fix misnamed built-in
  2020-09-16  1:38 [PATCH] rs6000: Fix misnamed built-in Bill Schmidt
@ 2020-09-16 10:32 ` Segher Boessenkool
  2020-09-16 13:26   ` Bill Schmidt
  0 siblings, 1 reply; 3+ messages in thread
From: Segher Boessenkool @ 2020-09-16 10:32 UTC (permalink / raw)
  To: Bill Schmidt; +Cc: GCC Patches, David Edelsohn

On Tue, Sep 15, 2020 at 08:38:42PM -0500, Bill Schmidt wrote:
> The description	in rs6000-builtin.def provides for a builtin named
> __builtin_altivec_xst_len_r.  However, it is hand-defined in
> altivec_init_builtins as __builtin_xst_len_r, against the usual naming
> practice.  Fix that.
> 
> Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no
> regressions; committed as obvious.

Does no one use this?  Should we provide an alias with the old (wrong)
name?  What does the documentation say it should be?

It is obvious of course, except for that "might break users' code"
thing ;-)


Segher

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

* Re: [PATCH] rs6000: Fix misnamed built-in
  2020-09-16 10:32 ` Segher Boessenkool
@ 2020-09-16 13:26   ` Bill Schmidt
  0 siblings, 0 replies; 3+ messages in thread
From: Bill Schmidt @ 2020-09-16 13:26 UTC (permalink / raw)
  To: Segher Boessenkool; +Cc: GCC Patches, David Edelsohn

On 9/16/20 5:32 AM, Segher Boessenkool wrote:
> On Tue, Sep 15, 2020 at 08:38:42PM -0500, Bill Schmidt wrote:
>> The description	in rs6000-builtin.def provides for a builtin named
>> __builtin_altivec_xst_len_r.  However, it is hand-defined in
>> altivec_init_builtins as __builtin_xst_len_r, against the usual naming
>> practice.  Fix that.
>>
>> Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no
>> regressions; committed as obvious.
> Does no one use this?  Should we provide an alias with the old (wrong)
> name?  What does the documentation say it should be?
>
> It is obvious of course, except for that "might break users' code"
> thing ;-)


Sorry, I should have mentioned this.  It's unlikely that people are 
using the incorrect name, as it is undocumented, and hidden by the 
supported overloaded interfaces.  The only documented interface is 
"vec_xl_len_r", which remains unchanged (and the internal hookup from 
that to this is unchanged by the patch).

If anyone's using the undocumented incorrect interface, I'd rather that 
get discovered and fixed.

Thanks,
Bill

>
> Segher

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

end of thread, other threads:[~2020-09-16 13:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-16  1:38 [PATCH] rs6000: Fix misnamed built-in Bill Schmidt
2020-09-16 10:32 ` Segher Boessenkool
2020-09-16 13:26   ` Bill Schmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).