1/1

|
What is the current Floating-Point Status?
by tarekeldeeb on Jun 28, 2012 |
tarekeldeeb
Posts: 4 Joined: Sep 9, 2008 Last seen: Mar 12, 2024 |
||
|
Hello all,
I'm little confused about the status of Floating-point support in the or1200. I see single/double FP in the OR1000 specs, and only single FP in the OR1200 implementation, that's fine. I see "or1200-fp.S" tests in trunk/orpsocv2/sw/tests/or1200/sim which does HW (apparent in the rtl simulation) computation. I see other tests (like or1200-float.c) not using the HW FPU, even if the Makefile is modified as: # All hardware flags MARCH_FLAGS ?=-mhard-mul -mhard-div -mhard-float Is the problem with the GCC not emitting the FPU opcodes? What other problem sources can lead to this behaviour? Thanks in advance, Tarek |
|||
|
RE: What is the current Floating-Point Status?
by jeremybennett on Jun 28, 2012 |
jeremybennett
Posts: 815 Joined: May 29, 2008 Last seen: Jun 13, 2019 |
||
|
Hi Tarek, There was another thread on this recently. It seems that GCC does not correctly issue floating point hardware instructions (at least for compare operations). The release was regression tested with software floating point only (which does work correctly). You might like to try running GCC regression wiht -mhard-float to see what tests fail. That will give us something to work on. HTH Jeremy
-- |
|||
|
RE: What is the current Floating-Point Status?
by tarekeldeeb on Jun 28, 2012 |
tarekeldeeb
Posts: 4 Joined: Sep 9, 2008 Last seen: Mar 12, 2024 |
||
|
Hello,
I don't know how to run GCC regression tests, But the orpsoc2 test (or1200-fp.S) report the following single-precision floating-point failures: 1.0 * 2^127 + 1.0 * 2^127 = +inf: Failed report(0x7f7fffff); -1.0 * 2^127 + -1.0 * 2^127 = -inf: Failed report(0xff7fffff); +inf - +inf = -NaN: Failed report(0x7fc00000); -NaN - -NaN = -NaN: Failed report(0x7fc00000); 1.0 - +sNaN = +qNaN: Failed report(0x7fc00000); 1.0 - -sNaN = -qNaN: Failed report(0xffc00000); +inf / +inf = -NaN: Failed report(0x7fc00000); -inf / -inf = -NaN: Failed report(0x7fc00000); -1.0 / +NaN = +NaN: Failed report(0xffc00000); -1.0 / -NaN = -NaN: Failed report(0x7fc00000); +NaN / -1.0 = +NaN: Failed report(0xffc00000); -NaN / -1.0 = -NaN: Failed report(0x7fc00000); +NaN / -NaN = +NaN: Failed report(0xffc00000); -NaN / -NaN = -NaN: Failed report(0x7fc00000); 1.0 * 2^127 / 1.0 * 2^-129 = +inf: Failed report(0x7f7fffff); -1.0 * 2^127 / -1.0 * 2^-129 = +inf: Failed report(0x7f7fffff); 1.0 * 2^-129 / 1.0 * 2^127 = +0.0: Failed report(0x00800000); -1.0 * 2^-129 / 1.0 * 2^127 = -0.0: Failed report(0x80800000); 1.0 * 2^-129 / -1.0 * 2^127 = -0.0: Failed report(0x80800000); -1.0 * 2^-129 / -1.0 * 2^127 = +0.0: Failed |
|||
|
RE: What is the current Floating-Point Status?
by jeremybennett on Jun 29, 2012 |
jeremybennett
Posts: 815 Joined: May 29, 2008 Last seen: Jun 13, 2019 |
||
|
Hi Tarek Thanks for this. Would you file a bug report in Bugzilla against GCC (http://bugzilla.opencores.org/). That way the issue won't be forgotten. Best wishes, Jeremy |
|||
1/1

