https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63260
Oleg Endo changed:
What|Removed |Added
CC||kkojima at gcc dot gnu.org
--- Comment #2 from Oleg Endo ---
(In reply to Oleg Endo from comment #0)
> Created attachment 33490 [details]
> Proposed patch
>
> The fabs and fneg insns do not require an FPSCR.PR or FPSCR.SZ mode setting
> as they operate on the high part of a double register pair. Thus they are
> the same for single and double precision
I've tested the proposed patch on sh-sim, there are some new failures:
-m4 -mb:
FAIL: g++.dg/torture/type-generic-1.C -O0 execution test
FAIL: gcc.c-torture/execute/builtins/complex-1.c execution, -O0
FAIL: gcc.c-torture/execute/builtins/complex-1.c execution, -Og -g
FAIL: gcc.c-torture/execute/complex-6.c -O0 execution test
FAIL: gcc.c-torture/execute/gofast.c -O0 execution test
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -O1
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -Og -g
FAIL: gcc.c-torture/execute/ieee/20030331-1.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/copysign1.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/mzero3.c execution, -O0
FAIL: gcc.dg/torture/type-generic-1.c -O0 execution test
-m4 -ml:
FAIL: g++.dg/torture/type-generic-1.C -O0 execution test
FAIL: g++.dg/torture/type-generic-1.C -O1 execution test
FAIL: g++.dg/torture/type-generic-1.C -O2 execution test
FAIL: g++.dg/torture/type-generic-1.C -O2 -flto -fno-use-linker-plugin
-flto-partition=none execution test
FAIL: g++.dg/torture/type-generic-1.C -O2 -flto -fuse-linker-plugin
-fno-fat-lto-objects execution test
FAIL: g++.dg/torture/type-generic-1.C -O3 -fomit-frame-pointer execution
test
FAIL: g++.dg/torture/type-generic-1.C -O3 -g execution test
FAIL: g++.dg/torture/type-generic-1.C -Os execution test
FAIL: gcc.c-torture/execute/builtins/complex-1.c execution, -O0
FAIL: gcc.c-torture/execute/builtins/complex-1.c execution, -Og -g
FAIL: gcc.c-torture/execute/complex-6.c -O0 execution test
FAIL: gcc.c-torture/execute/conversion.c -O0 execution test
FAIL: gcc.c-torture/execute/gofast.c -O0 execution test
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -O1
FAIL: gcc.c-torture/execute/ieee/20010114-2.c execution, -Og -g
FAIL: gcc.c-torture/execute/ieee/20030331-1.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/copysign1.c execution, -O0
FAIL: gcc.c-torture/execute/ieee/mzero3.c execution, -O0
FAIL: gcc.dg/pr28796-2.c execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O0 execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O1 execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O2 execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O2 -flto -fno-use-linker-plugin
-flto-partition=none execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O2 -flto -fuse-linker-plugin
-fno-fat-lto-objects execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O3 -fomit-frame-pointer
execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -O3 -g execution test
FAIL: gcc.dg/torture/fp-int-convert-float.c -Os execution test
FAIL: gcc.dg/torture/type-generic-1.c -O0 execution test
FAIL: gcc.dg/torture/type-generic-1.c -O1 execution test
FAIL: gcc.dg/torture/type-generic-1.c -O2 execution test
FAIL: gcc.dg/torture/type-generic-1.c -O2 -flto -fno-use-linker-plugin
-flto-partition=none execution test
FAIL: gcc.dg/torture/type-generic-1.c -O2 -flto -fuse-linker-plugin
-fno-fat-lto-objects execution test
FAIL: gcc.dg/torture/type-generic-1.c -O3 -fomit-frame-pointer execution
test
FAIL: gcc.dg/torture/type-generic-1.c -O3 -g execution test
FAIL: gcc.dg/torture/type-generic-1.c -Os execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O0 execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O1 execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O2 execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O2 -flto -fno-use-linker-plugin
-flto-partition=none execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O2 -flto -fuse-linker-plugin
-fno-fat-lto-objects execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O3 -fomit-frame-pointer execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O3 -fomit-frame-pointer -funroll-all-loops
-finline-functions execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O3 -fomit-frame-pointer -funroll-loops
execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -O3 -g execution test
FAIL: gcc.dg/torture/vec-cvt-1.c -Os execution test
This seems to be due to the implementation in GDB.
sim/sh/interp.c:
#define FP_UNARY(n, OP) \
{ \
if (FPSCR_PR) \
{ \
if ((n) & 1) \
RAISE_EXCEPTION (SIGILL); \
else