Skip to content

Commit

Permalink
Trac #14605: Better system detection for ATLAS
Browse files Browse the repository at this point in the history
See lots of rants in #10508.

This fixes a bunch of problems with ATLAS detection system.
Adds support for (some) ARM hard float systems.
Adds archdefs for Raspberry Pi and Cygwin64.

Use tarball at:
* http://boxen.math.washington.edu/home/jpflori/upstream/atlas-3.10.1.20
140210.tar.bz2

URL: http://trac.sagemath.org/14605
Reported by: jpflori
Ticket author(s): Jean-Pierre Flori
Reviewer(s): Volker Braun
  • Loading branch information
Release Manager authored and vbraun committed Apr 7, 2014
2 parents 83a3764 + 3f1defb commit 3bafd10
Show file tree
Hide file tree
Showing 10 changed files with 349 additions and 52 deletions.
17 changes: 9 additions & 8 deletions build/pkgs/atlas/SPKG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,14 @@ Solaris, but should also work on OSX and Cygwin.
* The package is never installed on OS X, unless you set SAGE_ATLAS_ARCH.

=== Patches ===
* patches/archinfo_linux.c.patch: Fix Itanium2 support on modern
RHEL 5 and SLES 10 systems.
* patches/probe_comp.c.patch: work around -m64 issue on Itanium2
* patches/long_filenames.patch: fix for long filenames (>128 chars)
* patches/detect.patch: Fix Itanium2 support on modern
RHEL 5 and SLES 10 systems, work around -m64 issue on Itanium2,
and correctly detect number and speed of CPUs on a bunch of systems.
* patches/arm_hard_floats.patch: make sure soft floats are not enforced on ARM.
* patches/long_filenames.patch: fix for long filenames (>128 chars).
* patches/shell.patch: replace two instances of "test -e" by "test -f",
as the former is not portable (in particular for the Solaris
shell).
as the former is not portable (in particular for the Solaris shell).
* patches/Makefile.patch: fix clean target.
* patches/threads.patch: Avoid thread-related symbols
ATL_(Set|Reset|Free|Dec)AtomicCount symbols in single-threaded
library.
Expand Down Expand Up @@ -71,8 +72,8 @@ The package can be configured via three environment variables:
IBMz10, IBMz196, x86x87, x86SSE1, x86SSE2, x86SSE3, P5, P5MMX,
PPRO, PII, PIII, PM, CoreSolo, CoreDuo, Core2Solo, Core2, Corei1,
Corei2, Atom, P4, P4E, Efficeon, K7, HAMMER, AMD64K10h, AMDDOZER,
UNKNOWNx86, IA64Itan, IA64Itan2, USI, USII, USIII, USIV, UST2,
UnknownUS, MIPSR1xK, MIPSICE9, ARMv7
UNKNOWNx86, IA64Itan, IA64Itan2, USI, USII, USIII, USIV, UST1, UST2,
UnknownUS, MIPSR1xK, MIPSICE9, ARMv6, ARMv7

and instruction set extensions are

Expand Down
6 changes: 3 additions & 3 deletions build/pkgs/atlas/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
tarball=atlas-VERSION.tar.bz2
sha1=d7a74adc654eaca6e05d0a90299fd271a5103c52
md5=43a9a4324648ee3506d7982393b50f00
cksum=3795128001
sha1=ecacb1132efac76c7a018ec7212508d4a7e7ebcc
md5=5d69a191785de59f693b604599570650
cksum=2926672652
3 changes: 2 additions & 1 deletion build/pkgs/atlas/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
#
# Linux?, Solaris?, Darwin?, FreeBSD?, CYGWIN? # system
# OS_X_Lion? # release
# Intel?, PPC?, SPARC? # processor
# Intel?, PPC?, SPARC? ARM? # processor
# 64bit?, 32bit? # bits
# fortran_g95?, fortran_GNU? # fortran
# linker_GNU?, linker_Solaris?, linker_Darwin? # ld
Expand Down Expand Up @@ -151,6 +151,7 @@ def close(self):

