Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 06afe2c12fbd458661d408321362569e0e327611
https://github.com/WebKit/WebKit/commit/06afe2c12fbd458661d408321362569e0e327611
Author: Tadeu Zagallo <[email protected]>
Date: 2023-10-24 (Tue, 24 Oct 2023)
Changed paths:
M Source/WebGPU/WGSL/ConstantFunctions.h
M Source/WebGPU/WGSL/ConstantValue.h
M Source/WebGPU/WGSL/TypeDeclarations.rb
M Source/WebGPU/WGSL/generator/main.rb
M Source/WebGPU/WGSL/tests/valid/overload.wgsl
Log Message:
-----------
[WGSL] Add missing constant functions
https://bugs.webkit.org/show_bug.cgi?id=263554
rdar://117371037
Reviewed by Mike Wyrzykowski.
Finish implementing constant functions for (nearly) all type declarations. This
just leaves functions that operate on matrices and functions that return structs
(e.g. modf), which are both currently unsupported.
* Source/WebGPU/WGSL/ConstantFunctions.h:
(WGSL::constantUnaryOperation):
(WGSL::constantBinaryOperation):
(WGSL::constantTernaryOperation):
(WGSL::constantConstructor):
(WGSL::constantVector):
(WGSL::constantMatrix):
(WGSL::constantAdd):
(WGSL::constantMinus):
(WGSL::constantMultiply):
(WGSL::BINARY_OPERATION):
(WGSL::UNARY_OPERATION):
(WGSL::constantBitwiseOr):
(WGSL::constantBitwiseAnd):
(WGSL::constantVec2):
(WGSL::constantVec3):
(WGSL::constantVec4):
(WGSL::constantAll):
(WGSL::constantAny):
(WGSL::constantSelect):
(WGSL::TERNARY_OPERATION):
(WGSL::constantCross):
(WGSL::constantDeterminant):
(WGSL::constantDistance):
(WGSL::constantDot):
(WGSL::constantLength):
(WGSL::constantFaceForward):
(WGSL::constantFma):
(WGSL::constantFract):
(WGSL::constantFrexp):
(WGSL::constantInsertBits):
(WGSL::constantInverseSqrt):
(WGSL::constantLdexp):
(WGSL::constantModf):
(WGSL::constantNormalize):
(WGSL::constantQuantizeToF16):
(WGSL::constantReflect):
(WGSL::constantRefract):
(WGSL::constantTranspose):
(WGSL::constantPow): Deleted.
(WGSL::constantDivide): Deleted.
(WGSL::constantEqual): Deleted.
(WGSL::constantNotEqual): Deleted.
(WGSL::constantLt): Deleted.
(WGSL::constantLtEq): Deleted.
(WGSL::constantGt): Deleted.
(WGSL::constantGtEq): Deleted.
(WGSL::constantNot): Deleted.
(WGSL::constantOr): Deleted.
(WGSL::constantAnd): Deleted.
(WGSL::constantBitwiseNot): Deleted.
(WGSL::constantBitwiseXor): Deleted.
(WGSL::constantBitwiseShiftLeft): Deleted.
(WGSL::constantBitwiseShiftRight): Deleted.
(WGSL::constantBool): Deleted.
(WGSL::constantI32): Deleted.
(WGSL::constantU32): Deleted.
(WGSL::constantF32): Deleted.
* Source/WebGPU/WGSL/ConstantValue.h:
(WGSL::ConstantValue::isVector const):
(WGSL::ConstantValue::toVector const):
* Source/WebGPU/WGSL/TypeDeclarations.rb:
* Source/WebGPU/WGSL/generator/main.rb:
Canonical link: https://commits.webkit.org/269721@main
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes