xref: /csrg-svn/sys/tahoe/align/Ashlq.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  *	@(#)Ashlq.c	7.1 (Berkeley) 12/06/90
11*45760Sbostic  */
1229633Ssam 
1345699Sbostic #include "align.h"
shlq(infop)1429633Ssam shlq(infop) 	process_info *infop;
1529633Ssam /*
1629633Ssam /*	Shift left quadword.
1729633Ssam /*
1829633Ssam /********************************/
1929633Ssam {
2029633Ssam 	register	long	Register_12;	/* Has to be first reg ! */
2129633Ssam 	register 	long	Register_11;
2229633Ssam 	register 	long	Register_10;
2329633Ssam 	register	long	*Register_9;
2429633Ssam 	quadword	result;
2529633Ssam 
2629633Ssam 	Register_12 = operand(infop,0)->data;	/* Counter */
2729633Ssam 	Register_9 = &operand(infop,1)->data;	/* Source */
2829633Ssam 
2929633Ssam 	Register_10=psl;
3029633Ssam 	Set_psl(r10);	/* restore the user psl */
3129633Ssam 	asm ("	shlq	r12,(r9),r10");
3229633Ssam 	asm ("	movpsl	r12");
3329633Ssam 	New_cc (Register_12);
3429633Ssam 	result.high = Register_10;
3529633Ssam 	result.low  = Register_11;
3629633Ssam 	write_quadword (infop, result, operand(infop,2));
3729633Ssam }
38