< prev index next >

test/micro/org/openjdk/bench/jdk/incubator/foreign/libCallOverhead.c

Print this page

17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18  *
19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20  * or visit www.oracle.com if you need additional information or have any
21  * questions.
22  */
23 
24 #ifdef _WIN64
25 #define EXPORT __declspec(dllexport)
26 #else
27 #define EXPORT
28 #endif
29 
30 EXPORT void func() {}
31 
32 EXPORT int identity(int x) {
33   return x;
34 }
35 
36 typedef struct {
37     long long x;
38     long long y;
39 } Point;
40 
41 EXPORT Point identity_struct(Point p) {
42     return p;
43 }
44 




45 EXPORT void* identity_memory_address(void* p) {
46     return p;
47 }
48 




49 EXPORT void args1(long long a0) {}
50 EXPORT void args2(long long a0, double a1) {}
51 EXPORT void args3(long long a0, double a1, long long a2) {}
52 EXPORT void args4(long long a0, double a1, long long a2, double a3) {}
53 EXPORT void args5(long long a0, double a1, long long a2, double a3, long long a4) {}
54 EXPORT void args10(long long a0, double a1, long long a2, double a3, long long a4,
55                    double a5, long long a6, double a7, long long a8, double a9) {}

17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18  *
19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20  * or visit www.oracle.com if you need additional information or have any
21  * questions.
22  */
23 
24 #ifdef _WIN64
25 #define EXPORT __declspec(dllexport)
26 #else
27 #define EXPORT
28 #endif
29 
30 EXPORT void func() {}
31 
32 EXPORT int identity(int x) {
33   return x;
34 }
35 
36 typedef struct {
37     int x;
38     int y;
39 } Point;
40 
41 EXPORT Point identity_struct(Point p) {
42     return p;
43 }
44 
45 EXPORT Point identity_struct_3(Point p1, Point p2, Point p3) {
46     return p1;
47 }
48 
49 EXPORT void* identity_memory_address(void* p) {
50     return p;
51 }
52 
53 EXPORT void* identity_memory_address_3(void* p1, void* p2, void* p3) {
54     return p1;
55 }
56 
57 EXPORT void args1(long long a0) {}
58 EXPORT void args2(long long a0, double a1) {}
59 EXPORT void args3(long long a0, double a1, long long a2) {}
60 EXPORT void args4(long long a0, double a1, long long a2, double a3) {}
61 EXPORT void args5(long long a0, double a1, long long a2, double a3, long long a4) {}
62 EXPORT void args10(long long a0, double a1, long long a2, double a3, long long a4,
63                    double a5, long long a6, double a7, long long a8, double a9) {}
< prev index next >