WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 138524
138617
Avoid looking up the type attribute twice in HTMLInputElement::ensureInputType()
https://bugs.webkit.org/show_bug.cgi?id=138617
Summary
Avoid looking up the type attribute twice in HTMLInputElement::ensureInputType()
Chris Dumez
Reported
2014-11-11 11:15:57 PST
We currently call hasAttribute(typeAttr) then if it returns true, we call fastGetAttribute(typeAttr). First of all, fastHasAttribute() would have been better as it would have avoided attribute synchronization. Secondly, We could call fastGetAttribute(typeAttr) directly and check if the returned value is nullAtom, instead of calling hasAttribute(). This way, we only do the linear attribute search once.
Attachments
Patch
(1.97 KB, patch)
2014-11-11 11:19 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(1.98 KB, patch)
2014-11-11 12:46 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2014-11-11 11:19:35 PST
Created
attachment 241365
[details]
Patch
Geoffrey Garen
Comment 2
2014-11-11 11:59:52 PST
Comment on
attachment 241365
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=241365&action=review
r=me
> Source/WebCore/ChangeLog:9 > + calling directly fastGetAttribute(typeAttr) and check if its returns
Should be "call" and "it" instead of "calling" and "its".
Chris Dumez
Comment 3
2014-11-11 12:46:04 PST
Created
attachment 241371
[details]
Patch
Chris Dumez
Comment 4
2014-11-11 15:49:26 PST
Merging into
Bug 138524
. *** This bug has been marked as a duplicate of
bug 138524
***
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