[webkit-reviews] review denied: [Bug 95316] Refactoring LLInt::Data to be a singleton : [Attachment 161195] Fixed typo.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Aug 29 08:07:59 PDT 2012


Geoffrey Garen <ggaren at apple.com> has denied Mark Lam <mark.lam at apple.com>'s
request for review:
Bug 95316: Refactoring LLInt::Data to be a singleton
https://bugs.webkit.org/show_bug.cgi?id=95316

Attachment 161195: Fixed typo.
https://bugs.webkit.org/attachment.cgi?id=161195&action=review

------- Additional Comments from Geoffrey Garen <ggaren at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=161195&action=review


Looks good to me. I have one edit I'd like to see before marking this r+.

> Source/JavaScriptCore/llint/LLIntData.cpp:44
> +    if (!Data::s_isInitialized) {

Please remove s_isInitialized and this test of it. This test is neither
necessary nor sufficient for a thread-safe singleton. It isn't necessary
because you're using the initializeThreading() hook to ensure a thread-safe
singleton. It isn't sufficient because this branch isn't guarded by a lock.

Side note about WebKit style: When we do use checks like this, we prefer "if
(!condition) { early return }" style, to reduce the amount of indentation in a
function.


More information about the webkit-reviews mailing list