infix
A JIT-Powered FFI Library for C
Loading...
Searching...
No Matches
types.h
Go to the documentation of this file.
1#pragma once
17#include <inttypes.h>
18#include <stddef.h>
20typedef struct {
21 double x;
22 double y;
23} Point;
25typedef struct {
26 float v[4];
27} Vector4;
29typedef struct {
30 long long data[4];
31} LargeData;
33typedef union {
34 int i;
35 float f;
36} Number;
38typedef struct {
39 int a, b, c, d, e, f;
42typedef struct {
43 int i;
44 double d;
47typedef struct {
48 int * val_ptr;
49 const char * str_ptr;
56#pragma pack(push, 1)
57typedef struct {
58 char a;
59 uint64_t b;
61#pragma pack(pop)
63typedef struct {
64 int a, b, c;
A larger struct used for testing pass-by-reference and stack arguments.
Definition types.h:29
A struct larger than 16 bytes, guaranteed to be passed by reference on most ABIs.
Definition types.h:38
int a
Definition types.h:39
A struct with mixed integer and float members, used to test complex classification rules on System V ...
Definition types.h:42
int i
Definition types.h:43
double d
Definition types.h:44
A struct whose size (12 bytes) is not a power of two, used to test ABI rules for such types.
Definition types.h:63
int a
Definition types.h:64
A packed struct with an unusual size (9 bytes) and alignment (1).
Definition types.h:57
char a
Definition types.h:58
uint64_t b
Definition types.h:59
A simple struct with two doubles, often used to test pass-by-value on registers.
Definition 501_direct_marshalling.c:20
A struct containing pointers, used to test pointer argument handling.
Definition types.h:47
const char * str_ptr
Definition types.h:49
int * val_ptr
Definition types.h:48
A struct containing an array, often used to test HFA (Homogeneous Floating-point Aggregate) rules.
Definition types.h:25
A simple union to test aggregate classification.
Definition types.h:33
float f
Definition types.h:35
int i
Definition types.h:34