Ruby: ext/fiddle/libffi-3.2.1/src/m88k/ffi.c File Reference

Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)

Macros | Functions
ffi.c File Reference
`#include <ffi.h>`
`#include <ffi_common.h>`
`#include <stdlib.h>`
`#include <unistd.h>`

Go to the source code of this file.

## Macros
#define | CIF_FLAGS_INT (1 << 0)
#define | CIF_FLAGS_DINT (1 << 1)

## Functions
void | ffi_call_OBSD (unsigned int, extended_cif *, unsigned int, void *, void(*fn)())
void * | ffi_prep_args (void *, extended_cif *)
void | ffi_closure_OBSD (ffi_closure *)
void | ffi_closure_struct_OBSD (ffi_closure *)
unsigned int | ffi_closure_OBSD_inner (ffi_closure *, void *, unsigned int *, char *)
void | ffi_cacheflush_OBSD (unsigned int, unsigned int)
ffi_status | ffi_prep_cif_machdep (ffi_cif *cif)
void | ffi_call (ffi_cif *cif, void(*fn)(), void *rvalue, void **avalue)
ffi_status | ffi_prep_closure_loc (ffi_closure *closure, ffi_cif *cif, void(*fun)(ffi_cif *, void *, void **, void *), void *user_data, void *codeloc)

## Macro Definition Documentation

## ◆ CIF_FLAGS_DINT

#define CIF_FLAGS_DINT (1 << 1)

Definition at line 62 of file ffi.c.

## ◆ CIF_FLAGS_INT

#define CIF_FLAGS_INT (1 << 0)

Definition at line 61 of file ffi.c.

## Function Documentation

## ◆ ffi_cacheflush_OBSD()

void ffi_cacheflush_OBSD | ( | unsigned int | ,
|  | unsigned int |
| ) |  |

Referenced by ffi_prep_closure_loc().

## ◆ ffi_call()

void ffi_call | ( | ffi_cif * | cif,
|  | void(*)() | fn,
|  | void * | rvalue,
|  | void ** | avalue
| ) |  |

Definition at line 232 of file ffi.c.

References alloca, extended_cif::avalue, extended_cif::cif, FFI_ASSERT, ffi_call_OBSD(), FFI_OBSD, NULL, and extended_cif::rvalue.

## ◆ ffi_call_OBSD()

void ffi_call_OBSD | ( | unsigned int | ,
|  | extended_cif * | ,
|  | unsigned int | ,
|  | void * | ,
|  | void(*)() | fn
| ) |  |

Referenced by ffi_call().

## ◆ ffi_closure_OBSD()

void ffi_closure_OBSD | ( | ffi_closure * |  | ) |

Referenced by ffi_prep_closure_loc().

## ◆ ffi_closure_OBSD_inner()

unsigned int ffi_closure_OBSD_inner | ( | ffi_closure * | closure,
|  | void * | resp,
|  | unsigned int * | regp,
|  | char * | stackp
| ) |  |

Definition at line 351 of file ffi.c.

References alloca.

## ◆ ffi_closure_struct_OBSD()

void ffi_closure_struct_OBSD | ( | ffi_closure * |  | ) |

Referenced by ffi_prep_closure_loc().

## ◆ ffi_prep_args()

void * ffi_prep_args | ( | void * | stack,
|  | extended_cif * | ecif
| ) |  |

Definition at line 72 of file ffi.c.

References ALIGN, extended_cif::avalue, extended_cif::cif, FFI_ASSERT, int(), memcpy, NULL, extended_cif::rvalue, and t.

## ◆ ffi_prep_cif_machdep()

ffi_status ffi_prep_cif_machdep | ( | ffi_cif * | cif | ) |

Definition at line 200 of file ffi.c.

References CIF_FLAGS_DINT, and CIF_FLAGS_INT.

## ◆ ffi_prep_closure_loc()

ffi_status ffi_prep_closure_loc | ( | ffi_closure * | closure,
|  | ffi_cif * | cif,
|  | void(*)(ffi_cif *, void *, void **, void *) | fun,
|  | void * | user_data,
|  | void * | codeloc
| ) |  |

Definition at line 368 of file ffi.c.

References FFI_ASSERT, ffi_cacheflush_OBSD(), ffi_closure_OBSD(), ffi_closure_struct_OBSD(), FFI_OBSD, FFI_TRAMPOLINE_SIZE, and int().