Bug 247742 - Fix broken preferred widths optimization involving subtree layout roots
Summary: Fix broken preferred widths optimization involving subtree layout roots
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: Safari Technology Preview
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-11-10 09:42 PST by Ahmad Saleem
Modified: 2022-11-13 16:59 PST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ahmad Saleem 2022-11-10 09:42:40 PST
Hi Team,

While going through Blink commits, I came across following commit:

Link - https://chromium.googlesource.com/chromium/blink/+/ed902d339fbff3a62e2f6124d8d40bbad45e97c0

Which removed a hacky optimization added in 2006.

We still have this optimization here:

https://github.com/WebKit/WebKit/blob/fa2a14f12031baf24d5bc6d6727c3e25c5052589/Source/WebCore/rendering/RenderBox.cpp#LL2610

The testcase attached render same as Chrome Canary 109 as in Safari Technology Preview 157 and Safari 16.1:

Test Case - https://jsfiddle.net/m4hja1pv/show

But I think it would be better tested in EWS. I will tag @Alexey (ap), who landed this in 2006. Just to get his input.

Thanks!
Comment 1 EWS 2022-11-13 16:58:00 PST
Committed 256623@main (06fa3e82eb2e): <https://commits.webkit.org/256623@main>

Reviewed commits have been landed. Closing PR #6433 and removing active labels.
Comment 2 Radar WebKit Bug Importer 2022-11-13 16:59:18 PST
<rdar://problem/102298308>