https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92658
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
It looks like there are already some avx512 patterns matching this but they
are not visible to the RTL expanders.
(define_insn "zero_extendv8qiv8hi2"
[(set (match_operand:V8HI 0 "register_operand" "=x,v")
(zero_extend:V8HI (match_operand:V8QI 1 "register_operand" "x,v")))]
"TARGET_SSE2"
"@
punpcklbw\t{%1, %0|%0, %1}
vpunpcklbw\t{%1, %0|%0, %1}"
)
does it for the testcase pasted but truncation and other extends are also
missing, likewise for floats.