home *** CD-ROM | disk | FTP | other *** search
Wrap
#include <inline/stub.h> #ifndef BASE_EXT_DECL #define BASE_EXT_DECL extern struct IFFParseBase * IFFParseBase; #endif #ifndef BASE_PAR_DECL #define BASE_PAR_DECL #define BASE_PAR_DECL0 void #endif #ifndef BASE_NAME #define BASE_NAME IFFParseBase #endif __inline static struct IFFHandle* AllocIFF(BASE_PAR_DECL0) { BASE_EXT_DECL register struct IFFHandle* res __asm("d0"); register void *a6 __asm ("a6"); a6 = BASE_NAME; __asm volatile (" jsr a6@(-0x1e)" : "=g" (res) : "g" (a6) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG OpenIFF(BASE_PAR_DECL struct IFFHandle* iff, long int rwMode) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; d0 = rwMode; __asm volatile (" jsr a6@(-0x24)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG ParseIFF(BASE_PAR_DECL struct IFFHandle* iff, long int control) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; d0 = control; __asm volatile (" jsr a6@(-0x2a)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static void CloseIFF(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0x30)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static void FreeIFF(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0x36)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static LONG ReadChunkBytes(BASE_PAR_DECL struct IFFHandle* iff, APTR buf, long int size) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register APTR a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = buf; d0 = size; __asm volatile (" jsr a6@(-0x3c)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG WriteChunkBytes(BASE_PAR_DECL struct IFFHandle* iff, APTR buf, long int size) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register APTR a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = buf; d0 = size; __asm volatile (" jsr a6@(-0x42)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG ReadChunkRecords(BASE_PAR_DECL struct IFFHandle* iff, APTR buf, long int bytesPerRecord, long int nRecords) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register APTR a1 __asm("a1"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; a1 = buf; d0 = bytesPerRecord; d1 = nRecords; __asm volatile (" jsr a6@(-0x48)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG WriteChunkRecords(BASE_PAR_DECL struct IFFHandle* iff, APTR buf, long int bytesPerRecord, long int nRecords) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register APTR a1 __asm("a1"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; a1 = buf; d0 = bytesPerRecord; d1 = nRecords; __asm volatile (" jsr a6@(-0x4e)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG PushChunk(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id, long int size) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); register long int d2 __asm("d2"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; d2 = size; __asm volatile (" jsr a6@(-0x54)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1), "g" (d2) : "d0", "d1", "a0", "a1", "d2"); return res; } __inline static LONG PopChunk(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0x5a)" : "=g" (res) : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG EntryHandler(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id, long int position, struct Hook* handler, APTR object) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); register long int d2 __asm("d2"); register struct Hook* a1 __asm("a1"); register APTR a2 __asm("a2"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; d2 = position; a1 = handler; a2 = object; __asm volatile (" jsr a6@(-0x66)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1), "g" (d2), "g" (a1), "g" (a2) : "d0", "d1", "a0", "a1", "d2", "a2"); return res; } __inline static LONG ExitHandler(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id, long int position, struct Hook* handler, APTR object) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); register long int d2 __asm("d2"); register struct Hook* a1 __asm("a1"); register APTR a2 __asm("a2"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; d2 = position; a1 = handler; a2 = object; __asm volatile (" jsr a6@(-0x6c)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1), "g" (d2), "g" (a1), "g" (a2) : "d0", "d1", "a0", "a1", "d2", "a2"); return res; } __inline static LONG PropChunk(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0x72)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG PropChunks(BASE_PAR_DECL struct IFFHandle* iff, LONG* propArray, long int nProps) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register LONG* a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = propArray; d0 = nProps; __asm volatile (" jsr a6@(-0x78)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG StopChunk(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0x7e)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG StopChunks(BASE_PAR_DECL struct IFFHandle* iff, LONG* propArray, long int nProps) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register LONG* a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = propArray; d0 = nProps; __asm volatile (" jsr a6@(-0x84)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG CollectionChunk(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0x8a)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG CollectionChunks(BASE_PAR_DECL struct IFFHandle* iff, LONG* propArray, long int nProps) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register LONG* a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = propArray; d0 = nProps; __asm volatile (" jsr a6@(-0x90)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG StopOnExit(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0x96)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static struct StoredProperty* FindProp(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register struct StoredProperty* res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0x9c)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static struct CollectionItem* FindCollection(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id) { BASE_EXT_DECL register struct CollectionItem* res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; __asm volatile (" jsr a6@(-0xa2)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1) : "d0", "d1", "a0", "a1"); return res; } __inline static struct ContextNode* FindPropContext(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register struct ContextNode* res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0xa8)" : "=g" (res) : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } __inline static struct ContextNode* CurrentChunk(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register struct ContextNode* res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0xae)" : "=g" (res) : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } __inline static struct ContextNode* ParentChunk(BASE_PAR_DECL struct ContextNode* contextNode) { BASE_EXT_DECL register struct ContextNode* res __asm("d0"); register void *a6 __asm ("a6"); register struct ContextNode* a0 __asm("a0"); a6 = BASE_NAME; a0 = contextNode; __asm volatile (" jsr a6@(-0xb4)" : "=g" (res) : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } __inline static struct LocalContextItem* AllocLocalItem(BASE_PAR_DECL long int type, long int id, long int ident, long int dataSize) { BASE_EXT_DECL register struct LocalContextItem* res __asm("d0"); register void *a6 __asm ("a6"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); register long int d2 __asm("d2"); register long int d3 __asm("d3"); a6 = BASE_NAME; d0 = type; d1 = id; d2 = ident; d3 = dataSize; __asm volatile (" jsr a6@(-0xba)" : "=g" (res) : "g" (a6), "g" (d0), "g" (d1), "g" (d2), "g" (d3) : "d0", "d1", "a0", "a1", "d2", "d3"); return res; } __inline static APTR LocalItemData(BASE_PAR_DECL struct LocalContextItem* localItem) { BASE_EXT_DECL register APTR res __asm("d0"); register void *a6 __asm ("a6"); register struct LocalContextItem* a0 __asm("a0"); a6 = BASE_NAME; a0 = localItem; __asm volatile (" jsr a6@(-0xc0)" : "=g" (res) : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } __inline static void SetLocalItemPurge(BASE_PAR_DECL struct LocalContextItem* localItem, struct Hook* purgeHook) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct LocalContextItem* a0 __asm("a0"); register struct Hook* a1 __asm("a1"); a6 = BASE_NAME; a0 = localItem; a1 = purgeHook; __asm volatile (" jsr a6@(-0xc6)" : /* no output */ : "g" (a6), "g" (a0), "g" (a1) : "d0", "d1", "a0", "a1"); } __inline static void FreeLocalItem(BASE_PAR_DECL struct LocalContextItem* localItem) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct LocalContextItem* a0 __asm("a0"); a6 = BASE_NAME; a0 = localItem; __asm volatile (" jsr a6@(-0xcc)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static struct LocalContextItem* FindLocalItem(BASE_PAR_DECL struct IFFHandle* iff, long int type, long int id, long int ident) { BASE_EXT_DECL register struct LocalContextItem* res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register long int d1 __asm("d1"); register long int d2 __asm("d2"); a6 = BASE_NAME; a0 = iff; d0 = type; d1 = id; d2 = ident; __asm volatile (" jsr a6@(-0xd2)" : "=g" (res) : "g" (a6), "g" (a0), "g" (d0), "g" (d1), "g" (d2) : "d0", "d1", "a0", "a1", "d2"); return res; } __inline static LONG StoreLocalItem(BASE_PAR_DECL struct IFFHandle* iff, struct LocalContextItem* localItem, long int position) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register struct LocalContextItem* a1 __asm("a1"); register long int d0 __asm("d0"); a6 = BASE_NAME; a0 = iff; a1 = localItem; d0 = position; __asm volatile (" jsr a6@(-0xd8)" : "=g" (res) : "g" (a6), "g" (a0), "g" (a1), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static void StoreItemInContext(BASE_PAR_DECL struct IFFHandle* iff, struct LocalContextItem* localItem, struct ContextNode* contextNode) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register struct LocalContextItem* a1 __asm("a1"); register struct ContextNode* a2 __asm("a2"); a6 = BASE_NAME; a0 = iff; a1 = localItem; a2 = contextNode; __asm volatile (" jsr a6@(-0xde)" : /* no output */ : "g" (a6), "g" (a0), "g" (a1), "g" (a2) : "d0", "d1", "a0", "a1", "a2"); } __inline static void InitIFF(BASE_PAR_DECL struct IFFHandle* iff, long int flags, struct Hook* streamHook) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); register long int d0 __asm("d0"); register struct Hook* a1 __asm("a1"); a6 = BASE_NAME; a0 = iff; d0 = flags; a1 = streamHook; __asm volatile (" jsr a6@(-0xe4)" : /* no output */ : "g" (a6), "g" (a0), "g" (d0), "g" (a1) : "d0", "d1", "a0", "a1"); } __inline static void InitIFFasDOS(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0xea)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static void InitIFFasClip(BASE_PAR_DECL struct IFFHandle* iff) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct IFFHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = iff; __asm volatile (" jsr a6@(-0xf0)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static struct ClipboardHandle* OpenClipboard(BASE_PAR_DECL long int unitNum) { BASE_EXT_DECL register struct ClipboardHandle* res __asm("d0"); register void *a6 __asm ("a6"); register long int d0 __asm("d0"); a6 = BASE_NAME; d0 = unitNum; __asm volatile (" jsr a6@(-0xf6)" : "=g" (res) : "g" (a6), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static void CloseClipboard(BASE_PAR_DECL struct ClipboardHandle* clipboard) { BASE_EXT_DECL register void *a6 __asm ("a6"); register struct ClipboardHandle* a0 __asm("a0"); a6 = BASE_NAME; a0 = clipboard; __asm volatile (" jsr a6@(-0xfc)" : /* no output */ : "g" (a6), "g" (a0) : "d0", "d1", "a0", "a1"); } __inline static LONG GoodID(BASE_PAR_DECL long int id) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register long int d0 __asm("d0"); a6 = BASE_NAME; d0 = id; __asm volatile (" jsr a6@(-0x102)" : "=g" (res) : "g" (a6), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static LONG GoodType(BASE_PAR_DECL long int type) { BASE_EXT_DECL register LONG res __asm("d0"); register void *a6 __asm ("a6"); register long int d0 __asm("d0"); a6 = BASE_NAME; d0 = type; __asm volatile (" jsr a6@(-0x108)" : "=g" (res) : "g" (a6), "g" (d0) : "d0", "d1", "a0", "a1"); return res; } __inline static STRPTR IDtoStr(BASE_PAR_DECL long int id, STRPTR buf) { BASE_EXT_DECL register STRPTR res __asm("d0"); register void *a6 __asm ("a6"); register long int d0 __asm("d0"); register STRPTR a0 __asm("a0"); a6 = BASE_NAME; d0 = id; a0 = buf; __asm volatile (" jsr a6@(-0x10e)" : "=g" (res) : "g" (a6), "g" (d0), "g" (a0) : "d0", "d1", "a0", "a1"); return res; } #undef BASE_EXT_DECL #undef BASE_PAR_DECL #undef BASE_PAR_DECL0 #undef BASE_NAME