1 ;;; Compiled by f2cl version:
2 ;;; ("f2cl1.l,v 2edcbd958861 2012/05/30 03:34:52 toy $"
3 ;;; "f2cl2.l,v 96616d88fb7e 2008/02/22 22:19:34 rtoy $"
4 ;;; "f2cl3.l,v 96616d88fb7e 2008/02/22 22:19:34 rtoy $"
5 ;;; "f2cl4.l,v 96616d88fb7e 2008/02/22 22:19:34 rtoy $"
6 ;;; "f2cl5.l,v 3fe93de3be82 2012/05/06 02:17:14 toy $"
7 ;;; "f2cl6.l,v 1d5cbacbb977 2008/08/24 00:56:27 rtoy $"
8 ;;; "macros.l,v 3fe93de3be82 2012/05/06 02:17:14 toy $")
10 ;;; Using Lisp CMU Common Lisp 20d (20D Unicode)
12 ;;; Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t)
13 ;;; (:coerce-assigns :as-needed) (:array-type ':array)
14 ;;; (:array-slicing t) (:declare-common nil)
15 ;;; (:float-format double-float))
20 (let* ((one 1.0) (zero 0.0))
21 (declare (type (double-float 1.0 1.0) one
)
22 (type (double-float 0.0 0.0) zero
)
24 (defun dsbmv (uplo n k alpha a lda x incx beta y incy
)
25 (declare (type (array double-float
(*)) y x a
)
26 (type (double-float) beta alpha
)
27 (type (f2cl-lib:integer4
) incy incx lda k n
)
28 (type (simple-string *) uplo
))
29 (f2cl-lib:with-multi-array-data
30 ((uplo character uplo-%data% uplo-%offset%
)
31 (a double-float a-%data% a-%offset%
)
32 (x double-float x-%data% x-%offset%
)
33 (y double-float y-%data% y-%offset%
))
34 (prog ((i 0) (info 0) (ix 0) (iy 0) (j 0) (jx 0) (jy 0) (kplus1 0) (kx 0)
35 (ky 0) (l 0) (temp1 0.0) (temp2 0.0))
36 (declare (type (f2cl-lib:integer4
) i info ix iy j jx jy kplus1 kx ky l
)
37 (type (double-float) temp1 temp2
))
40 ((and (not (lsame uplo
"U")) (not (lsame uplo
"L")))
46 ((< lda
(f2cl-lib:int-add k
1))
54 (xerbla "DSBMV " info
)
56 (if (or (= n
0) (and (= alpha zero
) (= beta one
))) (go end_label
))
63 (f2cl-lib:int-mul
(f2cl-lib:int-sub n
1)
71 (f2cl-lib:int-mul
(f2cl-lib:int-sub n
1)
79 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
82 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
86 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
89 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
91 (f2cl-lib:fref y-%data%
100 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
103 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
105 (setf iy
(f2cl-lib:int-add iy incy
))
108 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
111 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
113 (f2cl-lib:fref y-%data%
117 (setf iy
(f2cl-lib:int-add iy incy
))
119 (if (= alpha zero
) (go end_label
))
122 (setf kplus1
(f2cl-lib:int-add k
1))
124 ((and (= incx
1) (= incy
1))
125 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
130 (f2cl-lib:fref x-%data%
(j) ((1 *)) x-%offset%
)))
132 (setf l
(f2cl-lib:int-sub kplus1 j
))
134 (max (the f2cl-lib
:integer4
1)
135 (the f2cl-lib
:integer4
139 (f2cl-lib:int-add i
1))
141 (f2cl-lib:int-add j
(f2cl-lib:int-sub
1)))
144 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
146 (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
148 (f2cl-lib:fref a-%data%
149 ((f2cl-lib:int-add l i
) j
)
155 (f2cl-lib:fref a-%data%
156 ((f2cl-lib:int-add l i
) j
)
159 (f2cl-lib:fref x-%data%
164 (setf (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
165 (+ (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
167 (f2cl-lib:fref a-%data%
176 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
181 (f2cl-lib:fref x-%data%
(jx) ((1 *)) x-%offset%
)))
185 (setf l
(f2cl-lib:int-sub kplus1 j
))
187 (max (the f2cl-lib
:integer4
1)
188 (the f2cl-lib
:integer4
192 (f2cl-lib:int-add i
1))
194 (f2cl-lib:int-add j
(f2cl-lib:int-sub
1)))
197 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
199 (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
201 (f2cl-lib:fref a-%data%
202 ((f2cl-lib:int-add l i
) j
)
208 (f2cl-lib:fref a-%data%
209 ((f2cl-lib:int-add l i
) j
)
212 (f2cl-lib:fref x-%data%
216 (setf ix
(f2cl-lib:int-add ix incx
))
217 (setf iy
(f2cl-lib:int-add iy incy
))
219 (setf (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
220 (+ (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
222 (f2cl-lib:fref a-%data%
227 (setf jx
(f2cl-lib:int-add jx incx
))
228 (setf jy
(f2cl-lib:int-add jy incy
))
231 (setf kx
(f2cl-lib:int-add kx incx
))
232 (setf ky
(f2cl-lib:int-add ky incy
))))
236 ((and (= incx
1) (= incy
1))
237 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
242 (f2cl-lib:fref x-%data%
(j) ((1 *)) x-%offset%
)))
244 (setf (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
245 (+ (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
247 (f2cl-lib:fref a-%data%
251 (setf l
(f2cl-lib:int-sub
1 j
))
252 (f2cl-lib:fdo
(i (f2cl-lib:int-add j
1)
253 (f2cl-lib:int-add i
1))
255 (min (the f2cl-lib
:integer4 n
)
256 (the f2cl-lib
:integer4
257 (f2cl-lib:int-add j k
))))
260 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
262 (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
264 (f2cl-lib:fref a-%data%
265 ((f2cl-lib:int-add l i
) j
)
271 (f2cl-lib:fref a-%data%
272 ((f2cl-lib:int-add l i
) j
)
275 (f2cl-lib:fref x-%data%
280 (setf (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
281 (+ (f2cl-lib:fref y-%data%
(j) ((1 *)) y-%offset%
)
287 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
292 (f2cl-lib:fref x-%data%
(jx) ((1 *)) x-%offset%
)))
294 (setf (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
295 (+ (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
297 (f2cl-lib:fref a-%data%
301 (setf l
(f2cl-lib:int-sub
1 j
))
304 (f2cl-lib:fdo
(i (f2cl-lib:int-add j
1)
305 (f2cl-lib:int-add i
1))
307 (min (the f2cl-lib
:integer4 n
)
308 (the f2cl-lib
:integer4
309 (f2cl-lib:int-add j k
))))
312 (setf ix
(f2cl-lib:int-add ix incx
))
313 (setf iy
(f2cl-lib:int-add iy incy
))
314 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
316 (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
318 (f2cl-lib:fref a-%data%
319 ((f2cl-lib:int-add l i
) j
)
325 (f2cl-lib:fref a-%data%
326 ((f2cl-lib:int-add l i
) j
)
329 (f2cl-lib:fref x-%data%
334 (setf (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
335 (+ (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
337 (setf jx
(f2cl-lib:int-add jx incx
))
338 (setf jy
(f2cl-lib:int-add jy incy
))
342 (return (values nil nil nil nil nil nil nil nil nil nil nil
))))))
344 (in-package #-gcl
#:cl-user
#+gcl
"CL-USER")
345 #+#.
(cl:if
(cl:find-package
'#:f2cl
) '(and) '(or))
346 (eval-when (:load-toplevel
:compile-toplevel
:execute
)
347 (setf (gethash 'fortran-to-lisp
::dsbmv fortran-to-lisp
::*f2cl-function-info
*)
348 (fortran-to-lisp::make-f2cl-finfo
349 :arg-types
'((simple-string) (fortran-to-lisp::integer4
)
350 (fortran-to-lisp::integer4
) (double-float)
351 (array double-float
(*)) (fortran-to-lisp::integer4
)
352 (array double-float
(*)) (fortran-to-lisp::integer4
)
353 (double-float) (array double-float
(*))
354 (fortran-to-lisp::integer4
))
355 :return-values
'(nil nil nil nil nil nil nil nil nil nil nil
)
356 :calls
'(fortran-to-lisp::xerbla fortran-to-lisp
::lsame
))))