| Ticket UUID: | 2952904 | ||
| Title: | "floating point assist fault" on IA64 during Tcl startup | ||
| Type: | Bug | Created on: | 2010-02-16 17:35:29 |
| Submitter: | rmax | Assigned to: | rmax |
| Subsystem: | 48. Number Handling | Severity: | |
| Priority: | 1 Zero | Last modified: | 2026-10-22 17:19:29 |
| Status: | Closed | Closed by: | serhiy.storchaka |
| Resolution: | Fixed | Closed on: | 2026-10-21 10:03:35 |
| Version: | None | ||
| Description: | ||||
The line tiny = SafeLdExp(1.0, DBL_MIN_EXP * log2FLT_RADIX - mantBits); from TclInitDoubleConversion() causes a "floating-point assist fault" to be written to the system log on Linux/IA64. | ||||
| User Comments: | ||||
kennykb added on 2010-02-19 09:52:14:
The attached patch does the following things: It removes the constant 'tiny' which holds the smallest floating point number that is still greater than zero. It replaces a comparison 'retval < tiny' with 'retval <= 0.0', which is logically equivalent. It replaces an assignment from the 'tiny' constant with fabricating the number when the assignment takes place - note that this will cause floating point software assist only when the eventual return value will be a denormal. And it removes the run-time initialization of 'tiny'. This should avoid the spurious log message at initialization time, and cause log messages to appear only when denormals are produced. kennykb added on 2010-02-19 09:52:43:
File Added - 363529: 2952904.patch kennykb added on 2010-02-19 09:58:07:
IMO a regression test is difficult to develop because the SWFPA behaviour is not observable directly to the process; the only way to detect the problem is for a root process to examine the syslog output (which can be disabled in any case) on an IA64 machine. I don't have suitable hardware available to develop the test, so I'm assigning to rmax. The patch should not be committed without an appropriate test case. nijtmans added on 2010-05-19 18:42:19:
This fix caused [Bug #2996549] in HEAD, so whenever this fix is backported to the 8.5 branch, at least #2996549 should be backported along with it. nijtmans added on 2010-05-19 18:49:55:
File Added - 374432: 2952904_2.patch nijtmans added on 2010-05-19 18:51:05:
Or, just apply the corrected fix 2952904_2.patch to the 8.5 branch. serhiy.storchaka added on 2026-10-21 10:03:35:
Fixed by [0ff9783605] and the follow-up [0958a5f61a] (8.6.0; backported to 8.5.10): the smallest denormal is no longer computed at startup. Present in all current branches. | ||||
Attachments:
- 2952904_2.patch [download] added by nijtmans on 2010-05-19 18:49:55. [details]
- 2952904.patch [download] added by kennykb on 2010-02-19 09:52:42. [details]
