Bug 211965 - [patch] fmodl not properly aliased on architectures where LDBL_PREC == 53 (arm, mips, powerpc)
Summary: [patch] fmodl not properly aliased on architectures where LDBL_PREC == 53 (ar...
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-bugs (Nobody)
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2016-08-18 13:53 UTC by Kyle Evans
Modified: 2016-09-20 13:09 UTC (History)
0 users

See Also:


Attachments
diff(1) patch to properly alias fmodl on platforms where long double == double (263 bytes, patch)
2016-08-18 13:53 UTC, Kyle Evans
no flags Details | Diff
svn(1) diff of lib/msun/src, standardizing conditionals and properly aliasing fmodl (12.87 KB, patch)
2016-08-30 20:50 UTC, Kyle Evans
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle Evans freebsd_committer freebsd_triage 2016-08-18 13:53:39 UTC
Created attachment 173822 [details]
diff(1) patch to properly alias fmodl on platforms where long double == double

Noticed with the net/freerdp build log on ARMv6 [1], also previously noted at [2] and [3].

I am attaching a patch that addresses this in the exact fashion that this is resolved for all of the long 'long double' symbol aliases using [4] as a reference.

[1] http://files.kyle-evans.net/freebsd/freerdp-1.2.0_7.log
[2] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=199422
[3] https://lists.freebsd.org/pipermail/freebsd-bugs/2015-April/061672.html
[4] https://svnweb.freebsd.org/base/head/lib/msun/src/e_asin.c?view=markup#l115
Comment 1 Kyle Evans freebsd_committer freebsd_triage 2016-08-30 20:50:56 UTC
Created attachment 174233 [details]
svn(1) diff of lib/msun/src, standardizing conditionals and properly aliasing fmodl

As mentioned by Warner Losh [1], LDBL_MANT_DIG == 53 could be written as LDBL_MANT_DIG == DBL_MANT_DIG to better convey the intention of this block.

I've amended this to do that, as well as to give the same treatment to the other instances where the same meaning is intended. Also, I've standardized all of these to a form without parentheses enclosing the statement.

This could presumably be split out into a patch solely addressing the aliasing of fmodl and a patch addressing the consistency nits, but this is trivial enough that I left it alone.

[1] https://lists.freebsd.org/pipermail/freebsd-arm/2016-August/014604.html
Comment 2 commit-hook freebsd_committer freebsd_triage 2016-09-04 12:02:09 UTC
A commit references this bug:

Author: bde
Date: Sun Sep  4 12:01:32 UTC 2016
New revision: 305380
URL: https://svnweb.freebsd.org/changeset/base/305380

Log:
  Fix missing fmodl() on arches with 53-bit long doubles.

  PR:		199422, 211965
  MFC after:	1 week

Changes:
  head/lib/msun/src/e_fmod.c
Comment 3 commit-hook freebsd_committer freebsd_triage 2016-09-19 12:35:12 UTC
A commit references this bug:

Author: bde
Date: Mon Sep 19 12:34:29 UTC 2016
New revision: 305971
URL: https://svnweb.freebsd.org/changeset/base/305971

Log:
  MFC r305380:

  Fix missing fmodl() on arches with 53-bit long doubles.

  PR:		199422, 211965

Changes:
  stable/11/lib/msun/src/e_fmod.c