Bug 257842

Summary: B3 Select instruction truncates vector operands
Product: WebKit Reporter: David Degazio <d_degazio>
Component: WebAssemblyAssignee: David Degazio <d_degazio>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Description David Degazio 2023-06-07 18:44:19 PDT
rdar://108643371

B3 Select lowers to Air using one of several conditional moves, like MoveConditionally64 or MoveDoubleConditionallyFloat. These in turn generate native conditional move instructions, such as fcsel to select between floating-point registers on ARM. However, we don't implement conditional moves for vectors, so when we compile a WASM select instruction with vector operands, B3 ends up treating them like doubles, which ends up zeroing the upper half of the vector register.
Comment 1 David Degazio 2023-06-08 10:51:20 PDT
Pull request: https://github.com/WebKit/WebKit/pull/14778
Comment 2 EWS 2023-06-08 15:32:21 PDT
Committed 264996@main (c4e675b3afdd): <https://commits.webkit.org/264996@main>

Reviewed commits have been landed. Closing PR #14778 and removing active labels.