<?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>273228</bug_id>
          
          <creation_ts>2024-04-24 21:09:59 -0700</creation_ts>
          <short_desc>Disable use-after-return checking to fix JSC GC on ASan builds</short_desc>
          <delta_ts>2024-04-25 15:00:56 -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>Tools / Tests</component>
          <version>Other</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=273080</see_also>
          <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="David Kilzer (:ddkilzer)">ddkilzer</reporter>
          <assigned_to name="David Kilzer (:ddkilzer)">ddkilzer</assigned_to>
          <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2031080</commentid>
    <comment_count>0</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2024-04-24 21:09:59 -0700</bug_when>
    <thetext>Disable use-after-return checking to fix JSC garbage collection on ASan builds.

ASan use-after-return (UAR) checking allocates objects on a &quot;fake stack&quot; in order to detect UAR issues, but the JavaScriptCore garbage collector knows nothing of the &quot;fake stack&quot; (and thus does not scan it for live objects).  The garbage collector then assumes any object in the &quot;fake stack&quot; is no longer being referenced and can be freed, which results in false-positive use-after-free crashes.

The temporary fix is to disable use-after-return checking at compile time using `-fsanitize-address-use-after-return=never`.

At some point if ASan provides API to scan its &quot;fake stack&quot;, JSC GC could scan that on ASan builds, and this change could be reverted.

&lt;rdar://126269133&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2031082</commentid>
    <comment_count>1</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2024-04-24 21:17:06 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/27728</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2031226</commentid>
    <comment_count>2</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2024-04-25 11:10:30 -0700</bug_when>
    <thetext>Committed 277993@main (b59055bbf3f5): &lt;https://commits.webkit.org/277993@main&gt;

Reviewed commits have been landed. Closing PR #27728 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2031307</commentid>
    <comment_count>3</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2024-04-25 15:00:56 -0700</bug_when>
    <thetext>Committed 272448.961@safari-7618-branch (89f3455464b3): &lt;https://commits.webkit.org/272448.961@safari-7618-branch&gt;

Reviewed commits have been landed. Closing PR #1240 and removing active labels.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>