Loading init/body-expand.lisp +2 −15 Original line number Diff line number Diff line ;; Expand the body of a defmfun ;; Liam Healy 2009-04-13 22:07:13EDT body-expand.lisp ;; Time-stamp: <2010-12-04 09:48:48EST body-expand.lisp> ;; Time-stamp: <2010-12-16 11:46:22EST body-expand.lisp> ;; ;; Copyright 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License Loading Loading @@ -84,20 +84,7 @@ (defun cl-convert-form (decl) "Generate a form that calls the appropriate converter from C/GSL to CL." (or #+fsbv (if (fsbv:converter-defined-p (grid:st-actual-type decl)) `((fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))) #-fsbv nil (case (grid:st-actual-type decl) (sf-result `((val ,(grid:st-symbol decl)) (err ,(grid:st-symbol decl)))) (sf-result-e10 `((val ,(grid:st-symbol decl) 'sf-result-e10) (e10 ,(grid:st-symbol decl)) (err ,(grid:st-symbol decl) 'sf-result-e10))) (t `((cffi:mem-aref ,(grid:st-symbol decl) ',(grid:st-actual-type decl))))))) (list `(fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))) (defun values-unless-singleton (forms) (unless (listp forms) (error "Values are not a list.")) Loading init/funcallable.lisp +2 −2 Original line number Diff line number Diff line ;; Generate a lambda that calls the user function; will be called by callback. ;; Liam Healy ;; Time-stamp: <2011-01-10 18:19:11EST funcallable.lisp> ;; Time-stamp: <2011-10-23 20:25:24EDT funcallable.lisp> ;; ;; Copyright 2009, 2010, 2011 Liam M. Healy ;; Distributed under the terms of the GNU General Public License Loading Loading @@ -97,7 +97,7 @@ ,@(affi::delinearize-index (affi:make-affi (value-from-dimensions argspec dimension-values)) linear-index)) `(cffi:mem-aref `(fsbv:object ,foreign-pointer-name ',(parse-callback-argspec argspec 'element-type) ,linear-index)) Loading init/interface.lisp +2 −6 Original line number Diff line number Diff line ;; Macros to interface GSL functions, including definitions necessary for defmfun. ;; Liam Healy ;; Time-stamp: <2010-06-29 19:42:14EDT interface.lisp> ;; Time-stamp: <2010-12-19 15:58:10EST interface.lisp> ;; ;; Copyright 2009 Liam M. Healy ;; Copyright 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading Loading @@ -41,10 +41,6 @@ ;;;; Declare foreign objects ;;;;**************************************************************************** (defmacro scref (size &optional (index 0)) "Reference C size(s)." `(cffi:mem-aref ,size 'sizet ,index)) (defun wfo-declare (d cbinfo) `(,(grid:st-symbol d) ,@(if (eq (grid:st-symbol d) Loading init/types.lisp +6 −4 Original line number Diff line number Diff line ;; Number types used by GSL functions, and specification conversion ;; Liam Healy 2008-12-31 21:06:34EST types.lisp ;; Time-stamp: <2010-06-27 18:03:22EDT types.lisp> ;; Time-stamp: <2010-12-19 11:42:56EST types.lisp> ;; ;; Copyright 2008, 2009 Liam M. Healy ;; Copyright 2008, 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading @@ -24,13 +24,15 @@ ;;;; Unsigned address types size_t ;;;;**************************************************************************** (fsbv:defconvert (sizet :constructor values)) (case (cffi:foreign-type-size :long) (8 (push :int64 *features*) #+fsbv (fsbv:defsynonym sizet :uint64)) #+fsbv (fsbv:define-equivalent-type sizet :uint64)) (4 (push :int32 *features*) #+fsbv (fsbv:defsynonym sizet :uint32))) #+fsbv (fsbv:define-equivalent-type sizet :uint32))) ;;;;**************************************************************************** ;;;; Type specification conversion Loading linear-algebra/blas2.lisp +6 −9 Original line number Diff line number Diff line ;; BLAS level 2, Matrix-vector operations ;; Liam Healy, Wed Apr 26 2006 - 21:08 ;; Time-stamp: <2011-04-23 17:15:33EDT blas2.lisp> ;; Time-stamp: <2011-10-23 20:26:44EDT blas2.lisp> ;; ;; Copyright 2006, 2007, 2008, 2009, 2011 Liam M. Healy ;; Copyright 2006, 2007, 2008, 2009, 2010, 2011 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading @@ -17,7 +17,6 @@ ;; ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see <http://www.gnu.org/licenses/>. ;; $Id$ (in-package :gsl) Loading @@ -27,14 +26,12 @@ ;;;; Options ;;;;**************************************************************************** #+fsbv (fsbv:defcenum-aux cblas-transpose) #+fsbv (fsbv:defenumeration cblas-transpose) ;;; Eventually, #-fsbv (cffi:defconvert-cenum cblas-transpose) #+fsbv (fsbv:defcenum-aux cblas-uplo) #+fsbv (fsbv:defenumeration cblas-uplo) #+fsbv (fsbv:defcenum-aux cblas-diag) #+fsbv (fsbv:defenumeration cblas-diag) ;;;;**************************************************************************** ;;;; Functions Loading Loading
init/body-expand.lisp +2 −15 Original line number Diff line number Diff line ;; Expand the body of a defmfun ;; Liam Healy 2009-04-13 22:07:13EDT body-expand.lisp ;; Time-stamp: <2010-12-04 09:48:48EST body-expand.lisp> ;; Time-stamp: <2010-12-16 11:46:22EST body-expand.lisp> ;; ;; Copyright 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License Loading Loading @@ -84,20 +84,7 @@ (defun cl-convert-form (decl) "Generate a form that calls the appropriate converter from C/GSL to CL." (or #+fsbv (if (fsbv:converter-defined-p (grid:st-actual-type decl)) `((fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))) #-fsbv nil (case (grid:st-actual-type decl) (sf-result `((val ,(grid:st-symbol decl)) (err ,(grid:st-symbol decl)))) (sf-result-e10 `((val ,(grid:st-symbol decl) 'sf-result-e10) (e10 ,(grid:st-symbol decl)) (err ,(grid:st-symbol decl) 'sf-result-e10))) (t `((cffi:mem-aref ,(grid:st-symbol decl) ',(grid:st-actual-type decl))))))) (list `(fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))) (defun values-unless-singleton (forms) (unless (listp forms) (error "Values are not a list.")) Loading
init/funcallable.lisp +2 −2 Original line number Diff line number Diff line ;; Generate a lambda that calls the user function; will be called by callback. ;; Liam Healy ;; Time-stamp: <2011-01-10 18:19:11EST funcallable.lisp> ;; Time-stamp: <2011-10-23 20:25:24EDT funcallable.lisp> ;; ;; Copyright 2009, 2010, 2011 Liam M. Healy ;; Distributed under the terms of the GNU General Public License Loading Loading @@ -97,7 +97,7 @@ ,@(affi::delinearize-index (affi:make-affi (value-from-dimensions argspec dimension-values)) linear-index)) `(cffi:mem-aref `(fsbv:object ,foreign-pointer-name ',(parse-callback-argspec argspec 'element-type) ,linear-index)) Loading
init/interface.lisp +2 −6 Original line number Diff line number Diff line ;; Macros to interface GSL functions, including definitions necessary for defmfun. ;; Liam Healy ;; Time-stamp: <2010-06-29 19:42:14EDT interface.lisp> ;; Time-stamp: <2010-12-19 15:58:10EST interface.lisp> ;; ;; Copyright 2009 Liam M. Healy ;; Copyright 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading Loading @@ -41,10 +41,6 @@ ;;;; Declare foreign objects ;;;;**************************************************************************** (defmacro scref (size &optional (index 0)) "Reference C size(s)." `(cffi:mem-aref ,size 'sizet ,index)) (defun wfo-declare (d cbinfo) `(,(grid:st-symbol d) ,@(if (eq (grid:st-symbol d) Loading
init/types.lisp +6 −4 Original line number Diff line number Diff line ;; Number types used by GSL functions, and specification conversion ;; Liam Healy 2008-12-31 21:06:34EST types.lisp ;; Time-stamp: <2010-06-27 18:03:22EDT types.lisp> ;; Time-stamp: <2010-12-19 11:42:56EST types.lisp> ;; ;; Copyright 2008, 2009 Liam M. Healy ;; Copyright 2008, 2009, 2010 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading @@ -24,13 +24,15 @@ ;;;; Unsigned address types size_t ;;;;**************************************************************************** (fsbv:defconvert (sizet :constructor values)) (case (cffi:foreign-type-size :long) (8 (push :int64 *features*) #+fsbv (fsbv:defsynonym sizet :uint64)) #+fsbv (fsbv:define-equivalent-type sizet :uint64)) (4 (push :int32 *features*) #+fsbv (fsbv:defsynonym sizet :uint32))) #+fsbv (fsbv:define-equivalent-type sizet :uint32))) ;;;;**************************************************************************** ;;;; Type specification conversion Loading
linear-algebra/blas2.lisp +6 −9 Original line number Diff line number Diff line ;; BLAS level 2, Matrix-vector operations ;; Liam Healy, Wed Apr 26 2006 - 21:08 ;; Time-stamp: <2011-04-23 17:15:33EDT blas2.lisp> ;; Time-stamp: <2011-10-23 20:26:44EDT blas2.lisp> ;; ;; Copyright 2006, 2007, 2008, 2009, 2011 Liam M. Healy ;; Copyright 2006, 2007, 2008, 2009, 2010, 2011 Liam M. Healy ;; Distributed under the terms of the GNU General Public License ;; ;; This program is free software: you can redistribute it and/or modify Loading @@ -17,7 +17,6 @@ ;; ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see <http://www.gnu.org/licenses/>. ;; $Id$ (in-package :gsl) Loading @@ -27,14 +26,12 @@ ;;;; Options ;;;;**************************************************************************** #+fsbv (fsbv:defcenum-aux cblas-transpose) #+fsbv (fsbv:defenumeration cblas-transpose) ;;; Eventually, #-fsbv (cffi:defconvert-cenum cblas-transpose) #+fsbv (fsbv:defcenum-aux cblas-uplo) #+fsbv (fsbv:defenumeration cblas-uplo) #+fsbv (fsbv:defcenum-aux cblas-diag) #+fsbv (fsbv:defenumeration cblas-diag) ;;;;**************************************************************************** ;;;; Functions Loading