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 zsymm (side uplo m n alpha a lda b ldb$ beta c ldc
)
25 (declare (type (array f2cl-lib
:complex16
(*)) c b a
)
26 (type (f2cl-lib:complex16
) beta alpha
)
27 (type (f2cl-lib:integer4
) ldc ldb$ lda n m
)
28 (type (simple-string *) uplo side
))
29 (f2cl-lib:with-multi-array-data
30 ((side character side-%data% side-%offset%
)
31 (uplo character uplo-%data% uplo-%offset%
)
32 (a f2cl-lib
:complex16 a-%data% a-%offset%
)
33 (b f2cl-lib
:complex16 b-%data% b-%offset%
)
34 (c f2cl-lib
:complex16 c-%data% c-%offset%
))
35 (prog ((temp1 #C
(0.0
0.0)) (temp2 #C
(0.0
0.0)) (i 0) (info 0) (j 0) (k 0)
36 (nrowa 0) (upper nil
))
37 (declare (type (f2cl-lib:complex16
) temp1 temp2
)
38 (type (f2cl-lib:integer4
) i info j k nrowa
)
39 (type f2cl-lib
:logical upper
))
45 (setf upper
(lsame uplo
"U"))
48 ((and (not (lsame side
"L")) (not (lsame side
"R")))
50 ((and (not upper
) (not (lsame uplo
"L")))
56 ((< lda
(max (the f2cl-lib
:integer4
1) (the f2cl-lib
:integer4 nrowa
)))
58 ((< ldb$
(max (the f2cl-lib
:integer4
1) (the f2cl-lib
:integer4 m
)))
60 ((< ldc
(max (the f2cl-lib
:integer4
1) (the f2cl-lib
:integer4 m
)))
64 (xerbla "ZSYMM " info
)
66 (if (or (= m
0) (= n
0) (and (= alpha zero
) (= beta one
)))
72 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
75 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
78 (setf (f2cl-lib:fref c-%data%
86 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
89 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
92 (setf (f2cl-lib:fref c-%data%
97 (f2cl-lib:fref c-%data%
108 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
111 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
116 (f2cl-lib:fref b-%data%
121 (f2cl-lib:fdo
(k 1 (f2cl-lib:int-add k
1))
128 (setf (f2cl-lib:fref c-%data%
133 (f2cl-lib:fref c-%data%
138 (f2cl-lib:fref a-%data%
145 (f2cl-lib:fref b-%data%
149 (f2cl-lib:fref a-%data%
156 (setf (f2cl-lib:fref c-%data%
162 (f2cl-lib:fref a-%data%
168 (setf (f2cl-lib:fref c-%data%
174 (f2cl-lib:fref c-%data%
179 (f2cl-lib:fref a-%data%
187 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
190 (f2cl-lib:fdo
(i m
(f2cl-lib:int-add i
(f2cl-lib:int-sub
1)))
195 (f2cl-lib:fref b-%data%
200 (f2cl-lib:fdo
(k (f2cl-lib:int-add i
1)
201 (f2cl-lib:int-add k
1))
204 (setf (f2cl-lib:fref c-%data%
209 (f2cl-lib:fref c-%data%
214 (f2cl-lib:fref a-%data%
221 (f2cl-lib:fref b-%data%
225 (f2cl-lib:fref a-%data%
232 (setf (f2cl-lib:fref c-%data%
238 (f2cl-lib:fref a-%data%
244 (setf (f2cl-lib:fref c-%data%
250 (f2cl-lib:fref c-%data%
255 (f2cl-lib:fref a-%data%
263 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
268 (f2cl-lib:fref a-%data%
274 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
277 (setf (f2cl-lib:fref c-%data%
282 (f2cl-lib:fref b-%data%
288 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
291 (setf (f2cl-lib:fref c-%data%
297 (f2cl-lib:fref c-%data%
302 (f2cl-lib:fref b-%data%
307 (f2cl-lib:fdo
(k 1 (f2cl-lib:int-add k
1))
308 ((> k
(f2cl-lib:int-add j
(f2cl-lib:int-sub
1)))
315 (f2cl-lib:fref a-%data%
322 (f2cl-lib:fref a-%data%
326 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
329 (setf (f2cl-lib:fref c-%data%
334 (f2cl-lib:fref c-%data%
339 (f2cl-lib:fref b-%data%
345 (f2cl-lib:fdo
(k (f2cl-lib:int-add j
1) (f2cl-lib:int-add k
1))
352 (f2cl-lib:fref a-%data%
359 (f2cl-lib:fref a-%data%
363 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
366 (setf (f2cl-lib:fref c-%data%
371 (f2cl-lib:fref c-%data%
376 (f2cl-lib:fref b-%data%
385 (return (values nil nil nil nil nil nil nil nil nil nil nil nil
))))))
387 (in-package #:cl-user
)
388 #+#.
(cl:if
(cl:find-package
'#:f2cl
) '(and) '(or))
389 (eval-when (:load-toplevel
:compile-toplevel
:execute
)
390 (setf (gethash 'fortran-to-lisp
::zsymm fortran-to-lisp
::*f2cl-function-info
*)
391 (fortran-to-lisp::make-f2cl-finfo
392 :arg-types
'((simple-string) (simple-string)
393 (fortran-to-lisp::integer4
) (fortran-to-lisp::integer4
)
394 (fortran-to-lisp::complex16
)
395 (array fortran-to-lisp
::complex16
(*))
396 (fortran-to-lisp::integer4
)
397 (array fortran-to-lisp
::complex16
(*))
398 (fortran-to-lisp::integer4
)
399 (fortran-to-lisp::complex16
)
400 (array fortran-to-lisp
::complex16
(*))
401 (fortran-to-lisp::integer4
))
402 :return-values
'(nil nil nil nil nil nil nil nil nil nil nil nil
)
403 :calls
'(fortran-to-lisp::xerbla fortran-to-lisp
::lsame
))))