LAPACK  3.9.1
LAPACK: Linear Algebra PACKage

◆ iparmq()

integer function iparmq ( integer  ISPEC,
character, dimension( * )  NAME,
character, dimension( * )  OPTS,
integer  N,
integer  ILO,
integer  IHI,
integer  LWORK 
)

Definition at line 298 of file ilaenv.f.

299 *
300  INTEGER INMIN, INWIN, INIBL, ISHFTS, IACC22
301  parameter( inmin = 12, inwin = 13, inibl = 14,
302  $ ishfts = 15, iacc22 = 16 )
303  INTEGER NMIN, K22MIN, KACMIN, NIBBLE, KNWSWP
304  parameter( nmin = 11, k22min = 14, kacmin = 14,
305  $ nibble = 14, knwswp = 500 )
306  REAL TWO
307  parameter( two = 2.0 )
308 * ..
309 * .. Scalar Arguments ..
310  INTEGER IHI, ILO, ISPEC, LWORK, N
311  CHARACTER NAME*( * ), OPTS*( * )
312 * ..
313 * .. Local Scalars ..
314  INTEGER NH, NS
315 * ..
316 * .. Intrinsic Functions ..
317  INTRINSIC log, max, mod, nint, real
318 * ..
319 * .. Executable Statements ..
320  IF( ( ispec.EQ.ishfts ) .OR. ( ispec.EQ.inwin ) .OR.
321  $ ( ispec.EQ.iacc22 ) ) THEN
322 *
323 * ==== Set the number simultaneous shifts ====
324 *
325  nh = ihi - ilo + 1
326  ns = 2
327  IF( nh.GE.30 )
328  $ ns = 4
329  IF( nh.GE.60 )
330  $ ns = 10
331  IF( nh.GE.150 )
332  $ ns = max( 10, nh / nint( log( real( nh ) ) / log( two ) ) )
333  IF( nh.GE.590 )
334  $ ns = 64
335  IF( nh.GE.3000 )
336  $ ns = 128
337  IF( nh.GE.6000 )
338  $ ns = 256
339  ns = max( 2, ns-mod( ns, 2 ) )
340  END IF
341 *
342  IF( ispec.EQ.inmin ) THEN
343 *
344 *
345 * ===== Matrices of order smaller than NMIN get sent
346 * . to LAHQR, the classic double shift algorithm.
347 * . This must be at least 11. ====
348 *
349  iparmq = nmin
350 *
351  ELSE IF( ispec.EQ.inibl ) THEN
352 *
353 * ==== INIBL: skip a multi-shift qr iteration and
354 * . whenever aggressive early deflation finds
355 * . at least (NIBBLE*(window size)/100) deflations. ====
356 *
357  iparmq = nibble
358 *
359  ELSE IF( ispec.EQ.ishfts ) THEN
360 *
361 * ==== NSHFTS: The number of simultaneous shifts =====
362 *
363  iparmq = ns
364 *
365  ELSE IF( ispec.EQ.inwin ) THEN
366 *
367 * ==== NW: deflation window size. ====
368 *
369  IF( nh.LE.knwswp ) THEN
370  iparmq = ns
371  ELSE
372  iparmq = 3*ns / 2
373  END IF
374 *
375  ELSE IF( ispec.EQ.iacc22 ) THEN
376 *
377 * ==== IACC22: Whether to accumulate reflections
378 * . before updating the far-from-diagonal elements
379 * . and whether to use 2-by-2 block structure while
380 * . doing it. A small amount of work could be saved
381 * . by making this choice dependent also upon the
382 * . NH=IHI-ILO+1.
383 *
384  iparmq = 0
385  IF( ns.GE.kacmin )
386  $ iparmq = 1
387  IF( ns.GE.k22min )
388  $ iparmq = 2
389 *
390  ELSE
391 * ===== invalid value of ispec =====
392  iparmq = -1
393 *
394  END IF
395 *
396 * ==== End of IPARMQ ====
397 *
integer function iparmq(ISPEC, NAME, OPTS, N, ILO, IHI, LWORK)
IPARMQ
Definition: iparmq.f:222
Here is the call graph for this function: