Differences between revisions 1 and 2
Revision 1 as of 2009-01-08 08:10:28
Size: 24263
Comment: move content from solaris/solaris/sage-3.1.2
Revision 2 as of 2009-02-05 11:16:15
Size: 24385
Comment: add a note about this page being outdated and refer back to the main Solaris porting page
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:

'''Note''': This page is outdated. Please check the [[solaris|main Solaris bit porting page]] for the current status.

Toolchain

Note: This page is outdated. Please check the main Solaris bit porting page for the current status.

Sage 3.1.3.alpha1 ought to build on SkyNet using the toolchain provided by mabshoff. To use that toolchain run

  • -bash-3.00$ source /home/mabshoff/x86_64-solaris/toolchain.bash

on Fulvia. The Sparc build is still broken. While Sage 3.1.3.alpha0 is out it is still broken in a couple of places, but alpha1 will contain fixes for

  • cvxopt: complex.h problem - see http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6549313

  • libfplll build problem due to ntl_wrap.h: fix: in patches/dpe.h: instead of defining a round macro use '#include "tgmath.h' [details of the failure below]
  • cddlib-094b.p2: build fix for numeric constant issue in allfaces.cc - #4173
  • Sage library: RANDSTATE and number_of_partitions broken
  • jmol-11.6.rc8: tail uses GNUisms

Failed Doctests

There are currently 22 failed doctests:

        sage -t  devel/sage/sage/coding/code_bounds.py
        sage -t  devel/sage/sage/combinat/schubert_polynomial.py
        sage -t  devel/sage/sage/crypto/mq/mpolynomialsystem.py
        sage -t  devel/sage/sage/crypto/mq/sr.py
        sage -t  devel/sage/sage/functions/transcendental.py
        sage -t  devel/sage/sage/interfaces/lisp.py
        sage -t  devel/sage/sage/lfunctions/sympow.py
        sage -t  devel/sage/sage/libs/pari/gen.pyx
        sage -t  devel/sage/sage/libs/symmetrica/sb.pxi
        sage -t  devel/sage/sage/libs/symmetrica/sc.pxi
        sage -t  devel/sage/sage/modular/abvar/abvar.py
        sage -t  devel/sage/sage/plot/plot.py
        sage -t  devel/sage/sage/rings/polynomial/multi_polynomial_element.py
        sage -t  devel/sage/sage/rings/polynomial/multi_polynomial_ideal.py
        sage -t  devel/sage/sage/rings/polynomial/pbori.pyx
        sage -t  devel/sage/sage/rings/polynomial/polynomial_singular_interface.py
        sage -t  devel/sage/sage/rings/polynomial/term_order.py
        sage -t  devel/sage/sage/rings/polynomial/toy_buchberger.py
        sage -t  devel/sage/sage/rings/complex_double.pyx
        sage -t  devel/sage/sage/rings/qqbar.py
        sage -t  devel/sage/sage/rings/real_double.pyx
        sage -t  devel/sage/sage/schemes/elliptic_curves/ell_rational_field.py

Those can be attributed to the following bugs:

  • Singular vs. pexpect issues (8 doctest failures)
  • Symmetrica broken (3 doctest failures)
  • get_memory_usage NotImplemented error with gen.pyx (1 doctest failure)

  • NaN vs. nan or -inf vs. -Infinity (2 doctest failures)
  • gfortran vs. ATLAS & netlib.org BLAS and numpy/scipy (probably 3 doctest failures)

  • pexpect issue with lisp interface (1 doctest failure)
  • sympow broken on Solaris/x86 (3 doctest failures)
  • Numerical noise (1 doctest failure)

Ironically the doctest devel/sage/sage/gsl/ode.pyx times out, i.e. it takes roughly ten times as long on Solaris as it does on the same hardware under Linux.

Issues with Details

  • NaN vs. nan or -inf vs. -Infinity

