]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/test_emulate_step: Add testcases for divde[.] and divdeu[.] instructions
authorBalamuruhan S <bala24@linux.ibm.com>
Tue, 28 Jul 2020 13:03:08 +0000 (18:33 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 29 Jul 2020 13:47:52 +0000 (23:47 +1000)
commitc1b642b985da0571d46457c0ce3b0d9ae44019c1
tree921ab79d7fb91870ffe0e83a2a6a7ebeeb7ab07d
parentd66e0c987c35f53b8b9d8744fb47e29dd79e31cc
powerpc/test_emulate_step: Add testcases for divde[.] and divdeu[.] instructions

Add testcases for divde, divde., divdeu, divdeu. emulated instructions
to cover few scenarios,
  - with same dividend and divisor to have undefine RT
    for divdeu[.]
  - with divide by zero to have undefine RT for both
    divde[.] and divdeu[.]
  - with negative dividend to cover -|divisor| < r <= 0 if
    the dividend is negative for divde[.]
  - normal case with proper dividend and divisor for both
    divde[.] and divdeu[.]

Signed-off-by: Balamuruhan S <bala24@linux.ibm.com>
Reviewed-by: Sandipan Das <sandipan@linux.ibm.com>
Acked-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200728130308.1790982-4-bala24@linux.ibm.com
arch/powerpc/lib/test_emulate_step.c