comparison dyncall/dyncall_call_mips_o32.h @ 0:3e629dc19168

initial from svn dyncall-1745
author Daniel Adler
date Thu, 19 Mar 2015 22:24:28 +0100
parents
children 1ce60358fbad
comparison
equal deleted inserted replaced
-1:000000000000 0:3e629dc19168
1 /*
2
3 Package: dyncall
4 Library: dyncall
5 File: dyncall/dyncall_call_mips_o32.h
6 Description: mips "o32" abi call kernel C interface.
7 License:
8
9 Copyright (c) 2007-2015 Daniel Adler <dadler@uni-goettingen.de>,
10 Tassilo Philipp <tphilipp@potion-studios.com>
11
12 Permission to use, copy, modify, and distribute this software for any
13 purpose with or without fee is hereby granted, provided that the above
14 copyright notice and this permission notice appear in all copies.
15
16 THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
17 WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
18 MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
19 ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
20 WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
21 ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
22 OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
23
24 */
25
26
27
28 #ifndef DYNCALL_CALL_MIPS_O32_H
29 #define DYNCALL_CALL_MIPS_O32_H
30
31 #include "dyncall_types.h"
32
33 #ifdef __cplusplus
34 extern "C" {
35 #endif
36
37 /* Call-kernel register data:
38
39 Details:
40 The structure holds the argument data for transfering float/double arguments
41 via registers as well.
42 The call-kernel implements loads two doubles, which involves four
43 32-bit floating pointer registers.
44 Float arguments map as following:
45
46 float argument 0 is at floats[1] and
47 float argument 1 is at floats[3] of DCRegData_mips_o32 union.
48
49 */
50
51 typedef struct DCRegData_mips_o32_
52 {
53 union {
54 double d;
55 float f[2];
56 } u[2];
57 } DCRegData_mips_o32;
58
59
60 /* Call kernel. */
61
62 void dcCall_mips_o32(DCpointer target, DCRegData_mips_o32* regdata, DCsize stksize, DCpointer stkdata);
63
64
65 #ifdef __cplusplus
66 }
67 #endif
68
69
70 #endif /* DYNCALL_CALL_MIPS_O32_H */
71