================
@@ -2975,6 +2975,75 @@ static bool interp__builtin_vec_set(InterpState &S,
CodePtr OpPC,
return true;
}
+static bool interp__builtin_x86_psrldq_byteshift(InterpState &S, CodePtr OpPC,
+ const CallExpr *Call,
+ unsigned ID) {
+ assert(Call->getNumArgs() == 2);
+
+ APSInt ImmAPS = popToAPSInt(S, Call->getArg(1));
+ uint64_t Shift = ImmAPS.getZExtValue();
+
+ const Pointer &Concat = S.Stk.pop<Pointer>();
+ if (!Concat.getFieldDesc()->isPrimitiveArray())
+ return false;
+
+ unsigned NumElems = Concat.getNumElems();
+ const Pointer &Dst = S.Stk.peek<Pointer>();
+ PrimType ElemPT = Concat.getFieldDesc()->getPrimType();
+
+ TYPE_SWITCH(ElemPT, {
+ for (unsigned I = 0; I < NumElems; ++I) {
----------------
TianYe717 wrote:
Done, thanks!
https://github.com/llvm/llvm-project/pull/162005
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits