https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88698

            Bug ID: 88698
           Summary: Relax generic vector conversions
           Product: gcc
           Version: 9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: husseydevin at gmail dot com
  Target Milestone: ---

GCC is far too strict about vector conversions. 

Currently, mixing generic vector extensions and platform-specific intrinsics
almost always requires either a cast or -flax-vector-extensions, which is
annoying and breaks a lot of things Clang happily accepts.

Here is my proposal:
* x86's __mNi should implicitly convert between any N-bit vector. This matches
the void pointer-like behavior of SSE's vectors.
* Any vector with equivalent lane types and number of lanes should convert
without an issue. For example, uint32_t vector_size(16) and NEON's uint32x4_t
have no reason not to be compatible. 
* Signed <-> unsigned should act like other implicit signed <-> unsigned
conversions, -Wextra in C and warning in C++.
* Implicit conversions between different vectors of the same size should emit
an error.

Reply via email to