RESOLVED FIXED 193877
[WHLSL] Pack and unpack data at entry points and exit points
https://bugs.webkit.org/show_bug.cgi?id=193877
Summary [WHLSL] Pack and unpack data at entry points and exit points
Myles C. Maxfield
Reported 2019-01-26 17:27:55 PST
[WHLSL] Pack and unpack data at entry points and exit points
Attachments
WIP (64.23 KB, patch)
2019-01-26 17:29 PST, Myles C. Maxfield
no flags
Patch (64.23 KB, patch)
2019-01-27 10:02 PST, Myles C. Maxfield
no flags
Patch (125.19 KB, patch)
2019-01-27 22:45 PST, Myles C. Maxfield
no flags
WIP (125.26 KB, patch)
2019-03-05 14:26 PST, Myles C. Maxfield
no flags
Patch (127.73 KB, patch)
2019-03-06 14:03 PST, Myles C. Maxfield
no flags
Myles C. Maxfield
Comment 1 2019-01-26 17:29:37 PST
EWS Watchlist
Comment 2 2019-01-26 17:32:06 PST
Attachment 360258 [details] did not pass style-queue: ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5] Total errors found: 1 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Myles C. Maxfield
Comment 3 2019-01-27 10:02:33 PST
EWS Watchlist
Comment 4 2019-01-27 10:03:39 PST
Attachment 360298 [details] did not pass style-queue: ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5] Total errors found: 1 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Myles C. Maxfield
Comment 5 2019-01-27 22:45:34 PST
EWS Watchlist
Comment 6 2019-01-27 22:48:35 PST
Attachment 360319 [details] did not pass style-queue: ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5] Total errors found: 1 in 16 files If any of these errors are false positives, please file a bug against check-webkit-style.
Myles C. Maxfield
Comment 7 2019-03-05 14:26:46 PST
Myles C. Maxfield
Comment 8 2019-03-06 14:03:56 PST
Dean Jackson
Comment 9 2019-03-06 14:24:21 PST
Comment on attachment 363790 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=363790&action=review > Source/WebCore/Modules/webgpu/WHLSL/Metal/WHLSLEntryPointScaffolding.cpp:107 > + namedBindGroup.argumentBufferIndex = argumentBufferIndex++; Why can't you use i here? (or rename i to be argumentBufferIndex) > Source/WebCore/Modules/webgpu/WHLSL/Metal/WHLSLEntryPointScaffolding.cpp:113 > + namedBinding.index = index++; Why can't you use j here? > Source/WebCore/Modules/webgpu/WHLSL/Metal/WHLSLEntryPointScaffolding.cpp:407 > + m_namedOutputs.reserveInitialCapacity(m_entryPointItems.outputs.size()); > + for (size_t i = 0; i < m_entryPointItems.outputs.size(); ++i) { > + NamedOutput namedOutput; > + namedOutput.elementName = m_typeNamer.generateNextStructureElementName(); > + m_namedOutputs.uncheckedAppend(WTFMove(namedOutput)); > + } I wonder if you could use .map for these loops. It sets up the initial capacity for you. m_namedOutputs = m_entryPointItems.output.map([] (...) -> NamedOutput { .... return namedOutput; } > Source/WebCore/Modules/webgpu/WHLSL/Metal/WHLSLFunctionWriter.cpp:265 > + CRASH(); Really? Wouldn't we want to return an invalid program instead? > Source/WebCore/Modules/webgpu/WHLSL/Metal/WHLSLFunctionWriter.cpp:360 > + CRASH(); ditto for other instances of CRASH() > Source/WebCore/Modules/webgpu/WHLSL/WHLSLSemanticMatcher.cpp:97 > + itemIndices.add(i + 1); // Work around the fact that HashSet's keys are restricted. Confused--- Can't you use a HashSet with a zero key? You test for max above?
WebKit Commit Bot
Comment 10 2019-03-06 15:08:58 PST
Comment on attachment 363790 [details] Patch Clearing flags on attachment: 363790 Committed r242571: <https://trac.webkit.org/changeset/242571>
WebKit Commit Bot
Comment 11 2019-03-06 15:09:00 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 12 2019-03-06 15:09:20 PST
Note You need to log in before you can comment on or make changes to this bug.