WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
232768
Unify build of TestWebKitAPI/Tests/WebKitCocoa
https://bugs.webkit.org/show_bug.cgi?id=232768
Summary
Unify build of TestWebKitAPI/Tests/WebKitCocoa
Alex Christensen
Reported
2021-11-05 15:12:56 PDT
Unify build of TestWebKitAPI/Tests/WebKitCocoa
Attachments
Patch
(398.07 KB, patch)
2021-11-05 15:13 PDT
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(381.98 KB, patch)
2021-11-05 15:40 PDT
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(389.44 KB, patch)
2021-11-05 15:44 PDT
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(394.33 KB, patch)
2021-11-05 16:01 PDT
,
Alex Christensen
no flags
Details
Formatted Diff
Diff
Patch
(393.91 KB, patch)
2021-11-08 17:37 PST
,
Alex Christensen
no flags
Details
Formatted Diff
Diff
Patch
(399.10 KB, patch)
2021-11-09 14:36 PST
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Alex Christensen
Comment 1
2021-11-05 15:13:20 PDT
Created
attachment 443441
[details]
Patch
Alex Christensen
Comment 2
2021-11-05 15:40:18 PDT
Created
attachment 443445
[details]
Patch
Alex Christensen
Comment 3
2021-11-05 15:44:49 PDT
Created
attachment 443447
[details]
Patch
Alex Christensen
Comment 4
2021-11-05 16:01:02 PDT
Created
attachment 443453
[details]
Patch
Alex Christensen
Comment 5
2021-11-05 16:14:39 PDT
This reduces the time of "make -C Tools/TestWebKitAPI" from 86 seconds to 56 seconds
Alex Christensen
Comment 6
2021-11-08 17:37:05 PST
Created
attachment 443640
[details]
Patch
Tim Horton
Comment 7
2021-11-09 11:06:12 PST
Comment on
attachment 443640
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=443640&action=review
> Tools/TestWebKitAPI/DeprecatedGlobalValues.h:33 > +extern bool receivedScriptMessage;
I do not love *this* whole thing, would be better to fix the tests to use local `__block bool`s like we often do, or maybe these names in a per-test namespace? As it stands this makes the tests oddly not self-contained. I guess it's not the worst thing, though.
> Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh:18 > -UnifiedSourceMmFileCount=5 > +UnifiedSourceMmFileCount=50
Why so big, and why so big only for ObjC? This is the balance between fast incremental builds and fast world builds.
Alex Christensen
Comment 8
2021-11-09 11:09:29 PST
Comment on
attachment 443640
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=443640&action=review
>> Tools/TestWebKitAPI/DeprecatedGlobalValues.h:33 >> +extern bool receivedScriptMessage; > > I do not love *this* whole thing, would be better to fix the tests to use local `__block bool`s like we often do, or maybe these names in a per-test namespace? As it stands this makes the tests oddly not self-contained. I guess it's not the worst thing, though.
I don't love this whole thing either, but this gives us the benefits now. I called it DeprecatedGlobalValues.h because we shouldn't increase the use of this. We can go through and make all the tests only use local values and decrease the use of this file, but that's slow, low-priority work.
>> Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh:18 >> +UnifiedSourceMmFileCount=50 > > Why so big, and why so big only for ObjC? This is the balance between fast incremental builds and fast world builds.
This patch only adds unified sources from TestWebKitAPI/Tests/WebKitCocoa which only contains .mm files, so that is the only limit that needs increasing in this patch. This is a slight overshot, but not much. It will make it so we don't need to increase this limit immediately after adding the next file.
Tim Horton
Comment 9
2021-11-09 12:26:07 PST
(In reply to Alex Christensen from
comment #8
)
> Comment on
attachment 443640
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=443640&action=review
> > >> Tools/TestWebKitAPI/DeprecatedGlobalValues.h:33 > >> +extern bool receivedScriptMessage; > > > > I do not love *this* whole thing, would be better to fix the tests to use local `__block bool`s like we often do, or maybe these names in a per-test namespace? As it stands this makes the tests oddly not self-contained. I guess it's not the worst thing, though. > > I don't love this whole thing either, but this gives us the benefits now. I > called it DeprecatedGlobalValues.h because we shouldn't increase the use of > this. We can go through and make all the tests only use local values and > decrease the use of this file, but that's slow, low-priority work.
Makes sense.
> >> Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh:18 > >> +UnifiedSourceMmFileCount=50 > > > > Why so big, and why so big only for ObjC? This is the balance between fast incremental builds and fast world builds. > > This patch only adds unified sources from TestWebKitAPI/Tests/WebKitCocoa > which only contains .mm files, so that is the only limit that needs > increasing in this patch. > This is a slight overshot, but not much. It will make it so we don't need > to increase this limit immediately after adding the next file.
Oh oh oh wait, I misremembered; this isn't the "how many per bundle" count that I thought it was, this is just the total number of files. OK, fine.
Wenson Hsieh
Comment 10
2021-11-09 14:09:12 PST
(In reply to Tim Horton from
comment #9
)
> (In reply to Alex Christensen from
comment #8
) > > Comment on
attachment 443640
[details]
> > Patch > > > > View in context: > >
https://bugs.webkit.org/attachment.cgi?id=443640&action=review
> > > > >> Tools/TestWebKitAPI/DeprecatedGlobalValues.h:33 > > >> +extern bool receivedScriptMessage; > > > > > > I do not love *this* whole thing, would be better to fix the tests to use local `__block bool`s like we often do, or maybe these names in a per-test namespace? As it stands this makes the tests oddly not self-contained. I guess it's not the worst thing, though. > > > > I don't love this whole thing either, but this gives us the benefits now. I > > called it DeprecatedGlobalValues.h because we shouldn't increase the use of > > this. We can go through and make all the tests only use local values and > > decrease the use of this file, but that's slow, low-priority work. > > Makes sense.
Yeah, I think this is a tiny bit unfortunate but (in practice) a non-issue since TestWebKitAPI is relaunched for each API test. We should consider cleaning these global variables up to use local variables (or otherwise find a way to encapsulate this state per-test) so that we can parallelize API test execution in the future.
> > > >> Tools/TestWebKitAPI/Scripts/generate-unified-sources.sh:18 > > >> +UnifiedSourceMmFileCount=50 > > > > > > Why so big, and why so big only for ObjC? This is the balance between fast incremental builds and fast world builds. > > > > This patch only adds unified sources from TestWebKitAPI/Tests/WebKitCocoa > > which only contains .mm files, so that is the only limit that needs > > increasing in this patch. > > This is a slight overshot, but not much. It will make it so we don't need > > to increase this limit immediately after adding the next file. > > Oh oh oh wait, I misremembered; this isn't the "how many per bundle" count > that I thought it was, this is just the total number of files. OK, fine.
Alex Christensen
Comment 11
2021-11-09 14:36:56 PST
Created
attachment 443732
[details]
Patch
Alex Christensen
Comment 12
2021-11-09 17:05:36 PST
http://trac.webkit.org/r285547
Radar WebKit Bug Importer
Comment 13
2021-11-09 17:06:33 PST
<
rdar://problem/85230604
>
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