1*daf50b84Smickey /* $OpenBSD: prefix.h,v 1.2 2001/03/29 04:08:21 mickey Exp $ */ 270753211Smickey 370753211Smickey /* 470753211Smickey * (c) Copyright 1985 HEWLETT-PACKARD COMPANY 570753211Smickey * 670753211Smickey * To anyone who acknowledges that this file is provided "AS IS" 770753211Smickey * without any express or implied warranty: 870753211Smickey * permission to use, copy, modify, and distribute this file 970753211Smickey * for any purpose is hereby granted without fee, provided that 1070753211Smickey * the above copyright notice and this notice appears in all 1170753211Smickey * copies, and that the name of Hewlett-Packard Company not be 1270753211Smickey * used in advertising or publicity pertaining to distribution 1370753211Smickey * of the software without specific, written prior permission. 1470753211Smickey * Hewlett-Packard Company makes no representations about the 1570753211Smickey * suitability of this software for any purpose. 1670753211Smickey */ 1770753211Smickey 1870753211Smickey /* 1970753211Smickey * STANDARD INCLUDE FILE FOR MILLICODE 2070753211Smickey * Every source file must include this file. 2170753211Smickey * 2270753211Smickey * Hardware General Registers 2370753211Smickey * 2470753211Smickey * Frame Offsets (millicode convention!) 2570753211Smickey * Used when calling other millicode routines. 2670753211Smickey * Stack unwinding is dependent upon these definitions. 2770753211Smickey * r31_slot .equ -20 2870753211Smickey * sr0_slot .equ -16 2970753211Smickey */ 3070753211Smickey 3170753211Smickey #include <machine/asm.h> 3270753211Smickey 3370753211Smickey #define DEFINE(name, value)name: .EQU value 3470753211Smickey #ifdef milliext 3570753211Smickey #ifdef PIC 3670753211Smickey #define MILLI_BE(lbl) \ 3770753211Smickey BL .+8,r1\ 3870753211Smickey ! ADDIL L%lbl-labl/**/lbl,r1\ 3970753211Smickey ! .LABEL labl/**/lbl\ 4070753211Smickey ! BE R%lbl-labl/**/lbl(sr7,r1) 4170753211Smickey 4270753211Smickey #define MILLI_BEN(lbl) \ 4370753211Smickey BL .+8,r1\ 4470753211Smickey ! ADDIL L%lbl-labl/**/lbl,r1\ 4570753211Smickey ! .LABEL labl/**/lbl\ 4670753211Smickey ! BE,N R%lbl-labl/**/lbl(sr7,r1) 4770753211Smickey 4870753211Smickey #define MILLI_BLE(lbl) \ 4970753211Smickey BL .+8,r1\ 5070753211Smickey ! ADDIL L%lbl-labl/**/lbl,r1\ 5170753211Smickey ! .LABEL labl/**/lbl \ 5270753211Smickey ! BLE R%lbl-labl/**/lbl(sr7,r1) 5370753211Smickey 5470753211Smickey #define MILLI_BLEN(lbl) \ 5570753211Smickey BL .+8,r1\ 5670753211Smickey ! ADDIL L%lbl-labl/**/lbl,r1\ 5770753211Smickey ! .LABEL labl/**/lbl\ 5870753211Smickey ! BLE,N R%lbl-labl/**/lbl(sr7,r1) 5970753211Smickey #else 6070753211Smickey #define MILLI_BE(lbl) BE lbl(sr7,r0) 6170753211Smickey #define MILLI_BEN(lbl) BE,n lbl(sr7,r0) 6270753211Smickey #define MILLI_BLE(lbl) BLE lbl(sr7,r0) 6370753211Smickey #define MILLI_BLEN(lbl) BLE,n lbl(sr7,r0) 6470753211Smickey #endif 6570753211Smickey 6670753211Smickey #define MILLIRETN BE,n 0(sr0,r31) 6770753211Smickey #define MILLIRET BE 0(sr0,r31) 6870753211Smickey #define MILLI_RETN BE,n 0(sr0,r31) 6970753211Smickey #define MILLI_RET BE 0(sr0,r31) 7070753211Smickey 7170753211Smickey #else 7270753211Smickey #define MILLI_BE(lbl) B lbl 7370753211Smickey #define MILLI_BEN(lbl) B,n lbl 7470753211Smickey #define MILLI_BLE(lbl) BL lbl,r31 7570753211Smickey #define MILLI_BLEN(lbl) BL,n lbl,r31 7670753211Smickey #define MILLIRETN BV,n 0(r31) 7770753211Smickey #define MILLIRET BV 0(r31) 7870753211Smickey #define MILLI_RETN BV,n 0(r31) 7970753211Smickey #define MILLI_RET BV 0(r31) 8070753211Smickey #endif 8170753211Smickey ; VERSION is used wherever ".version" can appear in a routine 8270753211Smickey ;#define VERSION .version 8370753211Smickey #define VERSION ; 84