Package: atlas / 3.10.3-1~bpo8+1

ppc64el-abiv2.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
Origin: http://sourceforge.net/p/math-atlas/patches/65/#3cb1
Forwarded: http://sourceforge.net/p/math-atlas/patches/65/
Description: ELFv2 ABI changes for ppc64el
 For more details, see:
 https://bugzilla.redhat.com/show_bug.cgi?id=1080073#c40
Last-Update: 2014-10-24
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=766695
Reviewed-By: S├ębastien Villemot <sebastien@debian.org>
--- a/tune/blas/gemm/CASES/ATL_dmm4x4x32_ppc.c
+++ b/tune/blas/gemm/CASES/ATL_dmm4x4x32_ppc.c
@@ -268,7 +268,7 @@ Mjoin(.,ATL_USERMM):
 	.globl  Mjoin(_,ATL_USERMM)
 Mjoin(_,ATL_USERMM):
    #else
-      #if defined(ATL_USE64BITS)
+      #if defined(ATL_USE64BITS) && _CALL_ELF != 2
 /*
  *      Official Program Descripter section, seg fault w/o it on Linux/PPC64
  */
@@ -324,8 +324,15 @@ ATL_USERMM:
 #endif
 
 #ifdef ATL_USE64BITS
+#if _CALL_ELF == 2
+/* ABIv2 */
+        ld      pC0, 104(r1)
+        ld      incCn, 112(r1)
+#else
+/* ABIv1 */
         ld      pC0, 120(r1)
         ld      incCn, 128(r1)
+#endif
 #elif defined(ATL_AS_OSX_PPC) || defined(ATL_AS_AIX_PPC)
         lwz     pC0, 68(r1)
         lwz     incCn,  72(r1)
--- a/tune/blas/gemm/CASES/ATL_dmm4x4x80_ppc.c
+++ b/tune/blas/gemm/CASES/ATL_dmm4x4x80_ppc.c
@@ -170,13 +170,21 @@ void ATL_USERMM(const int M, const int N
                 const TYPE beta, TYPE *C, const int ldc)
                                   (r10)    8(r1)
 *******************************************************************************
-64 bit ABIs:
+64 bit ABIv1s:
                          r3           r4           r5             r6/f1
 void ATL_USERMM(const int M, const int N, const int K, const TYPE alpha,
                            r7             r8             r9            r10
                 const TYPE *A, const int lda, const TYPE *B, const int ldb,
                              f2   120(r1)        128(r1)
                 const TYPE beta, TYPE *C, const int ldc)
+
+64 bit ABIv2s:
+                         r3           r4           r5             r6/f1
+void ATL_USERMM(const int M, const int N, const int K, const TYPE alpha,
+                           r7             r8             r9            r10
+                const TYPE *A, const int lda, const TYPE *B, const int ldb,
+                             f2   104(r1)        112(r1)
+                const TYPE beta, TYPE *C, const int ldc)
 #endif
 #ifdef ATL_AS_AIX_PPC
         .csect .text[PR]
@@ -202,7 +210,7 @@ Mjoin(.,ATL_USERMM):
 	.globl  Mjoin(_,ATL_USERMM)
 Mjoin(_,ATL_USERMM):
    #else
-      #if defined(ATL_USE64BITS)
+      #if defined(ATL_USE64BITS) && _CALL_ELF != 2
 /*
  *      Official Program Descripter section, seg fault w/o it on Linux/PPC64
  */
@@ -257,9 +265,17 @@ ATL_USERMM:
    #endif
 #endif
 
+
 #if defined (ATL_USE64BITS)
+#if _CALL_ELF == 2
+/* ABIv2 */
+        ld      pC0, 104(r1)
+        ld      incCn, 112(r1)
+#else
+/* ABIv1 */
         ld      pC0, 120(r1)
         ld      incCn, 128(r1)
+#endif
 #elif defined(ATL_AS_OSX_PPC) || defined(ATL_AS_AIX_PPC)
         lwz     pC0, 68(r1)
         lwz     incCn,  72(r1)
--- a/tune/blas/gemm/CASES/ATL_dmm4x4x2pf_av.c
+++ b/tune/blas/gemm/CASES/ATL_dmm4x4x2pf_av.c
@@ -405,8 +405,15 @@ Mjoin(_,ATL_USERMM):
  */
 #ifdef ATL_GAS_LINUX_PPC
    #ifdef ATL_USE64BITS
+      #if _CALL_ELF == 2
+      /* ABIv2 */
+        ld      pC0, 104(r1)
+        ld      incCn, 112(r1)
+      #else
+      /* ABIv1 */
 	ld 	pC0, 120(r1)
 	ld 	incCn, 128(r1)
+      #endif
    #else
 	lwz	incCn, FSIZE+8(r1)
    #endif