Working with masm for ml64, I'm trying to move 2 unsigned qwords from r9 and r10 into xmm0 as an unsigned 128b int
So far I came up with this:
mov r9, 111 ;low qword for test
mov r10, 222 ;high qword for test
movq xmm0, r9 ;move low to xmm0 lower bits
movq xmm1, r10 ;move high to xmm1 lower bits
pslldq xmm1, 4 ;shift xmm1 lower half to higher half
por xmm0, xmm1 ;or the 2 halves together
I think it works because
movq rax, xmm0
returns the correct low value
psrldq xmm0, 4
movq rax, xmm0
returns the correct high value
Question is though, is there a better way to do it? I'm browsing the intel intrinsic guide but I'm not very good at guessing the names for whatever instructions they may possibly have.