Opened 11 years ago

Closed 11 years ago

Last modified 6 years ago

#9358 closed defect (fixed)

zn_poly passes all tests on on Solaris 10 64-bit SPARC, but fails to install

Reported by: drkirkby Owned by: drkirkby
Priority: major Milestone: sage-4.5.3
Component: porting: Solaris Keywords:
Cc: jhpalmieri, jsp Merged in: sage-4.5.3.alpha1
Authors: David Kirkby Reviewers: John Palmieri
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by chapoton)

Hardware & associated software

  • Sun Blade 1000
  • 2 x 900 MHz UltraSPARC III+ CPUs
  • 2 GB RAM
  • 8 GB swap
  • Solaris 10 03/2005 (first release of Solaris 10)
  • 147 GB SEAGATE-ST3146807FC 2 Gbit/s 15,000 rpm fiber channel disk (FCAL)
  • UFS local file systems.
  • gcc 4.4.3 (uses Sun linker and assembler)
  • 64-bit build - SAGE64 was exported to "yes"

How GCC was configured

GCC can be configured several ways on Solaris. For Solaris 10 SPARC, use of both the Sun linker and Sun assembler are usually recommended, which is what was done here.

drkirkby@redstart:~$ gcc -v
Using built-in specs.
Target: sparc-sun-solaris2.10
Configured with: ../gcc-4.4.3/configure --prefix=/usr/local/gcc-4.4.3 --with-mpfr=/usr/local/gcc-4.4.3 --with-build-time-tools=/usr/ccs/bin --with-gmp=/usr/local/gcc-4.4.3 --enable-languages=c,c++,fortran
Thread model: posix
gcc version 4.4.3 (GCC)

The problem

znpoly passes about 40 self-tests, but fails to install properly.

zn_array_mulmid_fft()... ok
zn_array_mul_fft_dft()... ok
zn_array_invert()... ok

All tests passed.
gcc -O3 -g -m64 -fPIC -L. -I/export/home/drkirkby/sage-4.5.alpha0/local/include 
-I./include -DNDEBUG -o src/tuning.o -c src/tuning.c
In file included from ./include/zn_poly.h:75,
                 from ./include/zn_poly_internal.h:41,
                 from src/tuning.c:28:
./include/wide_arith.h:297:2: warning: #warning No assembly implementation of wi
de multiplication available for this machine; using generic C code instead.
ar -r libzn_poly.a src/array.o src/invert.o src/ks_support.o src/mulmid.o src/mu
lmid_ks.o src/misc.o src/mpn_mulmid.o src/mul.o src/mul_fft.o src/mul_fft_dft.o 
src/mul_ks.o src/nuss.o src/pack.o src/pmf.o src/pmfvec_fft.o src/tuning.o src/z
n_mod.o
ar: creating libzn_poly.a
ranlib libzn_poly.a
gcc -shared -m64  -Wl,-soname,libzn_poly-`cat VERSION`.so -o libzn_poly-`cat VER
SION`.so src/array.o src/invert.o src/ks_support.o src/mulmid.o src/mulmid_ks.o 
src/misc.o src/mpn_mulmid.o src/mul.o src/mul_fft.o src/mul_fft_dft.o src/mul_ks
.o src/nuss.o src/pack.o src/pmf.o src/pmfvec_fft.o src/tuning.o src/zn_mod.o -L
/export/home/drkirkby/sage-4.5.alpha0/local/lib -lgmp -lm
ld: warning: option -o appears more than once, first setting taken
ld: fatal: file libzn_poly-0.9.so: unknown file type
ld: fatal: File processing errors. No output written to libzn_poly-0.9.so
collect2: ld returned 1 exit status
make: *** [libzn_poly.so] Error 1
Error building zn_poly shared library.

real 1m38.825s
user 1m34.368s
sys 0m3.849s
sage: An error occurred while installing zn_poly-0.9.p4

This looks like a problem in spkg-install, which was written to consider two Solaris/64-bit releated possibilities.

  • A 64-bit build
  • A Solaris build with the Sun linker.

It does not cover the possibility of a 64-bit build on Solaris with the Sun linker. Clearly that was an oversight on my part.

Likely solution

This should be hopefully quite easy to fix. spkg-install needs to consider the possibility of a 64-bit Solaris build with the Sun linker.

Attachments (2)

zn_poly-0.9.p4.log (77.0 KB) - added by drkirkby 11 years ago.
Log file of building on a Sun Blade 1000 SPARC (64-bit build)
9358-zn_poly.patch (6.0 KB) - added by drkirkby 11 years ago.

Download all attachments as: .zip

Change History (12)

Changed 11 years ago by drkirkby

Log file of building on a Sun Blade 1000 SPARC (64-bit build)

comment:1 Changed 11 years ago by drkirkby

  • Cc jhpalmieri jsp added
  • Description modified (diff)

comment:2 follow-up: Changed 11 years ago by jhpalmieri

This also fails with a 64-bit build on fulvia (Solaris on x86), by the way.

comment:3 in reply to: ↑ 2 Changed 11 years ago by drkirkby

Replying to jhpalmieri:

This also fails with a 64-bit build on fulvia (Solaris on x86), by the way.

You do not surprise me.

I have a patch, but I'm working on improving spkg-install and spkg-check. Currently spkg-install runs a quick test suite with make check. That does not seem such a bad idea, so I'm not changing that. With SAGE_CHECK unset, this takes 46 seconds to build and run the quick test suite on my Sun Ultra 27 to build.

However, spkg-check currently runs the same test suite for a second time, which is clearly pointless. I'm changing spkg-check to run run the more extensive test suite. That increases the time to 7 minutes and 37 seconds on my 3.33 GHz Sun Ultra 27. That will probably close to hour on the Sun T5240 't2.math.washington.edu', so if you run with SAGE_CHECK=yes, bear that in mind.

Dave

comment:4 Changed 11 years ago by drkirkby

Whilst looking at the zn_poly package, I found what I think is a serious flaw in the dependencies for the package - see #9681. I'd appreciate a second pair of eyes on that one.

Dave

comment:5 Changed 11 years ago by drkirkby

A fix can now be found.

http://boxen.math.washington.edu/home/kirkby/patches/zn_poly-0.9.p5.spkg

A much more extensive test suite can now be run if SAGE_CHECK is exported to "yes".

Dave

Changed 11 years ago by drkirkby

comment:6 Changed 11 years ago by drkirkby

  • Authors set to David Kirkby
  • Status changed from new to needs_review

comment:7 Changed 11 years ago by jhpalmieri

  • Reviewers set to John Palmieri
  • Status changed from needs_review to positive_review

Looks good to me. Builds successfully on lots of different platforms with SAGE_CHECK='yes' including t2 (both 32- and 64-bit) and fulvia (32-bit, and according to SAGE_CHECK, 64-bit -- since I don't have a working 64-bit build because of maxima, it's hard to be positive).

comment:8 Changed 11 years ago by mpatel

  • Merged in set to sage-4.5.3.alpha0
  • Resolution set to fixed
  • Status changed from positive_review to closed

comment:9 Changed 11 years ago by mpatel

  • Merged in changed from sage-4.5.3.alpha0 to sage-4.5.3.alpha1

comment:10 Changed 6 years ago by chapoton

  • Description modified (diff)
Note: See TracTickets for help on using tickets.