WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
237871
[WebGPU] Implement first draft of buffer copying according to the spec
https://bugs.webkit.org/show_bug.cgi?id=237871
Summary
[WebGPU] Implement first draft of buffer copying according to the spec
Myles C. Maxfield
Reported
2022-03-14 20:39:21 PDT
.
Attachments
Patch
(16.89 KB, patch)
2022-03-14 20:44 PDT
,
Myles C. Maxfield
no flags
Details
Formatted Diff
Diff
Patch
(16.89 KB, patch)
2022-03-14 22:05 PDT
,
Myles C. Maxfield
kkinnunen
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Myles C. Maxfield
Comment 1
2022-03-14 20:44:09 PDT
Created
attachment 454658
[details]
Patch
Myles C. Maxfield
Comment 2
2022-03-14 21:39:06 PDT
Comment on
attachment 454658
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=454658&action=review
> Source/WebGPU/WebGPU/CommandEncoder.mm:144 > + if (validateCopyBufferToBuffer(source, sourceOffset, destination, destinationOffset, size)) {
if (!validateCopyBufferToBuffer(source, sourceOffset, destination, destinationOffset, size))
Myles C. Maxfield
Comment 3
2022-03-14 22:05:22 PDT
Created
attachment 454664
[details]
Patch
Kimmo Kinnunen
Comment 4
2022-03-16 06:59:15 PDT
Comment on
attachment 454664
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=454664&action=review
> Source/WebGPU/WebGPU/CommandEncoder.mm:52 > + commandBuffer.label = [NSString stringWithCString:descriptor.label encoding:NSUTF8StringEncoding];
nullptr label remark (in case it's not handled in the fromAPI patch)
> Source/WebGPU/WebGPU/CommandsMixin.h:32 > +class CommandsMixin : public RefCounted<CommandsMixin> {
Based on this commit alone, it's not clear why would the refcounted be in the mixin. it would indicate objects hold references to the mixin, which is counter (my) expectation of mixins being just "way to import a bag of common functionality" Also having the WTF_MAKE_FAST_ALLOCATED here would imply you allocate the mixins
Kimmo Kinnunen
Comment 5
2022-03-16 07:08:01 PDT
Comment on
attachment 454664
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=454664&action=review
>> Source/WebGPU/WebGPU/CommandEncoder.mm:52 >> + commandBuffer.label = [NSString stringWithCString:descriptor.label encoding:NSUTF8StringEncoding]; > > nullptr label remark (in case it's not handled in the fromAPI patch)
Checked, I think the fromAPI patch was not written with this patch in, so there's that. so probably you could have some sort of fromAPI<NSString*>(descriptor.label) for these cases (or something else you come up with)
Myles C. Maxfield
Comment 6
2022-03-16 15:08:32 PDT
Comment on
attachment 454664
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=454664&action=review
>>> Source/WebGPU/WebGPU/CommandEncoder.mm:52 >>> + commandBuffer.label = [NSString stringWithCString:descriptor.label encoding:NSUTF8StringEncoding]; >> >> nullptr label remark (in case it's not handled in the fromAPI patch) > > Checked, I think the fromAPI patch was not written with this patch in, so there's that. > so probably you could have some sort of fromAPI<NSString*>(descriptor.label) for these cases (or something else you come up with)
Right. I'll have to update the fromAPI patch after this lands.
>> Source/WebGPU/WebGPU/CommandsMixin.h:32 >> +class CommandsMixin : public RefCounted<CommandsMixin> { > > Based on this commit alone, it's not clear why would the refcounted be in the mixin. it would indicate objects hold references to the mixin, which is counter (my) expectation of mixins being just "way to import a bag of common functionality" > > Also having the WTF_MAKE_FAST_ALLOCATED here would imply you allocate the mixins
Ah, I see what you're saying. Yeah, I guess multiple inheritance is better than making a mixin class that appears to be refcounted.
Myles C. Maxfield
Comment 7
2022-03-16 15:13:51 PDT
Committed
r291372
(
248504@trunk
): <
https://commits.webkit.org/248504@trunk
>
Radar WebKit Bug Importer
Comment 8
2022-03-16 15:14:16 PDT
<
rdar://problem/90394764
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug