#pragma once

static inline long syscall(long num, long a1, long a2, long a3)
{
    long ret;

    asm volatile (
        "syscall"
        : "=a"(ret)
        : "a"(num), "D"(a1), "S"(a2), "d"(a3)
        :
    );

    return ret;
}