<html>#2376: PreSync's HasAccess check only checks CCTK_REAL grid functions
<table style='border-spacing: 1ex 0pt; '>
<tr><td style='text-align:right'> Reporter:</td><td>Roland Haas</td></tr>
<tr><td style='text-align:right'> Status:</td><td>new</td></tr>
<tr><td style='text-align:right'>Milestone:</td><td></td></tr>
<tr><td style='text-align:right'> Version:</td><td></td></tr>
<tr><td style='text-align:right'> Type:</td><td>bug</td></tr>
<tr><td style='text-align:right'> Priority:</td><td>major</td></tr>
<tr><td style='text-align:right'>Component:</td><td>Carpet</td></tr>
</table>
<p>The HasAccess implementation in Carpet currently <a data-is-external-link="true" href="https://bitbucket.org/eschnett/carpet/commits/3acfebf12c9b12baea742591b72f68480dcefdc8" rel="nofollow">3acfebf1</a> reads something like:</p>
<div class="codehilite language-c++"><pre><span></span> <span class="k">if</span><span class="p">(</span><span class="n">type</span> <span class="o">==</span> <span class="n">CCTK_GF</span> <span class="o">&&</span> <span class="n">CCTK_VarTypeSize</span><span class="p">(</span><span class="n">CCTK_VarTypeI</span><span class="p">(</span><span class="n">var_index</span><span class="p">))</span> <span class="o">==</span> <span class="k">sizeof</span><span class="p">(</span><span class="n">CCTK_REAL</span><span class="p">))</span> <span class="p">{</span>
<span class="n">var_tuple</span> <span class="n">vi</span><span class="p">{</span><span class="n">var_index</span><span class="p">,</span><span class="o">-</span><span class="mi">1</span><span class="p">,</span><span class="mi">0</span><span class="p">};</span>
<span class="k">if</span><span class="p">(</span><span class="n">hasAccess</span><span class="p">(</span><span class="n">reads</span><span class="p">[</span><span class="n">current_routine</span><span class="p">],</span><span class="n">vi</span><span class="p">))</span>
<span class="k">return</span> <span class="nb">true</span><span class="p">;</span>
<span class="k">if</span><span class="p">(</span><span class="n">hasAccess</span><span class="p">(</span><span class="n">writes</span><span class="p">[</span><span class="n">current_routine</span><span class="p">],</span><span class="n">vi</span><span class="p">))</span>
<span class="k">return</span> <span class="nb">true</span><span class="p">;</span>
<span class="k">if</span><span class="p">(</span><span class="n">hasAccess</span><span class="p">(</span><span class="n">tmp_read</span><span class="p">,</span><span class="n">vi</span><span class="p">))</span> <span class="p">{</span>
<span c
<p>--<br/>
Ticket URL: <a href='https://bitbucket.org/einsteintoolkit/tickets/issues/2376/presyncs-hasaccess-check-only-checks'>https://bitbucket.org/einsteintoolkit/tickets/issues/2376/presyncs-hasaccess-check-only-checks</a></p>
</html>