source: branches/qres/ccl/lib/ffi-darwinx8632.lisp @ 14172

Last change on this file since 14172 was 13070, checked in by gz, 10 years ago

r13066, r13067 from trunk: copyrights etc

File size: 1.8 KB
Line 
1;;; Copyright 2009 Clozure Associates
2;;; This file is part of Clozure CL. 
3;;;
4;;; Clozure CL is licensed under the terms of the Lisp Lesser GNU
5;;; Public License , known as the LLGPL and distributed with Clozure
6;;; CL as the file "LICENSE".  The LLGPL consists of a preamble and
7;;; the LGPL, which is distributed with Clozure CL as the file "LGPL".
8;;; Where these conflict, the preamble takes precedence.
9;;;
10;;; Clozure CL is referenced in the preamble as the "LIBRARY."
11;;;
12;;; The LLGPL is also available online at
13;;; http://opensource.franz.com/preamble.html
14
15(in-package "CCL")
16
17;;; Some small structures are returned in EAX and EDX.  Otherwise,
18;;; return values are placed at the address specified by the caller.
19(defun x86-darwin32::record-type-returns-structure-as-first-arg (rtype)
20  (when (and rtype
21             (not (typep rtype 'unsigned-byte))
22             (not (member rtype *foreign-representation-type-keywords*
23                          :test #'eq)))
24    (let* ((ftype (if (typep rtype 'foreign-type)
25                    rtype
26                    (parse-foreign-type rtype)))
27           (nbits (ensure-foreign-type-bits ftype)))
28      (not (member nbits '(8 16 32 64))))))
29
30;;; We don't support the __m64, __m128, __m128d, and __m128i types.
31(defun x86-darwin32::expand-ff-call (callform args &key (arg-coerce #'null-coerce-foreign-arg) (result-coerce #'null-coerce-foreign-result))
32  (x8632::expand-ff-call callform args :arg-coerce arg-coerce :result-coerce result-coerce))
33
34(defun x86-darwin32::generate-callback-bindings (stack-ptr fp-args-ptr argvars argspecs result-spec struct-result-name)
35  (x8632::generate-callback-bindings stack-ptr fp-args-ptr argvars argspecs result-spec struct-result-name))
36
37(defun x86-darwin32::generate-callback-return-value (stack-ptr fp-args-ptr result return-type struct-return-arg)
38  (x8632::generate-callback-return-value stack-ptr fp-args-ptr result return-type struct-return-arg))
Note: See TracBrowser for help on using the repository browser.