Bug 498715

Summary: Illegal instruction encountered by an Intel Pentium III-M in libraries provided by atlas-sse
Product: [Fedora] Fedora Reporter: Joachim Frieben <jfrieben>
Component: atlasAssignee: Deji Akingunola <dakingun>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: rawhideCC: dakingun
Target Milestone: ---   
Target Release: ---   
Hardware: i586   
OS: Linux   
Whiteboard:
Fixed In Version: atlas-sse-3.8.3-4.fc11.i586 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-05-04 15:55:40 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Joachim Frieben 2009-05-02 13:36:23 UTC
Description of problem:
Running a private F77 code which requires LAPACK, the program aborts when it encounters an illegal instruction in /usr/lib/atlas-sse/libatlas.so.3. When run in GDB, the following information is returned:

 Program received signal SIGILL, Illegal instruction.
 0x077796cd in ATL_diamax_xp1yp0aXbX () from /usr/lib/atlas-sse/libatlas.so.3

The corresponding backtrace reads:

 #0  0x077796cd in ATL_diamax_xp1yp0aXbX ()
    from /usr/lib/atlas-sse/libatlas.so.3
 #1  0x07923be4 in ATL_ztpsvUN () from /usr/lib/atlas-sse/libatlas.so.3
 #2  0x0190d518 in ab.1513 () from /home/fedora/lib/libSO0.so.1
 #3  0x00000000 in ?? ()

libSO0.so.1 is a private dynamical library calling LAPACK routines.

Version-Release number of selected component (if applicable):
atlas-sse-3.8.3-3.fc11.i586

How reproducible:
Always.

Steps to Reproduce:
1. Remove all object files and the executable of the crashing program.
2. 'make'.
3. Run program.
  
Actual results:
Program aborts returning "Illegal instruction".

Expected results:
Program runs and completes as expected.

Additional info:
- System is an IBM ThinkPad T23 with a Pentium M processor running current
  "rawhide" including gcc-4.4.0-3. cpuinfo reads:

  processor	: 0
  vendor_id	: GenuineIntel
  cpu family	: 6
  model		: 11
  model name	: Mobile Intel(R) Pentium(R) III CPU - M  1200MHz
  stepping	: 4
  cpu MHz	: 1197.000
  cache size	: 512 KB
  fdiv_bug	: no
  hlt_bug	: no
  f00f_bug	: no
  coma_bug	: no
  fpu		: yes
  fpu_exception	: yes
  cpuid level	: 2
  wp		: yes
  flags		: fpu vme de pse tsc msr pae mce cx8 mtrr pge mca cmov
                  pat pse36 mmx fxsr sse up
  bogomips	: 2398.36
  clflush size	: 32
  power management:

  Thus the CPU should be able to execute SSE instructions if asked for.

- The Makefile contains "-llapack". The executable is linked dynamically
  against

    /usr/lib/atlas-sse/liblapack.so.3
    /usr/lib/atlas-sse/libf77blas.so.3
    /usr/lib/atlas-sse/libcblas.so.3
    /usr/lib/atlas-sse/libatlas.so.3

  At compile and run time, the following packages were installed:

    atlas-sse-3.8.3-3.fc11.i586
    atlas-sse-devel-3.8.3-3.fc11.i586
    blas-3.1.1-5.fc11.i586
    blas-devel-3.1.1-5.fc11.i586
    lapack-3.1.1-5.fc11.i586
    lapack-devel-3.1.1-5.fc11.i586

- After prepending /usr/lib to LD_LIBRARY_PATH, the executable is linked
  dynamically against

    /usr/lib/liblapack.so.3
    /usr/lib/libblas.so.3

  It runs correctly now.

- The program also crashes when building against atlas-sse after removing
  lapack-devel and blas-devel from the system.

Comment 1 Joachim Frieben 2009-05-02 15:58:43 UTC
A corresponding 32 bit executable built on an AMD64 system against atlas-sse, atlas-sse2, and atlas-sse3 respectively runs correctly in all three cases as it does when linked dynamically against BLAS and LAPACK 32 bit libraries.

Comment 2 Deji Akingunola 2009-05-03 00:16:18 UTC
Can you please upgrade to the packages at http://koji.fedoraproject.org/koji/taskinfo?taskID=1333136 and let me know if they fix the issue for you or not.
Thanks.

Comment 3 Joachim Frieben 2009-05-03 11:20:22 UTC
The culprit in atlas-sse-3.8.3-3.fc11.i586 appears to be

  0x077796cd  <ATL_diamax_xp1yp0aXbX+61>: movsd  (%esi),%xmm0 .

However, "movsd  (%esi),%xmm0" is not an SSE instruction but an SSE2 one.

Comment 4 Joachim Frieben 2009-05-03 11:24:19 UTC
Fixed in atlas-sse-3.8.3-4.fc11.i586.

Comment 5 Deji Akingunola 2009-05-04 15:55:40 UTC
atlas-3.8.3-4 have been built for rawhide and F11. Thanks for the report.