/* $Header:mtsr.s 12.0$ */
/* $ACIS:mtsr.s 12.0$ */
/* $Source: /ibm/acis/usr/sys/standca/RCS/mtsr.s,v $ */

	.data
rcsid:	.asciz	"$Header:mtsr.s 12.0$"
	.text

/*
 * 5799-WZQ (C) COPYRIGHT IBM CORPORATION 1986
 * LICENSED MATERIALS - PROPERTY OF IBM
 * REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083
 */
#include "asm.h"
 #
 #  system reqister access routines
 #
eye_profil(mtsr):
         sli   r2,2               # r2 = parm 1 * 4
         mfs   scr_iar,r5         # set r5 to address of next inst
1:         ais   r5,mts_vector - 1b  # set r5 to address of mts_vector
         a     r5,r2              # set r5 to address of mts_vector entry
         balr  r0,r5              # case statement (set r0 for debug)
mts_vector:                       # each entry must be 4 bytes
         brx   r15;   mts %0,r3   # set scr 00 to 2nd parm
         brx   r15;   mts %1,r3   # set scr 01 to 2nd parm
         brx   r15;   mts %2,r3   # set scr 02 to 2nd parm
         brx   r15;   mts %3,r3   # set scr 03 to 2nd parm
         brx   r15;   mts %4,r3   # set scr 04 to 2nd parm
         brx   r15;   mts %5,r3   # set scr 05 to 2nd parm
         brx   r15;   mts %6,r3   # set scr 06 to 2nd parm
         brx   r15;   mts %7,r3   # set scr 07 to 2nd parm
         brx   r15;   mts %8,r3   # set scr 08 to 2nd parm
         brx   r15;   mts %9,r3   # set scr 09 to 2nd parm
         brx   r15;   mts %10,r3   # set scr 10 to 2nd parm
         brx   r15;   mts %11,r3   # set scr 11 to 2nd parm
         brx   r15;   mts %12,r3   # set scr 12 to 2nd parm
         brx   r15;   mts %13,r3   # set scr 13 to 2nd parm
         brx   r15;   mts %14,r3   # set scr 14 to 2nd parm
         brx   r15;   mts %15,r3   # set scr 15 to 2nd parm
eye_profil(mfsr):
         sli   r2,2               # r2 = parm 1 * 4
         mfs   scr_iar,r5         # set r5 to address of next inst
1:         ais   r5,mfs_vector - 1b  # set r5 to address of mfs_vector
         a     r5,r2              # set r5 to address of mfs_vector entry
         balr  r0,r5              # case statement (set r0 for debug)
mfs_vector:                       # each entry must be 4 bytes
         brx   r15;   mfs %0,RETREG   # return scr 00
         brx   r15;   mfs %1,RETREG   # return scr 01
         brx   r15;   mfs %2,RETREG   # return scr 02
         brx   r15;   mfs %3,RETREG   # return scr 03
         brx   r15;   mfs %4,RETREG   # return scr 04
         brx   r15;   mfs %5,RETREG   # return scr 05
         brx   r15;   mfs %6,RETREG   # return scr 06
         brx   r15;   mfs %7,RETREG   # return scr 07
         brx   r15;   mfs %8,RETREG   # return scr 08
         brx   r15;   mfs %9,RETREG   # return scr 09
         brx   r15;   mfs %10,RETREG   # return scr 10
         brx   r15;   mfs %11,RETREG   # return scr 11
         brx   r15;   mfs %12,RETREG   # return scr 12
         brx   r15;   mfs %13,RETREG   # return scr 13
         brx   r15;   mfs %14,RETREG   # return scr 14
         brx   r15;   mfs %15,RETREG   # return scr 15