conf['processor'] = platform.processor()

conf['ARM?'] = (platform.machine().startswith('arm'))
conf['Intel?'] = (platform.machine() in ('i386', 'i486', 'i586', 'i686', 'x86_64',
'AMD64', 'i86pc'))
conf['IA64?'] = ((platform.processor() == 'ia64')
Expand Down
16 changes: 9 additions & 7 deletions build/pkgs/atlas/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
'CoreDuo', 'Core2Solo', 'Core2', 'Corei1', 'Corei2', 'Atom', 'P4', 'P4E',
'Efficeon', 'K7', 'HAMMER', 'AMD64K10h', 'AMDDOZER', 'UNKNOWNx86',
'IA64Itan', 'IA64Itan2',
'USI', 'USII', 'USIII', 'USIV', 'UST2', 'UnknownUS',
'MIPSR1xK', 'MIPSICE9', 'ARMv7')
'USI', 'USII', 'USIII', 'USIV', 'UST1', 'UST2', 'UnknownUS',
'MIPSR1xK', 'MIPSICE9', 'ARMv6', 'ARMv7')

ATLAS_ISAEXT = ( # static char *ISAXNAM
'None', 'VSX', 'AltiVec', 'AVXMAC', 'AVXFMA4', 'AVX', 'SSE3', 'SSE2', 'SSE1',
Expand Down Expand Up @@ -79,11 +79,13 @@
39 = 'USII'
40 = 'USIII'
41 = 'USIV'
42 = 'UST2'
43 = 'UnknownUS'
44 = 'MIPSR1xK'
45 = 'MIPSICE9'
46 = 'ARMv7'
42 = 'UST1'
43 = 'UST2'
44 = 'UnknownUS'
45 = 'MIPSR1xK'
46 = 'MIPSICE9'
47 = 'ARMv6'
48 = 'ARMv7'
Operating System enums (Config's enum OSTYPE):
0 = 'UNKNOWN'
Expand Down
2 changes: 1 addition & 1 deletion build/pkgs/atlas/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.10.1.20140128
3.10.1.20140210
20 changes: 0 additions & 20 deletions build/pkgs/atlas/patches/archinfo_linux.c.patch

This file was deleted.

21 changes: 21 additions & 0 deletions build/pkgs/atlas/patches/arm_hard_floats.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
diff -druN ATLAS.detect/CONFIG/src/atlcomp.txt ATLAS/CONFIG/src/atlcomp.txt
--- ATLAS.detect/CONFIG/src/atlcomp.txt 2013-01-08 10:15:42.000000000 -0800
+++ ATLAS/CONFIG/src/atlcomp.txt 2014-02-10 04:36:26.113011794 -0800
@@ -255,13 +255,13 @@
# ARM defaults
#
MACH=ARMv7 OS=ALL LVL=1000 COMPS=xcc
- 'gcc' '-mcpu=cortex-a8 -O1 -mfpu=vfpv3 -mfloat-abi=softfp '
+ 'gcc' '-mcpu=cortex-a8 -O1 -mfpu=vfpv3 -mfloat-abi=hard '
MACH=ARMv7 OS=ALL LVL=1000 COMPS=smc,skc,gcc,icc
- 'gcc' '-O1 -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=vfpv3 -mfloat-abi=softfp -fno-expensive-optimizations'
+ 'gcc' '-O1 -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard -fno-expensive-optimizations'
MACH=ARMv7 OS=ALL LVL=1000 COMPS=dmc,dkc
- 'gcc' '-O1 -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=vfpv3 -mfloat-abi=softfp -fno-schedule-insns2'
+ 'gcc' '-O1 -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard -fno-schedule-insns2'
MACH=ARMv7 OS=ALL LVL=1000 COMPS=f77
- 'gfortran' '-mcpu=cortex-a8 -mfpu=vfpv3 -mfloat-abi=softfp -O'
+ 'gfortran' '-mcpu=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard -O'
#
# Generic defaults
#
Loading

0 comments on commit 3bafd10

Please sign in to comment.