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

    <tr>
        <th>Summary</th>
        <td>
            [libc++] Consider enabling fast hardening mode (or extensive) when optimizations are disabled
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            libc++,
            hardening
      </td>
    </tr>

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

    <tr>
      <th>Reporter</th>
      <td>
          ldionne
      </td>
    </tr>
</table>

<pre>
    We can take for granted that someone building with `-O0` is doing some kind of debug build and doesn't care too much about performance. So it would probably make sense to enable the fast hardening mode (at least) in that case.

libstdc++ has done this: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112808
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJx0kruOpDwQhZ_GJKVBpmigCQjmItI_-IMNV74UUDvGbtlmemeefuXp3otW2ghUch2dc75SKfHqiSbRPQlEZzl4TwJRdC-VOvIW4nQfVjrY9-kLgVEesnolWEKENSqfyULeVIYUdgqeQB_sLPsVrpw3EL18-E-KXgInsKHMy0N4ZW8hLGBJH-ttB5S3YAMlL3DIYFQkyCHAfpgNlA5HhgvFJcRdeUM1_B-AM1zD4SxcYtBKu3fYi7dEPpVdIK-0I8gbwaJShk1FS76Y2IMlEHhWGRyplAWOwP6WxKhEtZCPQj461ilbI_BJ4BNsqmTwRZCTaB9hy_lSfgTOAufVmHr1Rx3iKnDWx_rBzimBc9rC9as-1tqsLNqZrWhfmgbP8lzZqbVjO6qKpmZo-_MgpRyrbWp7e9Jm6c1gaTnbZaDBWhyXXvUjdaOteEKJnWyaU9N1LY41mcGM_WJlR4Mel0WcJO2KXe3c2148VZzSQVODOGJXOaXJpZ_oWd8zFvr4LBB_VXW_hzgVnQd9rEmcpOOU02_lzNl9ntEfQt0LPAef2FK8cSi1_4NCiEDfM_nEb1RIXDfyEC6Zd_5QmYNPUK7Bcio8bXVEN_3VPeft0LUJu8C5-Lp_Hi4xfCOTBc6f8ZPA-d7A24Q_AgAA__-pR_1X">