Skip to content

Commit 71fbdd9

Browse files
authored
Apply ROUNDUP_LWORK (Reference-LAPACK PR 904)
1 parent c9378ba commit 71fbdd9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+282
-228
lines changed

lapack-netlib/SRC/chetrd_he2hb.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@
158158
*> \author Univ. of Colorado Denver
159159
*> \author NAG Ltd.
160160
*
161-
*> \ingroup complexHEcomputational
161+
*> \ingroup hetrd_he2hb
162162
*
163163
*> \par Further Details:
164164
* =====================
@@ -283,7 +283,8 @@ SUBROUTINE CHETRD_HE2HB( UPLO, N, KD, A, LDA, AB, LDAB, TAU,
283283
* .. External Functions ..
284284
LOGICAL LSAME
285285
INTEGER ILAENV2STAGE
286-
EXTERNAL LSAME, ILAENV2STAGE
286+
REAL SROUNDUP_LWORK
287+
EXTERNAL LSAME, ILAENV2STAGE, SROUNDUP_LWORK
287288
* ..
288289
* .. Executable Statements ..
289290
*
@@ -313,7 +314,7 @@ SUBROUTINE CHETRD_HE2HB( UPLO, N, KD, A, LDA, AB, LDAB, TAU,
313314
CALL XERBLA( 'CHETRD_HE2HB', -INFO )
314315
RETURN
315316
ELSE IF( LQUERY ) THEN
316-
WORK( 1 ) = LWMIN
317+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
317318
RETURN
318319
END IF
319320
*
@@ -506,7 +507,7 @@ SUBROUTINE CHETRD_HE2HB( UPLO, N, KD, A, LDA, AB, LDAB, TAU,
506507

507508
END IF
508509
*
509-
WORK( 1 ) = LWMIN
510+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
510511
RETURN
511512
*
512513
* End of CHETRD_HE2HB

lapack-netlib/SRC/chetrf.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
*> \author Univ. of Colorado Denver
131131
*> \author NAG Ltd.
132132
*
133-
*> \ingroup complexHEcomputational
133+
*> \ingroup hetrf
134134
*
135135
*> \par Further Details:
136136
* =====================
@@ -197,7 +197,8 @@ SUBROUTINE CHETRF( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
197197
* .. External Functions ..
198198
LOGICAL LSAME
199199
INTEGER ILAENV
200-
EXTERNAL LSAME, ILAENV
200+
REAL SROUNDUP_LWORK
201+
EXTERNAL LSAME, ILAENV, SROUNDUP_LWORK
201202
* ..
202203
* .. External Subroutines ..
203204
EXTERNAL CHETF2, CLAHEF, XERBLA
@@ -228,7 +229,7 @@ SUBROUTINE CHETRF( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
228229
*
229230
NB = ILAENV( 1, 'CHETRF', UPLO, N, -1, -1, -1 )
230231
LWKOPT = N*NB
231-
WORK( 1 ) = LWKOPT
232+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
232233
END IF
233234
*
234235
IF( INFO.NE.0 ) THEN
@@ -346,7 +347,7 @@ SUBROUTINE CHETRF( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
346347
END IF
347348
*
348349
40 CONTINUE
349-
WORK( 1 ) = LWKOPT
350+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
350351
RETURN
351352
*
352353
* End of CHETRF

lapack-netlib/SRC/chetrf_aa.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@
125125
*> \author Univ. of Colorado Denver
126126
*> \author NAG Ltd.
127127
*
128-
*> \ingroup complexHEcomputational
128+
*> \ingroup hetrf_aa
129129
*
130130
* =====================================================================
131131
SUBROUTINE CHETRF_AA( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO)
@@ -159,7 +159,8 @@ SUBROUTINE CHETRF_AA( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO)
159159
* .. External Functions ..
160160
LOGICAL LSAME
161161
INTEGER ILAENV
162-
EXTERNAL LSAME, ILAENV
162+
REAL SROUNDUP_LWORK
163+
EXTERNAL LSAME, ILAENV, SROUNDUP_LWORK
163164
* ..
164165
* .. External Subroutines ..
165166
EXTERNAL CLAHEF_AA, CGEMM, CCOPY, CSWAP, CSCAL, XERBLA
@@ -190,7 +191,7 @@ SUBROUTINE CHETRF_AA( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO)
190191
*
191192
IF( INFO.EQ.0 ) THEN
192193
LWKOPT = (NB+1)*N
193-
WORK( 1 ) = LWKOPT
194+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
194195
END IF
195196
*
196197
IF( INFO.NE.0 ) THEN
@@ -459,7 +460,7 @@ SUBROUTINE CHETRF_AA( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO)
459460
END IF
460461
*
461462
20 CONTINUE
462-
WORK( 1 ) = LWKOPT
463+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
463464
RETURN
464465
*
465466
* End of CHETRF_AA

lapack-netlib/SRC/chetrf_rk.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@
229229
*> \author Univ. of Colorado Denver
230230
*> \author NAG Ltd.
231231
*
232-
*> \ingroup complexHEcomputational
232+
*> \ingroup hetrf_rk
233233
*
234234
*> \par Further Details:
235235
* =====================
@@ -280,7 +280,8 @@ SUBROUTINE CHETRF_RK( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
280280
* .. External Functions ..
281281
LOGICAL LSAME
282282
INTEGER ILAENV
283-
EXTERNAL LSAME, ILAENV
283+
REAL SROUNDUP_LWORK
284+
EXTERNAL LSAME, ILAENV, SROUNDUP_LWORK
284285
* ..
285286
* .. External Subroutines ..
286287
EXTERNAL CLAHEF_RK, CHETF2_RK, CSWAP, XERBLA
@@ -311,7 +312,7 @@ SUBROUTINE CHETRF_RK( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
311312
*
312313
NB = ILAENV( 1, 'CHETRF_RK', UPLO, N, -1, -1, -1 )
313314
LWKOPT = N*NB
314-
WORK( 1 ) = LWKOPT
315+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
315316
END IF
316317
*
317318
IF( INFO.NE.0 ) THEN
@@ -487,7 +488,7 @@ SUBROUTINE CHETRF_RK( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
487488
*
488489
END IF
489490
*
490-
WORK( 1 ) = LWKOPT
491+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
491492
RETURN
492493
*
493494
* End of CHETRF_RK

lapack-netlib/SRC/chetrf_rook.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@
150150
*> \author Univ. of Colorado Denver
151151
*> \author NAG Ltd.
152152
*
153-
*> \ingroup complexHEcomputational
153+
*> \ingroup hetrf_rook
154154
*
155155
*> \par Further Details:
156156
* =====================
@@ -232,7 +232,8 @@ SUBROUTINE CHETRF_ROOK( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
232232
* .. External Functions ..
233233
LOGICAL LSAME
234234
INTEGER ILAENV
235-
EXTERNAL LSAME, ILAENV
235+
REAL SROUNDUP_LWORK
236+
EXTERNAL LSAME, ILAENV, SROUNDUP_LWORK
236237
* ..
237238
* .. External Subroutines ..
238239
EXTERNAL CLAHEF_ROOK, CHETF2_ROOK, XERBLA
@@ -263,7 +264,7 @@ SUBROUTINE CHETRF_ROOK( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
263264
*
264265
NB = ILAENV( 1, 'CHETRF_ROOK', UPLO, N, -1, -1, -1 )
265266
LWKOPT = MAX( 1, N*NB )
266-
WORK( 1 ) = LWKOPT
267+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
267268
END IF
268269
*
269270
IF( INFO.NE.0 ) THEN
@@ -386,7 +387,7 @@ SUBROUTINE CHETRF_ROOK( UPLO, N, A, LDA, IPIV, WORK, LWORK, INFO )
386387
END IF
387388
*
388389
40 CONTINUE
389-
WORK( 1 ) = LWKOPT
390+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
390391
RETURN
391392
*
392393
* End of CHETRF_ROOK

lapack-netlib/SRC/chetri_3.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@
152152
*> \author Univ. of Colorado Denver
153153
*> \author NAG Ltd.
154154
*
155-
*> \ingroup complexHEcomputational
155+
*> \ingroup hetri_3
156156
*
157157
*> \par Contributors:
158158
* ==================
@@ -190,7 +190,8 @@ SUBROUTINE CHETRI_3( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
190190
* .. External Functions ..
191191
LOGICAL LSAME
192192
INTEGER ILAENV
193-
EXTERNAL LSAME, ILAENV
193+
REAL SROUNDUP_LWORK
194+
EXTERNAL LSAME, ILAENV, SROUNDUP_LWORK
194195
* ..
195196
* .. External Subroutines ..
196197
EXTERNAL CHETRI_3X, XERBLA
@@ -225,7 +226,7 @@ SUBROUTINE CHETRI_3( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
225226
CALL XERBLA( 'CHETRI_3', -INFO )
226227
RETURN
227228
ELSE IF( LQUERY ) THEN
228-
WORK( 1 ) = LWKOPT
229+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
229230
RETURN
230231
END IF
231232
*
@@ -236,7 +237,7 @@ SUBROUTINE CHETRI_3( UPLO, N, A, LDA, E, IPIV, WORK, LWORK,
236237
*
237238
CALL CHETRI_3X( UPLO, N, A, LDA, E, IPIV, WORK, NB, INFO )
238239
*
239-
WORK( 1 ) = LWKOPT
240+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
240241
*
241242
RETURN
242243
*

lapack-netlib/SRC/chetrs_aa.f

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@
123123
*> \author Univ. of Colorado Denver
124124
*> \author NAG Ltd.
125125
*
126-
*> \ingroup complexHEcomputational
126+
*> \ingroup hetrs_aa
127127
*
128128
* =====================================================================
129129
SUBROUTINE CHETRS_AA( UPLO, N, NRHS, A, LDA, IPIV, B, LDB,
@@ -155,7 +155,8 @@ SUBROUTINE CHETRS_AA( UPLO, N, NRHS, A, LDA, IPIV, B, LDB,
155155
* ..
156156
* .. External Functions ..
157157
LOGICAL LSAME
158-
EXTERNAL LSAME
158+
REAL SROUNDUP_LWORK
159+
EXTERNAL LSAME,SROUNDUP_LWORK
159160
* ..
160161
* .. External Subroutines ..
161162
EXTERNAL CLACPY, CLACGV, CGTSV, CSWAP, CTRSM, XERBLA
@@ -186,7 +187,7 @@ SUBROUTINE CHETRS_AA( UPLO, N, NRHS, A, LDA, IPIV, B, LDB,
186187
RETURN
187188
ELSE IF( LQUERY ) THEN
188189
LWKOPT = (3*N-2)
189-
WORK( 1 ) = LWKOPT
190+
WORK( 1 ) = SROUNDUP_LWORK(LWKOPT)
190191
RETURN
191192
END IF
192193
*

lapack-netlib/SRC/chpevd.f

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
*> \author Univ. of Colorado Denver
187187
*> \author NAG Ltd.
188188
*
189-
*> \ingroup complexOTHEReigen
189+
*> \ingroup hpevd
190190
*
191191
* =====================================================================
192192
SUBROUTINE CHPEVD( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK,
@@ -223,8 +223,8 @@ SUBROUTINE CHPEVD( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK,
223223
* ..
224224
* .. External Functions ..
225225
LOGICAL LSAME
226-
REAL CLANHP, SLAMCH
227-
EXTERNAL LSAME, CLANHP, SLAMCH
226+
REAL CLANHP, SLAMCH, SROUNDUP_LWORK
227+
EXTERNAL LSAME, CLANHP, SLAMCH, SROUNDUP_LWORK
228228
* ..
229229
* .. External Subroutines ..
230230
EXTERNAL CHPTRD, CSSCAL, CSTEDC, CUPMTR, SSCAL, SSTERF,
@@ -268,7 +268,7 @@ SUBROUTINE CHPEVD( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK,
268268
LIWMIN = 1
269269
END IF
270270
END IF
271-
WORK( 1 ) = LWMIN
271+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
272272
RWORK( 1 ) = LRWMIN
273273
IWORK( 1 ) = LIWMIN
274274
*
@@ -359,7 +359,7 @@ SUBROUTINE CHPEVD( JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK,
359359
CALL SSCAL( IMAX, ONE / SIGMA, W, 1 )
360360
END IF
361361
*
362-
WORK( 1 ) = LWMIN
362+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
363363
RWORK( 1 ) = LRWMIN
364364
IWORK( 1 ) = LIWMIN
365365
RETURN

lapack-netlib/SRC/chpgvd.f

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@
212212
*> \author Univ. of Colorado Denver
213213
*> \author NAG Ltd.
214214
*
215-
*> \ingroup complexOTHEReigen
215+
*> \ingroup hpgvd
216216
*
217217
*> \par Contributors:
218218
* ==================
@@ -246,7 +246,8 @@ SUBROUTINE CHPGVD( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK,
246246
* ..
247247
* .. External Functions ..
248248
LOGICAL LSAME
249-
EXTERNAL LSAME
249+
REAL SROUNDUP_LWORK
250+
EXTERNAL LSAME, SROUNDUP_LWORK
250251
* ..
251252
* .. External Subroutines ..
252253
EXTERNAL CHPEVD, CHPGST, CPPTRF, CTPMV, CTPSV, XERBLA
@@ -292,7 +293,7 @@ SUBROUTINE CHPGVD( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK,
292293
END IF
293294
END IF
294295
*
295-
WORK( 1 ) = LWMIN
296+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
296297
RWORK( 1 ) = LRWMIN
297298
IWORK( 1 ) = LIWMIN
298299
IF( LWORK.LT.LWMIN .AND. .NOT.LQUERY ) THEN
@@ -374,7 +375,7 @@ SUBROUTINE CHPGVD( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK,
374375
END IF
375376
END IF
376377
*
377-
WORK( 1 ) = LWMIN
378+
WORK( 1 ) = SROUNDUP_LWORK(LWMIN)
378379
RWORK( 1 ) = LRWMIN
379380
IWORK( 1 ) = LIWMIN
380381
RETURN

lapack-netlib/SRC/chseqr.f

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@
216216
*> \author Univ. of Colorado Denver
217217
*> \author NAG Ltd.
218218
*
219-
*> \ingroup complexOTHERcomputational
219+
*> \ingroup hseqr
220220
*
221221
*> \par Contributors:
222222
* ==================
@@ -343,7 +343,8 @@ SUBROUTINE CHSEQR( JOB, COMPZ, N, ILO, IHI, H, LDH, W, Z, LDZ,
343343
* .. External Functions ..
344344
INTEGER ILAENV
345345
LOGICAL LSAME
346-
EXTERNAL ILAENV, LSAME
346+
REAL SROUNDUP_LWORK
347+
EXTERNAL ILAENV, LSAME, SROUNDUP_LWORK
347348
* ..
348349
* .. External Subroutines ..
349350
EXTERNAL CCOPY, CLACPY, CLAHQR, CLAQR0, CLASET, XERBLA

0 commit comments

Comments
 (0)