Skip to content

Commit d5e6940

Browse files
authored
Fix declaration of input arguments in the x86_64 microkernels for DOT and AXPY (#1965)
* Tag operands 0 and 1 as both input and output For #1964 (basically a continuation of coding problems first seen in #1292)
1 parent 24e697e commit d5e6940

37 files changed

+202
-202
lines changed

kernel/x86_64/caxpy_microk_bulldozer-2.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,9 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
114114
"vzeroupper \n\t"
115115

116116
:
117-
:
118-
"r" (i), // 0
119-
"r" (n), // 1
117+
"+r" (i), // 0
118+
"+r" (n) // 1
119+
:
120120
"r" (x), // 2
121121
"r" (y), // 3
122122
"r" (alpha), // 4
@@ -180,10 +180,10 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
180180
"jnz 1b \n\t"
181181
"vzeroupper \n\t"
182182

183-
:
184-
:
185-
"r" (i), // 0
186-
"r" (n), // 1
183+
:
184+
"+r" (i), // 0
185+
"+r" (n) // 1
186+
:
187187
"r" (x), // 2
188188
"r" (y), // 3
189189
"r" (alpha), // 4

kernel/x86_64/caxpy_microk_haswell-2.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,9 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
112112
"vzeroupper \n\t"
113113

114114
:
115-
:
116-
"r" (i), // 0
117-
"r" (n), // 1
115+
"+r" (i), // 0
116+
"+r" (n) // 1
117+
:
118118
"r" (x), // 2
119119
"r" (y), // 3
120120
"r" (alpha), // 4

kernel/x86_64/caxpy_microk_sandy-2.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,10 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
9595
"jnz 1b \n\t"
9696
"vzeroupper \n\t"
9797

98-
:
99-
:
100-
"r" (i), // 0
101-
"r" (n), // 1
98+
:
99+
"+r" (i), // 0
100+
"+r" (n) // 1
101+
:
102102
"r" (x), // 2
103103
"r" (y), // 3
104104
"r" (alpha), // 4

kernel/x86_64/caxpy_microk_steamroller-2.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,10 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
113113
"jnz 1b \n\t"
114114
"vzeroupper \n\t"
115115

116-
:
117-
:
118-
"r" (i), // 0
119-
"r" (n), // 1
116+
:
117+
"+r" (i), // 0
118+
"+r" (n) // 1
119+
:
120120
"r" (x), // 2
121121
"r" (y), // 3
122122
"r" (alpha), // 4
@@ -181,9 +181,9 @@ static void caxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
181181
"vzeroupper \n\t"
182182

183183
:
184-
:
185-
"r" (i), // 0
186-
"r" (n), // 1
184+
"+r" (i), // 0
185+
"+r" (n) // 1
186+
:
187187
"r" (x), // 2
188188
"r" (y), // 3
189189
"r" (alpha), // 4

kernel/x86_64/cdot_microk_bulldozer-2.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
9797
"vzeroupper \n\t"
9898

9999
:
100-
:
101-
"r" (i), // 0
102-
"r" (n), // 1
100+
"+r" (i), // 0
101+
"+r" (n) // 1
102+
:
103103
"r" (x), // 2
104104
"r" (y), // 3
105105
"r" (dot) // 4
@@ -175,10 +175,10 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
175175
"vmovups %%xmm4, 16(%4) \n\t"
176176
"vzeroupper \n\t"
177177

178-
:
179-
:
180-
"r" (i), // 0
181-
"r" (n), // 1
178+
:
179+
"+r" (i), // 0
180+
"+r" (n) // 1
181+
:
182182
"r" (x), // 2
183183
"r" (y), // 3
184184
"r" (dot) // 4

kernel/x86_64/cdot_microk_haswell-2.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
9898
"vzeroupper \n\t"
9999

100100
:
101-
:
102-
"r" (i), // 0
103-
"r" (n), // 1
101+
"+r" (i), // 0
102+
"+r" (n) // 1
103+
:
104104
"r" (x), // 2
105105
"r" (y), // 3
106106
"r" (dot) // 4

kernel/x86_64/cdot_microk_sandy-2.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,10 +105,10 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
105105
"vmovups %%xmm4, 16(%4) \n\t"
106106
"vzeroupper \n\t"
107107

108-
:
109-
:
110-
"r" (i), // 0
111-
"r" (n), // 1
108+
:
109+
"+r" (i), // 0
110+
"+r" (n) // 1
111+
:
112112
"r" (x), // 2
113113
"r" (y), // 3
114114
"r" (dot) // 4

kernel/x86_64/cdot_microk_steamroller-2.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
9797
"vzeroupper \n\t"
9898

9999
:
100-
:
101-
"r" (i), // 0
102-
"r" (n), // 1
100+
"+r" (i), // 0
101+
"+r" (n) // 1
102+
:
103103
"r" (x), // 2
104104
"r" (y), // 3
105105
"r" (dot) // 4
@@ -175,10 +175,10 @@ static void cdot_kernel_16( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *dot)
175175
"vmovups %%xmm4, 16(%4) \n\t"
176176
"vzeroupper \n\t"
177177

178-
:
179-
:
180-
"r" (i), // 0
181-
"r" (n), // 1
178+
:
179+
"+r" (i), // 0
180+
"+r" (n) // 1
181+
:
182182
"r" (x), // 2
183183
"r" (y), // 3
184184
"r" (dot) // 4

kernel/x86_64/daxpy_microk_bulldozer-2.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,9 @@ static void daxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
6464
"jnz 1b \n\t"
6565

6666
:
67-
:
68-
"r" (i), // 0
69-
"r" (n), // 1
67+
"+r" (i), // 0
68+
"+r" (n) // 1
69+
:
7070
"r" (x), // 2
7171
"r" (y), // 3
7272
"r" (alpha) // 4

kernel/x86_64/daxpy_microk_haswell-2.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,10 @@ static void daxpy_kernel_8( BLASLONG n, FLOAT *x, FLOAT *y, FLOAT *alpha)
5959
"jnz 1b \n\t"
6060
"vzeroupper \n\t"
6161

62-
:
63-
:
64-
"r" (i), // 0
65-
"r" (n), // 1
62+
:
63+
"+r" (i), // 0
64+
"+r" (n) // 1
65+
:
6666
"r" (x), // 2
6767
"r" (y), // 3
6868
"r" (alpha) // 4

0 commit comments

Comments
 (0)