• bbudge's avatar
    Turbofan: Add MachineOperators for SIMD. · 1c94bed6
    bbudge authored
    Takes the SIMD runtime intrinsics as a starting point for defining TF machine operators. The rationale for omitting functions is:
    
     - Check functions.
     - 'FromXxxBits' functions. These are essentially casts.
     - UInt constructors. int and uint aren't distinguished in wasm.
     - Uint functions, except where their behavior is bitwise different from the Int function.
    
    Some operators are typeless, i.e. they are the same for multiple related types, e.g. logical ops for int types, load/store for float and int types. Use a 'Simd128' prefix for these operators.
    
    Skipped fns:
    
    Float32x4Check
    Float32x4FromInt32x4Bits
    Float32x4FromUint32x4Bits
    Float32x4FromInt16x8Bits
    Float32x4FromUint16x8Bits
    Float32x4FromInt8x16Bits
    Float32x4FromUint8x16Bits
    
    Int32x4Check
    Int32x4FromUint32x4
    Int32x4FromFloat32x4Bits
    Int32x4FromUint32x4Bits
    Int32x4FromInt16x8Bits
    Int32x4FromUint16x8Bits
    Int32x4FromInt8x16Bits
    Int32x4FromUint8x16Bits
    
    CreateUint32x4
    Uint32x4Check
    Uint32x4ExtractLane
    Uint32x4ReplaceLane
    Uint32x4Add
    Uint32x4Sub
    Uint32x4Mul
    Uint32x4And
    Uint32x4Or
    Uint32x4Xor
    Uint32x4Not
    Uint32x4Equal
    Uint32x4NotEqual
    Uint32x4Select
    Uint32x4Swizzle
    Uint32x4Shuffle
    Uint32x4FromInt32x4
    Uint32x4FromFloat32x4Bits
    Uint32x4FromInt32x4Bits
    Uint32x4FromInt16x8Bits
    Uint32x4FromUint16x8Bits
    Uint32x4FromInt8x16Bits
    Uint32x4FromUint8x16Bits
    
    Bool32x4Check
    
    Int16x8Check
    Int16x8FromUint16x8
    Int16x8FromFloat32x4Bits
    Int16x8FromInt32x4Bits
    Int16x8FromUint32x4Bits
    Int16x8FromUint16x8Bits
    Int16x8FromInt8x16Bits
    Int16x8FromUint8x16Bits
    
    CreateUint16x8
    Uint16x8Check
    Uint16x8ExtractLane
    Uint16x8ReplaceLane
    Uint16x8Add
    Uint16x8Sub
    Uint16x8Mul
    Uint16x8And
    Uint16x8Or
    Uint16x8Xor
    Uint16x8Not
    Uint16x8Equal
    Uint16x8NotEqual
    Uint16x8Select
    Uint16x8Swizzle
    Uint16x8Shuffle
    Uint16x8FromInt16x8
    Uint16x8FromFloat32x4Bits
    Uint16x8FromInt32x4Bits
    Uint16x8FromUint32x4Bits
    Uint16x8FromInt16x8Bits
    Uint16x8FromInt8x16Bits
    Uint16x8FromUint8x16Bits
    
    Bool16x8Check
    
    Int8x16Check
    Int8x16FromUint8x16
    Int8x16FromFloat32x4Bits
    Int8x16FromInt32x4Bits
    Int8x16FromUint32x4Bits
    Int8x16FromInt16x8Bits
    Int8x16FromUint16x8Bits
    Int8x16FromUint8x16Bits
    
    CreateUint8x16
    Uint8x16Check
    Uint8x16ExtractLane
    Uint8x16ReplaceLane
    Uint8x16Add
    Uint8x16Sub
    Uint8x16Mul
    Uint8x16And
    Uint8x16Or
    Uint8x16Xor
    Uint8x16Not
    Uint8x16Equal
    Uint8x16NotEqual
    Uint8x16Select
    Uint8x16Swizzle
    Uint8x16Shuffle
    Uint8x16FromInt8x16
    Uint8x16FromFloat32x4Bits
    Uint8x16FromInt32x4Bits
    Uint8x16FromUint32x4Bits
    Uint8x16FromInt16x8Bits
    Uint8x16FromUint16x8Bits
    Uint8x16FromInt8x16Bits
    
    Bool8x16Check
    
    Generic operators for Float, Int types:
    
    Simd128Load
    Simd128Load1
    Simd128Load2
    Simd128Load3
    Simd128Store
    Simd128Store1
    Simd128Store2
    Simd128Store3
    
    Generic operators for Int types:
    
    Simd128And
    Simd128Or
    Simd128Xor
    Simd128Not
    
    LOG=N
    BUG=v8:4124
    
    Committed: https://crrev.com/3831d41e4ce7b162775732cb6ac1f8139e60aa30
    Cr-Commit-Position: refs/heads/master@{#35213}
    
    Review-Url: https://codereview.chromium.org/1848433003
    Cr-Commit-Position: refs/heads/master@{#35951}
    1c94bed6
machine-operator.cc 37.5 KB