<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>132581</bug_id>
          
          <creation_ts>2014-05-05 14:37:53 -0700</creation_ts>
          <short_desc>REGRESSION: RELEASE_ASSERT in CodeBlock::baselineVersion @ cnn.com</short_desc>
          <delta_ts>2014-05-07 13:02:49 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Michael Saboff">msaboff</reporter>
          <assigned_to name="Michael Saboff">msaboff</assigned_to>
          <cc>ggaren</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1006740</commentid>
    <comment_count>0</comment_count>
    <who name="Michael Saboff">msaboff</who>
    <bug_when>2014-05-05 14:37:53 -0700</bug_when>
    <thetext>We crash with the following traceback:
0   JavaScriptCore                      0x00000001005e1ac8 WTFCrash + 72
1   JavaScriptCore                      0x0000000100297a88 JSC::CodeBlock::baselineVersion() + 148
2   JavaScriptCore                      0x000000010031d684 JSC::DFG::JITFinalizer::finalizeCommon() + 124
3   JavaScriptCore                      0x000000010031d784 JSC::DFG::JITFinalizer::finalizeFunction() + 224
4   JavaScriptCore                      0x000000010033fe44 JSC::DFG::Plan::finalizeWithoutNotifyingCallback() + 188
5   JavaScriptCore                      0x000000010033ff50 JSC::DFG::Plan::finalizeAndNotifyCallback() + 36
6   JavaScriptCore                      0x00000001003ac9e8 JSC::DFG::Worklist::completeAllReadyPlansForVM(JSC::VM&amp;, JSC::DFG::CompilationKey) + 340
7   JavaScriptCore                      0x0000000100403358 operationOptimize + 552
8   ???                                 0x00000001061c40c4 0 + 4397482180
9   JavaScriptCore                      0x00000001004c03dc llint_op_call + 180
10  JavaScriptCore                      0x00000001004c0440 llint_op_call + 280
11  JavaScriptCore                      0x00000001004c0570 llint_op_construct + 236
12  ???                                 0x0000000106144c3c 0 + 4396960828
13  JavaScriptCore                      0x00000001004bb238 callToJavaScript + 304
14  JavaScriptCore                      0x00000001003ee37c JSC::JITCode::execute(JSC::VM*, JSC::ProtoCallFrame*) + 44
15  JavaScriptCore                      0x00000001003db6f4 JSC::Interpreter::execute(JSC::ProgramExecutable*, JSC::ExecState*, JSC::JSObject*) + 2940
16  JavaScriptCore                      0x00000001002abd48 JSC::evaluate(JSC::ExecState*, JSC::SourceCode const&amp;, JSC::JSValue, JSC::JSValue*) + 452
17  WebCore                             0x000000010145c224 WebCore::ScriptController::evaluateInWorld(WebCore::ScriptSourceCode const&amp;, WebCore::DOMWrapperWorld&amp;) + 280
18  WebCore                             0x000000010145c42c WebCore::ScriptController::evaluate(WebCore::ScriptSourceCode const&amp;) + 48
19  WebCore                             0x00000001014618f4 WebCore::ScriptElement::executeScript(WebCore::ScriptSourceCode const&amp;) + 592
20  WebCore                             0x00000001014604d0 WebCore::ScriptElement::prepareScript(WTF::TextPosition const&amp;, WebCore::ScriptElement::LegacyTypeSupport) + 1064
21  WebCore                             0x0000000100d74428 WebCore::HTMLScriptRunner::runScript(WebCore::Element*, WTF::TextPosition const&amp;) + 264
22  WebCore                             0x0000000100d742c0 WebCore::HTMLScriptRunner::execute(WTF::PassRefPtr&lt;WebCore::Element&gt;, WTF::TextPosition const&amp;) + 60
23  WebCore                             0x0000000100d1b164 WebCore::HTMLDocumentParser::runScriptsForPausedTreeBuilder() + 76
24  WebCore                             0x0000000100d1b208 WebCore::HTMLDocumentParser::canTakeNextToken(WebCore::HTMLDocumentParser::SynchronousMode, WebCore::PumpSession&amp;) + 104
25  WebCore                             0x0000000100d1aef8 WebCore::HTMLDocumentParser::pumpTokenizer(WebCore::HTMLDocumentParser::SynchronousMode) + 360
26  WebCore                             0x0000000100d1baa0 WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution() + 104
27  WebCore                             0x0000000100d1bcdc non-virtual thunk to WebCore::HTMLDocumentParser::notifyFinished(WebCore::CachedResource*) + 96
28  WebCore                             0x00000001009becd8 WebCore::CachedResource::checkNotify() + 268
29  WebCore                             0x00000001015066b8 WebCore::SubresourceLoader::didFinishLoading(double) + 108
30  CFNetwork                           0x00000001866ae168 ___ZN27URLConnectionClient_Classic26_delegate_didFinishLoadingEU13block_pointerFvvE_block_invoke + 100
31  CFNetwork                           0x0000000186767298 ___ZN27URLConnectionClient_Classic18_withDelegateAsyncEPKcU13block_pointerFvP16_CFURLConnectionPK33CFURLConnectionClientCurrent_VMaxE_block_invoke_2 + 92
32  CoreFoundation                      0x0000000186bac000 CFArrayApplyFunction + 64
33  CFNetwork                           0x000000018669be0c RunloopBlockContext::perform() + 132
34  CFNetwork                           0x000000018669bcc0 MultiplexerSource::perform() + 308
35  CFNetwork                           0x000000018669bae4 MultiplexerSource::_perform(void*) + 56
36  CoreFoundation                      0x0000000186c80d34 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 20
37  CoreFoundation                      0x0000000186c80050 __CFRunLoopDoSources0 + 240
38  CoreFoundation                      0x0000000186c7e2c4 __CFRunLoopRun + 696
39  CoreFoundation                      0x0000000186bac61c CFRunLoopRunSpecific + 384
40  WebCore                             0x00000001015c38c8 RunWebThread(void*) + 468
41  libsystem_pthread.dylib             0x0000000195ea4000 _pthread_body + 160
42  libsystem_pthread.dylib             0x0000000195ea3f5c _pthread_start + 136
43  libsystem_pthread.dylib             0x0000000195ea1430 thread_start + 0</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1006746</commentid>
    <comment_count>1</comment_count>
      <attachid>230856</attachid>
    <who name="Michael Saboff">msaboff</who>
    <bug_when>2014-05-05 14:59:33 -0700</bug_when>
    <thetext>Created attachment 230856
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1006751</commentid>
    <comment_count>2</comment_count>
    <who name="Michael Saboff">msaboff</who>
    <bug_when>2014-05-05 15:09:48 -0700</bug_when>
    <thetext>Committed r168319: &lt;http://trac.webkit.org/changeset/168319&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1006776</commentid>
    <comment_count>3</comment_count>
      <attachid>230856</attachid>
    <who name="Geoffrey Garen">ggaren</who>
    <bug_when>2014-05-05 16:34:04 -0700</bug_when>
    <thetext>Comment on attachment 230856
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=230856&amp;action=review

