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))
21 (declare (type (double-float 0.0 0.0) zero
) (ignorable zero
))
22 (defun dsyr2 (uplo n alpha x incx y incy a lda
)
23 (declare (type (array double-float
(*)) a y x
)
24 (type (double-float) alpha
)
25 (type (f2cl-lib:integer4
) lda incy incx n
)
26 (type (simple-string *) uplo
))
27 (f2cl-lib:with-multi-array-data
28 ((uplo character uplo-%data% uplo-%offset%
)
29 (x double-float x-%data% x-%offset%
)
30 (y double-float y-%data% y-%offset%
)
31 (a double-float a-%data% a-%offset%
))
32 (prog ((i 0) (info 0) (ix 0) (iy 0) (j 0) (jx 0) (jy 0) (kx 0) (ky 0)
33 (temp1 0.0) (temp2 0.0))
34 (declare (type (f2cl-lib:integer4
) i info ix iy j jx jy kx ky
)
35 (type (double-float) temp1 temp2
))
38 ((and (not (lsame uplo
"U")) (not (lsame uplo
"L")))
46 ((< lda
(max (the f2cl-lib
:integer4
1) (the f2cl-lib
:integer4 n
)))
50 (xerbla "DSYR2 " info
)
52 (if (or (= n
0) (= alpha zero
)) (go end_label
))
54 ((or (/= incx
1) (/= incy
1))
62 (f2cl-lib:int-sub n
1)
71 (f2cl-lib:int-sub n
1)
78 ((and (= incx
1) (= incy
1))
79 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
83 ((or (/= (f2cl-lib:fref x
(j) ((1 *))) zero
)
84 (/= (f2cl-lib:fref y
(j) ((1 *))) zero
))
87 (f2cl-lib:fref y-%data%
93 (f2cl-lib:fref x-%data%
97 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
100 (setf (f2cl-lib:fref a-%data%
105 (f2cl-lib:fref a-%data%
110 (f2cl-lib:fref x-%data%
116 (f2cl-lib:fref y-%data%
124 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
128 ((or (/= (f2cl-lib:fref x
(jx) ((1 *))) zero
)
129 (/= (f2cl-lib:fref y
(jy) ((1 *))) zero
))
132 (f2cl-lib:fref y-%data%
138 (f2cl-lib:fref x-%data%
144 (f2cl-lib:fdo
(i 1 (f2cl-lib:int-add i
1))
147 (setf (f2cl-lib:fref a-%data%
152 (f2cl-lib:fref a-%data%
157 (f2cl-lib:fref x-%data%
163 (f2cl-lib:fref y-%data%
168 (setf ix
(f2cl-lib:int-add ix incx
))
169 (setf iy
(f2cl-lib:int-add iy incy
))
171 (setf jx
(f2cl-lib:int-add jx incx
))
172 (setf jy
(f2cl-lib:int-add jy incy
))
176 ((and (= incx
1) (= incy
1))
177 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
181 ((or (/= (f2cl-lib:fref x
(j) ((1 *))) zero
)
182 (/= (f2cl-lib:fref y
(j) ((1 *))) zero
))
185 (f2cl-lib:fref y-%data%
191 (f2cl-lib:fref x-%data%
195 (f2cl-lib:fdo
(i j
(f2cl-lib:int-add i
1))
198 (setf (f2cl-lib:fref a-%data%
203 (f2cl-lib:fref a-%data%
208 (f2cl-lib:fref x-%data%
214 (f2cl-lib:fref y-%data%
222 (f2cl-lib:fdo
(j 1 (f2cl-lib:int-add j
1))
226 ((or (/= (f2cl-lib:fref x
(jx) ((1 *))) zero
)
227 (/= (f2cl-lib:fref y
(jy) ((1 *))) zero
))
230 (f2cl-lib:fref y-%data%
236 (f2cl-lib:fref x-%data%
242 (f2cl-lib:fdo
(i j
(f2cl-lib:int-add i
1))
245 (setf (f2cl-lib:fref a-%data%
250 (f2cl-lib:fref a-%data%
255 (f2cl-lib:fref x-%data%
261 (f2cl-lib:fref y-%data%
266 (setf ix
(f2cl-lib:int-add ix incx
))
267 (setf iy
(f2cl-lib:int-add iy incy
))
269 (setf jx
(f2cl-lib:int-add jx incx
))
270 (setf jy
(f2cl-lib:int-add jy incy
))
274 (return (values nil nil nil nil nil nil nil nil nil
))))))
276 (in-package #-gcl
#:cl-user
#+gcl
"CL-USER")
277 #+#.
(cl:if
(cl:find-package
'#:f2cl
) '(and) '(or))
278 (eval-when (:load-toplevel
:compile-toplevel
:execute
)
279 (setf (gethash 'fortran-to-lisp
::dsyr2 fortran-to-lisp
::*f2cl-function-info
*)
280 (fortran-to-lisp::make-f2cl-finfo
281 :arg-types
'((simple-string) (fortran-to-lisp::integer4
)
282 (double-float) (array double-float
(*))
283 (fortran-to-lisp::integer4
) (array double-float
(*))
284 (fortran-to-lisp::integer4
) (array double-float
(*))
285 (fortran-to-lisp::integer4
))
286 :return-values
'(nil nil nil nil nil nil nil nil nil
)
287 :calls
'(fortran-to-lisp::xerbla fortran-to-lisp
::lsame
))))