sage -t  devel/sage/sage/coding/code_bounds.py              
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/code_bounds.py", line 325:
    sage: P.save()
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_12[4]>", line 1, in <module>
        P.save()###line 325:
    sage: P.save()
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/plot.py", line 1546, in save
        xmin, xmax, ymin, ymax = sage_axes.add_xy_axes(subplot, xmin, xmax, ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 325, in add_xy_axes
        x_axis_ypos, ystep, ytslminor, ytslmajor = self._find_axes(ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 241, in _find_axes
        tslmajor, oppaxis, step = self._tasteful_ticks(minval, maxval)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 131, in _tasteful_ticks
        d0 = eval(sl[0])
      File "<string>", line 1, in <module>
    NameError: name 'NaN' is not defined
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/code_bounds.py", line 337:
    sage: P.save()
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_13[4]>", line 1, in <module>
        P.save()###line 337:
    sage: P.save()
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/plot.py", line 1546, in save
        xmin, xmax, ymin, ymax = sage_axes.add_xy_axes(subplot, xmin, xmax, ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 325, in add_xy_axes
        x_axis_ypos, ystep, ytslminor, ytslmajor = self._find_axes(ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 241, in _find_axes
        tslmajor, oppaxis, step = self._tasteful_ticks(minval, maxval)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 131, in _tasteful_ticks
        d0 = eval(sl[0])
      File "<string>", line 1, in <module>
    NameError: name 'NaN' is not defined
**********************************************************************

and

sage -t  devel/sage/sage/plot/plot.py                       
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/plot.py", line 3531:
    sage: plot(-x*log(x), (x,0,1))  # this works fine since the failed endpoint is just skipped.
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_102[31]>", line 1, in <module>
        plot(-x*log(x), (x,Integer(0),Integer(1)))  # this works fine since the failed endpoint is just skipped.###line 3531:
    sage: plot(-x*log(x), (x,0,1))  # this works fine since the failed endpoint is just skipped.
      File "sage_object.pyx", line 92, in sage.structure.sage_object.SageObject.__repr__ (sage/structure/sage_object.c:1026)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/plot.py", line 742, in _repr_
        self.show()
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/plot.py", line 1341, in show
        hgridlinesstyle=hgridlinesstyle)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/plot.py", line 1546, in save
        xmin, xmax, ymin, ymax = sage_axes.add_xy_axes(subplot, xmin, xmax, ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 325, in add_xy_axes
        x_axis_ypos, ystep, ytslminor, ytslmajor = self._find_axes(ymin, ymax)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 241, in _find_axes
        tslmajor, oppaxis, step = self._tasteful_ticks(minval, maxval)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/plot/axes.py", line 131, in _tasteful_ticks
        d0 = eval(sl[0])
      File "<string>", line 1, in <module>
    NameError: name 'NaN' is not defined
**********************************************************************

and

sage -t  devel/sage/sage/rings/complex_double.pyx           
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/complex_double.py", line 823:
    sage: ~(0*CDF(0,1))
Expected:
    nan + nan*I
Got:
    -NaN + NaN*I
**********************************************************************

and

sage -t  devel/sage/sage/rings/real_double.pyx              
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/real_double.py", line 1247:
    sage: RDF(0).log()
Expected:
    -inf
Got:
    -Infinity
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/real_double.py", line 1249:
    sage: RDF(-1).log()
Expected:
    nan
Got:
    -NaN
**********************************************************************
  • Symmetrica throws error:

sage -t  devel/sage/sage/combinat/schubert_polynomial.py    k
function: nullp(1) 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: empty object as parameter?: 
A mysterious error (perphaps a memory error?) occurred, which may have crashed doctest.

and

sage -t  devel/sage/sage/libs/symmetrica/sb.pxi             
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/sb.py", line 173:
    sage: symmetrica.divdiff_perm_schubert([2,3,1], [3,2,1])
Expected:
    X[2, 1]
Got:
    X[3, 2, 1]
For whitespace errors, see the file /home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/.doctest_sb.pyfunction: nullp(1) 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: empty object as parameter?: function: nullp code: -1 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: error during computation?: function: rz_lehmercode code: 140405696 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: error during computation?: function: rz_perm code: 140405696 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: error during computation?: function: divdiff_perm_schubert code: 140405696 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: error during computation?: function: nullp(1) 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: empty object as parameter?: function: nullp code: -1 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: error during computation?: 
A mysterious error (perphaps a memory error?) occurred, which may have crashed doctest.
         [101.8 s]

and

sage -t  devel/sage/sage/libs/symmetrica/sc.pxi             
function: inc(1) 

enter a to abort with core dump, g to go, f to supress
s to supress further error text, r to retry,  e to explain, else stop
ERROR: empty object as parameter?: 
A mysterious error (perphaps a memory error?) occurred, which may have crashed doctest.
  • Singular pexpect hangs

sage -t  devel/sage/sage/crypto/mq/mpolynomialsystem.py
sage -t  devel/sage/sage/crypto/mq/sr.py
sage -t  devel/sage/sage/rings/polynomial/multi_polynomial_element.py
sage -t  devel/sage/sage/rings/polynomial/multi_polynomial_ideal.py
sage -t  devel/sage/sage/rings/polynomial/pbori.pyx
sage -t  devel/sage/sage/rings/polynomial/polynomial_singular_interface.py
sage -t  devel/sage/sage/rings/polynomial/term_order.py
sage -t  devel/sage/sage/rings/polynomial/toy_buchberger.py

A good simple example:

sage: PolynomialRing(GF(127),9,names='x')._singular_()
[hang]

Oddly putting 8 instead of 9 and it works...

In fact, essentially *ANY* long line breaks the interface.

Indeed - the following works fine under Singular itself (note that the prompt for Singular has been changed to "@"):

-bash-3.00$ ./sage -singular
                     SINGULAR                             /  Development
 A Computer Algebra System for Polynomial Computations   /   version 3-0-4
                                                       0<
     by: G.-M. Greuel, G. Pfister, H. Schoenemann        \   Nov 2007
FB Mathematik der Universitaet, D-67653 Kaiserslautern    \
@ ring sage1036=(3,w),(x, y),lp;
@ module sage1044=y^48 + y^41 - y^40 + y^37 - y^36 - y^33 + y^32 - y^29 + y^28 - y^25 + y^24 + y^2 + y + 1, x - y^47 - y^45 + y^44 - y^43 + y^41 - y^39 - y^38 - y^37 - y^36 + y^35 - y^34 - y^33 + y^32 - y^31 + y^30 + y^28 + y^27 + y^26 + y^25 - y^23 + y^22 + y^21 - y^19 - y^18 - y^16 + y^15 + y^13 + y^12 - y^10 + y^9 + y^8 + y^7 - y^6 + y^4 + y^3 + y^2 + y - 1;
@ sage1044
. ;
sage1044[1]=y48*gen(1)+y41*gen(1)-y40*gen(1)+y37*gen(1)-y36*gen(1)-y33*gen(1)+y32*gen(1)-y29*gen(1)+y28*gen(1)-
y25*gen(1)+y24*gen(1)+y2*gen(1)+y*gen(1)+gen(1)
sage1044[2]=x*gen(1)-y47*gen(1)-y45*gen(1)+y44*gen(1)-y43*gen(1)+y41*gen(1)-y39*gen(1)-y38*gen(1)-y37*gen(1)-
y36*gen(1)+y35*gen(1)-y34*gen(1)-y33*gen(1)+y32*gen(1)-y31*gen(1)+y30*gen(1)+y28*gen(1)+y27*gen(1)+y26*gen(1)+
y25*gen(1)-y23*gen(1)+y22*gen(1)+y21*gen(1)-y19*gen(1)-y18*gen(1)-y16*gen(1)+y15*gen(1)+y13*gen(1)+y12*gen(1)-
y10*gen(1)+y9*gen(1)+y8*gen(1)+y7*gen(1)-y6*gen(1)+y4*gen(1)+y3*gen(1)+y2*gen(1)+y*gen(1)-gen(1)
@ Auf Wiedersehen.

But under pexpect something goes wrong:

@ module sage1044=y^48 + y^41 - y^40 + y^37 - y^36 - y^33 + y^32 - y^29 + y^28 - y^25 + y^24 + y^2 + y + 1, x - y^47 - y^45 + y^44 - y^43 + y^41 - y^39 - y^38 - y^37 - y^36 + y^35 - y^34 - y^33 + y^32 - y^31 + y^30 + y^28 + y^27 + y^26 + y^25 - y^23 + y^22 + y^21 - y^19 - y^18 - y^16 + y^15 + y^13 + y^12 - y^10 + y^9 + y^8 + y^7 - y^6 + y^4 + y^3 + y^2 + y - 1;
module sage1044=y^48 + y^41 - y^40 + y^37 - y^36 - y^33 + y^32 - y^29 + y^28 - y^25 + y^24 + y^2 + y + 1, x - y^47 - y^45 + y^44 - y^43 + y^41 - y^39 - y^38 - y^37 - y^36 + y^35 - y^34 - y^33 + y^32 - y^31 + y^30 + y^28 + y^27 + y^26 + y^25 - y^23 + y^22 + ^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G
^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G
^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G^G

The problem is not caused by (a) a limited stack since increasing it to 512kb still hangs or (b) a compiler issue since Singular compiled with "-O0" still hangs. All fingers point to pexpect

  • scipy related segfault: this is caused by some problem when using ATLAS + netlib.org Lapack on Solaris with gfortran 4.2.4

sage -t  devel/sage/sage/functions/transcendental.py        

------------------------------------------------------------
Unhandled SIGSEGV: A segmentation fault occured in SAGE.
This probably occured because a *compiled* component
of SAGE has a bug in it (typically accessing invalid memory)
or is not properly wrapped with _sig_on, _sig_off.
You might want to run SAGE under gdb with 'sage -gdb' to debug this.
SAGE will now terminate (sorry).
------------------------------------------------------------
  • timeout gsl error:

sage -t  devel/sage/sage/gsl/ode.pyx                        *** *** Error: TIMED OUT! *** ***
*** *** Error: TIMED OUT! *** ***
         [393.6 s]
  • pexpect issue with lisp interface:

sage -t  devel/sage/sage/interfaces/lisp.py                 
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/lisp.py", line 464:
    sage: a / b
Expected:
    1/2
Got:
    /2
**********************************************************************
1 items had failures:
   1 of   4 in __main__.example_29
***Test Failed*** 1 failures.
  • sympow broken on Solaris/x86:

sage -t  devel/sage/sage/lfunctions/sympow.py               
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/sympow.py", line 182:
    sage: sympow.modular_degree(EllipticCurve('11a'))
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_6[2]>", line 1, in <module>
        sympow.modular_degree(EllipticCurve('11a'))###line 182:
    sage: sympow.modular_degree(EllipticCurve('11a'))
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/lfunctions/sympow.py", line 198, in modular_degree
        raise RuntimeError, "failed to compute modular degree"
    RuntimeError: failed to compute modular degree
**********************************************************************
<SNIP>

and

sage -t  devel/sage/sage/modular/abvar/abvar.py             
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/abvar.py", line 2940:
    sage: E.modular_degree()
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_83[8]>", line 1, in <module>
        E.modular_degree()###line 2940:
    sage: E.modular_degree()
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/schemes/elliptic_curves/ell_rational_field.py", line 2395, in modular_degree
        m = sympow.modular_degree(self)
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/lfunctions/sympow.py", line 198, in modular_degree
        raise RuntimeError, "failed to compute modular degree"
    RuntimeError: failed to compute modular degree
**********************************************************************

and

sage -t  devel/sage/sage/schemes/elliptic_curves/ell_rational_field.py
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/ell_rational_field.py", line 976:
    sage: E.analytic_rank(algorithm='sympow')
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_26[5]>", line 1, in <module>
        E.analytic_rank(algorithm='sympow')###line 976:
    sage: E.analytic_rank(algorithm='sympow')
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/schemes/elliptic_curves/ell_rational_field.py", line 990, in analytic_rank
        return sympow.analytic_rank(self)[0]
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/lfunctions/sympow.py", line 246, in analytic_rank
        raise RuntimeError, "failed to compute analytic rank"
    RuntimeError: failed to compute analytic rank
**********************************************************************
<SNIP>
  • get_memory_usage() broken on Solaris:

sage -t  devel/sage/sage/libs/pari/gen.pyx                  Terminated
*** *** Error: TIMED OUT! *** ***
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/gen.py", line 7190:
    sage: print "ignore this";  get_memory_usage()                       # random output
Exception raised:
    Traceback (most recent call last):
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/doctest.py", line 1228, in __run
        compileflags, 1) in test.globs
      File "<doctest __main__.example_268[2]>", line 1, in <module>
        print "ignore this";  get_memory_usage()                       # random output###line 7190:
    sage: print "ignore this";  get_memory_usage()                       # random output
      File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/local/lib/python2.5/site-packages/sage/misc/getusage.py", line 61, in get_memory_usage
        raise NotImplementedError, "memory usage not implemented on platform %s"%U
    NotImplementedError: memory usage not implemented on platform sunos
**********************************************************************
<SNIP>

The fix here is to do something similar as on OSX, i.e. "top -b -n 300" returns 300 processes in a non-interactive session. The following patch fixes the problem:

diff -r 7ad998b19bb4 sage/misc/getusage.py
--- a/sage/misc/getusage.py     Fri Sep 19 19:49:58 2008 -0700
+++ b/sage/misc/getusage.py     Wed Oct 01 08:56:08 2008 -0400
@@ -27,6 +27,8 @@
         cmd = 'top -b -n 1 -p %s'%pid
     elif U == 'darwin':
         cmd = 'top -l 1 |grep "^ *%s "'%pid
+    elif U == 'sunos':
+        cmd = 'top -b -n 65635 |grep "^ *%s "'%pid
     else:
         raise NotImplementedError, "top not implemented on platform %s"%U
     
@@ -57,6 +59,8 @@
             return linux_memory_usage() - t
     elif U == 'darwin':
         return top().split()[-1]
+    elif U == 'sunos':
+        return top().split()[-5]
     else:
         raise NotImplementedError, "memory usage not implemented on platform %s"%U

After the patch gen.pyx crashes on exit after running out of 2GB address space *after* all tests have passed. top reports the memory usage rising whn Python is exiting:

   4 tests in __main__.example_98
   4 tests in __main__.example_99
1385 tests in 277 items.
1385 passed and 0 failed.
Test passed.


     Segmentation Fault - core dumped

         [196.6 s]
exit code: 768
  • Numerical noise (which is bad considering we use mpfi here:

sage -t  devel/sage/sage/rings/qqbar.py                     
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/qqbar.py", line 3770:
    sage: cp.complex_roots(30, 1)
Expected:
    [1.189207115002721?,
     -1.189207115002721?,
     1.189207115002721?*I,
     -1.189207115002721?*I]
Got:
    [1.189207115002721?, -1.1892071150027211?, 1.189207115002721?*I, -1.189207115002721?*I]
**********************************************************************

Applying #4224 changes the doctest failure to:

sage -t  devel/sage/sage/rings/qqbar.py                     
**********************************************************************
File "/home/mabshoff/build-3.1.3.alpha0/sage-3.1.3.alpha0-fulvia/tmp/qqbar.py", line 3770:
    sage: cp.complex_roots(30, 1)
Expected:
    [1.189207115002721?,
     -1.189207115002721?,
     1.189207115002721?*I,
     -1.189207115002721?*I]
Got:
    [1.189207115002721?, -1.189207115002722?, 1.189207115002721?*I, -1.189207115002721?*I]
**********************************************************************