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 (f2cl-lib:cmplx
1.0 0.0)) (zero (f2cl-lib:cmplx
0.0 0.0)))
21 (declare (type (f2cl-lib:complex16
) one
)
22 (type (f2cl-lib:complex16
) zero
)
24 (defun zgemv (trans m n alpha a lda x incx beta y incy
)
25 (declare (type (array f2cl-lib
:complex16
(*)) y x a
)
26 (type (f2cl-lib:complex16
) beta alpha
)
27 (type (f2cl-lib:integer4
) incy incx lda n m
)
28 (type (simple-string *) trans
))
29 (f2cl-lib:with-multi-array-data
30 ((trans character trans-%data% trans-%offset%
)
31 (a f2cl-lib
:complex16 a-%data% a-%offset%
)
32 (x f2cl-lib
:complex16 x-%data% x-%offset%
)
33 (y f2cl-lib
:complex16 y-%data% y-%offset%
))
34 (prog ((noconj nil
) (i 0) (info 0) (ix 0) (iy 0) (j 0) (jx 0) (jy 0)
35 (kx 0) (ky 0) (lenx 0) (leny 0) (temp #C
(0.0
0.0)))
36 (declare (type f2cl-lib
:logical noconj
)
37 (type (f2cl-lib:integer4
) i info ix iy j jx jy kx ky lenx
39 (type (f2cl-lib:complex16
) temp
))
42 ((and (not (lsame trans
"N"))
43 (not (lsame trans
"T"))
44 (not (lsame trans
"C")))
50 ((< lda
(max (the f2cl-lib
:integer4
1) (the f2cl-lib
:integer4 m
)))
58 (xerbla "ZGEMV " info
)
60 (if (or (= m
0) (= n
0) (and (= alpha zero
) (= beta one
)))
62 (setf noconj
(lsame trans
"T"))
77 (f2cl-lib:int-sub lenx
1)
86 (f2cl-lib:int-sub leny
1)
94 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
97 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
101 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
104 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
106 (f2cl-lib:fref y-%data%
115 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
118 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
120 (setf iy
(f2cl-lib:int-add iy incy
))
123 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
126 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
128 (f2cl-lib:fref y-%data%
132 (setf iy
(f2cl-lib:int-add iy incy
))
134 (if (= alpha zero
) (go end_label
))
140 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
144 ((/= (f2cl-lib:fref x
(jx) ((1 *))) zero
)
147 (f2cl-lib:fref x-%data%
151 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
154 (setf (f2cl-lib:fref y-%data%
(i) ((1 *)) y-%offset%
)
156 (f2cl-lib:fref y-%data%
161 (f2cl-lib:fref a-%data%
166 (setf jx
(f2cl-lib:int-add jx incx
))
169 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
173 ((/= (f2cl-lib:fref x
(jx) ((1 *))) zero
)
176 (f2cl-lib:fref x-%data%
181 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
184 (setf (f2cl-lib:fref y-%data%
(iy) ((1 *)) y-%offset%
)
186 (f2cl-lib:fref y-%data%
191 (f2cl-lib:fref a-%data%
195 (setf iy
(f2cl-lib:int-add iy incy
))
197 (setf jx
(f2cl-lib:int-add jx incx
))
203 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
209 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
215 (f2cl-lib:fref a-%data%
219 (f2cl-lib:fref x-%data%
225 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
232 (f2cl-lib:fref a-%data%
236 (f2cl-lib:fref x-%data%
241 (setf (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
242 (+ (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
244 (setf jy
(f2cl-lib:int-add jy incy
))
247 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
254 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
260 (f2cl-lib:fref a-%data%
264 (f2cl-lib:fref x-%data%
268 (setf ix
(f2cl-lib:int-add ix incx
))
271 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
278 (f2cl-lib:fref a-%data%
282 (f2cl-lib:fref x-%data%
286 (setf ix
(f2cl-lib:int-add ix incx
))
288 (setf (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
289 (+ (f2cl-lib:fref y-%data%
(jy) ((1 *)) y-%offset%
)
291 (setf jy
(f2cl-lib:int-add jy incy
))
295 (return (values nil nil nil nil nil nil nil nil nil nil nil
))))))
297 (in-package #-gcl
#:cl-user
#+gcl
"CL-USER")
298 #+#.
(cl:if
(cl:find-package
'#:f2cl
) '(and) '(or))
299 (eval-when (:load-toplevel
:compile-toplevel
:execute
)
300 (setf (gethash 'fortran-to-lisp
::zgemv fortran-to-lisp
::*f2cl-function-info
*)
301 (fortran-to-lisp::make-f2cl-finfo
302 :arg-types
'((simple-string) (fortran-to-lisp::integer4
)
303 (fortran-to-lisp::integer4
)
304 (fortran-to-lisp::complex16
)
305 (array fortran-to-lisp
::complex16
(*))
306 (fortran-to-lisp::integer4
)
307 (array fortran-to-lisp
::complex16
(*))
308 (fortran-to-lisp::integer4
)
309 (fortran-to-lisp::complex16
)
310 (array fortran-to-lisp
::complex16
(*))
311 (fortran-to-lisp::integer4
))
312 :return-values
'(nil nil nil nil nil nil nil nil nil nil nil
)
313 :calls
'(fortran-to-lisp::xerbla fortran-to-lisp
::lsame
))))