Bug 246559
| Summary: | [WGSL] Flesh out WGSL AST | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Dan Glastonbury <djg> |
| Component: | WebGPU | Assignee: | Dan Glastonbury <djg> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Other | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | |||
| Bug Blocks: | 246558 | ||
Dan Glastonbury
Only a partial AST is implemented. After studying the WGSL specification, I propose:
```
Node
|- Attribute
| |- AlignAttribute
| |- BindingAttribute
| |- BuiltinAttribute
| |- ConstAttribute
| |- GroupAttribute
| |- IdAttribute
| |- InterpolateAttribute
| |- InvariantAttribute
| |- LocationAttribute
| |- SizeAttribute
| |- StageAttribute
| |- WorkgroupSizeAttribute
|- Directive
|- Expression
| |- BinaryExpression
| |- BitcastExpression
| |- IndexAccessExpression
| |- CallExpression
| |- IdentiferExpression
| |- LiteralExpression
| | |- BoolLiteral
| | |- FloatLiteral
| | |- IntegerLiteral
| |- FieldAccessExpression
| |- UnaryExpression
|- Function
|- ShaderModule
|- Statement
| |- AssignmentStatement
| |- BreakStatement
| |- CallStatement
| |- CompoundAssignmentStatement
| |- CompoundStatement
| |- ContinueStatement
| |- DecrementStatement
| |- DiscardStatement
| |- ForStatement
| |- IfStatement
| |- IncrementStatement
| |- LoopStatement
| |- ReturnStatement
| |- StaticAssertStatement
| |- SwitchStatement
| |- VariableStatement
| |- WhileStatement
|- Structure
|- StructureMember
|- TypeAlias
|- TypeName
| |- ArrayTypeName
| |- NamedTypeName
| |- ParameterizedTypeName
|- Value
| |- ConstantValue
| |- OverrideValue
| |- LetValue
| |- ParameterValue
|- Variable
|- VariableQualifier
```
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/101198259>
Dan Glastonbury
Pull request: https://github.com/WebKit/WebKit/pull/9369
EWS
Committed 259661@main (664eceb30ec0): <https://commits.webkit.org/259661@main>
Reviewed commits have been landed. Closing PR #9369 and removing active labels.