<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/69779>69779</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
shift count is negative in int_to_fp_impl for arm64-apple-ios11.0-simulator
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
itf
</td>
</tr>
</table>
<pre>
After this commit: https://github.com/llvm/llvm-project/commit/6dfea561ba96974b205c31546c5e2069429c75b1,
I see the error:
```
/int_to_fp_impl.inc:60:29: error: shift count is negative [-Werror,-Wshift-count-negative]
60 | const int dstExpBias = (1 << (dstExpBits - 1)) - 1;
| ^ ~~~~~~~~~~~~~~~~
1 error generated.
```
to reproduce:
```
clang -nostdlibinc compiler-rt/lib/builtins/floatuntitf.c -fsyntax-only -target arm64-apple-ios11.0-simulator
```
the error seems to be caused by wrongly assuming the size of a `long double`
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyUU8GOpDYQ_RpzKdEyNobxgUNPz7aUL9jjyDYF7cjYyC52t3PIt0fQ2xklmkRahMBWPZer6r1nSvFzRByYemXqrTIb3VIePE2VTeN9OE-EGejmC7i0LJ6YPMONaC1Mnpm4MnGdPd02e3JpYeIawrfnr15z-h0dMXH9eVRcu3FCo7rGGt3pvrWCKycb1XZOoeCdboV2vbINExdg_I3x8-P7GxREoBsC5pzyfvcj2vGf72Mrrj7SO6X3aX33yxpOPjomzx1n8iz0XvvzPJSbnwhc2iKBLxBxNuS_ITD1Wn99oMSl_nrA6gNWPzFMvT3uA4COA-svAOBSLAQ-EoyFvvxYX70pwOQbMPHSAJMXJi_7-hmlAjU0TGgm9LGSr38nBTiSMvUF4M9_PQ9Q82gEZoyYDeF4-nQglCDjmtO4OfwY2mdIF0ycoY6p0Bi89dHthK8-YK7zTl3wlomr3XwgHwsT1ykkQ1skT9PJQT2VeyTzo04x3KEmk2ckMHnp2tqsa8Dap9I0J14Xv2zBUMqfU_io-8n0zvtSgBJYBGe2giPYO3zPKc7hDqaUbfFxPqRR_B8IaQIDrOMhxRnGtNmArOPVOMhRS20qHJpO9y9StV1f3Qau0DpuXdNao3FqHU4vxnHljH4Z9dRWfhBcyIYLLrjq2_4klbK2G0cp7cSVHlnLcTE-nHbNn1KeK1_KhkOn-15XwVgM5XCXEBG_wxFkQuxmy8PhE7vNhbU8-ELlIwt5Cjj8l0p9hH8qHaaU_3_c1ZbD8MvWPerd6T76-SsAAP__c8xPBw">