xref: /csrg-svn/sys/tahoe/align/Ainc.c (revision 45760)
1*45760Sbostic /*-
2*45760Sbostic  * Copyright (c) 1986 The Regents of the University of California.
3*45760Sbostic  * All rights reserved.
4*45760Sbostic  *
5*45760Sbostic  * This code is derived from software contributed to Berkeley by
6*45760Sbostic  * Computer Consoles Inc.
7*45760Sbostic  *
8*45760Sbostic  * %sccs.include.redist.c%
9*45760Sbostic  *
10*45760Sbostic  *	@(#)Ainc.c	7.1 (Berkeley) 12/06/90
11*45760Sbostic  */
1229611Ssam 
1345699Sbostic #include "align.h"
inc(infop)1429611Ssam inc(infop)	process_info *infop;
1529611Ssam /*
1629611Ssam /*	Increment operand.
1729611Ssam /*
1829611Ssam /***************************************/
1929611Ssam {
2029611Ssam 	register	long	Register_12;	/* Has to be first reg ! */
2129611Ssam 	register	long	Register_11;
2229611Ssam 
2329611Ssam 	Register_11 = operand(infop,0)->data;
2429611Ssam 	Register_12=psl;
2529611Ssam 	Set_psl(r12);	/* restore the user psl */
2629611Ssam 	asm ("	incl	r11");			/* Make sure to use the
2729611Ssam 						 * right opcode */
2829611Ssam 	asm ("	movpsl	r12");
2929611Ssam 	New_cc (Register_12);
3029611Ssam 
3129611Ssam 	write_back (infop,Register_11, operand(infop,0) );
3229611Ssam }
33