Bug 158391
Summary: | Do everything necessary to make IDBConnectionToServer::putOrAdd pass it's key by rvalue | ||
---|---|---|---|
Product: | WebKit | Reporter: | Brady Eidson <beidson> |
Component: | WebCore Misc. | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED WONTFIX | ||
Severity: | Normal | ||
Priority: | P2 | ||
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Bug Depends on: | |||
Bug Blocks: | 149117 |
Brady Eidson
Do everything necessary to make IDBConnectionToServer::putOrAdd pass it's key by rvalue
This is a spinoff from https://bugs.webkit.org/show_bug.cgi?id=158124
It seems simple to do this, but it opens a can of worms making templated objects and lambdas handle it.
But we should still do it.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Brady Eidson
(In reply to comment #0)
> Do everything necessary to make IDBConnectionToServer::putOrAdd pass it's
> key by rvalue
>
> This is a spinoff from https://bugs.webkit.org/show_bug.cgi?id=158124
>
> It seems simple to do this, but it opens a can of worms making templated
> objects and lambdas handle it.
>
> But we should still do it.
Actually... this is unlikely to be possible: The can of worms that opens is once that IDBKeyData rvalue hits CrossThreadCopier/CrossThreadTask.
But when an object hits those, we *have* to make an isolatedCopy.
So whether we WTFMove the IDBKeyData&& all the way along the chain, or just pass it by const IDBKeyData& all the way along the chain, we get no benefit - We have to make an isolatedCopy in the end.
That said, while exploring this I came up with some great enhancements to CrossThreadTask.