github.com/zuoyebang/bitalosdb@v1.1.1-0.20240516111551-79a8c4d8ce20/internal/bindex/match.s (about)

     1  //go:build amd64
     2  
     3  #include "textflag.h"
     4  
     5  TEXT ·MatchMetadata(SB), NOSPLIT, $0-18
     6  	MOVQ     metadata+0(FP), AX
     7  	MOVBLSX  hash+8(FP), CX
     8  	MOVD     CX, X0
     9  	PXOR     X1, X1
    10  	PSHUFB   X1, X0
    11  	MOVOU    (AX), X1
    12  	PCMPEQB  X1, X0
    13  	PMOVMSKB X0, AX
    14  	MOVW     AX, ret+16(FP)
    15  	RET