<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/70187>70187</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [clang static analyzer] false negative related to alpha.security.ArrayBoundV2
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          hallo-mars
      </td>
    </tr>
</table>

<pre>
    For this case, If `l_2003[9][0]` is accessed, the analyzer would report "Out of bound memory access". However, when accessing `l_2003[9][0].a`, it doesn't. 

```c
struct S1 {
    unsigned a : 2
} b() {
    struct S1 l_2003[5][4] = {};
    l_2003[9][0].a;
}
int main() { b(); }
```

See it live: https://godbolt.org/z/cxYYv6vMv

Could you take a look when you have time? Many thanks!
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx0k81unDAQx59muIyCzPBhOHDYzQq1h6iHSJVyqgxMFjcGr2xDunn6CnazSStFQhiG33z8ZwblvT5OzDXke8gPkZrDYF09KGPs3aicj1rbn-vGOgyD9tgpz0D3-P0ZoRDmFwmRQr6vID9AvhfrUQjUHlXXsffcr3AYGNWkzPmNHb7a2fTo-GRdQCD6MQe0z9jaeepx5NG689UZiGL8Zl95YbeGeR14un7S0_Gr_LGCQqy4Dthb9hOQDDGCOIDYXe-FuFzd5d0HN3cBHxMEub-YEBHnaetNjwoh3SFdneUBW6ASqPoX_4hyKyu_lJVBfkBIDxsvD5B-8vpCwjuy4tuDngKOSk8fmd-rgHSPN-wm7bPeR-a1G0YvvAoZQjh5SHdADVBztH1rTYitOwI1b0BN9-fpaSmWh-VzjPttbGc7Y1AvjAqNtS-XkazGQS2MQY8MaYMPajpjGNT04oGSqK_TvkorFXGdFFVJJKWU0VDnZUVSdknellImrMpEljLPOurKjKusj3RNgtJEUC6qvEiKuO_TVmRVnnCa5V1ZQiZ4VNrExizjqiDS3s9cS5GUMjKqZeO3zSbqjJqOQLQuuatX_q6djx4yYbQP_iNC0MFsv8PmgT6ooLvb-q6TfFbGM058VEEvjI6NCtxjsKjMaVCx5252OpzjnXPqvF8X-ydFszP1f53XYZjbuLMjULPmvx53J2d_cxeAmk2OB2o2RX8DAAD__6IxEzs">