<p dir="auto">On PPC this test fails as reported in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="165624414" data-permission-text="Title is private" data-url="https://github.com/numpy/numpy/issues/7836" data-hovercard-type="issue" data-hovercard-url="/numpy/numpy/issues/7836/hovercard" href="https://github.com/numpy/numpy/issues/7836">#7836</a></p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="    o = 1 + np.finfo(np.longdouble).eps
    assert_equal(np.longdouble(repr(o)), o,
                 &quot;repr was %s&quot; % repr(o))"><pre class="notranslate"><code class="notranslate">    o = 1 + np.finfo(np.longdouble).eps
    assert_equal(np.longdouble(repr(o)), o,
                 "repr was %s" % repr(o))
</code></pre></div>
<p dir="auto">with</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="
AssertionError:
Items are not equal: repr was 1.0
 ACTUAL: 1.0
 DESIRED: 1.0"><pre class="notranslate"><code class="notranslate">
AssertionError:
Items are not equal: repr was 1.0
 ACTUAL: 1.0
 DESIRED: 1.0
</code></pre></div>
<p dir="auto">Among other things, probably finfo, it looks like repr does not have sufficient digits.</p>
<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/numpy/ticket/2077" rel="nofollow">http://projects.scipy.org/numpy/ticket/2077</a> on 2012-03-10 by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/matthew-brett/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/matthew-brett">@matthew-brett</a>, assigned to unknown.</em></p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [1]: import numpy as np

In [2]: print np.finfo(np.longdouble)
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:125: RuntimeWarning: overflow encountered in add
  a = a + a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:127: RuntimeWarning: invalid value encountered in subtract
  temp1 = temp - a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:136: RuntimeWarning: invalid value encountered in subtract
  itemp = int_conv(temp-a)
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:160: RuntimeWarning: overflow encountered in add
  a = a + a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:162: RuntimeWarning: invalid value encountered in subtract
  temp1 = temp - a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:169: RuntimeWarning: invalid value encountered in subtract
  if any(temp-a != zero):
Machine parameters for float128
---------------------------------------------------------------------
precision= 75   resolution= 1e-75
machep=    -4   eps=        1.3817869701e-76
negep =    -4   epsneg=     1.3817869701e-76
minexp=    -1   tiny=       -1.08420217274e-19
maxexp=     1   max=        -9.22337203471e+18
nexp  =     1   min=        -max
---------------------------------------------------------------------


In [3]: print np.finfo(np.longdouble).nmant
1

In [4]: np.__version__
Out[4]: '1.7.0.dev-aae5b0a'"><pre class="notranslate"><code class="notranslate">In [1]: import numpy as np

In [2]: print np.finfo(np.longdouble)
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:125: RuntimeWarning: overflow encountered in add
  a = a + a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:127: RuntimeWarning: invalid value encountered in subtract
  temp1 = temp - a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:136: RuntimeWarning: invalid value encountered in subtract
  itemp = int_conv(temp-a)
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:160: RuntimeWarning: overflow encountered in add
  a = a + a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:162: RuntimeWarning: invalid value encountered in subtract
  temp1 = temp - a
/Users/mb312/dev_trees/numpy/numpy/core/machar.py:169: RuntimeWarning: invalid value encountered in subtract
  if any(temp-a != zero):
Machine parameters for float128
---------------------------------------------------------------------
precision= 75   resolution= 1e-75
machep=    -4   eps=        1.3817869701e-76
negep =    -4   epsneg=     1.3817869701e-76
minexp=    -1   tiny=       -1.08420217274e-19
maxexp=     1   max=        -9.22337203471e+18
nexp  =     1   min=        -max
---------------------------------------------------------------------


In [3]: print np.finfo(np.longdouble).nmant
1

In [4]: np.__version__
Out[4]: '1.7.0.dev-aae5b0a'
</code></pre></div>
<p dir="auto">I think the correct answers for nexp, nmant are 11, 106 respectively; see:<br>
<a href="https://developer.apple.com/library/mac/#documentation/Darwin/Reference/Manpages/man3/float.3.html" rel="nofollow">https://developer.apple.com/library/mac/#documentation/Darwin/Reference/Manpages/man3/float.3.html</a></p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="(np-devel)[mb312@jerry ~]$ uname -a
Darwin jerry.bic.berkeley.edu 8.11.0 Darwin Kernel Version 8.11.0: Wed Oct 10 18:26:00 PDT 2007; root:xnu-792.24.17~1/RELEASE_PPC Power Macintosh powerpc
(np-devel)[mb312@jerry ~]$ gcc -v
Using built-in specs.
Target: powerpc-apple-darwin8
Configured with: /var/tmp/gcc/gcc-5370~2/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --with-slibdir=/usr/lib --build=powerpc-apple-darwin8 --host=powerpc-apple-darwin8 --target=powerpc-apple-darwin8
Thread model: posix
gcc version 4.0.1 (Apple Computer, Inc. build 5370)"><pre class="notranslate"><code class="notranslate">(np-devel)[mb312@jerry ~]$ uname -a
Darwin jerry.bic.berkeley.edu 8.11.0 Darwin Kernel Version 8.11.0: Wed Oct 10 18:26:00 PDT 2007; root:xnu-792.24.17~1/RELEASE_PPC Power Macintosh powerpc
(np-devel)[mb312@jerry ~]$ gcc -v
Using built-in specs.
Target: powerpc-apple-darwin8
Configured with: /var/tmp/gcc/gcc-5370~2/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --with-slibdir=/usr/lib --build=powerpc-apple-darwin8 --host=powerpc-apple-darwin8 --target=powerpc-apple-darwin8
Thread model: posix
gcc version 4.0.1 (Apple Computer, Inc. build 5370)
</code></pre></div>