aboutsummaryrefslogtreecommitdiff
path: root/riscv/insns/khmbt16.h
blob: 4bb1f48c8c171ef01be9f93fc72ffe072e7ee4fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
require_vector_vs;
require_rv64;
P_LOOP(32, {
  int32_t aop = P_SH(ps1, 0);
  int32_t bop = P_SH(ps2, 1);  
  if ((INT16_MIN != aop) | (INT16_MIN != bop)) {
    pd = aop * bop;
    pd >>= 15;
  } else {
    pd = INT16_MAX;
    P_SET_OV(1);
  }
  pd = (int16_t)pd;
})