Re: [PATCH] Simplify a VEC_SELECT fed by its own inverse

2014-04-21 Thread Bill Schmidt
On Mon, 2014-04-21 at 13:48 -0700, Richard Henderson wrote: > On 04/21/2014 01:19 PM, Bill Schmidt wrote: > > + if (GET_CODE (trueop0) == VEC_SELECT > > + && GET_MODE (XEXP (trueop0, 0)) == mode) > > + { > > + rtx op0_subop1 = XEXP (trueop0,

Re: [PATCH] Simplify a VEC_SELECT fed by its own inverse

2014-04-22 Thread Bill Schmidt
Hi, Below is the revised patch addressing Richard's concerns about the assertions. Bootstrapped and tested on powerpc64[,le]-unknown-linux-gnu. Ok for trunk? Thanks, Bill [gcc] 2014-04-22 Bill Schmidt * simplify-rtx.c (simplify_binary_operation_1): Optimize ca

[PATCH] Fix PR60930

2014-04-24 Thread Bill Schmidt
equally to 4.8, 4.9, and trunk. Is this ok for trunk (and for 4.8/4.9 after a suitable burn-in period)? Thanks, Bill [gcc] 2014-04-24 Bill Schmidt PR tree-optimization/60930 * gimple-ssa-strength-reduction.c (create_mul_imm_cand): Reject creating a multiply candidate by

Re: [PATCH] Fix up pow folding (PR tree-optimization/56125)

2013-01-28 Thread Bill Schmidt
LGTM! Thanks for fixing this. Bill On Mon, 2013-01-28 at 15:25 +0100, Jakub Jelinek wrote: > Hi! > > gimple_expand_builtin_pow last two optimizations rely on earlier > optimizations in the same function to be performed, e.g. > folding pow (x, c) for n = 2c into sqrt(x) * powi(x, n / 2) is only

[PATCH] Fix PR56321

2013-02-15 Thread Bill Schmidt
When we remove __builtin_pow statements as part of reassociation, we have to unlink the associated VDEF. We've always done this when we directly remove the statement. However, in reassociation the statements are sometimes modified in place instead of removed, potentially leaving one or more dangl

Re: [PATCH] Fix PR56321

2013-02-18 Thread Bill Schmidt
On Mon, 2013-02-18 at 13:05 +0100, Richard Biener wrote: > On Fri, Feb 15, 2013 at 6:53 PM, Bill Schmidt > wrote: > > When we remove __builtin_pow statements as part of reassociation, we > > have to unlink the associated VDEF. We've always done this when we > >

Re: [PATCH, rs6000] Deprecate unnecessary __builtin_dfp_dtstsfi_*_dd and td overloads

2021-01-26 Thread Bill Schmidt via Gcc-patches
On 1/25/21 10:23 AM, Segher Boessenkool wrote: Hi! On Thu, Jan 21, 2021 at 05:49:14PM -0600, will schmidt wrote: Noted as part of the work-in-progress builtins rewrite, the __builtin_dfp_dtstsfi_*_{dd,td} builtins are redundant, and are thusly being marked as deprecated. They will be remove

Re: [PATCH 42/55] rs6000: Handle gimple folding of target built-ins

2021-08-02 Thread Bill Schmidt via Gcc-patches
Hi Will, On 7/29/21 7:42 AM, Bill Schmidt wrote: On 7/28/21 4:21 PM, will schmidt wrote: On Thu, 2021-06-17 at 10:19 -0500, Bill Schmidt via Gcc-patches wrote: +/* Vector compares; EQ, NE, GE, GT, LE. */ +case RS6000_BIF_VCMPEQUB: +case RS6000_BIF_VCMPEQUH: +case

Re: [PATCH, rs6000] Add store fusion support for Power10

2021-08-04 Thread Bill Schmidt via Gcc-patches
Hi Pat, Good stuff!  Comments below. On 8/2/21 3:19 PM, Pat Haugen via Gcc-patches wrote: Enable store fusion on Power10. Use the SCHED_REORDER hook to implement Power10 specific ready list reordering. As of now, pairing stores for store fusion is the only function being performed. Bootstrap/

Re: [PATCH 01/34] rs6000: Incorporate new builtins code into the build machinery

2021-08-05 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/4/21 5:29 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:48AM -0500, Bill Schmidt wrote: +rs6000-gen-builtins: rs6000-gen-builtins.o rbtree.o + $(LINKER_FOR_BUILD) $(BUILD_LINKERFLAGS) $(BUILD_LDFLAGS) -o $@ \ + $(filter-out $(BUILD_LIBDEPS

Re: [PATCH] rs6000: Add vec_unpacku_{hi,lo}_v4si

2021-08-06 Thread Bill Schmidt via Gcc-patches
Hi Kewen, On 8/4/21 9:06 PM, Kewen.Lin wrote: Hi, The existing vec_unpacku_{hi,lo} supports emulated unsigned unpacking for short and char but misses the support for int. This patch adds the support for vec_unpacku_{hi,lo}_v4si. Meanwhile, the current implementation uses vector permutation way

Re: [PATCH] Fix typo in fold-vec-load-builtin_vec_xl-* tests.

2021-08-08 Thread Bill Schmidt via Gcc-patches
Hi Mike, FWIW, looks fine to me, if tests are all passing now. Bill On 8/5/21 9:44 PM, Michael Meissner wrote: [PATCH] Fix typo in fold-vec-load-builtin_vec_xl-* tests. When I checked in the fix for running tests on power10 systems with power10 code generation, I had a typo in the fold-vec-lo

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-08 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/6/21 7:01 PM, Segher Boessenkool wrote: Hi! On Thu, Jul 29, 2021 at 08:30:50AM -0500, Bill Schmidt wrote: + const vsc __builtin_altivec_abss_v16qi (vsc); +ABSS_V16QI altivec_abss_v16qi {} + + const vsi __builtin_altivec_abss_v4si (vsi); +ABSS_V4SI altivec_abss_v4si

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-08 Thread Bill Schmidt via Gcc-patches
Hi... On 8/8/21 3:27 PM, Segher Boessenkool wrote: Hi! On Sun, Aug 08, 2021 at 11:53:38AM -0500, Bill Schmidt wrote: On 8/6/21 7:01 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:50AM -0500, Bill Schmidt wrote: + const vsc __builtin_altivec_abss_v16qi (vsc); +ABSS_V16QI

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-09 Thread Bill Schmidt via Gcc-patches
Hi Segher, + pcvoid_type_node += build_pointer_type (build_qualified_type (void_type_node, + TYPE_QUAL_CONST)); A const void? Interesting. You are building a pointer to a const void here, not a const pointer to void. Is that what you wanted?

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-10 Thread Bill Schmidt via Gcc-patches
On 8/9/21 6:44 PM, Segher Boessenkool wrote: This is not a documented GCC extension either, and it might even conflict with the existing void * extension (allowing arithmetic on it, by defining sizeof(void)). In either case it is not currently defined. I'm not sure how you get to this, bu

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-10 Thread Bill Schmidt via Gcc-patches
On 8/10/21 7:48 AM, Segher Boessenkool wrote: On Tue, Aug 10, 2021 at 07:17:54AM -0500, Bill Schmidt wrote: On 8/9/21 6:44 PM, Segher Boessenkool wrote: This is not a documented GCC extension either, and it might even conflict with the existing void * extension (allowing arithmetic on it, by

Re: [PATCH 03/34] rs6000: Add the rest of the [altivec] stanza to the builtins file

2021-08-10 Thread Bill Schmidt via Gcc-patches
On 8/10/21 8:40 AM, Segher Boessenkool wrote: On Tue, Aug 10, 2021 at 08:02:24AM -0500, Bill Schmidt wrote: The whole point is that this data type is only used for interfaces, as shown in the example code.  Nobody wants to define const void as anything.  The const serves only as a contract

Re: [PATCH 05/34] rs6000: Add available-everywhere and ancient builtins

2021-08-10 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/10/21 1:38 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:52AM -0500, Bill Schmidt wrote: * config/rs6000/rs6000-builtin-new.def: Add always, power5, and power6 stanzas. + unsigned long __builtin_ppc_mftb (); +MFTB rs6000_mftb_di {32bit} I&#

Re: [PATCH 05/34] rs6000: Add available-everywhere and ancient builtins

2021-08-10 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/10/21 12:34 PM, Segher Boessenkool wrote: On Tue, Aug 10, 2021 at 11:17:05AM -0500, will schmidt wrote: On Thu, 2021-07-29 at 08:30 -0500, Bill Schmidt wrote: +; This will break for long double == _Float128. libgcc history. + const long double __builtin_pack_longdouble

Re: [PATCH] rs6000: Add missing unsigned info for some P10 bifs

2021-08-11 Thread Bill Schmidt via Gcc-patches
Hi Kewen, On 8/11/21 12:44 AM, Kewen.Lin wrote: Hi, This patch is to make prototypes of some Power10 built-in functions consistent with what's in the documentation, as well as the vector version. Otherwise, useless conversions can be generated in gimple IR, and the vectorized versions will hav

Re: [PATCH] rs6000: Make some BIFs vectorized on P10

2021-08-11 Thread Bill Schmidt via Gcc-patches
Hi Kewen, FWIW, it's easier on reviewers if you include the patch inline instead of as an attachment. On 8/11/21 1:56 AM, Kewen.Lin wrote: Hi, This patch is to add the support to make vectorizer able to vectorize scalar version of some built-in functions with its corresponding vector version

Re: [PATCH] rs6000: Fix ICE expanding lxvp and stxvp gimple built-ins [PR101849]

2021-08-11 Thread Bill Schmidt via Gcc-patches
Hi Peter, LGTM.  Still needs maintainer review, of course. :) Bill On 8/10/21 6:37 PM, Peter Bergner wrote: PR101849 shows we ICE on a test case when we pass a non __vector_pair * pointer to the __builtin_vsx_lxvp and __builtin_vsx_stxvp built-ins that is cast to __vector_pair *. The problem

Re: [PATCH] rs6000: Make some BIFs vectorized on P10

2021-08-12 Thread Bill Schmidt via Gcc-patches
On 8/11/21 9:10 PM, Kewen.Lin wrote: Hi Bill, Thanks for your prompt review! on 2021/8/12 上午12:34, Bill Schmidt wrote: Hi Kewen, FWIW, it's easier on reviewers if you include the patch inline instead of as an attachment. On 8/11/21 1:56 AM, Kewen.Lin wrote: Hi, This patch is to ad

Re: PING: [RS6000] rotate and mask constants [PR94393]

2021-08-12 Thread Bill Schmidt via Gcc-patches
On 8/10/21 11:02 AM, Bill Schmidt wrote: Hm, is this code ever executed?  How does this not result in assignment through null pointers? It would be good to figure out whether this code is reachable at all, and just yank it out if not.  Otherwise we need a test case that hits it. I seem to

Re: [PATCH 47/55] rs6000: Builtin expansion, part 4

2021-08-12 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/3/21 7:34 PM, Segher Boessenkool wrote: Whoops, I forgot some stuff: On Tue, Jul 27, 2021 at 04:06:49PM -0500, will schmidt wrote: On Thu, 2021-06-17 at 10:19 -0500, Bill Schmidt via Gcc-patches wrote: static rtx ldv_expand_builtin (rtx target, insn_code icode, rtx *op

[PATCH] rs6000: Avoid buffer overruns

2021-08-12 Thread Bill Schmidt via Gcc-patches
Although safe_inc_pos avoids buffer overruns in rs6000-gen-builtins.c, there are some other routines where we fail to detect the possibility. Clean those up! Regstrap in progress on powerpc64le-linux-gnu. OK for trunk if that passes? Thanks, Bill 2021-08-12 Bill Schmidt gcc

Re: [PATCH] rs6000: Avoid buffer overruns

2021-08-12 Thread Bill Schmidt via Gcc-patches
Per discussion with Martin, I'm also changing the post-increment to pre-increment in safe_inc_pos.  That's what I'm regstrapping at the moment. Thanks, Bill On 8/12/21 3:28 PM, Bill Schmidt via Gcc-patches wrote: Although safe_inc_pos avoids buffer overruns in rs6000-gen-builti

Re: [PATCH] rs6000: Avoid buffer overruns

2021-08-13 Thread Bill Schmidt via Gcc-patches
Hi, On 8/12/21 3:43 PM, Bill Schmidt via Gcc-patches wrote: Per discussion with Martin, I'm also changing the post-increment to pre-increment in safe_inc_pos.  That's what I'm regstrapping at the moment. Thanks, Bill On 8/12/21 3:28 PM, Bill Schmidt via Gcc-patches w

Re: [PATCH] rs6000: Fix ICE expanding lxvp and stxvp gimple built-ins [PR101849]

2021-08-13 Thread Bill Schmidt via Gcc-patches
Hi Peter, On 8/13/21 12:01 PM, Peter Bergner wrote: On 8/12/21 1:20 PM, David Edelsohn wrote: On Tue, Aug 10, 2021 at 7:37 PM Peter Bergner wrote: gcc/ PR target/101849 * config/rs6000/rs6000-call.c (rs6000_gimple_fold_mma_builtin): Cast pointer to __vector_pair *.

Re: [PATCH 1/6] rs6000: Support SSE4.1 "round" intrinsics

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi, Paul! On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Suppress exceptions (when specified), by saving, manipulating, and restoring the FPSCR. Similarly, save, set, and restore the floating-point rounding mode when required. No attempt is made to optimize writing the FPSCR (by chec

Re: [PATCH 2/6] rs6000: Support SSE4.1 "min" and "max" intrinsics

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Also, copy tests for _mm_min_epi8, _mm_min_epu16, _mm_min_epi32, _mm_min_epu32, _mm_max_epi8, _mm_max_epu16, _mm_max_epi32, _mm_max_epu32 from gcc/testsuite/gcc.target/i386. sse4_1-pmaxsb.c and sse4_1-pminsb.c were modified from

Re: [PATCH 3/6] rs6000: Simplify some SSE4.1 "test" intrinsics

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Copy some simple redirections from i386 , for: - _mm_test_all_zeros - _mm_test_all_ones - _mm_test_mix_ones_zeros Testing, backports, etc. Simple is good!  LGTM. Bill 2021-08-09 Paul A. Clarke gcc * config/rs60

Re: [PATCH 4/6] rs6000: Support SSE4.1 "cvt" intrinsics

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Also, copy tests for: - _mm_cvtepi8_epi16, _mm_cvtepi8_epi32, _mm_cvtepi8_epi64 - _mm_cvtepi16_epi32, _mm_cvtepi16_epi64 - _mm_cvtepi32_epi64, - _mm_cvtepu8_epi16, _mm_cvtepu8_epi32, _mm_cvtepu8_epi64 - _mm_cvtepu16_epi32, _mm_cvt

Re: [PATCH 5/6] rs6000: Support more SSE4.1 "cmp", "mul", "pack" intrinsics

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Also, copy tests for: - _mm_cmpeq_epi64, _mm_cmpgt_epi64 - _mm_mullo_epi32, _mm_mul_epi32 - _mm_packus_epi32 from gcc/testsuite/gcc.target/i386. Testing, backports, etc. This patch LGTM with the usual comment about documentin

Re: [PATCH 6/6] rs6000: Guard some x86 intrinsics implementations

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/9/21 3:23 PM, Paul A. Clarke via Gcc-patches wrote: Some compatibility implementations of x86 intrinsics include Power intrinsics which require POWER8. Guard them. emmintrin.h: - _mm_cmpord_pd: Remove code which was ostensibly for pre-POWER8, but which indeed depended on POWER

Re: [PATCH] Move xx* builtins to vsx.md.

2021-08-18 Thread Bill Schmidt via Gcc-patches
Hi Mike, On 8/12/21 11:20 PM, Michael Meissner wrote: Move xx* builtins to vsx.md. I originally posted this patch in May. It needed a slight tune up as the souces have changed, so I'm reposting it now. I noticed that the xx built-in functions (xxspltiw, xxspltidp, xxsplti32dx, xxeval, xxblend

[PATCH v2] rs6000: Avoid buffer overruns

2021-08-19 Thread Bill Schmidt via Gcc-patches
! (Also, safe_inc_pos is not quite right itself.) Bootstrapped and tested on powerpc64le-linux-gnu, this time without some unsubmitted patches in the way. Is this OK for trunk? Thanks, Bill 2021-08-19 Bill Schmidt gcc/ PR target/101830 * config/rs6000/rs6000-gen-builtins.c

[PATCH, rs6000, committed] Fix AIX bootstrap (don't call asprintf)

2021-08-23 Thread Bill Schmidt via Gcc-patches
d to using malloc and sprintf. Bootstrapped on powerpc64le-linux-gnu, committed as obvious. Sorry for the trouble! Bill 2021-08-23 Bill Schmidt gcc/ * config/rs6000/rs6000-gen-builtins.c (parse_bif_entry): Don't call asprintf, which is not available on AIX. --- gcc/confi

Re: [PATCH 08/34] rs6000: Add Power9 builtins

2021-08-24 Thread Bill Schmidt via Gcc-patches
On 8/23/21 4:40 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:55AM -0500, Bill Schmidt wrote: 2021-06-15 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add power9-vector, power9, and power9-64 stanzas. +; These things need some review to see whether they

Re: [PATCH 09/34] rs6000: Add more type nodes to support builtin processing

2021-08-24 Thread Bill Schmidt via Gcc-patches
On 8/23/21 5:15 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:56AM -0500, Bill Schmidt wrote: * config/rs6000/rs6000-call.c (rs6000_init_builtins): Initialize various pointer type nodes. * config/rs6000/rs6000.h (rs6000_builtin_type_index): Add enum

Re: [PATCH 08/34] rs6000: Add Power9 builtins

2021-08-24 Thread Bill Schmidt via Gcc-patches
On 8/24/21 10:38 AM, Segher Boessenkool wrote: Hi! On Tue, Aug 24, 2021 at 09:20:09AM -0500, Bill Schmidt wrote: On 8/23/21 4:40 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:30:55AM -0500, Bill Schmidt wrote: +; These things need some review to see whether they really require

Re: [PATCH] rs6000: Make some BIFs vectorized on P10

2021-08-24 Thread Bill Schmidt via Gcc-patches
Hi Kewen, Sorry this sat in my queue for so long.  It looks like you addressed all of our concerns, so LGTM -- recommend maintainers approve. Thanks! Bill On 8/12/21 9:34 PM, Kewen.Lin wrote: Hi Segher, Thanks for the review! on 2021/8/12 下午11:10, Segher Boessenkool wrote: Hi! On Wed, Au

Re: [PATCH, rs6000] Disable gimple fold for float or double vec_minmax when fast-math is not set

2021-08-24 Thread Bill Schmidt via Gcc-patches
Hi Hao Chen, On 8/24/21 3:52 AM, HAO CHEN GUI wrote: Hi    The patch disables gimple fold for float or double vec_min/max builtin when fast-math is not set. Two test cases are added to verify the patch.    The attachments are the patch diff and change log file.    Bootstrapped and teste

Re: [PATCH, rs6000] Disable gimple fold for float or double vec_minmax when fast-math is not set

2021-08-25 Thread Bill Schmidt via Gcc-patches
r float vb = vec_promote (b, PREF_F); +  return vec_extract (vec_min (va, vb), PREF_F); +} On 25/8/2021 上午 6:40, Segher Boessenkool wrote: Hi! On Tue, Aug 24, 2021 at 03:04:26PM -0500, Bill Schmidt wrote: On 8/24/21 3:52 AM, HAO CHEN GUI wrote: Thanks for this patch!  In the future, if you can put your

Re: [PATCH 14/34] rs6000: Add remaining overloads

2021-08-26 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/25/21 6:27 PM, Segher Boessenkool wrote: On Thu, Jul 29, 2021 at 08:31:01AM -0500, Bill Schmidt wrote: * config/rs6000/rs6000-overload.def: Add remaining overloads. +; TODO: Note that the entry for VEC_ADDE currently gets ignored in +; altivec_resolve_overloaded_builtin

Re: [PATCH 15/34] rs6000: Execute the automatic built-in initialization code

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/26/21 6:15 PM, Segher Boessenkool wrote: Hi! On Thu, Jul 29, 2021 at 08:31:02AM -0500, Bill Schmidt wrote: * config/rs6000/rs6000-call.c (rs6000-builtins.h): New #include. (rs6000_init_builtins): Call rs6000_autoinit_builtins; skip the old

Re: [PATCH v3 1/6] rs6000: Support SSE4.1 "round" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/23/21 2:03 PM, Paul A. Clarke wrote: Suppress exceptions (when specified), by saving, manipulating, and restoring the FPSCR. Similarly, save, set, and restore the floating-point rounding mode when required. No attempt is made to optimize writing the FPSCR (by checking if the new

Re: [PATCH v3 1/6] rs6000: Support SSE4.1 "round" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
On 8/27/21 8:44 AM, Bill Schmidt wrote: Again, please specify where the patch was tested and whether this is for trunk, backports, etc.  Thanks!  (I know you aren't asking for backports, but in general please get in the habit of this.) Sorry, I see that you did this in the cover l

Re: [PATCH v3 2/6] rs6000: Support SSE4.1 "min" and "max" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Paul, This looks fine to me, recommend approval. Thanks, Bill On 8/23/21 2:03 PM, Paul A. Clarke wrote: Function signatures and decorations match gcc/config/i386/smmintrin.h. Also, copy tests for _mm_min_epi8, _mm_min_epu16, _mm_min_epi32, _mm_min_epu32, _mm_max_epi8, _mm_max_epu16, _mm_ma

Re: [PATCH v3 3/6] rs6000: Simplify some SSE4.1 "test" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
This looks fine, recommend approval. Thanks! Bill On 8/23/21 2:03 PM, Paul A. Clarke wrote: Copy some simple redirections from i386 , for: - _mm_test_all_zeros - _mm_test_all_ones - _mm_test_mix_ones_zeros 2021-08-20 Paul A. Clarke gcc * config/rs6000/smmintrin.h (_mm_test_all_zero

Re: [PATCH v3 4/6] rs6000: Support SSE4.1 "cvt" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
This looks fine, recommend approval. Thanks! Bill On 8/23/21 2:03 PM, Paul A. Clarke wrote: Function signatures and decorations match gcc/config/i386/smmintrin.h. Also, copy tests for: - _mm_cvtepi8_epi16, _mm_cvtepi8_epi32, _mm_cvtepi8_epi64 - _mm_cvtepi16_epi32, _mm_cvtepi16_epi64 - _mm_cvte

Re: [PATCH v3 5/6] rs6000: Support more SSE4 "cmp", "mul", "pack" intrinsics

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/23/21 2:03 PM, Paul A. Clarke wrote: Function signatures and decorations match gcc/config/i386/smmintrin.h. Also, copy tests for: - _mm_cmpeq_epi64 - _mm_mullo_epi32, _mm_mul_epi32 - _mm_packus_epi32 - _mm_cmpgt_epi64 (SSE4.2) from gcc/testsuite/gcc.target/i386. 2021-08-23 Paul

Re: [PATCH v3 6/6] rs6000: Guard some x86 intrinsics implementations

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Paul, Thanks for the changes!  This looks fine to me, recommend approval. Thanks, Bill On 8/23/21 2:03 PM, Paul A. Clarke wrote: Some compatibility implementations of x86 intrinsics include Power intrinsics which require POWER8. Guard them. emmintrin.h: - _mm_cmpord_pd: Remove code which

Re: [PATCH] Fix float128-call.c test for power8 IEEE 128 and power10.

2021-08-27 Thread Bill Schmidt via Gcc-patches
Hi Mike, Thanks for this clean-up! On 8/25/21 5:09 PM, Michael Meissner wrote: From 327273dfeec5c000f3c33ca7b88ee0097fd33586 Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Wed, 25 Aug 2021 00:31:35 -0400 Subject: [PATCH] Fix float128-call.c test for power8 IEEE 128 and power10. I buil

Re: [PATCH v3 1/6] rs6000: Support SSE4.1 "round" intrinsics

2021-08-30 Thread Bill Schmidt via Gcc-patches
Hi Paul, On 8/30/21 4:16 PM, Paul A. Clarke wrote: On Fri, Aug 27, 2021 at 08:44:43AM -0500, Bill Schmidt via Gcc-patches wrote: On 8/23/21 2:03 PM, Paul A. Clarke wrote: + __fpscr_save.__fr = __builtin_mffsl (); As pointed out in the v1 review, __builtin_mffsl is enabled (or supposed

Re: [PATCH 19/34] rs6000: Handle overloads during program parsing

2021-08-30 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 8/27/21 6:07 PM, Segher Boessenkool wrote: Hi! On Thu, Jul 29, 2021 at 08:31:06AM -0500, Bill Schmidt wrote: Although this patch looks quite large, the changes are fairly minimal. Most of it is duplicating the large function that does the overload resolution using the

[PATCH] rs6000: Fix misnamed built-in

2020-09-15 Thread Bill Schmidt via Gcc-patches
; committed as obvious. 2020-09-15 Bill Schmidt 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

Re: [PATCH] rs6000: Fix misnamed built-in

2020-09-16 Thread Bill Schmidt via Gcc-patches
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

[PATCH] rs6000: Add rs6000_cfun_pcrel_p

2020-09-16 Thread Bill Schmidt via Gcc-patches
think it's worth keeping around in case we have a late discovery where we need it.) Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2020-09-16 Bill Schmidt gcc/ * config/rs6000/predicat

Re: [PATCH] rs6000: Add rs6000_cfun_pcrel_p

2020-09-16 Thread Bill Schmidt via Gcc-patches
On 9/16/20 12:09 PM, Segher Boessenkool wrote: On Wed, Sep 16, 2020 at 08:36:35AM -0500, Bill Schmidt wrote: This is a cleanup requested by Segher in a previous review. Most uses of rs6000_pcrel_p are called for the current function. A specialized version for cfun is more efficient for these

Re: [PATCH, rs6000] correct an erroneous BTM value in the BU_P10_MISC define

2020-09-27 Thread Bill Schmidt via Gcc-patches
On 9/25/20 6:50 PM, Segher Boessenkool wrote: On Fri, Sep 25, 2020 at 03:34:49PM -0500, will schmidt wrote: On Fri, 2020-09-25 at 12:36 -0500, Segher Boessenkool wrote: No, it cannot. This is used for pdepd/pextd/cntlzdm/cnttzdm/cfuged, all of which do need 64-bit registers to do anything sane

[PATCH] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-01-19 Thread Bill Schmidt via Gcc-patches
t the default patterns are for little endian, and the overridden patterns in rs6000-builtin.cc are for big endian. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk, and eventually for backport to GCC 11? Thanks! Bill 2022-01-18 Bill Schmidt

[PATCH v2] rs6000: More factoring of overload processing

2022-01-19 Thread Bill Schmidt via Gcc-patches
al cases, but leaves vec_splats, vec_promote, vec_extract, vec_insert, and vec_step alone. Bootstrapped and tested on powerpc64le-linux-gnu. Is this okay for trunk? Thanks, Bill 2022-01-18 Bill Schmidt gcc/ * config/rs6000/rs6000-c.cc (resolve_vec_mul): Accept args and types p

[PATCH] rs6000: Support vector float/double for vec_sldw

2022-01-21 Thread Bill Schmidt via Gcc-patches
x27;t actually checking for generation of the xxsldwi instruction, so I added that check as well. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks! Bill 2022-01-21 Bill Schmidt gcc/ * config/rs6000/rs6000-overload.def (VEC_SLDW)

Re: [PATCH] rs6000: Support vector float/double for vec_sldw

2022-01-21 Thread Bill Schmidt via Gcc-patches
Thanks!  Pushed as r12-6806 with the testcase adjusted. Bill On 1/21/22 11:47 AM, Segher Boessenkool wrote: > Hi! > > On Fri, Jan 21, 2022 at 11:31:34AM -0600, Bill Schmidt wrote: >> It was recently discovered that Clang supports a couple of variants of >> vec_sldw that &g

Re: [PATCH v9] rtl: builtins: (not just) rs6000: Add builtins for fegetround, feclearexcept and feraiseexcept [PR94193]

2022-01-24 Thread Bill Schmidt via Gcc-patches
Adding the patch author for his information. Thanks, Bill On 1/24/22 2:26 PM, Jakub Jelinek via Gcc-patches wrote: > On Mon, Jan 24, 2022 at 08:55:37AM -0600, Segher Boessenkool wrote: >> Hi! >> >> On Thu, Jan 13, 2022 at 02:08:53PM -0300, Raoni Fassina Firmino wrote: >>> Changes since v8[8]: >>>

[PATCH 0/8] rs6000: Built-in function cleanups and bug fixes

2022-01-28 Thread Bill Schmidt via Gcc-patches
group primarily because 5-8 are dependent on the previous patches, particularly patch 4, which consolidates much of the built-in code in a new file. Thanks for your consideration! Bill Bill Schmidt (8): rs6000: More factoring of overload processing rs6000: Don't #ifdef "short" bui

[PATCH 1/8] rs6000: More factoring of overload processing

2022-01-28 Thread Bill Schmidt via Gcc-patches
d and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2022-01-18 Bill Schmidt gcc/ * config/rs6000/rs6000-c.cc (resolve_vec_mul): Accept args and types parameters instead of arglist and nargs. Simplify accordingly. Remove unnec

[PATCH 2/8] rs6000: Don't #ifdef "short" built-in names

2022-01-28 Thread Bill Schmidt via Gcc-patches
able using __attribute__((target)), so I failed in this respect. This patch corrects the problem by removing the apply. For example, #ifdef __PPU__ is still appropriate. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2022-01-06 Bill Schm

[PATCH 3/8] rs6000: Convert built-in constraints to form

2022-01-28 Thread Bill Schmidt via Gcc-patches
added a note in rs6000-builtins.def that this form is deprecated in favor of . I think it's harmless to leave it in, in case a desire for the distinction comes up in the future. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2022

[PATCH 5/8] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-01-28 Thread Bill Schmidt via Gcc-patches
These built-ins were misimplemented as always having big-endian semantics. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2022-01-18 Bill Schmidt gcc/ PR target/95082 * config/rs6000/rs6000-builtin.cc

[PATCH 6/8] rs6000: Remove -m[no-]fold-gimple flag [PR103686]

2022-01-28 Thread Bill Schmidt via Gcc-patches
gest the proper incantation for an opcode ending with a period. Bootstrapped and tested on powerpc64le-linux-gnu and on powerpc64-linux-gnu (32- and 64-bit) with no regressions. Is this okay for trunk? Thanks, Bill 2022-01-27 Bill Schmidt gcc/ PR target/103686 * config/rs6000/rs

[PATCH 7/8] rs6000: vec_neg built-ins wrongly require POWER8

2022-01-28 Thread Bill Schmidt via Gcc-patches
As the subject states. Fixing this is accomplished by moving the built-ins to the correct stanzas, [altivec] and [vsx]. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2022-01-27 Bill Schmidt gcc/ * config/rs6000/rs6000

[PATCH 8/8] rs6000: Fix some missing built-in attributes [PR104004]

2022-01-28 Thread Bill Schmidt via Gcc-patches
regressions. Is this okay for trunk? Thanks, Bill 2022-01-27 Bill Schmidt gcc/ * config/rs6000/rs6000-builtin.def (MFFSL): Mark nosoft. (MTFSB0): Likewise. (MTFSB1): Likewise. (SET_FPSCR_RN): Likewise. (SET_FPSCR_DRN): Mark nosoft and no32bit. --- gcc/

Re: [PATCH 1/8] rs6000: More factoring of overload processing

2022-01-28 Thread Bill Schmidt via Gcc-patches
On 1/28/22 1:11 PM, Segher Boessenkool wrote: > On Fri, Jan 28, 2022 at 11:50:19AM -0600, Bill Schmidt wrote: >> This patch continues the refactoring started with r12-6014. > ab3f5b71dc6e > >> + and the generic code will issue the appropriate error message. Skip &

Re: [PATCH 2/8] rs6000: Don't #ifdef "short" built-in names

2022-01-28 Thread Bill Schmidt via Gcc-patches
On 1/28/22 2:32 PM, Segher Boessenkool wrote: > On Fri, Jan 28, 2022 at 11:50:20AM -0600, Bill Schmidt wrote: >> It was recently pointed out that we get anomalous behavior when using >> __attribute__((target)) to select a CPU. As an example, when building for >> -

Re: [PATCH 3/8] rs6000: Convert built-in constraints to form

2022-01-31 Thread Bill Schmidt via Gcc-patches
On 1/28/22 5:24 PM, Segher Boessenkool wrote: > On Fri, Jan 28, 2022 at 11:50:21AM -0600, Bill Schmidt wrote: >> When introducing the new built-in support, I tried to match as many >> existing error messages as possible. One common form was "argument X must >> b

Re: [PATCH 3/8] rs6000: Convert built-in constraints to form

2022-01-31 Thread Bill Schmidt via Gcc-patches
On 1/31/22 11:28 AM, Segher Boessenkool wrote: > On Mon, Jan 31, 2022 at 11:21:32AM -0600, Bill Schmidt wrote: >> On 1/28/22 5:24 PM, Segher Boessenkool wrote: >>> On Fri, Jan 28, 2022 at 11:50:21AM -0600, Bill Schmidt wrote: >>>> When introducing the new built-in sup

Re: [PATCH 4/8] rs6000: Consolidate target built-ins code

2022-01-31 Thread Bill Schmidt via Gcc-patches
Hi Segher, On 1/31/22 3:32 PM, Segher Boessenkool wrote: > Hi! > > On Fri, Jan 28, 2022 at 11:50:22AM -0600, Bill Schmidt wrote: >> Continuing with the refactoring effort, this patch moves as much of the >> target-specific built-in support code into a new file, rs6000-built

[PATCH v2 1/8] rs6000: More factoring of overload processing

2022-02-01 Thread Bill Schmidt via Gcc-patches
insert, and vec_step alone. Thanks! Bill 2022-01-31 Bill Schmidt gcc/ * config/rs6000/rs6000-c.cc (resolve_vec_mul): Accept args and types parameters instead of arglist and nargs. Simplify accordingly. Remove unnecessary test for argument count mismatch.

[PATCH v2 3/8] rs6000: Unify error messages for built-in constant restrictions

2022-02-01 Thread Bill Schmidt via Gcc-patches
between two values. It's better to be consistent. Change the error message for the n-bit literal to look like the other one. Bootstrapped and tested on powerpc64le-linux-gnu. Is this okay for trunk? Thanks! Bill 2022-01-31 Bill Schmidt gcc/ * config/rs6000/rs6000-ca

Re: [PATCH] rs6000: Fix up PCH on powerpc* [PR104323]

2022-02-01 Thread Bill Schmidt via Gcc-patches
Hi! Jakub, thanks for fixing this.  I didn't realize the PCH implications here, clearly... On 2/1/22 12:33 PM, Segher Boessenkool wrote: > Hi! > > On Tue, Feb 01, 2022 at 04:27:40PM +0100, Jakub Jelinek wrote: >> +/* PR target/104323 */ >> +/* { dg-require-effective-target powerpc_altivec_ok } *

Re: [PATCH v2 1/8] rs6000: More factoring of overload processing

2022-02-02 Thread Bill Schmidt via Gcc-patches
Hi! On 2/1/22 3:48 PM, Segher Boessenkool wrote: > On Tue, Feb 01, 2022 at 08:49:34AM -0600, Bill Schmidt wrote: >> I've modified the previous patch to add more explanatory commentary about >> the number-of-arguments test that was previously confusing, and to convert >>

[PATCH v3 1/8] rs6000: More factoring of overload processing

2022-02-03 Thread Bill Schmidt via Gcc-patches
ing on the remaining special cases, but leaves vec_splats, vec_promote, vec_extract, vec_insert, and vec_step alone. Thanks, Bill 2022-02-02 Bill Schmidt gcc/ * config/rs6000/rs6000-c.cc (resolve_vec_mul): Accept args and types parameters instead of arglist and nargs. Simplify

[PATCH, committed] rs6000: Clean up ISA 3.1 documentation [PR100808]

2022-02-04 Thread Bill Schmidt via Gcc-patches
Hi! PR100808 pointed out some trivial formatting issues with Power documentation for basic ISA 3.1 built-in functions. This patch cleans those up. Tested on powerpc64le-linux-gnu, committed as obvious. Thanks! Bill 2022-02-04 Bill Schmidt gcc/ PR target/100808 * doc

Re: [PATCH 7/8] rs6000: vec_neg built-ins wrongly require POWER8

2022-02-07 Thread Bill Schmidt via Gcc-patches
Hi Segher, Thanks for all the reviews for this series!  I'd like to gently ping the last two patches. BR, Bill On 1/28/22 11:50 AM, Bill Schmidt via Gcc-patches wrote: > As the subject states. Fixing this is accomplished by moving the built-ins > to the correct stanzas, [altive

[PATCH] rs6000: Add support for vmsumcud and vec_msumc

2022-02-07 Thread Bill Schmidt via Gcc-patches
dered. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks! Bill 2022-02-07 Bill Schmidt gcc/ * config/rs6000/rs6000-builtins.def (VMSUMCUD): New. * config/rs6000/rs6000-overload.def (VEC_MSUMC): New. * config/rs6000/v

Re: [PATCH] rs6000: Add support for vmsumcud and vec_msumc

2022-02-07 Thread Bill Schmidt via Gcc-patches
Hi! On 2/7/22 5:05 PM, Segher Boessenkool wrote: > Hi! > > On Mon, Feb 07, 2022 at 04:20:24PM -0600, Bill Schmidt wrote: >> I observed recently that a couple of Power10 instructions and built-in >> functions >> were somehow not implemented. This patch adds one of the

Re: [PATCH] rs6000: Add support for vmsumcud and vec_msumc

2022-02-08 Thread Bill Schmidt via Gcc-patches
On 2/8/22 9:45 AM, Segher Boessenkool wrote: > On Mon, Feb 07, 2022 at 10:06:36PM -0600, Bill Schmidt wrote: >> On 2/7/22 5:05 PM, Segher Boessenkool wrote: >>> On Mon, Feb 07, 2022 at 04:20:24PM -0600, Bill Schmidt wrote: >>>> I observed recently that a couple of

Re: [PATCH v3] rs6000: Fix some issues in rs6000_can_inline_p [PR102059]

2022-02-08 Thread Bill Schmidt via Gcc-patches
Hi! >From some discussion today, I think we want to limit the scope of this patch to just the power8-fusion flag that's causing trouble for now, given stage 4. We've talked about making power8-fusion a do- nothing flag, since it doesn't add much benefit now and probably shouldn't be a separate fl

[PATCH] rs6000: Correct function prototypes for vec_replace_unaligned

2022-02-08 Thread Bill Schmidt via Gcc-patches
misaligned by this built-in function. This patch corrects the misimplementation. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Eventually I would also like to backport it to GCC 11, after burn-in. Thanks! Bill 2022-02-04 Bill Schmidt gcc

[PATCH] rs6000: Rename vec_clrl and vec_clrr to agreed-upon names

2022-02-09 Thread Bill Schmidt via Gcc-patches
like I neglected to make that change, so fixing it now. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk, and for backport to gcc 11 after some burn-in? Thanks! Bill 2022-02-09 Bill Schmidt gcc/ * config/rs6000/rs6000-overload.def (VEC_CLR

[PATCH, 11 backport] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-02-10 Thread Bill Schmidt via Gcc-patches
modifications to the test suite are identical (after fixing the issue with -mbig that David pointed out with the original patch). Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for releases/gcc-11? Thanks! Bill 2022-02-10 Bill Schmidt gcc/ PR target/95082

Re: [PATCH, 11 backport] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-02-10 Thread Bill Schmidt via Gcc-patches
Hi! On 2/10/22 2:06 PM, Segher Boessenkool wrote: > Hi! > > On Thu, Feb 10, 2022 at 12:22:28PM -0600, Bill Schmidt wrote: >> This is a backport from mainline 3f30f2d1dbb3228b8468b26239fe60c2974ce2ac. >> These built-ins were misimplemented as always having big-endian semantics

Re: [PATCH, 11 backport] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-02-10 Thread Bill Schmidt via Gcc-patches
Hi! On 2/10/22 2:50 PM, Segher Boessenkool wrote: > On Thu, Feb 10, 2022 at 12:22:28PM -0600, Bill Schmidt wrote: >> This is a backport from mainline 3f30f2d1dbb3228b8468b26239fe60c2974ce2ac. >> These built-ins were misimplemented as always having big-endian semantics. >> &g

Re: [PATCH, 11 backport] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-02-10 Thread Bill Schmidt via Gcc-patches
Hi! On 2/10/22 4:11 PM, Segher Boessenkool wrote: > On Thu, Feb 10, 2022 at 03:17:05PM -0600, Bill Schmidt wrote: >>>> /* 1 argument vector functions added in ISA 3.0 (power9). */ >>>> -BU_P9V_AV_1 (VCLZLSBB_V16QI, "vclzlsbb_v16qi",CONST, vclzlsbb_v1

Re: [PATCH, 11 backport] rs6000: Fix LE code gen for vec_cnt[lt]z_lsbb [PR95082]

2022-02-11 Thread Bill Schmidt via Gcc-patches
Fine.  I withdraw the patch request, and will remove my name from the bugzilla. Somebody else can deal with it. I have more important things to worry about. Bill On 2/11/22 1:31 AM, Segher Boessenkool wrote: > Hi! > > On Thu, Feb 10, 2022 at 04:28:02PM -0600, Bill Schmidt wrote: >

Re: [PATCH v2] rs6000: Test case adjustments for new builtins

2021-11-17 Thread Bill Schmidt via Gcc-patches
On 11/17/21 6:44 AM, Segher Boessenkool wrote: > Hi! > > On Tue, Nov 16, 2021 at 02:26:22PM -0600, Bill Schmidt wrote: >> Hi! I recently submitted [1] to make adjustments to test cases for the new >> builtins >> support, mostly due to error messages changing f

Re: [PATCH] rs6000: Better error messages for power8/9-vector builtins

2021-11-17 Thread Bill Schmidt via Gcc-patches
On 11/17/21 10:54 AM, Paul A. Clarke wrote: > On Tue, Nov 16, 2021 at 11:12:35AM -0600, Bill Schmidt via Gcc-patches wrote: >> Hi! During a previous patch review, Segher asked that I provide better >> messages when builtins are unavailable because they require both a minimum

<    5   6   7   8   9   10   11   12   13   14   >