Bug 190105

Summary: Setting a style height value to the existing value still triggers a clone of StyleBoxData and thus slows down RenderStyle::diff
Product: WebKit Reporter: Simon Fraser (smfr) <simon.fraser>
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: koivisto, mitz, simon.fraser, zalan
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Simon Fraser (smfr)
Reported 2018-09-28 20:36:19 PDT
If script keeps setting style.height to the same value, RenderStyle::setHeight still triggers access() which clones StyleBoxData, thus making future calls to RenderStyle::diff slower, since the pointer comparison fails. Probably true of most of the DataRef<> types.
Attachments
Simon Fraser (smfr)
Comment 1 2018-09-29 11:54:49 PDT
Seen in MotionMark leaves test.
Simon Fraser (smfr)
Comment 2 2018-09-29 16:05:06 PDT
Actually SET_VAR() already does a compareEqual(), so we're good.
Note You need to log in before you can comment on or make changes to this bug.