Ruby  2.7.0p0(2019-12-25revision647ee6f091eafcce70ffb75ddf7e121e192ab217)
Macros | Functions
ffi.c File Reference
#include <ffi.h>
#include <ffi_common.h>
#include <stdlib.h>
#include <stdint.h>
#include <sys/cachectl.h>

Go to the source code of this file.

Macros

#define CODE_ENDIAN(x)   ( (((uint32_t) (x)) << 16) | (((uint32_t) (x)) >> 16))
 

Functions

void ffi_prep_args (char *stack, extended_cif *ecif)
 
ffi_status ffi_prep_cif_machdep (ffi_cif *cif)
 
void ffi_call_ARCompact (void(*)(char *, extended_cif *), extended_cif *, unsigned, unsigned, unsigned *, void(*fn)(void))
 
void ffi_call (ffi_cif *cif, void(*fn)(void), void *rvalue, void **avalue)
 
int ffi_closure_inner_ARCompact (ffi_closure *closure, void *rvalue, ffi_arg *args)
 
void ffi_closure_ARCompact (void)
 
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

◆ CODE_ENDIAN

#define CODE_ENDIAN (   x)    ( (((uint32_t) (x)) << 16) | (((uint32_t) (x)) >> 16))

Definition at line 39 of file ffi.c.

Function Documentation

◆ ffi_call()

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

◆ ffi_call_ARCompact()

void ffi_call_ARCompact ( void(*)(char *, extended_cif *)  ,
extended_cif ,
unsigned  ,
unsigned  ,
unsigned ,
void(*)(void fn 
)

Referenced by ffi_call().

◆ ffi_closure_ARCompact()

void ffi_closure_ARCompact ( void  )

Referenced by ffi_prep_closure_loc().

◆ ffi_closure_inner_ARCompact()

int ffi_closure_inner_ARCompact ( ffi_closure *  closure,
void rvalue,
ffi_arg args 
)

Definition at line 197 of file ffi.c.

References ALIGN, alloca, i, and unsigned.

◆ ffi_prep_args()

unsigned int ffi_prep_args ( char stack,
extended_cif ecif 
)

Definition at line 46 of file ffi.c.

References ALIGN, extended_cif::avalue, extended_cif::cif, FFI_ASSERT, i, int, memcpy(), extended_cif::rvalue, and unsigned.

Referenced by ffi_call().

◆ ffi_prep_cif_machdep()

ffi_status ffi_prep_cif_machdep ( ffi_cif *  cif)

Definition at line 134 of file ffi.c.

References unsigned.

◆ 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 243 of file ffi.c.

References CODE_ENDIAN, FFI_ARCOMPACT, FFI_ASSERT, ffi_closure_ARCompact(), and FFI_TRAMPOLINE_SIZE.