Ale*_*lex 5 c c++ assembly sse
如何只获取float的整数部分?所以,我有一个浮点数组:x [4] = {5.0,13.0,25.0,41.0}; 我把它放在xmm0然后我正在制作它的sqrt.我还需要一个命令来帮助只占用这个sqrt的int部分.例如,5的sqrt将是2.236068,我在答案
代码中只需要2.0 :
__asm
{
movups xmm0, x
sqrtps xmm0, xmm0
//here need some command
movups x, xmm0
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
337 次 |
| 最近记录: |