Changes between Version 85 and Version 86 of Ticket #5847


Ignore:
Timestamp:
11/25/10 14:23:00 (8 years ago)
Author:
leif
Comment:

Replying to leif:

P.S.: As I said, I first want to get some test results (e.g. on PowerPCs etc.) before I upload further changes.

Although (or because) there's not much feedback yet, I've uploaded a corrected spkg (still p2) with also some other changes. This obsoletes setting ECM_EXTRA_OPTS=--with-pic or -fPIC in CFLAGS etc., works with all GCC 4.0.x on x86 as well and also uses processor-specific settings from MPIR if available.

Updated spkg: http://spkg-upload.googlecode.com/files/ecm-6.3.p2.spkg (same place)

md5sum: 8246ca74be1ee07b312a84d2a88d9142 ecm-6.3.p2.spkg (fortunately differs ;-) )


ecm-6.3.p2 (Leif Leonhardy, November 25th, 2010)

  • #5847: Apply another patch from upstream to 'configure.in' to fix com- pilation on 32-bit x86 processors supporting SSE2. (Also #10252.) (There's only a single, cumulative patch file since both patches are to 'configure.in'.)
  • Work around linker bug on MacOS X 10.5 PPC (see Special Update/Build? Instructions above, and #5847 comment 35 ff.).
  • Allow passing extra arguments to 'configure' through ECM_EXTRA_OPTS.
  • Add "-march=native" to CFLAGS on platforms that support it, or use processor-specific CFLAGS from GMP's / MPIR's 'gmp.h' if available, but only if CFLAGS do not already contain similar (i.e., don't over- ride a user's choice). [Subject to further improvement.]
  • Print settings of CC, CFLAGS etc. and how we configure.
  • Print settings of CC and CFLAGS found in 'SAGE_LOCAL/include/gmp.h' and eventually a system-wide 'gmp.h', although the latter aren't (yet) used at all, and only processor-specific parts of the former.
  • Add '-fPIC' conditionally, i.e. not if we're also building a shared library (or '--with-pic' was given).
  • Don't delete previous installations unless the build succeeded.
  • Further clean-up.

Special Update/Build? Instructions

[...]

  • ECM currently does not (by itself) use the CC and CFLAGS settings from 'gmp.h' since we pass (other) options in CFLAGS, and CC is set by Sage and might got set by the user (though MPIR currently doesn't use its own CFLAGS for the same reason, which is fixed in an MPIR 2.1.3.p2 spkg). We now at least partially fix that s.t. "optimized" code generation options ('-mcpu=...', '-mtune=...') are used by gcc. Of course a user can also manually enable them by setting the "global" CFLAGS to e.g. '-march=native' on x86[_64] systems, or '-mcpu=...' and '-mtune=...' on other architectures where "native" isn't supported. Note that this doesn't affect the packages' selection of processor- specific optimized [assembly] code. 'spkg-install' already reads the settings from Sage's and also a system-wide GMP / MPIR now, but doesn't (yet) use all of them. If SAGE_FAT_BINARY="yes", we should avoid too specific settings of "-mcpu=...", and perhaps pass a more generic "--host=..." to 'configure'. (MPIR honors '--enable-fat' to some extent, but this option isn't used on anything other than x86 / x86_64.)

A new MPIR (2.1.3.p2) spkg which handles CFLAGS better (allowing us to use processor-specific settings chosen by MPIR) is on the way, but will live on another ticket (not #8664). Just haven't committed the changes yet.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #5847

    • Property Status changed from needs_work to needs_review
    • Property Keywords MPIR elliptic curves libecm added
  • Ticket #5847 – Description

    v85 v86  
    4343----
    4444
    45 '''New spkg: http://spkg-upload.googlecode.com/files/ecm-6.3.p2.spkg'''
     45'''Updated new spkg: http://spkg-upload.googlecode.com/files/ecm-6.3.p2.spkg'''
    4646
    47 '''md5sum:''' `85eabecaa8974a270d5587ef8de06da1  ecm-6.3.p2.spkg`
     47'''md5sum:''' `8246ca74be1ee07b312a84d2a88d9142  ecm-6.3.p2.spkg`