jalr.c 817 Bytes
/****************************************************************
  WHAT: RSP SCALAR UNIT Jxx INSTRUCTION TEST GENERATOR
  SCCS: @(#)jalr.c	1.1 03 Aug 1994
  FILE:	jalr.c
   WHO:	Project Reality - Evan Y. Wang
   (C):	1994 Silicon Graphics, Inc.
 ****************************************************************/
#include <stdio.h>
#include "software.h"
#include "gen.h"
#include "suregre.h"

#define	MAX_TCS	MAX_JALR_TCS

#define GenCase()	fprintf(outp,JALRTempl,CurTcNo,ip->name,rA,rB,rT)

/*			     CHKJALR(  n,Op,   rA,   rB,   rT); */
PRIVATE char *JALRTempl = "\tChkJALR(%2d,%s,r%-2d,r%-2d,r%-2d)\n";

int JalrGen(outp, ip)
    FILE *outp;
    I_TABLE *ip;
{
    int r = rT;
    do {
	FILE_SPLIT {
	    GenCase();
	    UpdRegID();
	}
    } while (CurTcNo++, r != rT);
    return CurTcNo = 0;

}   /* JalrGen */