162306a36Sopenharmony_ci~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 262306a36Sopenharmony_ciMOTOROLA MICROPROCESSOR & MEMORY TECHNOLOGY GROUP 362306a36Sopenharmony_ciM68000 Hi-Performance Microprocessor Division 462306a36Sopenharmony_ciM68060 Software Package 562306a36Sopenharmony_ciProduction Release P1.00 -- October 10, 1994 662306a36Sopenharmony_ci 762306a36Sopenharmony_ciM68060 Software Package Copyright © 1993, 1994 Motorola Inc. All rights reserved. 862306a36Sopenharmony_ci 962306a36Sopenharmony_ciTHE SOFTWARE is provided on an "AS IS" basis and without warranty. 1062306a36Sopenharmony_ciTo the maximum extent permitted by applicable law, 1162306a36Sopenharmony_ciMOTOROLA DISCLAIMS ALL WARRANTIES WHETHER EXPRESS OR IMPLIED, 1262306a36Sopenharmony_ciINCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE 1362306a36Sopenharmony_ciand any warranty against infringement with regard to the SOFTWARE 1462306a36Sopenharmony_ci(INCLUDING ANY MODIFIED VERSIONS THEREOF) and any accompanying written materials. 1562306a36Sopenharmony_ci 1662306a36Sopenharmony_ciTo the maximum extent permitted by applicable law, 1762306a36Sopenharmony_ciIN NO EVENT SHALL MOTOROLA BE LIABLE FOR ANY DAMAGES WHATSOEVER 1862306a36Sopenharmony_ci(INCLUDING WITHOUT LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFITS, 1962306a36Sopenharmony_ciBUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, OR OTHER PECUNIARY LOSS) 2062306a36Sopenharmony_ciARISING OF THE USE OR INABILITY TO USE THE SOFTWARE. 2162306a36Sopenharmony_ciMotorola assumes no responsibility for the maintenance and support of the SOFTWARE. 2262306a36Sopenharmony_ci 2362306a36Sopenharmony_ciYou are hereby granted a copyright license to use, modify, and distribute the SOFTWARE 2462306a36Sopenharmony_ciso long as this entire notice is retained without alteration in any modified and/or 2562306a36Sopenharmony_ciredistributed versions, and that such modified versions are clearly identified as such. 2662306a36Sopenharmony_ciNo licenses are granted by implication, estoppel or otherwise under any patents 2762306a36Sopenharmony_cior trademarks of Motorola, Inc. 2862306a36Sopenharmony_ci~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2962306a36Sopenharmony_ci68060 FLOATING-POINT SOFTWARE PACKAGE (Kernel version) 3062306a36Sopenharmony_ci------------------------------------------------------- 3162306a36Sopenharmony_ci 3262306a36Sopenharmony_ciThe file fpsp.sa contains the 68060 Floating-Point Software 3362306a36Sopenharmony_ciPackage. This package is essentially a set of exception handlers 3462306a36Sopenharmony_cithat can be integrated into an operating system. 3562306a36Sopenharmony_ciThese exception handlers emulate Unimplemented FP instructions, 3662306a36Sopenharmony_ciinstructions using unimplemented data types, and instructions 3762306a36Sopenharmony_ciusing unimplemented addressing modes. In addition, this package 3862306a36Sopenharmony_ciincludes exception handlers to provide full IEEE-754 compliant 3962306a36Sopenharmony_ciexception handling. 4062306a36Sopenharmony_ci 4162306a36Sopenharmony_ciRelease file format: 4262306a36Sopenharmony_ci-------------------- 4362306a36Sopenharmony_ciThe file fpsp.sa is essentially a hexadecimal image of the 4462306a36Sopenharmony_cirelease package. This is the ONLY format which will be supported. 4562306a36Sopenharmony_ciThe hex image was created by assembling the source code and 4662306a36Sopenharmony_cithen converting the resulting binary output image into an 4762306a36Sopenharmony_ciASCII text file. The hexadecimal numbers are listed 4862306a36Sopenharmony_ciusing the Motorola Assembly Syntax assembler directive "dc.l" 4962306a36Sopenharmony_ci(define constant longword). The file can be converted to other 5062306a36Sopenharmony_ciassembly syntaxes by using any word processor with a global 5162306a36Sopenharmony_cisearch and replace function. 5262306a36Sopenharmony_ci 5362306a36Sopenharmony_ciTo assist in assembling and linking this module with other modules, 5462306a36Sopenharmony_cithe installer should add a symbolic label to the top of the file. 5562306a36Sopenharmony_ciThis will allow calling routines to access the entry points 5662306a36Sopenharmony_ciof this package. 5762306a36Sopenharmony_ci 5862306a36Sopenharmony_ciThe source code fpsp.s has also been included but only for 5962306a36Sopenharmony_cidocumentation purposes. 6062306a36Sopenharmony_ci 6162306a36Sopenharmony_ciRelease file structure: 6262306a36Sopenharmony_ci----------------------- 6362306a36Sopenharmony_ci 6462306a36Sopenharmony_ci(top of module) 6562306a36Sopenharmony_ci ----------------- 6662306a36Sopenharmony_ci | | - 128 byte-sized section 6762306a36Sopenharmony_ci (1) | Call-Out | - 4 bytes per entry (user fills these in) 6862306a36Sopenharmony_ci | | - example routines in fskeleton.s 6962306a36Sopenharmony_ci ----------------- 7062306a36Sopenharmony_ci | | - 8 bytes per entry 7162306a36Sopenharmony_ci (2) | Entry Point | - user does "bra" or "jmp" to this address 7262306a36Sopenharmony_ci | | 7362306a36Sopenharmony_ci ----------------- 7462306a36Sopenharmony_ci | | - code section 7562306a36Sopenharmony_ci (3) ~ ~ 7662306a36Sopenharmony_ci | | 7762306a36Sopenharmony_ci ----------------- 7862306a36Sopenharmony_ci(bottom of module) 7962306a36Sopenharmony_ci 8062306a36Sopenharmony_ciThe first section of this module is the "Call-out" section. This section 8162306a36Sopenharmony_ciis NOT INCLUDED in fpsp.sa (an example "Call-out" section is provided at 8262306a36Sopenharmony_cithe end of the file fskeleton.s). The purpose of this section is to allow 8362306a36Sopenharmony_cithe FPSP routines to reference external functions that must be provided 8462306a36Sopenharmony_ciby the host operating system. This section MUST be exactly 128 bytes in 8562306a36Sopenharmony_cisize. There are 32 fields, each 4 bytes in size. Each field corresponds 8662306a36Sopenharmony_cito a function required by the FPSP (these functions and their location are 8762306a36Sopenharmony_cilisted in "68060FPSP call-outs" below). Each field entry should contain 8862306a36Sopenharmony_cithe address of the corresponding function RELATIVE to the starting address 8962306a36Sopenharmony_ciof the "call-out" section. The "Call-out" section must sit adjacent to the 9062306a36Sopenharmony_cifpsp.sa image in memory. 9162306a36Sopenharmony_ci 9262306a36Sopenharmony_ciThe second section, the "Entry-point" section, is used by external routines 9362306a36Sopenharmony_cito access the functions within the FPSP. Since the fpsp.sa hex file contains 9462306a36Sopenharmony_cino symbol names, this section contains function entry points that are fixed 9562306a36Sopenharmony_ciwith respect to the top of the package. The currently defined entry-points 9662306a36Sopenharmony_ciare listed in section "68060 FPSP entry points" below. A calling routine 9762306a36Sopenharmony_ciwould simply execute a "bra" or "jmp" that jumped to the selected function 9862306a36Sopenharmony_cientry-point. 9962306a36Sopenharmony_ci 10062306a36Sopenharmony_ciFor example, if the 68060 hardware took a "Line-F Emulator" exception 10162306a36Sopenharmony_ci(vector #11), the operating system should execute something similar to: 10262306a36Sopenharmony_ci 10362306a36Sopenharmony_ci bra _060FPSP_TOP+128+48 10462306a36Sopenharmony_ci 10562306a36Sopenharmony_ci(_060FPSP_TOP is the starting address of the "Call-out" section; the "Call-out" 10662306a36Sopenharmony_cisection is 128 bytes long; and the F-Line FPSP handler entry point is located 10762306a36Sopenharmony_ci48 bytes from the top of the "Entry-point" section.) 10862306a36Sopenharmony_ci 10962306a36Sopenharmony_ciThe third section is the code section. After entering through an "Entry-point", 11062306a36Sopenharmony_cithe entry code jumps to the appropriate emulation code within the code section. 11162306a36Sopenharmony_ci 11262306a36Sopenharmony_ci68060FPSP call-outs: (details in fskeleton.s) 11362306a36Sopenharmony_ci-------------------- 11462306a36Sopenharmony_ci0x000: _060_real_bsun 11562306a36Sopenharmony_ci0x004: _060_real_snan 11662306a36Sopenharmony_ci0x008: _060_real_operr 11762306a36Sopenharmony_ci0x00c: _060_real_ovfl 11862306a36Sopenharmony_ci0x010: _060_real_unfl 11962306a36Sopenharmony_ci0x014: _060_real_dz 12062306a36Sopenharmony_ci0x018: _060_real_inex 12162306a36Sopenharmony_ci0x01c: _060_real_fline 12262306a36Sopenharmony_ci0x020: _060_real_fpu_disabled 12362306a36Sopenharmony_ci0x024: _060_real_trap 12462306a36Sopenharmony_ci0x028: _060_real_trace 12562306a36Sopenharmony_ci0x02c: _060_real_access 12662306a36Sopenharmony_ci0x030: _060_fpsp_done 12762306a36Sopenharmony_ci 12862306a36Sopenharmony_ci0x034: (Motorola reserved) 12962306a36Sopenharmony_ci0x038: (Motorola reserved) 13062306a36Sopenharmony_ci0x03c: (Motorola reserved) 13162306a36Sopenharmony_ci 13262306a36Sopenharmony_ci0x040: _060_imem_read 13362306a36Sopenharmony_ci0x044: _060_dmem_read 13462306a36Sopenharmony_ci0x048: _060_dmem_write 13562306a36Sopenharmony_ci0x04c: _060_imem_read_word 13662306a36Sopenharmony_ci0x050: _060_imem_read_long 13762306a36Sopenharmony_ci0x054: _060_dmem_read_byte 13862306a36Sopenharmony_ci0x058: _060_dmem_read_word 13962306a36Sopenharmony_ci0x05c: _060_dmem_read_long 14062306a36Sopenharmony_ci0x060: _060_dmem_write_byte 14162306a36Sopenharmony_ci0x064: _060_dmem_write_word 14262306a36Sopenharmony_ci0x068: _060_dmem_write_long 14362306a36Sopenharmony_ci 14462306a36Sopenharmony_ci0x06c: (Motorola reserved) 14562306a36Sopenharmony_ci0x070: (Motorola reserved) 14662306a36Sopenharmony_ci0x074: (Motorola reserved) 14762306a36Sopenharmony_ci0x078: (Motorola reserved) 14862306a36Sopenharmony_ci0x07c: (Motorola reserved) 14962306a36Sopenharmony_ci 15062306a36Sopenharmony_ci68060FPSP entry points: 15162306a36Sopenharmony_ci----------------------- 15262306a36Sopenharmony_ci0x000: _060_fpsp_snan 15362306a36Sopenharmony_ci0x008: _060_fpsp_operr 15462306a36Sopenharmony_ci0x010: _060_fpsp_ovfl 15562306a36Sopenharmony_ci0x018: _060_fpsp_unfl 15662306a36Sopenharmony_ci0x020: _060_fpsp_dz 15762306a36Sopenharmony_ci0x028: _060_fpsp_inex 15862306a36Sopenharmony_ci0x030: _060_fpsp_fline 15962306a36Sopenharmony_ci0x038: _060_fpsp_unsupp 16062306a36Sopenharmony_ci0x040: _060_fpsp_effadd 16162306a36Sopenharmony_ci 16262306a36Sopenharmony_ci 16362306a36Sopenharmony_ci 16462306a36Sopenharmony_ciMiscellaneous: 16562306a36Sopenharmony_ci-------------- 16662306a36Sopenharmony_ci 16762306a36Sopenharmony_ci_060_fpsp_snan: 16862306a36Sopenharmony_ci---------------- 16962306a36Sopenharmony_ci- documented in 3.5 of 060SP spec. 17062306a36Sopenharmony_ci- Basic flow: 17162306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_snan --| 17262306a36Sopenharmony_ci | 17362306a36Sopenharmony_ci always exits through _060_real_snan <---- 17462306a36Sopenharmony_ci 17562306a36Sopenharmony_ci_060_fpsp_operr: 17662306a36Sopenharmony_ci---------------- 17762306a36Sopenharmony_ci- documented in 3.5 of 060SP spec. 17862306a36Sopenharmony_ci- Basic flow: 17962306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_operr --| 18062306a36Sopenharmony_ci | 18162306a36Sopenharmony_ci always exits through _060_real_operr <----- 18262306a36Sopenharmony_ci 18362306a36Sopenharmony_ci_060_fpsp_dz: 18462306a36Sopenharmony_ci---------------- 18562306a36Sopenharmony_ci- documented in 3.7 of 060SP spec. 18662306a36Sopenharmony_ci- Basic flow: 18762306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_dz --| 18862306a36Sopenharmony_ci | 18962306a36Sopenharmony_ci always exits through _060_real_dz <---- 19062306a36Sopenharmony_ci 19162306a36Sopenharmony_ci_060_fpsp_inex: 19262306a36Sopenharmony_ci---------------- 19362306a36Sopenharmony_ci- documented in 3.6 of 060SP spec. 19462306a36Sopenharmony_ci- Basic flow: 19562306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_inex --| 19662306a36Sopenharmony_ci | 19762306a36Sopenharmony_ci always exits through _060_real_inex <---- 19862306a36Sopenharmony_ci 19962306a36Sopenharmony_ci 20062306a36Sopenharmony_ci_060_fpsp_ovfl: 20162306a36Sopenharmony_ci---------------- 20262306a36Sopenharmony_ci- documented in 3.4 of 060SP spec. 20362306a36Sopenharmony_ci- Basic flow: 20462306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_ovfl --| 20562306a36Sopenharmony_ci | 20662306a36Sopenharmony_ci may exit through _060_real_inex <---| 20762306a36Sopenharmony_ci or | 20862306a36Sopenharmony_ci may exit through _060_real_ovfl <---| 20962306a36Sopenharmony_ci or | 21062306a36Sopenharmony_ci may exit through _060_fpsp_done <---| 21162306a36Sopenharmony_ci 21262306a36Sopenharmony_ci_060_fpsp_unfl: 21362306a36Sopenharmony_ci---------------- 21462306a36Sopenharmony_ci- documented in 3.4 of 060SP spec. 21562306a36Sopenharmony_ci- Basic flow: 21662306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_unfl --| 21762306a36Sopenharmony_ci | 21862306a36Sopenharmony_ci may exit through _060_real_inex <---| 21962306a36Sopenharmony_ci or | 22062306a36Sopenharmony_ci may exit through _060_real_unfl <---| 22162306a36Sopenharmony_ci or | 22262306a36Sopenharmony_ci may exit through _060_fpsp_done <---| 22362306a36Sopenharmony_ci 22462306a36Sopenharmony_ci 22562306a36Sopenharmony_ci_060_fpsp_fline: 22662306a36Sopenharmony_ci----------------- 22762306a36Sopenharmony_ci- not fully documented in 060SP spec. 22862306a36Sopenharmony_ci- Basic flow: 22962306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_fline --| 23062306a36Sopenharmony_ci | 23162306a36Sopenharmony_ci ------------------------------------------- 23262306a36Sopenharmony_ci | | | 23362306a36Sopenharmony_ci v v v 23462306a36Sopenharmony_ci (unimplemented (fpu disabled) (possible F-line illegal) 23562306a36Sopenharmony_ci stack frame) | v 23662306a36Sopenharmony_ci | v special case "fmovecr"? 23762306a36Sopenharmony_ci | exit through | 23862306a36Sopenharmony_ci | _060_real_fpu_disabled ------------- 23962306a36Sopenharmony_ci | | | 24062306a36Sopenharmony_ci | ^ v v 24162306a36Sopenharmony_ci | | (yes) (no) 24262306a36Sopenharmony_ci | | v v 24362306a36Sopenharmony_ci | | fpu disabled? exit through 24462306a36Sopenharmony_ci | | | _060_real_fline 24562306a36Sopenharmony_ci v | ------------- 24662306a36Sopenharmony_ci | | | | 24762306a36Sopenharmony_ci | | v v 24862306a36Sopenharmony_ci | |-----------(yes) (no) 24962306a36Sopenharmony_ci | | 25062306a36Sopenharmony_ci |----<------------------------------------| 25162306a36Sopenharmony_ci | 25262306a36Sopenharmony_ci | 25362306a36Sopenharmony_ci |----> may exit through _060_real_trace 25462306a36Sopenharmony_ci | 25562306a36Sopenharmony_ci |----> may exit through _060_real_trap 25662306a36Sopenharmony_ci | 25762306a36Sopenharmony_ci |----> may exit through _060_real_bsun 25862306a36Sopenharmony_ci | 25962306a36Sopenharmony_ci |----> may exit through _060_fpsp_done 26062306a36Sopenharmony_ci 26162306a36Sopenharmony_ci 26262306a36Sopenharmony_ci_060_fpsp_unsupp: 26362306a36Sopenharmony_ci------------------ 26462306a36Sopenharmony_ci- documented in 3.1 of 060SP spec. 26562306a36Sopenharmony_ci- Basic flow: 26662306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_unsupp --| 26762306a36Sopenharmony_ci | 26862306a36Sopenharmony_ci | 26962306a36Sopenharmony_ci may exit through _060_real_snan <----| 27062306a36Sopenharmony_ci or | 27162306a36Sopenharmony_ci may exit through _060_real_operr <----| 27262306a36Sopenharmony_ci or | 27362306a36Sopenharmony_ci may exit through _060_real_ovfl <----| 27462306a36Sopenharmony_ci or | 27562306a36Sopenharmony_ci may exit through _060_real_unfl <----| 27662306a36Sopenharmony_ci or | 27762306a36Sopenharmony_ci may exit through _060_real_inex <----| 27862306a36Sopenharmony_ci or | 27962306a36Sopenharmony_ci may exit through _060_real_trace <----| 28062306a36Sopenharmony_ci or | 28162306a36Sopenharmony_ci may exit through _060_fpsp_done <----| 28262306a36Sopenharmony_ci 28362306a36Sopenharmony_ci 28462306a36Sopenharmony_ci_060_fpsp_effadd: 28562306a36Sopenharmony_ci------------------ 28662306a36Sopenharmony_ci- documented in 3.3 of 060 spec. 28762306a36Sopenharmony_ci- Basic flow: 28862306a36Sopenharmony_ci exception taken ---> enter _060_fpsp_effadd --| 28962306a36Sopenharmony_ci | 29062306a36Sopenharmony_ci | 29162306a36Sopenharmony_ci may exit through _060_real_trace <----| 29262306a36Sopenharmony_ci or | 29362306a36Sopenharmony_ci may exit through _060_real_fpu_disabled <----| 29462306a36Sopenharmony_ci or | 29562306a36Sopenharmony_ci may exit through _060_fpsp_done <----| 296