Bug 188517

Summary: [WHLSL] Verify the parser uses the same grammar as the language
Product: WebKit Reporter: Thomas Denney <tdenney>
Component: WebGPUAssignee: Nobody <webkit-unassigned>
Status: RESOLVED MOVED    
Severity: Normal CC: dino, jonlee, mmaxfield, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 176199, 189202    

Description Thomas Denney 2018-08-13 08:50:45 PDT
The current hand-written recursive-descent parser is relatively slow and is the main bottleneck of the `prepare` function. The parser should be rewritten using a tool that produces more efficient code, such as https://github.com/antlr/antlr4.
Comment 1 Myles C. Maxfield 2018-08-27 15:21:28 PDT
*** Bug 189014 has been marked as a duplicate of this bug. ***
Comment 2 Myles C. Maxfield 2018-08-27 15:22:11 PDT
It takes 2.5 hours to compile the standard library. 95% of the time is spent parsing.
Comment 3 Myles C. Maxfield 2018-08-28 15:55:01 PDT
One way to do this is by using a parser generator. Another way of doing this is with testing. Another way is via inspection.
Comment 4 Radar WebKit Bug Importer 2018-09-12 18:51:31 PDT
<rdar://problem/44403020>
Comment 5 Myles C. Maxfield 2018-10-13 15:35:46 PDT
Migrated to https://github.com/gpuweb/WHLSL/issues/101