&gt; Source/JavaScriptCore/ChangeLog:11
&gt; +        (JSC::DFG::Plan::isStillValid): Check that the alternative codeBlock we
&gt; +        started compiling for is still the same at the end of compilation.
&gt; +        Also did some minor restructuring.

Why might they be different? Please explain.

Please add a regression test.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1006781</commentid>
    <comment_count>4</comment_count>
    <who name="Michael Saboff">msaboff</who>
    <bug_when>2014-05-05 16:43:58 -0700</bug_when>
    <thetext>(In reply to comment #3)
&gt; (From update of attachment 230856 [details])
&gt; View in context: https://bugs.webkit.org/attachment.cgi?id=230856&amp;action=review
&gt; 
&gt; &gt; Source/JavaScriptCore/ChangeLog:11
&gt; &gt; +        (JSC::DFG::Plan::isStillValid): Check that the alternative codeBlock we
&gt; &gt; +        started compiling for is still the same at the end of compilation.
&gt; &gt; +        Also did some minor restructuring.
&gt; 
&gt; Why might they be different? Please explain.

Because we cleared the code blocks of the executable during GC.

&gt; Please add a regression test.

Given that the issue is the result of a GC while we have compilation(s) queued up or needing finalization, I think it would difficult to write a deterministic test.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1007157</commentid>
    <comment_count>5</comment_count>
    <who name="Michael Saboff">msaboff</who>
    <bug_when>2014-05-06 17:36:26 -0700</bug_when>
    <thetext>(In reply to comment #3)
&gt; (From update of attachment 230856 [details])
&gt; View in context: https://bugs.webkit.org/attachment.cgi?id=230856&amp;action=review
&gt; 
&gt; &gt; Source/JavaScriptCore/ChangeLog:11
&gt; &gt; +        (JSC::DFG::Plan::isStillValid): Check that the alternative codeBlock we
&gt; &gt; +        started compiling for is still the same at the end of compilation.
&gt; &gt; +        Also did some minor restructuring.
&gt; 
&gt; Why might they be different? Please explain.
&gt; 
&gt; Please add a regression test.

New test tracked in https://bugs.webkit.org/show_bug.cgi?id=132632 and landed in change set r168396: &lt;http://trac.webkit.org/changeset/168396&gt;.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1007405</commentid>
    <comment_count>6</comment_count>
    <who name="Geoffrey Garen">ggaren</who>
    <bug_when>2014-05-07 13:02:49 -0700</bug_when>
    <thetext>&lt;rdar://problem/15961859&gt;</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>230856</attachid>
            <date>2014-05-05 14:59:33 -0700</date>
            <delta_ts>2014-05-05 16:34:04 -0700</delta_ts>
            <desc>Patch</desc>
            <filename>132581.patch</filename>
            <type>text/plain</type>
            <size>1575</size>
            <attacher name="Michael Saboff">msaboff</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9KYXZhU2NyaXB0Q29yZS9DaGFuZ2VMb2cKPT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQotLS0gU291
cmNlL0phdmFTY3JpcHRDb3JlL0NoYW5nZUxvZwkocmV2aXNpb24gMTY4MzE3KQorKysgU291cmNl
L0phdmFTY3JpcHRDb3JlL0NoYW5nZUxv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dvcmtpbmcgY29weSkKQEAg
LTM4Myw4ICszODMsMTYgQEAgUGxhbjo6Q29tcGlsYXRpb25QYXRoIFBsYW46OmNvbXBpbGVJblRo
cgogCiBib29sIFBsYW46OmlzU3RpbGxWYWxpZCgpCiB7Ci0gICAgcmV0dXJuIHdhdGNocG9pbnRz
LmFyZVN0aWxsVmFsaWQoKQotICAgICAgICAmJiBjaGFpbnMuYXJlU3RpbGxWYWxpZCgpOworICAg
IENvZGVCbG9jayogcmVwbGFjZW1lbnQgPSBjb2RlQmxvY2stPnJlcGxhY2VtZW50KCk7CisgICAg
aWYgKCFyZXBsYWNlbWVudCkKKyAgICAgICAgcmV0dXJuIGZhbHNlOworICAgIGlmIChjb2RlQmxv
Y2stPmFsdGVybmF0aXZlKCkgIT0gcmVwbGFjZW1lbnQtPmJhc2VsaW5lVmVyc2lvbigpKQorICAg
ICAgICByZXR1cm4gZmFsc2U7CisgICAgaWYgKCF3YXRjaHBvaW50cy5hcmVTdGlsbFZhbGlkKCkp
CisgICAgICAgIHJldHVybiBmYWxzZTsKKyAgICBpZiAoIWNoYWlucy5hcmVTdGlsbFZhbGlkKCkp
CisgICAgICAgIHJldHVybiBmYWxzZTsKKyAgICByZXR1cm4gdHJ1ZTsKIH0KIAogdm9pZCBQbGFu
OjpyZWFsbHlBZGQoQ29tbW9uRGF0YSogY29tbW9uRGF0YSkK
</data>
<flag name="review"
          id="255244"
          type_id="1"
          status="+"
          setter="fpizlo"
    />
          </attachment>
      

    </bug>

</bugzilla>