At most callsites of AXObjectCache::get and AXObjectCache::getOrCreate, we already know the Node* / RenderObject* / Widget* is not null, but we still perform an extra null check in these methods anyways, which is a waste. And looking at the assembly generated by clang, it's not smart enough to optimize the null checks away itself in any of these contexts.
<rdar://problem/125689037>
Created attachment 470689 [details] Patch
Comment on attachment 470689 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=470689&action=review > Source/WebCore/accessibility/AXObjectCache.h:301 > + AccessibilityObject* get(Node* node) const does it make sense to make these inline?
Created attachment 470712 [details] Patch
(In reply to chris fleizach from comment #3) > Comment on attachment 470689 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=470689&action=review > > > Source/WebCore/accessibility/AXObjectCache.h:301 > > + AccessibilityObject* get(Node* node) const > > does it make sense to make these inline? Yeah I think so, done in latest patch!
Committed 276927@main (c608d5842016): <https://commits.webkit.org/276927@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 470712 [details].