On Mon, 22 May 2023, Jonathan Wakely via Libstdc++ wrote:
* subscripting vector builtins is not allowed in constant expressions
Is that just because nobody made it work (yet)?
Yes.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101651 and others.
* if the implementation would otherwise call
On Tue, 21 Mar 2023, Ken Matsui via Libstdc++ wrote:
/// add_const
+#if __has_builtin(__add_const)
+ template
+struct add_const
+{ using type = __add_const(_Tp); };
+#else
template
struct add_const
{ using type = _Tp const; };
+#endif
Is that really better? You asked elsew
On Fri, 4 Nov 2022, Hongyu Wang via Gcc-patches wrote:
This is a follow-up patch for PR98167
The sequence
c1 = VEC_PERM_EXPR (a, a, mask)
c2 = VEC_PERM_EXPR (b, b, mask)
c3 = c1 op c2
can be optimized to
c = a op b
c3 = VEC_PERM_EXPR (c, c, mask)
for all integer vector opera
On Tue, 13 Sep 2022, Roger Sayle wrote:
This patch tweaks the match.pd transformation previously added to fold
(X<
In https://gcc.gnu.org/onlinedocs/gcc/Integers-implementation.html , I
read:
"Bitwise operators act on the representation of the value including both
the sign and value bits, w
On Thu, 31 Mar 2022, Jonathan Wakely wrote:
On Thu, 31 Mar 2022 at 17:03, Marc Glisse via Libstdc++
wrote:
On Thu, 31 Mar 2022, Matthias Kretz via Gcc-patches wrote:
I like it. But I'd like it even more if we could have
#elif defined _UBSAN
__ubsan_invoke_ub("reached std::unreachable()"
On Thu, 31 Mar 2022, Matthias Kretz via Gcc-patches wrote:
I like it. But I'd like it even more if we could have
#elif defined _UBSAN
__ubsan_invoke_ub("reached std::unreachable()");
But to my knowledge UBSAN has no hooks for the library like this (yet).
-fsanitize=undefined already repla
On Fri, 11 Mar 2022, Roger Sayle wrote:
+(match vec_same_elem_p
+ CONSTRUCTOR@0
+ (if (uniform_vector_p (TREE_CODE (@0) == SSA_NAME
+? gimple_assign_rhs1 (SSA_NAME_DEF_STMT (@0)) : @0
Ah, I didn't remember we needed that, we don't seem to be very consistent
about i