X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/6c506d8916fb114675e93d0e2cb20831d4022294..d1b1c8d9119229dbeed06cd252917e54a1cb77f6:/lunaix-os/arch/generic/includes/sys/abi.h diff --git a/lunaix-os/arch/generic/includes/sys/abi.h b/lunaix-os/arch/generic/includes/sys/abi.h new file mode 100644 index 0000000..bef0f5d --- /dev/null +++ b/lunaix-os/arch/generic/includes/sys/abi.h @@ -0,0 +1,58 @@ +#ifndef __LUNAIX_ARCH_ABI_H +#define __LUNAIX_ARCH_ABI_H + +#include + +#define stack_alignment 0 + +#ifndef __ASM__ +#define align_stack(ptr) ((ptr) & stack_alignment) +#define store_retval(retval) (void) + +#define store_retval_to(th, retval) (void) + +static inline void must_inline noret +j_usr(ptr_t sp, ptr_t pc) +{ + +} + + +static inline void must_inline noret +switch_context() { + unreachable; +} + +#define push_arg1(stack_ptr, arg) (void) + +#define push_arg2(stack_ptr, arg1, arg2) \ + { } + +#define push_arg3(stack_ptr, arg1, arg2, arg3) \ + { } + +#define push_arg4(stack_ptr, arg1, arg2, arg3, arg4) \ + { } + + +static inline ptr_t must_inline +abi_get_callframe() +{ + return 0; +} + +static inline ptr_t +abi_get_retaddr() +{ + return 0; +} + +static inline ptr_t +abi_get_retaddrat(ptr_t fp) +{ + return 0; +} + +#endif +#endif /* __LUNAIX_ABI_H */ +