1*b65ab6e5Sbostic /*- 2*b65ab6e5Sbostic * Copyright (c) 1986 The Regents of the University of California. 3*b65ab6e5Sbostic * All rights reserved. 4*b65ab6e5Sbostic * 5*b65ab6e5Sbostic * This code is derived from software contributed to Berkeley by 6*b65ab6e5Sbostic * Computer Consoles Inc. 7*b65ab6e5Sbostic * 8*b65ab6e5Sbostic * %sccs.include.redist.c% 9*b65ab6e5Sbostic * 10*b65ab6e5Sbostic * @(#)Asub3.c 7.1 (Berkeley) 12/06/90 11*b65ab6e5Sbostic */ 1288fc2307Ssam 13f5878f6dSbostic #include "align.h" sub3(infop)1488fc2307Ssamsub3(infop) process_info *infop; 1588fc2307Ssam /* 1688fc2307Ssam /* Subtract , 3 operands. 1788fc2307Ssam /* 1888fc2307Ssam /*****************************************/ 1988fc2307Ssam { 2088fc2307Ssam 2188fc2307Ssam register long Register_12; /* Has to be first reg ! */ 2288fc2307Ssam register long data0, data1, result; 2388fc2307Ssam 2488fc2307Ssam data0 = operand(infop,0)->data; 2588fc2307Ssam data1 = operand(infop,1)->data; 2688fc2307Ssam Register_12=psl; 2788fc2307Ssam Set_psl(r12); /* restore the user psl */ 2888fc2307Ssam result = data1 - data0; /* 32 bits of true result */ 2988fc2307Ssam asm (" movpsl r12"); 3088fc2307Ssam New_cc (Register_12); 3188fc2307Ssam write_back (infop,result, operand(infop,2) ); 3288fc2307Ssam } 33