+ OP(FILTER_OP_BIT_RSHIFT):
+ {
+ int64_t res;
+
+ /* Dynamic typing. */
+ if (estack_ax_t != REG_S64 || estack_bx_t != REG_S64) {
+ ret = -EINVAL;
+ goto end;
+ }
+ /* Catch undefined behavior. */
+ if (caa_unlikely(estack_ax_v < 0 || estack_ax_v >= 64)) {
+ ret = -EINVAL;
+ goto end;
+ }
+ res = ((uint64_t) estack_bx_v >> (uint32_t) estack_ax_v);
+ estack_pop(stack, top, ax, bx, ax_t, bx_t);
+ estack_ax_v = res;
+ estack_ax_t = REG_S64;
+ next_pc += sizeof(struct binary_op);
+ PO;
+ }
+ OP(FILTER_OP_BIT_LSHIFT):
+ {
+ int64_t res;
+
+ /* Dynamic typing. */
+ if (estack_ax_t != REG_S64 || estack_bx_t != REG_S64) {
+ ret = -EINVAL;
+ goto end;
+ }
+ /* Catch undefined behavior. */
+ if (caa_unlikely(estack_ax_v < 0 || estack_ax_v >= 64)) {
+ ret = -EINVAL;
+ goto end;
+ }
+ res = ((uint64_t) estack_bx_v << (uint32_t) estack_ax_v);
+ estack_pop(stack, top, ax, bx, ax_t, bx_t);
+ estack_ax_v = res;
+ estack_ax_t = REG_S64;
+ next_pc += sizeof(struct binary_op);
+ PO;
+ }