xref: /OK3568_Linux_fs/kernel/arch/m68k/fpsp040/x_bsun.S (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun|
2*4882a593Smuzhiyun|	x_bsun.sa 3.3 7/1/91
3*4882a593Smuzhiyun|
4*4882a593Smuzhiyun|	fpsp_bsun --- FPSP handler for branch/set on unordered exception
5*4882a593Smuzhiyun|
6*4882a593Smuzhiyun|	Copy the PC to FPIAR to maintain 881/882 compatibility
7*4882a593Smuzhiyun|
8*4882a593Smuzhiyun|	The real_bsun handler will need to perform further corrective
9*4882a593Smuzhiyun|	measures as outlined in the 040 User's Manual on pages
10*4882a593Smuzhiyun|	9-41f, section 9.8.3.
11*4882a593Smuzhiyun|
12*4882a593Smuzhiyun
13*4882a593Smuzhiyun|		Copyright (C) Motorola, Inc. 1990
14*4882a593Smuzhiyun|			All Rights Reserved
15*4882a593Smuzhiyun|
16*4882a593Smuzhiyun|       For details on the license for this file, please see the
17*4882a593Smuzhiyun|       file, README, in this same directory.
18*4882a593Smuzhiyun
19*4882a593SmuzhiyunX_BSUN:	|idnt    2,1 | Motorola 040 Floating Point Software Package
20*4882a593Smuzhiyun
21*4882a593Smuzhiyun	|section	8
22*4882a593Smuzhiyun
23*4882a593Smuzhiyun#include "fpsp.h"
24*4882a593Smuzhiyun
25*4882a593Smuzhiyun	|xref	real_bsun
26*4882a593Smuzhiyun
27*4882a593Smuzhiyun	.global	fpsp_bsun
28*4882a593Smuzhiyunfpsp_bsun:
29*4882a593Smuzhiyun|
30*4882a593Smuzhiyun	link		%a6,#-LOCAL_SIZE
31*4882a593Smuzhiyun	fsave		-(%a7)
32*4882a593Smuzhiyun	moveml		%d0-%d1/%a0-%a1,USER_DA(%a6)
33*4882a593Smuzhiyun	fmovemx	%fp0-%fp3,USER_FP0(%a6)
34*4882a593Smuzhiyun	fmoveml	%fpcr/%fpsr/%fpiar,USER_FPCR(%a6)
35*4882a593Smuzhiyun
36*4882a593Smuzhiyun|
37*4882a593Smuzhiyun	movel		EXC_PC(%a6),USER_FPIAR(%a6)
38*4882a593Smuzhiyun|
39*4882a593Smuzhiyun	moveml		USER_DA(%a6),%d0-%d1/%a0-%a1
40*4882a593Smuzhiyun	fmovemx	USER_FP0(%a6),%fp0-%fp3
41*4882a593Smuzhiyun	fmoveml	USER_FPCR(%a6),%fpcr/%fpsr/%fpiar
42*4882a593Smuzhiyun	frestore	(%a7)+
43*4882a593Smuzhiyun	unlk		%a6
44*4882a593Smuzhiyun	bral		real_bsun
45*4882a593Smuzhiyun|
46*4882a593Smuzhiyun	|end
47