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

    <tr>
        <th>Summary</th>
        <td>
            [libc] remove `-O3` from build rules
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            cmake,
            libc
      </td>
    </tr>

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

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

<pre>
    Forking the discussion from [here](https://github.com/llvm/llvm-project/pull/88054#discussion_r1795989138) (cc @jyknight ).  I don't think we should be hard coding `-O3` throughout our cmake build files. Not only is it tedious, but it's very likely we will have customers that would prefer a binary sized optimized build (`-Os`).  Instead, I think the widely understood `CMAKE_BUILD_TYPE` should be used to key off whether we should be building with `-O2` vs `-Os`.  If we need `-O3`, I think it would be good to understand where+why.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyUk81yozoQhZ-m2XTFBQ3YsGARx3FV6v4u7l3MKiVQgxTLyKUfu5innxJJxpnlrEAL9fnO0WnhvZ5m5g7qPdSHTMSgrOtmPZwkexHNrNn5rLdy6Y7WnfQ8YVCMUvsheq_tjKOzZ4R6r9gx1AegRoVw8VA-Ah2BjpMOKvabwZ6BjsZcPz8PF2ffeAhAx0s0BujYNHldAZX34a-u2LV127RF2QC1CNQMA0KVvy2nWU8qIFC7QXxBaWegXcCg9HzCG6NXNhqJPaMSTuJgZWKHbf7wTwnbHINyNk7KxoA2OhzO4sTYR20kjtqw3-DfNqCdzYLaow4YWGobPdAT9jGgDkA7j1d2Cxp9YrMk1Zs2BpW4Mg7RB3tm5zEoEfC20lwcj-xQYK9n4Rb0-jtLtJegz-vfuz5Qs3J62OYf_mYfWMik_fJhMb3CTcukG2fJzgdrZfL39NfjH8-v-_9f_jy8_vft3-dk9h5G9CwxWDzxgnYc8aY4KHa_JrZipLhuOqj3zCiNuXr8CZaoxnRtZpb3XL8i6k_bPeOU6IL9ZBWzTNKOgfY3tWwy2ZWyLVuRcVfsqM2LsmmaTHVlXdRUNG3RFiQLMZbbqi-2LW139dDWtMt0RzlVRV7Uxa5s8mYjOeexangYypIaUUGV81los0ml21g3Zdr7yF1RUJW3mRE9G7_2n2htARABPQGR0f2QDvUhc91a2T5OHqrcaB_8fV7QwawbtF6oD-j4bK_8pWzrjrw_rouGfRad6X57TVZuD3T8QL929CMAAP__kMs1Fw">