将霓虹灯向量寄存器存储到内存
这似乎是一个愚蠢的问题,但我无法为生活做出解决。
我有一个像缓冲区一样;
let result_buff: &[u8]
而且我有一些代码,例如
let anded_value: uint8x16_t = unsafe { vandq_u8(sa1, sa2) };
我只想将Vector寄存器的此结果复制到result_buff [x..16]
,可能是通过内在的?
基本上是16个字节,我需要制定语法将其复制到[u8]
/vec< u8>
中的特定位置。
This seems like a stupid question, but I can't for the life work out how to do it.
I have a buffer like;
let result_buff: &[u8]
and I have some code like
let anded_value: uint8x16_t = unsafe { vandq_u8(sa1, sa2) };
I just want to copy this result from the vector register to result_buff[x..16]
, probably via an intrinsic?
basically it's 16 bytes long and I need to work out the syntax to copy it to a particular position in the [u8]
/ Vec<u8>
.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
只需使用内在 :
Just use the intrinsic
vst1q_u8
:您可能会使它比实际更复杂;)
https://godbolt.org.org.org.org/z/6m94bh4pf <6m94bh4pf < /a>
You might be making it way more complicated than it actually is ;)
https://godbolt.org/z/6M94bh4Pf