home *** CD-ROM | disk | FTP | other *** search
- #include <inline/stub.h>
- #ifndef BASE_EXT_DECL
- #define BASE_EXT_DECL extern struct ArpBase * ArpBase;
- #endif
- #ifndef BASE_PAR_DECL
- #define BASE_PAR_DECL
- #endif
- #ifndef BASE_NAME
- #define BASE_NAME ArpBase
- #endif
- #ifdef PRIVATE
- __inline static BPTR Open(BASE_PAR_DECL char* name, LONG accessMode)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = accessMode;
- __asm volatile ("
- jsr a6@(-0x1e)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static void Close(BASE_PAR_DECL BPTR file)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = file;
- __asm volatile ("
- jsr a6@(-0x24)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static LONG Read(BASE_PAR_DECL BPTR file, char* buffer, LONG length)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register char* d2 __asm("d2");
- register LONG d3 __asm("d3");
-
- a6 = BASE_NAME;
- d1 = file;
- d2 = buffer;
- d3 = length;
- __asm volatile ("
- jsr a6@(-0x2a)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2), "g" (d3)
- : "d0", "d1", "a0", "a1", "d2", "d3");
- return res;
- }
- __inline static LONG Write(BASE_PAR_DECL BPTR file, char* buffer, LONG length)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register char* d2 __asm("d2");
- register LONG d3 __asm("d3");
-
- a6 = BASE_NAME;
- d1 = file;
- d2 = buffer;
- d3 = length;
- __asm volatile ("
- jsr a6@(-0x30)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2), "g" (d3)
- : "d0", "d1", "a0", "a1", "d2", "d3");
- return res;
- }
- __inline static BPTR Input(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x36)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BPTR Output(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x3c)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Seek(BASE_PAR_DECL BPTR file, LONG position, LONG offset)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register LONG d2 __asm("d2");
- register LONG d3 __asm("d3");
-
- a6 = BASE_NAME;
- d1 = file;
- d2 = position;
- d3 = offset;
- __asm volatile ("
- jsr a6@(-0x42)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2), "g" (d3)
- : "d0", "d1", "a0", "a1", "d2", "d3");
- return res;
- }
- __inline static LONG DeleteFile(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = name;
- __asm volatile ("
- jsr a6@(-0x48)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Rename(BASE_PAR_DECL char* oldName, char* newName)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register char* d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = oldName;
- d2 = newName;
- __asm volatile ("
- jsr a6@(-0x4e)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static BPTR Lock(BASE_PAR_DECL char* name, LONG type)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = type;
- __asm volatile ("
- jsr a6@(-0x54)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static void UnLock(BASE_PAR_DECL BPTR lock)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = lock;
- __asm volatile ("
- jsr a6@(-0x5a)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static BPTR DupLock(BASE_PAR_DECL BPTR lock)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = lock;
- __asm volatile ("
- jsr a6@(-0x60)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Examine(BASE_PAR_DECL BPTR lock, struct FileInfoBlock* fileInfoBlock)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register struct FileInfoBlock* d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = lock;
- d2 = fileInfoBlock;
- __asm volatile ("
- jsr a6@(-0x66)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static LONG ExNext(BASE_PAR_DECL BPTR lock, struct FileInfoBlock* fileInfoBlock)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register struct FileInfoBlock* d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = lock;
- d2 = fileInfoBlock;
- __asm volatile ("
- jsr a6@(-0x6c)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static LONG Info(BASE_PAR_DECL BPTR lock, struct InfoData* parameterBlock)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register struct InfoData* d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = lock;
- d2 = parameterBlock;
- __asm volatile ("
- jsr a6@(-0x72)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static BPTR CreateDir(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = name;
- __asm volatile ("
- jsr a6@(-0x78)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BPTR CurrentDir(BASE_PAR_DECL BPTR lock)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = lock;
- __asm volatile ("
- jsr a6@(-0x7e)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG IoErr(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x84)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct MsgPort* CreateProc(BASE_PAR_DECL char* name, LONG pri, BPTR segList, LONG stackSize)
- {
- BASE_EXT_DECL
- register struct MsgPort* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
- register BPTR d3 __asm("d3");
- register LONG d4 __asm("d4");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = pri;
- d3 = segList;
- d4 = stackSize;
- __asm volatile ("
- jsr a6@(-0x8a)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2), "g" (d3), "g" (d4)
- : "d0", "d1", "a0", "a1", "d2", "d3", "d4");
- return res;
- }
- __inline static void Exit(BASE_PAR_DECL LONG returnCode)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = returnCode;
- __asm volatile ("
- jsr a6@(-0x90)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static BPTR LoadSeg(BASE_PAR_DECL char* fileName)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = fileName;
- __asm volatile ("
- jsr a6@(-0x96)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void UnLoadSeg(BASE_PAR_DECL BPTR segment)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = segment;
- __asm volatile ("
- jsr a6@(-0x9c)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static struct MsgPort* DeviceProc(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register struct MsgPort* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = name;
- __asm volatile ("
- jsr a6@(-0xae)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG SetComment(BASE_PAR_DECL char* name, char* comment)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register char* d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = comment;
- __asm volatile ("
- jsr a6@(-0xb4)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static LONG SetProtection(BASE_PAR_DECL char* name, LONG mask)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = mask;
- __asm volatile ("
- jsr a6@(-0xba)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static LONG* DateStamp(BASE_PAR_DECL LONG* date)
- {
- BASE_EXT_DECL
- register LONG* res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = date;
- __asm volatile ("
- jsr a6@(-0xc0)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void Delay(BASE_PAR_DECL LONG timeout)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = timeout;
- __asm volatile ("
- jsr a6@(-0xc6)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static LONG WaitForChar(BASE_PAR_DECL BPTR file, LONG timeout)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = file;
- d2 = timeout;
- __asm volatile ("
- jsr a6@(-0xcc)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static BPTR ParentDir(BASE_PAR_DECL BPTR lock)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = lock;
- __asm volatile ("
- jsr a6@(-0xd2)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG IsInteractive(BASE_PAR_DECL BPTR file)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = file;
- __asm volatile ("
- jsr a6@(-0xd8)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Execute(BASE_PAR_DECL char* string, BPTR file, BPTR file)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register BPTR d2 __asm("d2");
- register BPTR d3 __asm("d3");
-
- a6 = BASE_NAME;
- d1 = string;
- d2 = file;
- d3 = file;
- __asm volatile ("
- jsr a6@(-0xde)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2), "g" (d3)
- : "d0", "d1", "a0", "a1", "d2", "d3");
- return res;
- }
- #ifdef DOTDOTDOT
- __inline static LONG Printf(BASE_PAR_DECL char* string, ... stream)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register ... a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = string;
- a1 = stream;
- __asm volatile ("
- jsr a6@(-0xe4)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG FPrintf(BASE_PAR_DECL BPTR file, char* string, ... stream)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d0 __asm("d0");
- register char* a0 __asm("a0");
- register ... a1 __asm("a1");
-
- a6 = BASE_NAME;
- d0 = file;
- a0 = string;
- a1 = stream;
- __asm volatile ("
- jsr a6@(-0xea)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- #endif
- __inline static LONG Puts(BASE_PAR_DECL char* string)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = string;
- __asm volatile ("
- jsr a6@(-0xf0)"
- : "=g" (res)
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG ReadLine(BASE_PAR_DECL char* buffer)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = buffer;
- __asm volatile ("
- jsr a6@(-0xf6)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG GADS(BASE_PAR_DECL char* line, LONG len, char* help, char** args, char* tplate)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register LONG d0 __asm("d0");
- register char* a1 __asm("a1");
- register char** a2 __asm("a2");
- register char* a3 __asm("a3");
-
- a6 = BASE_NAME;
- a0 = line;
- d0 = len;
- a1 = help;
- a2 = args;
- a3 = tplate;
- __asm volatile ("
- jsr a6@(-0xfc)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0), "g" (a1), "g" (a2), "g" (a3)
- : "d0", "d1", "a0", "a1", "a2", "a3");
- return res;
- }
- __inline static LONG Atol(BASE_PAR_DECL char* string)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = string;
- __asm volatile ("
- jsr a6@(-0x102)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static ULONG EscapeString(BASE_PAR_DECL char* string)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = string;
- __asm volatile ("
- jsr a6@(-0x108)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG CheckAbort(BASE_PAR_DECL void(*func)())
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register void(*a1)() __asm("a1");
-
- a6 = BASE_NAME;
- a1 = func;
- __asm volatile ("
- jsr a6@(-0x10e)"
- : "=g" (res)
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG CheckBreak(BASE_PAR_DECL LONG masks, void(*func)())
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d1 __asm("d1");
- register void(*a1)() __asm("a1");
-
- a6 = BASE_NAME;
- d1 = masks;
- a1 = func;
- __asm volatile ("
- jsr a6@(-0x114)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BYTE* Getenv(BASE_PAR_DECL char* string, char* buffer, LONG size)
- {
- BASE_EXT_DECL
- register BYTE* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a0 = string;
- a1 = buffer;
- d0 = size;
- __asm volatile ("
- jsr a6@(-0x11a)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL Setenv(BASE_PAR_DECL char* varname, char* value)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = varname;
- a1 = value;
- __asm volatile ("
- jsr a6@(-0x120)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BYTE* FileRequest(BASE_PAR_DECL struct FileRequester* FileRequester)
- {
- BASE_EXT_DECL
- register BYTE* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct FileRequester* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = FileRequester;
- __asm volatile ("
- jsr a6@(-0x126)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void CloseWindowSafely(BASE_PAR_DECL struct Window* Window1, LONG Window2)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct Window* a0 __asm("a0");
- register LONG a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = Window1;
- a1 = Window2;
- __asm volatile ("
- jsr a6@(-0x12c)"
- : /* no output */
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static struct MsgPort* CreatePort(BASE_PAR_DECL const char* name, LONG pri)
- {
- BASE_EXT_DECL
- register struct MsgPort* res __asm("d0");
- register void *a6 __asm ("a6");
- register const char* a0 __asm("a0");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a0 = name;
- d0 = pri;
- __asm volatile ("
- jsr a6@(-0x132)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void DeletePort(BASE_PAR_DECL struct MsgPort* port)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct MsgPort* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = port;
- __asm volatile ("
- jsr a6@(-0x138)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static LONG SendPacket(BASE_PAR_DECL LONG action, LONG* args, struct MsgPort* handler)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG* a0 __asm("a0");
- register struct MsgPort* a1 __asm("a1");
-
- a6 = BASE_NAME;
- d0 = action;
- a0 = args;
- a1 = handler;
- __asm volatile ("
- jsr a6@(-0x13e)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void InitStdPacket(BASE_PAR_DECL LONG action, LONG* args, struct DosPacket* packet, struct MsgPort* replyport)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG* a0 __asm("a0");
- register struct DosPacket* a1 __asm("a1");
- register struct MsgPort* a2 __asm("a2");
-
- a6 = BASE_NAME;
- d0 = action;
- a0 = args;
- a1 = packet;
- a2 = replyport;
- __asm volatile ("
- jsr a6@(-0x144)"
- : /* no output */
- : "g" (a6), "g" (d0), "g" (a0), "g" (a1), "g" (a2)
- : "d0", "d1", "a0", "a1", "a2");
- }
- __inline static ULONG PathName(BASE_PAR_DECL BPTR lock, char* buffer, LONG componentcount)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d0 __asm("d0");
- register char* a0 __asm("a0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = lock;
- a0 = buffer;
- d1 = componentcount;
- __asm volatile ("
- jsr a6@(-0x14a)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (a0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static ULONG Assign(BASE_PAR_DECL char* logical, char* physical)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = logical;
- a1 = physical;
- __asm volatile ("
- jsr a6@(-0x150)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void* DosAllocMem(BASE_PAR_DECL LONG size)
- {
- BASE_EXT_DECL
- register void* res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- d0 = size;
- __asm volatile ("
- jsr a6@(-0x156)"
- : "=g" (res)
- : "g" (a6), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void DosFreeMem(BASE_PAR_DECL void* dosblock)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register void* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = dosblock;
- __asm volatile ("
- jsr a6@(-0x15c)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static ULONG BtoCStr(BASE_PAR_DECL char* cstr, BSTR bstr, LONG maxlength)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register BSTR d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- a0 = cstr;
- d0 = bstr;
- d1 = maxlength;
- __asm volatile ("
- jsr a6@(-0x162)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static ULONG CtoBStr(BASE_PAR_DECL char* cstr, BSTR bstr, LONG maxlength)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register BSTR d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- a0 = cstr;
- d0 = bstr;
- d1 = maxlength;
- __asm volatile ("
- jsr a6@(-0x168)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct DeviceList* GetDevInfo(BASE_PAR_DECL struct DeviceList* devnode)
- {
- BASE_EXT_DECL
- register struct DeviceList* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct DeviceList* a2 __asm("a2");
-
- a6 = BASE_NAME;
- a2 = devnode;
- __asm volatile ("
- jsr a6@(-0x16e)"
- : "=g" (res)
- : "g" (a6), "g" (a2)
- : "d0", "d1", "a0", "a1", "a2");
- return res;
- }
- __inline static BOOL FreeTaskResList(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x174)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #ifdef DOTDOTDOT
- __inline static void ArpExit(BASE_PAR_DECL LONG rc, ... result2)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register ... d2 __asm("d2");
-
- a6 = BASE_NAME;
- d0 = rc;
- d2 = result2;
- __asm volatile ("
- jsr a6@(-0x17a)"
- : /* no output */
- : "g" (a6), "g" (d0), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- }
- #endif
- #ifdef PRIVATE
- __inline static void* ArpAlloc(BASE_PAR_DECL LONG size)
- {
- BASE_EXT_DECL
- register void* res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- d0 = size;
- __asm volatile ("
- jsr a6@(-0x180)"
- : "=g" (res)
- : "g" (a6), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void* ArpAllocMem(BASE_PAR_DECL LONG size, LONG requirements)
- {
- BASE_EXT_DECL
- register void* res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = size;
- d1 = requirements;
- __asm volatile ("
- jsr a6@(-0x186)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BPTR ArpOpen(BASE_PAR_DECL char* name, LONG mode)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = mode;
- __asm volatile ("
- jsr a6@(-0x18c)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static BPTR ArpDupLock(BASE_PAR_DECL BPTR lock)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = lock;
- __asm volatile ("
- jsr a6@(-0x192)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BPTR ArpLock(BASE_PAR_DECL char* name, LONG mode)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
- register LONG d2 __asm("d2");
-
- a6 = BASE_NAME;
- d1 = name;
- d2 = mode;
- __asm volatile ("
- jsr a6@(-0x198)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (d2)
- : "d0", "d1", "a0", "a1", "d2");
- return res;
- }
- __inline static void* RListAlloc(BASE_PAR_DECL struct ResList* reslist, LONG size)
- {
- BASE_EXT_DECL
- register void* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct ResList* a0 __asm("a0");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a0 = reslist;
- d0 = size;
- __asm volatile ("
- jsr a6@(-0x19e)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- __inline static struct Process* FindCLI(BASE_PAR_DECL LONG clinum)
- {
- BASE_EXT_DECL
- register struct Process* res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- d0 = clinum;
- __asm volatile ("
- jsr a6@(-0x1a4)"
- : "=g" (res)
- : "g" (a6), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL QSort(BASE_PAR_DECL void* base, LONG rsize, LONG bsize, int(*comp)())
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register void* a0 __asm("a0");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
- register int(*a1)() __asm("a1");
-
- a6 = BASE_NAME;
- a0 = base;
- d0 = rsize;
- d1 = bsize;
- a1 = comp;
- __asm volatile ("
- jsr a6@(-0x1aa)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0), "g" (d1), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL PatternMatch(BASE_PAR_DECL char* pattern, char* string)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = pattern;
- a1 = string;
- __asm volatile ("
- jsr a6@(-0x1b0)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG FindFirst(BASE_PAR_DECL char* pattern, struct AnchorPath* AnchorPath)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d0 __asm("d0");
- register struct AnchorPath* a0 __asm("a0");
-
- a6 = BASE_NAME;
- d0 = pattern;
- a0 = AnchorPath;
- __asm volatile ("
- jsr a6@(-0x1b6)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG FindNext(BASE_PAR_DECL struct AnchorPath* AnchorPath)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register struct AnchorPath* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = AnchorPath;
- __asm volatile ("
- jsr a6@(-0x1bc)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void FreeAnchorChain(BASE_PAR_DECL struct AnchorPath* AnchorPath)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct AnchorPath* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = AnchorPath;
- __asm volatile ("
- jsr a6@(-0x1c2)"
- : /* no output */
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- }
- __inline static ULONG CompareLock(BASE_PAR_DECL BPTR lock1, BPTR lock2)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d0 __asm("d0");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = lock1;
- d1 = lock2;
- __asm volatile ("
- jsr a6@(-0x1c8)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct ResList* FindTaskResList(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register struct ResList* res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x1ce)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct ResList* CreateTaskResList(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register struct ResList* res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x1d4)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void FreeResList(BASE_PAR_DECL struct ResList* freelist)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct ResList* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = freelist;
- __asm volatile ("
- jsr a6@(-0x1da)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static void FreeTrackedItem(BASE_PAR_DECL struct DefaultTracker* item)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct DefaultTracker* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = item;
- __asm volatile ("
- jsr a6@(-0x1e0)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- #ifdef PRIVATE
- __inline static struct DefaultTracker* GetTracker(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register struct DefaultTracker* res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x1e6)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- __inline static void* GetAccess(BASE_PAR_DECL struct DefaultTracker* tracker)
- {
- BASE_EXT_DECL
- register void* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct DefaultTracker* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = tracker;
- __asm volatile ("
- jsr a6@(-0x1ec)"
- : "=g" (res)
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void FreeAccess(BASE_PAR_DECL struct DefaultTracker* tracker)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct DefaultTracker* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = tracker;
- __asm volatile ("
- jsr a6@(-0x1f2)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static void FreeDAList(BASE_PAR_DECL struct DirectoryEntry* node)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct DirectoryEntry* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = node;
- __asm volatile ("
- jsr a6@(-0x1f8)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static struct DirectoryEntry* AddDANode(BASE_PAR_DECL char* data, struct DirectoryEntry** dalist, LONG length, LONG id)
- {
- BASE_EXT_DECL
- register struct DirectoryEntry* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register struct DirectoryEntry** a1 __asm("a1");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- a0 = data;
- a1 = dalist;
- d0 = length;
- d1 = id;
- __asm volatile ("
- jsr a6@(-0x1fe)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static ULONG AddDADevs(BASE_PAR_DECL struct DirectoryEntry** dalist, LONG select)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register struct DirectoryEntry** a0 __asm("a0");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a0 = dalist;
- d0 = select;
- __asm volatile ("
- jsr a6@(-0x204)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Strcmp(BASE_PAR_DECL char* s1, char* s2)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = s1;
- a1 = s2;
- __asm volatile ("
- jsr a6@(-0x20a)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG Strncmp(BASE_PAR_DECL char* s1, char* s2, LONG count)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a0 = s1;
- a1 = s2;
- d0 = count;
- __asm volatile ("
- jsr a6@(-0x210)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #ifdef PRIVATE
- __inline static BYTE Toupper(BASE_PAR_DECL BYTE character)
- {
- BASE_EXT_DECL
- register BYTE res __asm("d0");
- register void *a6 __asm ("a6");
- register BYTE d0 __asm("d0");
-
- a6 = BASE_NAME;
- d0 = character;
- __asm volatile ("
- jsr a6@(-0x216)"
- : "=g" (res)
- : "g" (a6), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- __inline static LONG SyncRun(BASE_PAR_DECL char* name, char* command, BPTR input, BPTR output)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
- register BPTR d0 __asm("d0");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- a0 = name;
- a1 = command;
- d0 = input;
- d1 = output;
- __asm volatile ("
- jsr a6@(-0x21c)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG ASyncRun(BASE_PAR_DECL char* name, char* command, struct ProcessControlBlock* pcb)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
- register struct ProcessControlBlock* a2 __asm("a2");
-
- a6 = BASE_NAME;
- a0 = name;
- a1 = command;
- a2 = pcb;
- __asm volatile ("
- jsr a6@(-0x222)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1), "g" (a2)
- : "d0", "d1", "a0", "a1", "a2");
- return res;
- }
- __inline static BPTR LoadPrg(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register BPTR res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = name;
- __asm volatile ("
- jsr a6@(-0x228)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL PreParse(BASE_PAR_DECL char* source, char* dest)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = source;
- a1 = dest;
- __asm volatile ("
- jsr a6@(-0x22e)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL StamptoStr(BASE_PAR_DECL struct DateTime* datetime)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register struct DateTime* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = datetime;
- __asm volatile ("
- jsr a6@(-0x234)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static BOOL StrtoStamp(BASE_PAR_DECL struct DateTime* datetime)
- {
- BASE_EXT_DECL
- register BOOL res __asm("d0");
- register void *a6 __asm ("a6");
- register struct DateTime* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = datetime;
- __asm volatile ("
- jsr a6@(-0x23a)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct ResidentProgramNode* ObtainResidentPrg(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register struct ResidentProgramNode* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = name;
- __asm volatile ("
- jsr a6@(-0x240)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct ResidentProgramNode* AddResidentPrg(BASE_PAR_DECL BPTR Segment, char* name)
- {
- BASE_EXT_DECL
- register struct ResidentProgramNode* res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- d1 = Segment;
- a0 = name;
- __asm volatile ("
- jsr a6@(-0x246)"
- : "=g" (res)
- : "g" (a6), "g" (d1), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG RemResidentPrg(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = name;
- __asm volatile ("
- jsr a6@(-0x24c)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void UnLoadPrg(BASE_PAR_DECL BPTR segment)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = segment;
- __asm volatile ("
- jsr a6@(-0x252)"
- : /* no output */
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static LONG LMult(BASE_PAR_DECL LONG a, LONG b)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = a;
- d1 = b;
- __asm volatile ("
- jsr a6@(-0x258)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG LDiv(BASE_PAR_DECL LONG a, LONG b)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = a;
- d1 = b;
- __asm volatile ("
- jsr a6@(-0x25e)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG LMod(BASE_PAR_DECL LONG a, LONG b)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register LONG d0 __asm("d0");
- register LONG d1 __asm("d1");
-
- a6 = BASE_NAME;
- d0 = a;
- d1 = b;
- __asm volatile ("
- jsr a6@(-0x264)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static ULONG CheckSumPrg(BASE_PAR_DECL struct ResidentProgramNode* ResidentNode)
- {
- BASE_EXT_DECL
- register ULONG res __asm("d0");
- register void *a6 __asm ("a6");
- register struct ResidentProgramNode* d0 __asm("d0");
-
- a6 = BASE_NAME;
- d0 = ResidentNode;
- __asm volatile ("
- jsr a6@(-0x26a)"
- : "=g" (res)
- : "g" (a6), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void TackOn(BASE_PAR_DECL char* pathname, char* filename)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = pathname;
- a1 = filename;
- __asm volatile ("
- jsr a6@(-0x270)"
- : /* no output */
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static BYTE* BaseName(BASE_PAR_DECL char* name)
- {
- BASE_EXT_DECL
- register BYTE* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = name;
- __asm volatile ("
- jsr a6@(-0x276)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct ResidentProgramNode* ReleaseResidentPrg(BASE_PAR_DECL BPTR segment)
- {
- BASE_EXT_DECL
- register struct ResidentProgramNode* res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR d1 __asm("d1");
-
- a6 = BASE_NAME;
- d1 = segment;
- __asm volatile ("
- jsr a6@(-0x27c)"
- : "=g" (res)
- : "g" (a6), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #ifdef PRIVATE
- #ifdef DOTDOTDOT
- __inline static LONG SPrintf(BASE_PAR_DECL char* file, char* string, ... stream)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* d0 __asm("d0");
- register char* a0 __asm("a0");
- register ... a1 __asm("a1");
-
- a6 = BASE_NAME;
- d0 = file;
- a0 = string;
- a1 = stream;
- __asm volatile ("
- jsr a6@(-0x282)"
- : "=g" (res)
- : "g" (a6), "g" (d0), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- __inline static LONG GetKeywordIndex(BASE_PAR_DECL char* char *, char* char *)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a0 __asm("a0");
- register char* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = char *;
- a1 = char *;
- __asm volatile ("
- jsr a6@(-0x288)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct Library* ArpOpenLibrary(BASE_PAR_DECL char* name, LONG vers)
- {
- BASE_EXT_DECL
- register struct Library* res __asm("d0");
- register void *a6 __asm ("a6");
- register char* a1 __asm("a1");
- register LONG d0 __asm("d0");
-
- a6 = BASE_NAME;
- a1 = name;
- d0 = vers;
- __asm volatile ("
- jsr a6@(-0x28e)"
- : "=g" (res)
- : "g" (a6), "g" (a1), "g" (d0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct FileRequester* ArpAllocFreq(BASE_PAR_DECL void)
- {
- BASE_EXT_DECL
- register struct FileRequester* res __asm("d0");
- register void *a6 __asm ("a6");
- a6 = BASE_NAME;
- __asm volatile ("
- jsr a6@(-0x294)"
- : "=g" (res)
- : "g" (a6)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #endif
- #undef BASE_EXT_DECL
- #undef BASE_PAR_DECL
- #undef BASE_NAME
-