M68060 User's Manual - Freescale Semiconductor
M68060 User's Manual - Freescale Semiconductor
M68060 User's Manual - Freescale Semiconductor
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Motorola reserves the right to make changes without further notice to any products herein. Motorola makes no warranty, representation or guarantee regarding<br />
the suitability of its products for any particular purpose, nor does Motorola assume any liability arising out of the application or use of any product or circuit, and<br />
specifically disclaims any and all liability, including without limitation consequential or incidental damages. "Typical" parameters can and do vary in different<br />
applications. All operating parameters, including "Typicals" must be validated for each customer application by customer's technical experts. Motorola does not<br />
convey any license under its patent rights nor the rights of others. Motorola products are not designed, intended, or authorized for use as components in systems<br />
intended for surgical implant into the body, or other applications intended to support or sustain life, or for any other application in which the failure of the Motorola<br />
product could create a situation where personal injury or death may occur. Should Buyer purchase or use Motorola products for any such unintended or<br />
unauthorized application, Buyer shall indemnify and hold Motorola and its officers, employees, subsidiaries, affiliates, and distributors harmless against all claims,<br />
costs, damages, and expenses, and reasonable attorney fees arising out of, directly or indirectly, any claim of personal injury or death associated with such<br />
unintended or unauthorized use, even if such claim alleges that Motorola was negligent regarding the design or manufacture of the part. Motorola and µ are<br />
registered trademarks of Motorola, Inc. Motorola, Inc. is an Equal Opportunity/Affirmative Action Employer.<br />
© MOTOROLA, 1994<br />
<strong>M68060</strong> User’s <strong>Manual</strong><br />
Including the<br />
MC68060,<br />
MC68LC060,<br />
and<br />
MC68EC060
MOTOROLA<br />
68K FAX-IT<br />
Documentation Comments<br />
FAX 512-891-8593—Documentation Comments Only<br />
The Motorola High-End Technical Publications Department provides a fax number for you<br />
to submit any questions or comments about this document or how to order other documents.<br />
We welcome your suggestions for improving our documentation. Please do not fax technical<br />
questions.<br />
Please provide the part number and revision number (located in upper right-hand corner of<br />
the cover) and the title of the document. When referring to items in the manual, please reference<br />
by the page number, paragraph number, figure number, table number, and line number<br />
if needed.<br />
When sending a fax, please provide your name, company, fax number, and phone number<br />
including area code.<br />
Applications and Technical Information<br />
For questions or comments pertaining to technical information, questions, and applications,<br />
please contact one of the following sales offices nearest you.<br />
<strong>M68060</strong> USER’S MANUAL<br />
iii
iv<br />
— Sales Offices —<br />
Field Applications Engineering Available Through All Sales Offices<br />
UNITED STATES<br />
ALABAMA,<br />
Huntsville<br />
ARIZONA,<br />
Tempe<br />
CALIFORNIA,<br />
Agoura Hills<br />
CALIFORNIA,<br />
Los Angeles<br />
CALIFORNIA,<br />
Irvine<br />
CALIFORNIA,<br />
Rosevllle<br />
CALIFORNIA,<br />
San Diego<br />
CALIFORNIA,<br />
Sunnyvale<br />
COLORADO,<br />
Colorado Springs<br />
COLORADO,<br />
Denver<br />
CONNECTICUT,<br />
Wallingford<br />
FLORIDA,<br />
Maitland<br />
FLORIDA,<br />
Pompano Beach/<br />
Fort Lauderdale<br />
FLORIDA,<br />
Clearwater<br />
GEORGlA,<br />
Atlanta<br />
IDAHO,<br />
Boise<br />
ILLINOIS,<br />
Chicago/Hoffman Estates<br />
INDlANA,<br />
Fort Wayne<br />
INDIANA,<br />
Indianapolis<br />
INDIANA,<br />
Kokomo<br />
IOWA,<br />
Cedar Rapids<br />
KANSAS,<br />
Kansas City/Mission<br />
MARYLAND,<br />
Columbia<br />
MASSACHUSETTS,<br />
Marborough<br />
MASSACHUSETTS,<br />
Woburn<br />
MICHIGAN,<br />
Detroit<br />
MINNESOTA,<br />
Minnetonka<br />
MISSOURI,<br />
St. Louis<br />
NEW JERSEY,<br />
Fairfield<br />
NEW YORK,<br />
Fairport<br />
NEW YORK,<br />
Hauppauge<br />
NEW YORK,<br />
Poughkeepsie/Fishkill<br />
NORTH CAROLINA,<br />
Raleigh<br />
OHIO,<br />
Cleveland<br />
OHIO,<br />
Columbus/Worthington<br />
OHIO,<br />
Dayton<br />
OKLAHOMA,<br />
Tulsa<br />
OREGON,<br />
Portland<br />
PENNSYLVANIA,<br />
Colmar<br />
Philadelphia/Horsham<br />
TENNESSEE,<br />
Knoxville<br />
TEXAS,<br />
Austin<br />
TEXAS,<br />
Houston<br />
TEXAS,<br />
Plano<br />
VIRGINIA,<br />
Richmond<br />
WASHINGTON,<br />
Bellevue<br />
Seattle Access<br />
WISCONSIN,<br />
Milwaukee/Brookfield<br />
CANADA<br />
(205) 464-6800<br />
(602) 897-5056<br />
(818) 706-1929<br />
(310) 417-8848<br />
(714) 753-7360<br />
(916) 922-7152<br />
(619) 541-2163<br />
(408) 749-0510<br />
(719) 599-7497<br />
(303) 337-3434<br />
(203) 949-4100<br />
(407) 628-2636<br />
(305) 486-9776<br />
(813) 538-7750<br />
(404) 729-7100<br />
(208) 323-9413<br />
(708) 490-9500<br />
(219) 436-5818<br />
(317) 571-0400<br />
(317) 457-6634<br />
(319) 373-1328<br />
(913) 451-8555<br />
(410) 381-1570<br />
(508) 481-8100<br />
(617) 932-9700<br />
(313) 347-6800<br />
(612) 932-1500<br />
(314) 275-7380<br />
(201) 808-2400<br />
(716) 425-4000<br />
(516) 361-7000<br />
(914) 473-8102<br />
(919) 870-4355<br />
(216) 349-3100<br />
(614) 431-8492<br />
(513) 495-6800<br />
(800) 544-9496<br />
(503) 641-3681<br />
(215) 997-1020<br />
(215) 957-4100<br />
(615) 690-5593<br />
(512) 873-2000<br />
(800) 343-2692<br />
(214) 516-5100<br />
(804) 285-2100<br />
(206) 454-4160<br />
(206) 622-9960<br />
(414) 792-0122<br />
BRITISH COLUMBIA,<br />
Vancouver (604) 293-7605<br />
ONTARIO,<br />
Toronto (416) 497-8181<br />
ONTARIO,<br />
Ottawa (613) 226-3491<br />
QUEBEC,<br />
Montreal<br />
INTERNATIONAL<br />
(514) 731-6881<br />
AUSTRALIA,<br />
Melbourne (61-3)887-0711<br />
AUSTRALIA,<br />
Sydney<br />
BRAZIL,<br />
Sao Paulo<br />
(61(2)906-3855<br />
55(11)815-4200<br />
CHINA,<br />
Beijing 86 505-2180<br />
FINLAND,<br />
Helsinki 358-0-35161191<br />
Car Phone 358(49)211501<br />
FRANCE,<br />
Paris/Vanves 33(1)40 955 900<br />
<strong>M68060</strong> USER’S MANUAL<br />
GERMANY,<br />
Langenhagen/ Hanover 49(511)789911<br />
GERMANY,<br />
Munich 49 89 92103-0<br />
GERMANY,<br />
Nuremberg 49 911 64-3044<br />
GERMANY,<br />
Sindelfingen 49 7031 69 910<br />
GERMANY,<br />
Wiesbaden 49 611 761921<br />
HONG KONG,<br />
Kwai Fong 852-4808333<br />
Tai Po 852-6668333<br />
INDIA,<br />
Bangalore (91-812)627094<br />
ISRAEL,<br />
Tel Aviv 972(3)753-8222<br />
ITALY,<br />
Milan 39(2)82201<br />
JAPAN,<br />
Aizu 81(241)272231<br />
JAPAN,<br />
Atsugi 81(0462)23-0761<br />
JAPAN,<br />
Kumagaya 81(0485)26-2600<br />
JAPAN,<br />
Kyushu 81(092)771-4212<br />
JAPAN,<br />
Mito 81(0292)26-2340<br />
JAPAN,<br />
Nagoya 81(052)232-1621<br />
JAPAN,<br />
Osaka 81(06)305-1801<br />
JAPAN, Sendai 81(22)268-4333<br />
JAPAN, Tachikawa 81(0425)23-6700<br />
JAPAN, Tokyo 81(03)3440-3311<br />
JAPAN,<br />
Yokohama 81(045)472-2751<br />
KOREA,<br />
Pusan 82(51)4635-035<br />
KOREA,<br />
Seoul<br />
MALAYSIA,<br />
Penang<br />
82(2)554-5188<br />
60(4)374514<br />
MEXICO,<br />
Mexico City 52(5)282-2864<br />
MEXICO,<br />
Guadalajara 52(36)21-8977<br />
Marketing 52(36)21-9023<br />
Customer Service 52(36)669-9160<br />
NETHERLANDS,<br />
Best (31)49988 612 11<br />
PUERTO RICO,<br />
San Juan (809)793-2170<br />
SINGAPORE<br />
(65)2945438<br />
SPAIN,<br />
Madrid 34(1)457-8204<br />
or 34(1)457-8254<br />
SWEDEN,<br />
Solna 46(8)734-8800<br />
SWITZERLAND,<br />
Geneva 41(22)7991111<br />
SWITZERLAND,<br />
Zurich 41(1)730 4074<br />
TAlWAN,<br />
Taipei 886(2)717-7089<br />
THAILAND,<br />
Bangkok (66-2)254-4910<br />
UNITED KINGDOM,<br />
Aylesbury 44(296)395-252<br />
FULL LINE REPRESENTATIVES<br />
COLORADO,<br />
Grand Junction<br />
Cheryl Lee Whltely (303) 243-9658<br />
KANSAS,<br />
Wichita<br />
Melinda Shores/Kelly Greiving (316) 838 0190<br />
NEVADA,<br />
Reno<br />
Galena Technology Group (702) 746 0642<br />
NEW MEXICO,<br />
Albuquerque<br />
S&S Technologies, lnc. (505) 298-7177<br />
UTAH,<br />
Salt Lake City<br />
Utah Component Sales, Inc. (801) 561-5099<br />
WASHINGTON,<br />
Spokane<br />
Doug Kenley (509) 924-2322<br />
ARGENTINA,<br />
Buenos Aires<br />
Argonics, S.A. (541) 343-1787<br />
HYBRID COMPONENTS RESELLERS<br />
Elmo <strong>Semiconductor</strong> (818) 768-7400<br />
Minco Technology Labs Inc. (512) 834-2022<br />
Semi Dice Inc. (310) 594-4631<br />
MOTOROLA
MOTOROLA<br />
PREFACE<br />
The complete documentation package for the MC68060, MC68LC060, and MC68EC060<br />
(collectively called <strong>M68060</strong>) consists of the <strong>M68060</strong>UM/AD, <strong>M68060</strong> User’s <strong>Manual</strong>, and<br />
the M68000PM/AD, M68000 Family Programmer’s Reference <strong>Manual</strong>. The <strong>M68060</strong> User’s<br />
<strong>Manual</strong> describes the capabilities, operation, and programming of the <strong>M68060</strong> superscalar<br />
32-bit microprocessors. The M68000 Family Programmer’s Reference <strong>Manual</strong> contains the<br />
complete instruction set for the M68000 family.<br />
The introduction of this manual includes general information concerning the MC68060 and<br />
summarizes the differences among the <strong>M68060</strong> family devices. Additionally, appendices<br />
provide detailed information on how these <strong>M68060</strong> derivatives operate differently from the<br />
MC68060.<br />
When reading this manual, disregard information concerning the floating-point unit in reference<br />
to the MC68LC060, and disregard information concerning the floating-point unit and<br />
memory management unit in reference to the MC68EC060.<br />
The organization of this manual is as follows:<br />
Section 1 Introduction<br />
Section 2 Signal Description<br />
Section 3 Integer Unit<br />
Section 4 Memory Management Unit<br />
Section 5 Caches<br />
Section 6 Floating-Point Unit<br />
Section 7 Bus Operation<br />
Section 8 Exception Processing<br />
Section 9 IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Section 10 Instruction Timings<br />
Section 11 Applications<br />
Section 12 Electrical and Thermal Characteristics<br />
Section 13 Ordering Information and Mechanical Data<br />
Appendix A MC68LC060<br />
Appendix B MC68EC060<br />
Appendix C MC68060 Software Package<br />
Appendix D <strong>M68060</strong> Instructions<br />
<strong>M68060</strong> USER’S MANUAL<br />
v
AGU—address generation unit<br />
ALU—arithmetic logic unit<br />
ATC—address translation cache<br />
BUSCR—bus control register<br />
CACR—cache control register<br />
CCR—condition code register<br />
CM—cache mode<br />
CPU—central processing unit<br />
DFC—destination function code<br />
DTTx—data transparent translation register<br />
DRAM—dynamic random access memory<br />
MOTOROLA<br />
MC68060 ACRONYM LIST<br />
FPIAR—floating-point instruction address register<br />
FPCR—floating-point control register<br />
FPSP—floating-point software package<br />
FPSR—floating-point status register<br />
FPU—floating-point unit<br />
FP7–FP0—floating-point data registers 7–0<br />
FSLW—fault status long word<br />
IEE—integer execute unit<br />
IFP—instruction fetch pipeline<br />
IFU—instruction fetch unit<br />
IPU—instruction pipe unit<br />
ISP—interrupt stack pointer<br />
ITTR—instruction transparent translation register<br />
IU—integer unit<br />
JTAG—Joint Test Action Group<br />
MMU—memory management unit<br />
<strong>M68060</strong> USER’S MANUAL<br />
vii
MC68060 Acronym List<br />
MMUSR—memory management unit status register<br />
<strong>M68060</strong>SP—<strong>M68060</strong> software package<br />
NANs—not-a-numbers<br />
NOP—no operation<br />
OEP—operand execution pipeline<br />
OPU—operand pipe unit<br />
PC—program counter<br />
PCR—processor configuration register<br />
PGI—page index field<br />
PI—pointer index field<br />
PLL—phase-locked loop<br />
pOEP—primary operand execution pipeline<br />
RI—root index field<br />
SFC—source function code<br />
SNAN—signaling not-a-number<br />
sOEP—secondary operand execution pipeline<br />
SP—stack pointer<br />
SR—status register<br />
SRP—supervisor root pointer register<br />
SSP—supervisor stack pointer<br />
TAP—test access port<br />
TCR—translation control register<br />
TTL—transistor-transistor logic<br />
TTR—transparent translation register<br />
UPA—user page attribute<br />
URP—user root pointer register<br />
USP—user stack pointer<br />
VBR—vector base register<br />
VLSI—very large-scale integration<br />
viii<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
TABLE OF CONTENTS<br />
Section 1<br />
Introduction<br />
1.1 Differences Among <strong>M68060</strong> Family Members.............................................. 1-3<br />
1.1.1 MC68LC060................................................................................................ 1-3<br />
1.1.2 MC68EC060 ............................................................................................... 1-3<br />
1.1.2.1 Address Translation Differences .............................................................. 1-3<br />
1.1.2.2 Instruction Differences.............................................................................. 1-3<br />
1.2 Features........................................................................................................ 1-4<br />
1.3 Architecture................................................................................................... 1-4<br />
1.4 Processor Overview...................................................................................... 1-5<br />
1.4.1 Functional Blocks........................................................................................ 1-5<br />
1.4.2 Integer Unit ................................................................................................. 1-7<br />
1.4.2.1 Instruction Fetch Unit................................................................................ 1-7<br />
1.4.2.2 Integer Unit ............................................................................................... 1-8<br />
1.4.2.3 Floating-Point Unit .................................................................................... 1-8<br />
1.4.2.4 Memory Units ........................................................................................... 1-9<br />
1.4.2.5 Address Translation Caches .................................................................... 1-9<br />
1.4.2.6 Instruction and Data Caches .................................................................... 1-9<br />
1.4.2.6.1 Cache Organization.............................................................................. 1-10<br />
1.4.2.6.2 Cache Coherency................................................................................. 1-10<br />
1.4.3 Bus Controller ........................................................................................... 1-10<br />
1.5 Processing States ....................................................................................... 1-10<br />
1.6 Programming Model.................................................................................... 1-11<br />
1.7 Data Format Summary................................................................................ 1-14<br />
1.8 Addressing Capabilities Summary .............................................................. 1-14<br />
1.9 Instruction Set Overview ............................................................................. 1-15<br />
1.10 Notational Conventions............................................................................... 1-21<br />
2.1<br />
Section 2<br />
Signal Description<br />
Address and Control Signals ........................................................................ 2-3<br />
2.1.1 Address Bus (A31–A0) ............................................................................... 2-3<br />
2.1.2 Cycle Long-Word Address (CLA) ............................................................... 2-4<br />
2.2 Data Bus (D31–D0)....................................................................................... 2-4<br />
2.3 Transfer Attribute Signals ............................................................................. 2-4<br />
2.3.1 Transfer Cycle Type (TT1, TT0) ................................................................. 2-4<br />
2.3.2 Transfer Cycle Modifier (TM2–TM0)........................................................... 2-4<br />
2.3.3 Transfer Line Number (TLN1, TLN0).......................................................... 2-5<br />
2.3.4 User-Programmable Page Attributes (UPA1, UPA0).................................. 2-5<br />
2.3.5 Read/Write (R/W) ....................................................................................... 2-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
ix
Table of Contents<br />
2.3.6 Transfer Size (SIZ1, SIZ0).......................................................................... 2-6<br />
2.3.7 Bus Lock (LOCK)........................................................................................ 2-6<br />
2.3.8 Bus Lock End (LOCKE).............................................................................. 2-6<br />
2.3.9 Cache Inhibit Out (CIOUT) ......................................................................... 2-7<br />
2.3.10 Byte Select Lines (BS3–BS0)..................................................................... 2-7<br />
2.4 Master Transfer Control Signals ................................................................... 2-7<br />
2.4.1 Transfer Start (TS)...................................................................................... 2-8<br />
2.4.2 Transfer in Progress (TIP) .......................................................................... 2-8<br />
2.4.3 Starting Termination Acknowledge Signal Sampling (SAS) ....................... 2-8<br />
2.5 Slave Transfer Control Signals ..................................................................... 2-8<br />
2.5.1 Transfer Acknowledge (TA)........................................................................ 2-8<br />
2.5.2 Transfer Retry Acknowledge (TRA)............................................................ 2-8<br />
2.5.3 Transfer Error Acknowledge (TEA) ............................................................ 2-9<br />
2.5.4 Transfer Burst Inhibit (TBI) ......................................................................... 2-9<br />
2.5.5 Transfer Cache Inhibit (TCI) ....................................................................... 2-9<br />
2.6 Snoop Control (SNOOP) .............................................................................. 2-9<br />
2.7 Arbitration Signals....................................................................................... 2-10<br />
2.7.1 Bus Request (BR)..................................................................................... 2-10<br />
2.7.2 Bus Grant (BG)......................................................................................... 2-10<br />
2.7.3 Bus Grant Relinquish Control (BGR)........................................................ 2-10<br />
2.7.4 Bus Tenure Termination (BTT)................................................................. 2-10<br />
2.7.5 Bus Busy (BB) .......................................................................................... 2-11<br />
2.8 Processor Control Signals .......................................................................... 2-11<br />
2.8.1 Cache Disable (CDIS) .............................................................................. 2-11<br />
2.8.2 MMU Disable (MDIS)................................................................................ 2-12<br />
2.8.3 Reset In (RSTI)......................................................................................... 2-12<br />
2.8.4 Reset Out (RSTO) .................................................................................... 2-12<br />
2.9 Interrupt Control Signals ............................................................................. 2-12<br />
2.9.1 Interrupt Priority Level (IPL2–IPL0) .......................................................... 2-12<br />
2.9.2 Interrupt Pending Status (IPEND) ............................................................ 2-12<br />
2.9.3 Autovector (AVEC) ................................................................................... 2-13<br />
2.10 Status and Clock Signals............................................................................ 2-13<br />
2.10.1 Processor Status (PST4–PST0)............................................................... 2-13<br />
2.10.2 MC68060 Processor Clock (CLK) ............................................................ 2-14<br />
2.10.3 Clock Enable (CLKEN) ............................................................................. 2-14<br />
2.11 Test Signals ................................................................................................ 2-15<br />
2.11.1 JTAG Enable (JTAG)................................................................................ 2-15<br />
2.11.2 Test Clock (TCK) ...................................................................................... 2-15<br />
2.11.3 Test Mode Select (TMS)........................................................................... 2-15<br />
2.11.4 Test Data In (TDI)..................................................................................... 2-16<br />
2.11.5 Test Data Out (TDO) ................................................................................ 2-16<br />
2.11.6 Test Reset (TRST) ................................................................................... 2-16<br />
2.12 Thermal Sensing Pins (THERM1, THERM0).............................................. 2-16<br />
2.13 Power Supply Connections......................................................................... 2-16<br />
2.14 Signal Summary ......................................................................................... 2-16<br />
x<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
Section 3<br />
Integer Unit<br />
<strong>M68060</strong> USER’S MANUAL<br />
Table of Contents<br />
3.1 Integer Unit Execution Pipelines ................................................................... 3-1<br />
3.2 Integer Unit Register Description .................................................................. 3-2<br />
3.2.1 Integer Unit User Programming Model ....................................................... 3-2<br />
3.2.1.1 Data Registers (D7–D0) ........................................................................... 3-2<br />
3.2.1.2 Address Registers (A6–A0) ...................................................................... 3-2<br />
3.2.1.3 User Stack Pointer (A7)............................................................................ 3-2<br />
3.2.1.4 Program Counter ...................................................................................... 3-3<br />
3.2.1.5 Condition Code Register .......................................................................... 3-3<br />
3.2.2 Integer Unit Supervisor Programming Model.............................................. 3-3<br />
3.2.2.1 Supervisor Stack Pointer .......................................................................... 3-4<br />
3.2.2.2 Status Register ......................................................................................... 3-4<br />
3.2.2.3 Vector Base Register................................................................................ 3-4<br />
3.2.2.4 Alternate Function Code Registers........................................................... 3-5<br />
3.2.2.5 Processor Configuration Register............................................................. 3-5<br />
4.1<br />
Section 4<br />
Memory Management Unit<br />
Memory Management Programming Model.................................................. 4-3<br />
4.1.1 User and Supervisor Root Pointer Registers.............................................. 4-3<br />
4.1.2 Translation Control Register ....................................................................... 4-4<br />
4.1.3 Transparent Translation Registers ............................................................. 4-6<br />
4.2 Logical Address Translation.......................................................................... 4-7<br />
4.2.1 Translation Tables ...................................................................................... 4-7<br />
4.2.2 Descriptors................................................................................................ 4-12<br />
4.2.2.1 Table Descriptors.................................................................................... 4-12<br />
4.2.2.2 Page Descriptors .................................................................................... 4-12<br />
4.2.2.3 Descriptor Field Definitions..................................................................... 4-13<br />
4.2.3 Translation Table Example ....................................................................... 4-15<br />
4.2.4 Variations in Translation Table Structure.................................................. 4-16<br />
4.2.4.1 Indirect Action......................................................................................... 4-16<br />
4.2.4.2 Table Sharing Between Tasks................................................................ 4-17<br />
4.2.4.3 Table Paging .......................................................................................... 4-17<br />
4.2.4.4 Dynamically Allocated Tables................................................................. 4-17<br />
4.2.5 Table Search Accesses ............................................................................ 4-19<br />
4.2.6 Address Translation Protection................................................................. 4-20<br />
4.2.6.1 Supervisor and User Translation Tables ................................................ 4-21<br />
4.2.6.2 Supervisor Only ...................................................................................... 4-22<br />
4.2.6.3 Write Protect........................................................................................... 4-22<br />
4.3 Address Translation Caches....................................................................... 4-24<br />
4.4 Transparent Translation.............................................................................. 4-27<br />
4.5 Address Translation Summary.................................................................... 4-28<br />
4.6 RSTI and MDIS Effect on the MMU ............................................................ 4-28<br />
4.6.1 Effect of RSTI on the MMUs ..................................................................... 4-28<br />
xi
Table of Contents<br />
4.6.2 Effect of MDIS on Address Translation .................................................... 4-30<br />
4.7 MMU Instructions........................................................................................ 4-30<br />
4.7.1 MOVEC .................................................................................................... 4-30<br />
4.7.2 PFLUSH ................................................................................................... 4-30<br />
4.7.3 PLPA ........................................................................................................ 4-30<br />
xii<br />
Section 5<br />
Caches<br />
5.1 Cache Operation........................................................................................... 5-1<br />
5.2 Cache Control Register ................................................................................ 5-5<br />
5.3 Cache Management ..................................................................................... 5-6<br />
5.4 Caching Modes............................................................................................. 5-7<br />
5.4.1 Cachable Accesses .................................................................................... 5-7<br />
5.4.1.1 Writethrough Mode................................................................................... 5-7<br />
5.4.1.2 Copyback Mode ....................................................................................... 5-8<br />
5.4.2 Cache-Inhibited Accesses .......................................................................... 5-8<br />
5.4.3 Special Accesses ....................................................................................... 5-9<br />
5.5 Cache Protocol ............................................................................................. 5-9<br />
5.5.1 Read Miss................................................................................................... 5-9<br />
5.5.2 Write Miss................................................................................................... 5-9<br />
5.5.3 Read Hit...................................................................................................... 5-9<br />
5.5.4 Write Hit.................................................................................................... 5-10<br />
5.6 Cache Coherency ....................................................................................... 5-10<br />
5.7 Memory Accesses for Cache Maintenance ................................................ 5-11<br />
5.7.1 Cache Filling............................................................................................. 5-11<br />
5.7.2 Cache Pushes .......................................................................................... 5-13<br />
5.8 Push Buffer ................................................................................................. 5-13<br />
5.9 Store Buffer................................................................................................. 5-13<br />
5.10 Push Buffer and Store Buffer Bus Operation.............................................. 5-14<br />
5.11 Branch Cache ............................................................................................. 5-14<br />
5.12 Cache Operation Summary ........................................................................ 5-15<br />
5.12.1 Instruction Cache...................................................................................... 5-15<br />
5.12.2 Data Cache............................................................................................... 5-16<br />
6.1<br />
Section 6<br />
Floating-Point Unit<br />
Floating-Point User Programming Model...................................................... 6-2<br />
6.1.1 Floating-Point Data Registers (FP7–FP0) .................................................. 6-3<br />
6.1.2 Floating-Point Control Register (FPCR) ..................................................... 6-3<br />
6.1.2.1 Exception Enable Byte ............................................................................. 6-3<br />
6.1.2.2 Mode Control Byte.................................................................................... 6-3<br />
6.1.3 Floating-Point Status Register (FPSR)....................................................... 6-4<br />
6.1.3.1 Floating-Point Condition Code Byte ......................................................... 6-5<br />
6.1.3.2 Quotient Byte............................................................................................ 6-5<br />
6.1.3.3 Exception Status Byte .............................................................................. 6-5<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Table of Contents<br />
6.1.3.4 Accrued Exception Byte ........................................................................... 6-6<br />
6.1.4 Floating-Point Instruction Address Register (FPIAR) ................................. 6-7<br />
6.2 Floating-Point Data Formats and Data Types............................................... 6-7<br />
6.3 Computational Accuracy ............................................................................. 6-11<br />
6.3.1 Intermediate Result................................................................................... 6-12<br />
6.3.2 Rounding the Result ................................................................................. 6-13<br />
6.4 Postprocessing Operation........................................................................... 6-15<br />
6.4.1 Underflow, Round, and Overflow.............................................................. 6-15<br />
6.4.2 Conditional Testing ................................................................................... 6-16<br />
6.5 Floating-Point Exceptions ........................................................................... 6-19<br />
6.5.1 Unimplemented Floating-Point Instructions .............................................. 6-19<br />
6.5.2 Unsupported Floating-Point Data Types................................................... 6-21<br />
6.5.3 Unimplemented Effective Address Exception........................................... 6-22<br />
6.6 Floating-Point Arithmetic Exceptions .......................................................... 6-22<br />
6.6.1 Branch/Set on Unordered (BSUN)............................................................ 6-24<br />
6.6.1.1 Trap Disabled Results (FPCR BSUN Bit Cleared) ................................. 6-24<br />
6.6.1.2 Trap Enabled Results (FPCR BSUN Bit Set) ......................................... 6-24<br />
6.6.2 Signaling Not-a-Number (SNAN).............................................................. 6-25<br />
6.6.2.1 Trap Disabled Results (FPCR SNAN Bit Cleared) ................................. 6-25<br />
6.6.2.2 Trap Enabled Results (FPCR SNAN Bit Set) ......................................... 6-26<br />
6.6.3 Operand Error........................................................................................... 6-26<br />
6.6.3.1 Trap Disabled Results (FPCR OPERR Bit Cleared)............................... 6-27<br />
6.6.3.2 Trap Enabled Results (FPCR OPERR Bit Set)....................................... 6-27<br />
6.6.4 Overflow.................................................................................................... 6-28<br />
6.6.4.1 Trap Disabled Results (FPCR OVFL Bit Cleared).................................. 6-29<br />
6.6.4.2 Trap Enabled Results (FPCR OVFL Bit Set).......................................... 6-29<br />
6.6.5 Underflow.................................................................................................. 6-30<br />
6.6.5.1 Trap Disabled Results (FPCR UNFL Bit Cleared).................................. 6-31<br />
6.6.5.2 Trap Enabled Results (FPCR UNFL Bit Set).......................................... 6-31<br />
6.6.6 Divide-by-Zero .......................................................................................... 6-32<br />
6.6.6.1 Trap Disabled Results (FPCR DZ Bit Cleared)....................................... 6-33<br />
6.6.6.2 Trap Enabled Results (FPCR DZ Bit Set)............................................... 6-33<br />
6.6.7 Inexact Result ........................................................................................... 6-33<br />
6.6.7.1 Trap Disabled Results (FPCR INEX1 Bit and INEX2 Bit Cleared........... 6-34<br />
6.6.7.2 Trap Enabled Results (Either FPCR INEX1 Bit or INEX2 Bit Set).......... 6-34<br />
6.7 Floating-Point State Frames ....................................................................... 6-35<br />
7.1<br />
Section 7<br />
Bus Operation<br />
Bus Characteristics ....................................................................................... 7-1<br />
7.2 Full-, Half-, and Quarter-Speed Bus Operation and BCLK ........................... 7-3<br />
7.3 Acknowledge Termination Ignore State Capability ....................................... 7-4<br />
7.4 Bus Control Register..................................................................................... 7-4<br />
7.5 Data Transfer Mechanism............................................................................. 7-5<br />
7.6 Misaligned Operands .................................................................................... 7-9<br />
xiii
Table of Contents<br />
7.7 Processor Data Transfers........................................................................... 7-12<br />
7.7.1 Byte, Word, and Long-Word Read Transfer Cycles ................................. 7-12<br />
7.7.2 Line Read Transfer................................................................................... 7-15<br />
7.7.3 Byte, Word, and Long-Word Write Cycles................................................ 7-20<br />
7.7.4 Line Write Cycles..................................................................................... 7-25<br />
7.7.5 Locked Read-Modify-Write Cycles .......................................................... 7-28<br />
7.7.6 Emulating CAS2 and CAS Misaligned...................................................... 7-31<br />
7.7.7 Using CLA to Increment A3 and A2.......................................................... 7-32<br />
7.8 Acknowledge Cycles................................................................................... 7-32<br />
7.8.1 Interrupt Acknowledge Cycles ................................................................. 7-32<br />
7.8.1.1 Interrupt Acknowledge Cycle (Terminated Normally)............................. 7-35<br />
7.8.1.2 Autovector Interrupt Acknowledge Cycle ............................................... 7-35<br />
7.8.1.3 Spurious Interrupt Acknowledge Cycle .................................................. 7-35<br />
7.8.2 Breakpoint Acknowledge Cycle ................................................................ 7-36<br />
7.8.2.1 LPSTOP Broadcast Cycle ...................................................................... 7-38<br />
7.9 Bus Exception Control Cycles .................................................................... 7-46<br />
7.9.1 Bus Errors................................................................................................. 7-46<br />
7.9.2 Retry Operation ........................................................................................ 7-48<br />
7.9.3 Double Bus Fault ...................................................................................... 7-51<br />
7.10 Bus Synchronization ................................................................................... 7-52<br />
7.11 Bus Arbitration ............................................................................................ 7-52<br />
7.11.1 MC68040-Arbitration Protocol (BB Protocol)............................................ 7-53<br />
7.11.2 MC68060-Arbitration Protocol (BTT Protocol).......................................... 7-58<br />
7.11.3 External Arbiter Considerations................................................................ 7-65<br />
7.12 Bus Snooping Operation............................................................................ 7-68<br />
7.13 Reset Operation......................................................................................... 7-71<br />
7.14 Special Modes of Operation ....................................................................... 7-74<br />
7.14.1 Acknowledge Termination Ignore State Capability................................... 7-74<br />
7.14.2 Acknowledge Termination Protocol .......................................................... 7-76<br />
7.14.3 Extra Data Write Hold Time Mode............................................................ 7-76<br />
8.1<br />
Section 8<br />
Exception Processing<br />
Exception Processing Overview ................................................................... 8-1<br />
8.2 Integer Unit Exceptions................................................................................. 8-4<br />
8.2.1 Access Error Exception .............................................................................. 8-5<br />
8.2.2 Address Error Exception............................................................................. 8-7<br />
8.2.3 Instruction Trap Exception.......................................................................... 8-7<br />
8.2.4 Illegal Instruction and Unimplemented Instruction Exceptions ................... 8-8<br />
8.2.5 Privilege Violation Exception .................................................................... 8-10<br />
8.2.6 Trace Exception........................................................................................ 8-10<br />
8.2.7 Format Error Exception ............................................................................ 8-11<br />
8.2.8 Breakpoint Instruction Exception .............................................................. 8-11<br />
8.2.9 Interrupt Exception ................................................................................... 8-12<br />
8.2.10 Reset Exception ....................................................................................... 8-14<br />
xiv<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Table of Contents<br />
8.3 Exception Priorities ..................................................................................... 8-17<br />
8.4 Return from Exceptions .............................................................................. 8-19<br />
8.4.1 Four-Word Stack Frame (Format $0) ....................................................... 8-19<br />
8.4.2 Six-Word Stack Frame (Format $2).......................................................... 8-20<br />
8.4.3 Floating-Point Post-Instruction Stack Frame (Format $3) ........................ 8-20<br />
8.4.4 Eight-Word Stack Frame (Format $4)....................................................... 8-21<br />
8.4.4.1 Program Counter (PC)............................................................................ 8-21<br />
8.4.4.2 Fault Address ......................................................................................... 8-22<br />
8.4.4.3 Fault Status Long Word (FSLW)............................................................. 8-22<br />
8.4.5 Recovering from an Access Error............................................................. 8-25<br />
8.4.6 Bus Errors and Pending Memory Writes ................................................. 8-27<br />
8.4.7 Branch Prediction Error ............................................................................ 8-29<br />
Section 9<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9.1 IEEE 1149.1 Test Access Port (Normal JTAG) Mode .................................. 9-1<br />
9.1.1 Overview..................................................................................................... 9-2<br />
9.1.2 JTAG Instruction Shift Register .................................................................. 9-3<br />
9.1.2.1 EXTEST.................................................................................................... 9-4<br />
9.1.2.2 LPSAMPLE............................................................................................... 9-5<br />
9.1.2.3 Private Instructions ................................................................................... 9-5<br />
9.1.2.4 SAMPLE/PRELOAD................................................................................. 9-5<br />
9.1.2.5 IDCODE.................................................................................................... 9-5<br />
9.1.2.6 CLAMP ..................................................................................................... 9-6<br />
9.1.2.7 HIGHZ....................................................................................................... 9-6<br />
9.1.2.8 BYPASS ................................................................................................... 9-6<br />
9.1.3 JTAG Test Data Registers.......................................................................... 9-7<br />
9.1.3.1 Idcode Register ........................................................................................ 9-7<br />
9.1.3.2 Boundary Scan Register........................................................................... 9-7<br />
9.1.3.3 Bypass Register ..................................................................................... 9-15<br />
9.1.4 Restrictions ............................................................................................... 9-15<br />
9.1.5 Disabling the IEEE 1149.1 Standard Operation ....................................... 9-15<br />
9.1.6 Motorola MC68060 BSDL Description...................................................... 9-17<br />
9.2 Debug Pipe Control Mode........................................................................... 9-24<br />
9.2.1 Debug Command Interface....................................................................... 9-25<br />
9.2.2 Debug Pipe Control Mode Commands ..................................................... 9-27<br />
9.2.3 Emulator Mode ......................................................................................... 9-31<br />
9.3 Switching between JTAG and Debug Pipe ControlModes of Operation..... 9-33<br />
Section 10<br />
Instruction Execution Timing<br />
10.1 Superscalar Operand Execution Pipelines ................................................. 10-1<br />
10.1.1 Dispatch Test 1: sOEP Opword and Required<br />
Extension Words Are Valid ....................................................................... 10-2<br />
10.1.2 Dispatch Test 2: Instruction Classification ................................................ 10-2<br />
xv
Table of Contents<br />
10.1.3 Dispatch Test 3: Allowable Effective Addressing Mode in the sOEP ....... 10-8<br />
10.1.4 Dispatch Test 4: Allowable Operand Data Memory Reference ................ 10-8<br />
10.1.5 Dispatch Test 5: No Register Conflicts on sOEP.AGU Resources .......... 10-8<br />
10.1.6 Dispatch Test 6: No Register Conflicts on sOEP.IEE Resources ............ 10-9<br />
10.2 Timing Assumptions ................................................................................. 10-10<br />
10.3 Cache and ATC Performance Degradation Times ................................... 10-12<br />
10.3.1 Instruction ATC Miss .............................................................................. 10-12<br />
10.3.2 Data ATC Miss ....................................................................................... 10-13<br />
10.3.3 Instruction Cache Miss ........................................................................... 10-13<br />
10.3.4 Data Cache Miss .................................................................................... 10-13<br />
10.4 Effective Address Calculation Times ........................................................ 10-14<br />
10.5 Move Instruction Execution Times............................................................ 10-14<br />
10.6 Standard Instruction Execution Times ...................................................... 10-16<br />
10.7 Immediate Instruction Execution Times.................................................... 10-17<br />
10.8 Single-Operand Instruction Execution Times ........................................... 10-18<br />
10.9 Shift/Rotate Execution Times ................................................................... 10-19<br />
10.10 Bit Manipulation and Bit Field Execution Times........................................ 10-19<br />
10.11 Branch Instruction Execution Times ......................................................... 10-21<br />
10.12 LEA, PEA, and MOVEM Execution Times................................................ 10-22<br />
10.13 Multiprecision Instruction Execution Times............................................... 10-22<br />
10.14 Status Register, MOVES, and Miscellaneous<br />
Instruction Execution Times...................................................................... 10-22<br />
10.15 FPU Instruction Execution Times ............................................................. 10-24<br />
10.16 Exception Processing Times .................................................................... 10-26<br />
11.1<br />
Section 11<br />
Applications Information<br />
Guidelines for Porting Software to the MC68060 ....................................... 11-1<br />
11.1.1 User Code ................................................................................................ 11-1<br />
11.1.2 Supervisor Code....................................................................................... 11-1<br />
11.1.2.1 Initialization Code (Reset Exception Handler)........................................ 11-2<br />
11.1.2.1.1 Processor Configuration Register (PCR) (MOVEC of PCR). ............... 11-2<br />
11.1.2.1.2 Default Transparent Translation Register (MOVEC of TCR) ............... 11-2<br />
11.1.2.1.3 MC68060 Software Package (<strong>M68060</strong>SP). ......................................... 11-2<br />
11.1.2.1.4 Cache Control Register (CACR) (MOVEC of CACR).......................... 11-3<br />
11.1.2.1.5 Resource Checking (Access Error Handler) ........................................ 11-3<br />
11.1.2.2 Virtual Memory Software ........................................................................ 11-3<br />
11.1.2.2.1 Translation Control Register (MOVEC of TCR).................................... 11-3<br />
11.1.2.2.2 Descriptors in Cacheable Copyback Pages Prohibited........................ 11-4<br />
11.1.2.2.3 Page and Descriptor Faults (Access Error Handler). ........................... 11-4<br />
11.1.2.2.4 PTEST, MOVEC of MMUSR, and PLPA.............................................. 11-4<br />
11.1.2.3 Context Switch Interrupt Handlers.......................................................... 11-5<br />
11.1.2.4 Trace Handlers....................................................................................... 11-5<br />
11.1.2.5 I/O Device Driver Software..................................................................... 11-5<br />
11.1.3 Precise Vs. Imprecise Exception Mode .................................................... 11-6<br />
xvi<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Table of Contents<br />
11.1.4 Other Considerations................................................................................ 11-6<br />
11.2 Using an MC68060 in an Existing MC68040 System ................................. 11-6<br />
11.2.1 Power Considerations............................................................................... 11-6<br />
11.2.1.1 DC to DC Voltage Conversion................................................................ 11-6<br />
11.2.1.1.1 Linear Voltage Regulator Solution........................................................ 11-7<br />
11.2.1.1.2 Switching Regulator Solution................................................................ 11-7<br />
11.2.1.2 Input Signals During Power-Up Requirement....................................... 11-11<br />
11.2.2 Output Hold Time Differences ................................................................ 11-11<br />
11.2.3 Bus Arbitration ........................................................................................ 11-13<br />
11.2.4 Snooping................................................................................................. 11-13<br />
11.2.5 Special Modes ........................................................................................ 11-13<br />
11.2.6 Clocking .................................................................................................. 11-14<br />
11.2.7 PSTx Encoding ....................................................................................... 11-14<br />
11.2.8 Miscellaneous Pullup Resistors .............................................................. 11-15<br />
11.3 Example DRAM Access............................................................................ 11-15<br />
11.4 Thermal Management.............................................................................. 11-17<br />
11.5 Support Devices....................................................................................... 11-20<br />
Section 12<br />
Electrical and Thermal Characteristics<br />
12.1 Maximum Ratings ....................................................................................... 12-1<br />
12.2 Thermal Characteristics .............................................................................. 12-1<br />
12.3 Power Dissipation ....................................................................................... 12-1<br />
12.4 DC Electrical Specifications (Vcc = 3.3 Vdc ± 5%) ..................................... 12-2<br />
12.5 Clock Input Specifications (Vcc = 3.3 Vdc ± 5%)........................................ 12-3<br />
12.6 Output AC Timing Specifications (Vcc = 3.3 Vdc ± 5%) ............................. 12-4<br />
12.7 Input AC Timing Specifications (Vcc = 3.3 Vdc ± 5%) ................................ 12-6<br />
Section 13<br />
Ordering Information and Mechanical Data<br />
13.1 Ordering Information ................................................................................... 13-1<br />
13.2 Pin Assignments ......................................................................................... 13-1<br />
13.2.1 MC68060, MC68LC060, and MC68EC060 Pin Grid Array (RC Suffix) .... 13-2<br />
13.2.2 MC68060, MC68LC060, and MC68EC060 Quad Flat Pack (FE Suffix)... 13-3<br />
13.3 Mechanical Data ......................................................................................... 13-4<br />
Appendix A<br />
MC68LC060<br />
Appendix B<br />
MC68EC060<br />
B.1 Address Translation Differences...................................................................B-1<br />
B.2 Instruction Differences ..................................................................................B-1<br />
xvii
Table of Contents<br />
xviii<br />
Appendix C<br />
MC68060 Software Package<br />
C.1 Module Format..............................................................................................C-2<br />
C.2 Unimplemented Integer Instructions .............................................................C-4<br />
C.2.1 Integer Emulation Results ..........................................................................C-5<br />
C.2.2 Module 1: Unimplemented Integer Instruction Exception<br />
(MC68060ISP)............................................................................................C-5<br />
C.2.2.1 Unimplemented Integer Instruction Exception Module Entry Points ........C-6<br />
C.2.2.2 Unimplemented Integer Instruction Exception Module Call-Outs.............C-6<br />
C.2.2.3 CAS Misaligned Address and CAS2<br />
Emulation-Related Call-Outs and Entry Points ........................................C-6<br />
C.2.3 Module 2: Unimplemented Integer Instruction Library (MC68060ILSP) .....C-9<br />
C.3 Floating-Point Emulation Package (MC68060FPSP) .................................C-11<br />
C.3.1 Floating-Point Emulation Results .............................................................C-13<br />
C.3.2 Module 3: Full Floating-Point Kernel ........................................................C-14<br />
C.3.2.1 Full Floating-Point Kernel Module Entry Points......................................C-14<br />
C.3.2.2 Full Floating-Point Kernel Module Call-Outs ..........................................C-14<br />
C.3.2.2.1 The F-Line Exception Call-Outs ...........................................................C-14<br />
C.3.2.2.2 System-Supplied Floating-Point Arithmetic<br />
Exception Handler Call-Outs................................................................C-15<br />
C.3.2.2.3 Exception-Related Call-Outs...............................................................C-15<br />
C.3.2.2.4 Exit Point Call-Outs ..............................................................................C-15<br />
C.3.2.3 Bypassing Module-Supplied Floating-Point Arithmetic Handlers ...........C-15<br />
C.3.2.3.1 Overflow/Underflow..............................................................................C-16<br />
C.3.2.3.2 Signalling Not-A-Number, Operand Error.............................................C-17<br />
C.3.2.3.3 Inexact Exception.................................................................................C-18<br />
C.3.2.3.4 Divide-by-Zero Exception.....................................................................C-19<br />
C.3.2.3.5 Branch/Set on Unordered Exception....................................................C-19<br />
C.3.2.4 Exceptions During Emulation .................................................................C-20<br />
C.3.2.4.1 Trap-Disabled Operation......................................................................C-20<br />
C.3.2.4.2 Trap-Enabled Operation.......................................................................C-21<br />
C.3.3 Module 4: Partial Floating-Point Kernel ....................................................C-21<br />
C.3.4 Module 5: Floating-Point Library (<strong>M68060</strong>FPLSP)...................................C-22<br />
C.4 Operating System Dependencies ...............................................................C-23<br />
C.4.1 Instruction and Data Fetches....................................................................C-23<br />
C.4.2 Instructions Not Recommended ...............................................................C-26<br />
C.5 Installation Notes ........................................................................................C-27<br />
C.5.1 Installing the Library Modules...................................................................C-27<br />
C.5.2 Installing the Kernel Modules ...................................................................C-27<br />
C.5.3 Release Notes and Module Offset Assignments ......................................C-28<br />
C.5.4 AESOP Electronic Bulletin Board .............................................................C-29<br />
Appendix D<br />
MC68060 Instructions<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
LIST OF ILLUSTRATIONS<br />
1-1 MC68060 Block Diagram ................................................................................... 1-6<br />
1-2 Programming Model ......................................................................................... 1-12<br />
2-1 Functional Signal Groups ................................................................................... 2-3<br />
3-1 MC68060 Integer Unit Pipeline .......................................................................... 3-1<br />
3-2 Integer Unit User Programming Model............................................................... 3-2<br />
3-3 Integer Unit Supervisor Programming Model ..................................................... 3-3<br />
3-4 Status Register................................................................................................... 3-4<br />
3-5 Processor Configuration Register ...................................................................... 3-5<br />
4-1 Memory Management Unit ................................................................................. 4-2<br />
4-2 Memory Management Programming Model ....................................................... 4-3<br />
4-3 URP and SRP Register Formats........................................................................ 4-3<br />
4-4 Translation Control Register Format .................................................................. 4-4<br />
4-5 Transparent Translation Register Format .......................................................... 4-6<br />
4-6 Translation Table Structure ................................................................................ 4-8<br />
4-7 Logical Address Format ..................................................................................... 4-8<br />
4-8 Detailed Flowchart of Table Search Operation ................................................ 4-10<br />
4-9 Detailed Flowchart of Descriptor Fetch Operation ........................................... 4-11<br />
4-10 Table Descriptor Formats................................................................................. 4-12<br />
4-11 Page Descriptor Formats ................................................................................. 4-12<br />
4-12 Example Translation Table............................................................................... 4-15<br />
4-13 Translation Table Using Indirect Descriptors ................................................... 4-16<br />
4-14 Translation Table Using Shared Tables ........................................................... 4-18<br />
4-15 Translation Table with Nonresident Tables ...................................................... 4-19<br />
4-16 Translation Table Structure for Two Tasks ...................................................... 4-21<br />
4-17 Logical Address Map with Shared Supervisor and User Address Spaces....... 4-22<br />
4-18 Translation Table Using S-Bit and W-Bit To Set Protection ............................. 4-23<br />
4-19 ATC Organization............................................................................................. 4-24<br />
4-20 ATC Entry and Tag Fields ................................................................................ 4-25<br />
4-21 Address Translation Flowchart......................................................................... 4-29<br />
5-1 MC68060 Instruction and Data Caches ............................................................. 5-2<br />
5-2 Instruction Cache Line Format ........................................................................... 5-2<br />
5-3 Data Cache Line Format .................................................................................... 5-2<br />
5-4 Caching Operation ............................................................................................. 5-3<br />
5-5 Cache Control Register ...................................................................................... 5-5<br />
5-6 Instruction Cache Line State Diagram.............................................................. 5-16<br />
5-7 Data Cache Line State Diagrams..................................................................... 5-18<br />
6-1 Floating-Point Unit Block Diagram ..................................................................... 6-2<br />
6-2 Floating-Point User Programming Model ........................................................... 6-3<br />
6-3 Floating-Point Control Register Format.............................................................. 6-4<br />
<strong>M68060</strong> USER’S MANUAL<br />
xix
List of Illustrations<br />
6-4 Floating-Point Condition Code (FPSR) .............................................................. 6-5<br />
6-5 Floating-Point Quotient Byte (FPSR) ................................................................. 6-5<br />
6-6 Floating-Point Exception Status Byte (FPSR).................................................... 6-6<br />
6-7 Floating-Point Accrued Exception Byte (FPSR)................................................. 6-6<br />
6-8 Intermediate Result Format.............................................................................. 6-12<br />
6-9 Rounding Algorithm Flowchart ......................................................................... 6-14<br />
6-10 Floating-Point State Frame .............................................................................. 6-35<br />
6-11 Status Word Contents ...................................................................................... 6-36<br />
7-1 Signal Relationships to Clocks........................................................................... 7-2<br />
7-2 Full-Speed Clock................................................................................................ 7-2<br />
7-3 Half-Speed Clock ............................................................................................... 7-2<br />
7-4 Quarter-Speed Clock ......................................................................................... 7-3<br />
7-5 Bus Control Register Format.............................................................................. 7-4<br />
7-6 Internal Operand Representation....................................................................... 7-5<br />
7-7 Data Multiplexing................................................................................................ 7-6<br />
7-8 Byte Select Signal Generation and PAL Equation ............................................. 7-8<br />
7-9 Example of a Misaligned Long-Word Transfer................................................. 7-10<br />
7-10 Example of Misaligned Word Transfer ............................................................. 7-10<br />
7-11 Misaligned Long-Word Read Bus Cycle Timing............................................... 7-11<br />
7-12 Byte, Word, and Long-Word Read Cycle Flowchart ........................................ 7-13<br />
7-13 Byte, Word, and Long-Word Read Bus Cycle Timing ...................................... 7-14<br />
7-14 Line Read Cycle Flowchart .............................................................................. 7-17<br />
7-15 Line Read Transfer Timing............................................................................... 7-18<br />
7-16 Burst-Inhibited Line Read Cycle Flowchart ...................................................... 7-20<br />
7-17 Burst-Inhibited Line Read Bus Cycle Timing.................................................... 7-21<br />
7-18 Byte, Word, and Long-Word Write Transfer Flowchart .................................... 7-22<br />
7-19 Long-Word Write Bus Cycle Timing ................................................................. 7-23<br />
7-20 Line Write Cycle Flowchart .............................................................................. 7-26<br />
7-21 Line Write Burst-Inhibited Cycle Flowchart ...................................................... 7-27<br />
7-22 Line Write Bus Cycle Timing ............................................................................ 7-28<br />
7-23 Locked Bus Cycle for TAS Instruction Timing.................................................. 7-30<br />
7-24 Using CLA in a High-Speed DRAM Design ..................................................... 7-33<br />
7-25 Interrupt Pending Procedure ............................................................................ 7-33<br />
7-26 Assertion of IPEND .......................................................................................... 7-34<br />
7-27 Interrupt Acknowledge Cycle Flowchart........................................................... 7-36<br />
7-28 Interrupt Acknowledge Bus Cycle Timing ........................................................ 7-37<br />
7-29 Autovector Interrupt Acknowledge Bus Cycle Timing ...................................... 7-38<br />
7-30 Breakpoint Interrupt Acknowledge Cycle Flowchart......................................... 7-39<br />
7-31 Breakpoint Interrupt Acknowledge Bus Cycle Timing ...................................... 7-40<br />
7-32 LPSTOP Broadcast Cycle Flowchart ............................................................... 7-41<br />
7-33 LPSTOP Broadcast Bus Cycle Timing, BG Negated ....................................... 7-42<br />
7-34 LPSTOP Broadcast Bus Cycle Timing, BG Asserted ...................................... 7-43<br />
7-35 Exiting LPSTOP Mode Flowchart..................................................................... 7-44<br />
7-36 Exiting LPSTOP Mode Timing Diagram........................................................... 7-45<br />
7-37 Word Write Access Bus Cycle Terminated with TEA Timing ........................... 7-48<br />
xx<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
List of Illustrations<br />
7-38 Line Read Access Bus Cycle Terminated with TEA Timing............................. 7-49<br />
7-39 Retry Read Bus Cycle Timing .......................................................................... 7-50<br />
7-40 Line Write Retry Bus Cycle Timing................................................................... 7-51<br />
7-41 MC68040-Arbitration Protocol State Diagram .................................................. 7-57<br />
7-42 MC68060-Arbitration Protocol State Diagram .................................................. 7-64<br />
7-43 Processor Bus Request Timing........................................................................ 7-67<br />
7-44 Arbitration During Relinquish and Retry Timing ............................................... 7-68<br />
7-45 Implicit Bus Ownership Arbitration Timing........................................................ 7-69<br />
7-46 Effect of BGR on Locked Sequences............................................................... 7-70<br />
7-47 Snooped Bus Cycle.......................................................................................... 7-71<br />
7-48 Initial Power-On Reset Timing.......................................................................... 7-72<br />
7-49 Normal Reset Timing........................................................................................ 7-73<br />
7-50 Data Bus Usage During Reset ......................................................................... 7-74<br />
7-51 Acknowledge Termination Ignore State Example ............................................ 7-75<br />
7-52 Extra Data Write Hold Example........................................................................ 7-77<br />
8-1 General Exception Processing Flowchart .......................................................... 8-2<br />
8-2 General Form of Exception Stack Frame ........................................................... 8-3<br />
8-3 Interrupt Recognition Examples ....................................................................... 8-13<br />
8-4 Interrupt Exception Processing Flowchart........................................................ 8-15<br />
8-5 Reset Exception Processing Flowchart............................................................ 8-16<br />
8-6 Fault Status Long-Word Format ....................................................................... 8-22<br />
9-1 JTAG Test Logic Block Diagram ........................................................................ 9-3<br />
9-2 JTAG Idcode Register Format............................................................................ 9-7<br />
9-3 Output Pin Cell (O.Pin)....................................................................................... 9-8<br />
9-4 Observe-Only Input Pin Cell (I.Obs)................................................................... 9-8<br />
9-5 Input Pin Cell (I.Pin) ........................................................................................... 9-9<br />
9-6 Output Control Cell (IO.Ctl) ................................................................................ 9-9<br />
9-7 General Arrangement of Bidirectional Pin Cells ............................................... 9-10<br />
9-8 JTAG Bypass Register ..................................................................................... 9-15<br />
9-9 Circuit Disabling IEEE Standard 1149.1........................................................... 9-16<br />
9-10 Debug Command Interface Schematic ............................................................ 9-25<br />
9-11 Interface Timing................................................................................................ 9-26<br />
9-12 Transition from JTAG to Debug Mode Timing Diagram ................................... 9-34<br />
9-13 Transition from Debug to JTAG Mode Timing Diagram ................................... 9-35<br />
11-1 Linear Voltage Regulator Solution.................................................................... 11-7<br />
11-2 LTC1147 Voltage Regulator Solution............................................................... 11-8<br />
11-3 LTC1148 Voltage Regulator Solution............................................................... 11-9<br />
11-4 MAX767 Voltage Regulator Solution.............................................................. 11-10<br />
11-5 MC68040 Address Hold Time ........................................................................ 11-11<br />
11-6 MC68060 Address Hold Time ........................................................................ 11-12<br />
11-7 MC68060 Address Hold Time Fix .................................................................. 11-12<br />
11-8 Simple CLK Generation.................................................................................. 11-14<br />
11-9 Generic CLK Generation ................................................................................ 11-14<br />
11-10 MC68040 BCLK to CLKEN Relationship........................................................ 11-15<br />
11-11 DRAM Timing Analysis................................................................................... 11-15<br />
xxi
List of Illustrations<br />
12-12 Clock Input Timing Diagram............................................................................. 12-3<br />
12-13 Drive Levels and Test Points for AC Specifications ......................................... 12-7<br />
12-14 Reset Configuration Timing.............................................................................. 12-8<br />
12-15 Read/Write Timing ........................................................................................... 12-9<br />
12-16 Bus Arbitration Timing.................................................................................... 12-10<br />
12-17 Bus Arbitration Timing (Continued) ................................................................ 12-11<br />
12-18 CLA Timing .................................................................................................... 12-12<br />
12-19 Snoop Timing ................................................................................................. 12-13<br />
12-20 Other Signals Timing...................................................................................... 12-14<br />
13-1 PGA Package Dimensions (RC Suffix) ............................................................ 13-4<br />
13-2 QFP Package Dimensions (FE Suffix) ............................................................. 13-5<br />
C-1 Call-Out Dispatch Table Example ......................................................................C-2<br />
C-2 Example Pseudo-Assembly File ........................................................................C-3<br />
C-3 Module Call-In, Call-Out Example......................................................................C-4<br />
C-4 CAS and CAS2 Call-Outs and Entry Points .......................................................C-9<br />
C-5 C-Code Representation of Integer Library Routines ........................................C-10<br />
C-6 MUL Instruction Call Example..........................................................................C-11<br />
C-7 CMP2 Instruction Call Example .......................................................................C-11<br />
C-8 SNAN/OPERR Exception Handler Pseudo-Code ............................................C-18<br />
C-9 Disabled vs. Enabled Exception Actions..........................................................C-20<br />
C-10 _mem_read Pseudo-Code ...............................................................................C-23<br />
C-11 Register Usage of {i,d}mem_{read,write}_{b,w,l} .............................................C-25<br />
C-12 Vector Table and <strong>M68060</strong>SP Relationship ......................................................C-28<br />
xxii<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
LIST OF TABLES<br />
1-1 Data Formats.................................................................................................... 1-14<br />
1-2 Effective Addressing Modes............................................................................. 1-15<br />
1-3 Instruction Set Summary .................................................................................. 1-16<br />
1-4 Notational Conventions .................................................................................... 1-21<br />
2-1 Signal Index........................................................................................................ 2-1<br />
2-2 Transfer-Type Encoding..................................................................................... 2-4<br />
2-3 Normal and MOVE16 Access TMx Encoding..................................................... 2-5<br />
2-4 Alternate Access TMx Encoding ........................................................................ 2-5<br />
2-5 SIZx Encoding .................................................................................................... 2-6<br />
2-6 Data Bus Byte Select Signals............................................................................. 2-7<br />
2-7 PSTx Encoding................................................................................................. 2-14<br />
2-8 Signal Summary ............................................................................................... 2-17<br />
4-1 Updating U-Bit and M-Bit for Page Descriptors................................................ 4-20<br />
4-2 SFC and DFC Values....................................................................................... 4-20<br />
5-1 TLNx Encoding................................................................................................. 5-11<br />
5-2 Instruction Cache Line State Transitions.......................................................... 5-15<br />
5-3 Data Cache Line State Transitions................................................................... 5-18<br />
6-1 RND Encoding.................................................................................................... 6-4<br />
6-2 PREC Encoding ................................................................................................. 6-4<br />
6-3 MC68060 FPU Data Formats and Data Types .................................................. 6-7<br />
6-4 Single-Precision Real Format Summary ............................................................ 6-8<br />
6-5 Double-Precision Real Format Summary........................................................... 6-9<br />
6-6 Extended-Precision Real Format Summary ..................................................... 6-10<br />
6-7 Packed Decimal Real Format Summary .......................................................... 6-11<br />
6-8 Floating-Point Condition Code Encoding ......................................................... 6-16<br />
6-9 Floating-Point Conditional Tests ...................................................................... 6-18<br />
6-10 Floating-Point Exception Vectors ..................................................................... 6-19<br />
6-11 Unimplemented Instructions............................................................................. 6-20<br />
6-12 Possible Operand Errors Exceptions ............................................................... 6-27<br />
6-13 Overflow Rounding Mode Values..................................................................... 6-29<br />
6-14 Underflow Rounding Mode Values................................................................... 6-31<br />
6-15 Possible Divide-by-Zero Exceptions................................................................. 6-33<br />
6-16 Rounding Mode Values .................................................................................... 6-34<br />
7-1 Data Bus Requirements for Read and Write Cycles .......................................... 7-7<br />
7-2 Summary of Access Types vs. Bus Signal Encoding......................................... 7-9<br />
7-3 Memory Alignment Influence on Noncachable and<br />
Writethrough Bus Cycles.................................................................................. 7-12<br />
7-4 Interrupt Acknowledge Termination Summary ................................................. 7-34<br />
7-5 Termination Result Summary........................................................................... 7-46<br />
7-6 MC68040-Arbitration Protocol Transition Conditions ....................................... 7-55<br />
<strong>M68060</strong> USER’S MANUAL<br />
xxiii
List of Tables<br />
7-7 MC68040-Arbitration Protocol State Description ............................................. 7-56<br />
7-8 MC68060-Arbitration Protocol State Transition Conditions.............................. 7-62<br />
7-9 MC68060-Arbitration Protocol State Description ............................................. 7-63<br />
7-10 Special Mode vs. IPLx Signals......................................................................... 7-74<br />
8-1 Exception Vector Assignments .......................................................................... 8-4<br />
8-2 Interrupt Levels and Mask Values.................................................................... 8-12<br />
8-3 Exception Priority Groups ................................................................................ 8-17<br />
9-1 JTAG States....................................................................................................... 9-2<br />
9-2 JTAG Instructions............................................................................................... 9-4<br />
9-3 Boundary Scan Bit Definitions.......................................................................... 9-10<br />
9-4 Debug Command Interface Pins ...................................................................... 9-25<br />
9-5 Command Summary ........................................................................................ 9-28<br />
10-1 Superscalar OEP Dispatch Test Algorithm ...................................................... 10-4<br />
10-2 MC68060 Superscalar Classification of M680x0 Integer Instructions.............. 10-4<br />
10-3 Superscalar Classification of M680x0 Privileged Instructions.......................... 10-7<br />
10-4 Superscalar Classification of M680x0 Floating-Point Instructions ................... 10-7<br />
10-5 Effective Address Calculation Times.............................................................. 10-14<br />
10-6 Move Byte and Word Execution Times .......................................................... 10-15<br />
10-7 Move Long Execution Times.......................................................................... 10-15<br />
10-8 MOVE16 Execution Times ............................................................................. 10-15<br />
10-9 Standard Instruction Execution Time ............................................................. 10-16<br />
10-10 Immediate Instruction Execution Times ......................................................... 10-17<br />
10-11 Single-Operand Instruction Execution Times................................................. 10-18<br />
10-12 Clear (CLR) Execution Times ........................................................................ 10-18<br />
10-13 Shift/Rotate Execution Times......................................................................... 10-19<br />
10-14 Bit Manipulation (Dynamic Bit Count) Execution Times................................. 10-19<br />
10-15 Bit Manipulation (Static Bit Count) Execution Times...................................... 10-20<br />
10-16 Bit Field Execution Times............................................................................... 10-20<br />
10-17 Branch Execution Times ................................................................................ 10-21<br />
10-18 JMP, JSR Execution Times............................................................................ 10-21<br />
10-19 Return Instruction Execution Times ............................................................... 10-21<br />
10-20 LEA, PEA, and MOVEM Instruction Execution Times ................................... 10-22<br />
10-21 Multiprecision Instruction Execution Times .................................................... 10-22<br />
10-22 Status Register (SR) Instruction Execution Times ......................................... 10-23<br />
10-23 MOVES Execution Times............................................................................... 10-23<br />
10-24 Miscellaneous Instruction Execution Times ................................................... 10-23<br />
10-25 Floating-Point Instruction Execution Times.................................................... 10-24<br />
10-26 Exception Processing Times.......................................................................... 10-26<br />
11-1 With Heat Sink, No Air Flow........................................................................... 11-18<br />
11-2 With Heat Sink, with Air Flow ......................................................................... 11-18<br />
11-3 No Heat Sink .................................................................................................. 11-19<br />
11-4 Support Devices and Products....................................................................... 11-20<br />
C-1 Call-Out Dispatch Table and Module Size .........................................................C-4<br />
C-2 FPU Comparison..............................................................................................C-12<br />
C-3 Unimplemented Instructions.............................................................................C-13<br />
xxiv<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
List of Tables<br />
C-4 Unimplemented Data Formats and Data Types .............................................. C-13<br />
C-5 UNIX Operating System Calls ......................................................................... C-23<br />
C-6 Instructions Not Handled by the <strong>M68060</strong>SP ................................................... C-26<br />
C-7 Files Provided in an <strong>M68060</strong>SP Release........................................................ C-27<br />
D-1 M68000 Family Instruction Set and Processor Cross-Reference ..................... D-1<br />
D-2 M68000 Family Instruction Set.......................................................................... D-6<br />
D-3 Exception Vector Assignments for the M68000 Family................................... D-10<br />
xxv
List of Tables<br />
xxvi<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
SECTION 1<br />
INTRODUCTION<br />
The superscalar MC68060 represents a new line of Motorola microprocessor products. The<br />
first generation of the <strong>M68060</strong> product line consists of the MC68060, MC68LC060, and<br />
MC68EC060. All three microprocessors offer superscalar integer performance of over 100<br />
MIPS at 66 MHz. The MC68060 comes fully equipped with both a floating-point unit (FPU)<br />
and a memory management unit (MMU) for high-performance embedded control and desktop<br />
applications. For cost-sensitive embedded control and desktop applications where an<br />
MMU is required, but the additional cost of a FPU is not justified, the MC68LC060 offers<br />
high-performance at a low cost. Specifically designed for low-cost embedded control applications,<br />
the MC68EC060 eliminates both the FPU and MMU, permitting designers to leverage<br />
MC68060 performance while avoiding the cost of unnecessary features. Throughout<br />
this product brief, all references to the MC68060 also refer to the MC68LC060 and the<br />
MC68EC060, unless otherwise noted.<br />
Leveraging many of the same performance enhancements used by RISC designs as well<br />
as providing innovative architectural techniques, the MC68060 harnesses new levels of performance<br />
for the M68000 family. Incorporating 2.5 million transistors on a single piece of silicon,<br />
the MC68060 employs a deep pipeline, dual issue superscalar execution, a branch<br />
cache, a high-performance floating-point unit (MC68060 only), eight Kbytes each of on-chip<br />
instruction and data caches, and dual on-chip demand paging MMUs (MC68060 and<br />
MC68LC060 only). The MC68060 allows simultaneous execution of two integer instructions<br />
(or an integer and a float instruction) and one branch instruction during each clock.<br />
The MC68060 features a full internal Harvard architecture. The instruction and data caches<br />
are designed to support concurrent instruction fetch, operand read and operand write references<br />
on every clock. Separate 8-Kbyte instruction and 8-Kbyte data caches can be frozen<br />
to prevent allocation over time-critical code or data. The independent nature of the caches<br />
allows instruction stream fetches, data-stream fetches, and external accesses to occur<br />
simultaneously with instruction execution. The operand data cache is four-way banked to<br />
permit simultaneous read and write access each clock.<br />
A very high bandwidth internal memory system coupled with the compact nature of the<br />
M68000 family code allows the MC68060 to achieve extremely high levels of performance,<br />
even when operating from low-cost memory such as a 32-bit wide dynamic random access<br />
memory system.<br />
Instructions are fetched from the internal cache or external memory by a four-stage instruction<br />
fetch pipeline. The MC68060 variable-length instruction system is internally decoded<br />
into a fixed-length representation and channeled into an instruction buffer. The instruction<br />
buffer acts as a FIFO which provides a decoupling mechanism between the instruction fetch<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
1-1
Introduction<br />
unit and the operand execution units. Fixed format instructions are dispatched to dual fourstage<br />
pipelined RISC operand execution engines where they are then executed.<br />
The branch cache also plays a major role in achieving the high performance levels of the<br />
MC68060. It has been implemented such that most branches are executed in zero cycles.<br />
Using a technique known as branch folding, the branch cache allows the instruction fetch<br />
pipeline to detect and change the instruction prefetch stream before the change of flow<br />
affects the instruction execution engines, minimizing the need for pipeline refill.<br />
In addition to substantial cost and performance benefits, the MC68060 also offers advantages<br />
in power consumption and power management. The MC68060 automatically minimizes<br />
power dissipation by using a fully-static design, dynamic power management, and<br />
low-voltage operation. It automatically powers-down internal functional blocks that are not<br />
needed on a clock-by-clock basis. Explicitly the MC68060 power consumption can be controlled<br />
from the operating system. Although the MC68060 operates at a lower operating voltage,<br />
it directly interfaces to both 3-V and 5-V peripherals and logic.<br />
Complete code compatibility with the M68000 family allows the designer to draw on existing<br />
code and past experience to bring products to market quickly. There is also a broad base of<br />
established development tools, including real-time kernels, operating systems, languages,<br />
and applications, to assist in product design. The functionality provided by the MC68060<br />
makes it the ideal choice for a range of high-performance embedded applications and computing<br />
applications. With M68000 family code compatibility, the MC68060 provides a range<br />
of upgrade opportunities to virtually any existing MC68040 application.<br />
1-2<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
1.1 DIFFERENCES AMONG <strong>M68060</strong> FAMILY MEMBERS<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
Because the functionality of individual <strong>M68060</strong> family members are similar, this manual is<br />
organized so that the reader will take the following differences into account while reading<br />
the rest of this manual. Unless otherwise noted, all references to MC68060, with the exception<br />
of the differences outlined below, will apply to the MC68060, MC68LC060, and<br />
MC68EC060. The following paragraphs describe how the MC68LC060 and the<br />
MC68EC060 differ from the MC68060.<br />
1.1.1 MC68LC060<br />
The MC68LC060 is a derivative of the MC68060. The MC68LC060 has the same execution<br />
unit and MMU as the MC68060, but has no FPU. The MC68LC060 is 100% pin compatible<br />
with the MC68060. Disregard all information concerning the FPU when reading this manual.<br />
The following difference exists between the MC68LC060 and the MC68060:<br />
• The MC68LC060 does not contain an FPU. When floating-point instructions are<br />
encountered, a floating-point disabled exception is taken.<br />
1.1.2 MC68EC060<br />
The MC68EC060 is a derivative of the MC68060. The MC68EC060 has the same execution<br />
unit as the MC68060, but has no FPU or paged MMU, which embedded control applications<br />
generally do not require. Disregard information concerning the FPU and MMU when reading<br />
this manual. The MC68EC060 is pin compatible with the MC68060. The following differences<br />
exist between the MC68EC060 and the MC68060:<br />
• The MC68EC060 does not contain an FPU. When floating-point instructions are<br />
encountered, a floating-point disabled exception is taken.<br />
• The MDIS pin name has been changed to the JS0 pin and is included for boundary scan<br />
purposes only.<br />
1.1.2.1 ADDRESS TRANSLATION DIFFERENCES. Although the MC68EC060 has no<br />
paged MMU, the four transparent translation registers (ITT0, ITT1, DTT0, and DTT1) and<br />
the default transparent translation (defined by certain bits in the translation control register<br />
(TCR)) operate normally and can still be used to assign cache modes and supervisor and<br />
write protection for given address ranges. All addresses can be mapped by the four transparent<br />
translation registers (TTRs) and the default transparent translation.<br />
1.1.2.2 INSTRUCTION DIFFERENCES. The PFLUSH and PLPA instructions, the supervisor<br />
root pointer (SRP) and user root pointer (URP) registers, and the E- and P-bits of the<br />
TCR are not supported by the MC68EC060 and must not be used. Use of these instructions<br />
and registers in the MC68EC060 exhibits poor programming practice since no useful results<br />
can be achieved. Any functional anomalies that may result from their use will require system<br />
software modification (to remove offending instructions) to achieve proper operation.<br />
The PLPA instruction operates normally except that when an address misses in the four<br />
TTRs, instead of performing a table search operation, the access cache mode and write protection<br />
properties are defined by the default transparent translation bits in the TCR. The<br />
address register contents are never changed since all addresses are always transparently<br />
1-3
Introduction<br />
translated. The PLPA instruction can only generate an access error exception only on supervisor<br />
or write protection violation cases. The PFLUSH instruction operates as a virtual NOP<br />
instruction.<br />
When the MOVEC instruction is used to access the SRP and URP registers and the E- and<br />
P-bits in the TCR, no exceptions are reported. However, those bits are undefined for the<br />
MC68EC060 and must not be used.<br />
1.2 FEATURES<br />
The main features of the MC68060 are as follows:<br />
• 1.6–1.7 Times the MC68040 Performance at the Same Clock Rate with Existing Compliers.<br />
3.2–3.4 Times the Performance of a 25 MHZ MC68040.<br />
• Harvard Architecture with Independent, Decoupled Fetch and Execution Pipelines.<br />
• Branch Prediction Logic with a 256-Entry, 4-Way Set-Associative, Virtual-Mapped<br />
Branch Cache for Improved Branch Instruction Performance.<br />
• A Superscalar Pipeline and Dual Integer Execution Units Achieving Simultaneous, but<br />
not Out-of-Order Instruction Execution.<br />
• An IEEE Standard, MC68040- and MC68881-/MC68882-Compatible FPU.<br />
• An MC68040-Compatible Paged Memory Management Unit with Dual 64-Entry<br />
Address Translation Caches<br />
• Dual 8-Kbyte Caches (Instruction Cache and Data Cache)<br />
• A Flexible, High-Bandwidth Synchronous Bus Interface<br />
• User Object-Code Compatible with All Earlier M68000 Microprocessors<br />
1.3 ARCHITECTURE<br />
The instruction fetch unit (IFU) is a four-stage pipeline for prefetching instructions. The dual<br />
operand execution pipelines (OEPs) (named primary” (pOEP) and secondary (sOEP)) are<br />
four-stage pipelines for decoding the instructions, fetching the required operand(s), and then<br />
performing the actual execution of the instructions. Since the IFU and OEP are decoupled<br />
by a first-in-first-out (FIFO) instruction buffer, the IFU is able to prefetch instructions in<br />
advance of their actual use by the OEPs.<br />
The MC68060 is designed to maximize the OEP’s efficiency through the use of a superscalar<br />
pipeline architecture. This architectural advance improves processor performance dramatically<br />
by exploiting instruction-level parallelism. The term superscalar denotes the ability<br />
to detect, dispatch, execute, and return results from more than one instruction during each<br />
machine cycle from an otherwise conventional instruction stream.<br />
As a result, multiple instructions may be executed in a single machine cycle. Since the dual<br />
OEPs perform in a lock-step mode of operation, the multiple instruction execution is performed<br />
simultaneously, but not out-of-order. The net effect is a software-invisible pipeline<br />
architecture capable of sustained execution rates of < 1 machine cycle per instruction of the<br />
M68000 instruction set.<br />
1-4<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
Architectural highlights of the MC68060 include:<br />
• Four-Stage Instruction Fetch Unit (IFU)<br />
— 64-Entry Instruction Address Translation Cache (ATC), Organized as 4-Way Set-<br />
Associative, for Fast Virtual-to-Physical Address Translations<br />
— 8- Kbyte, 4-Way Set-Associative, Physically-Mapped Instruction Cache<br />
—256-Entry, 4-Way Set-Associative, Virtually-Mapped Branch Cache, Which Predicts<br />
the Direction of Branches Based on Their Past Execution History<br />
—96-Byte FIFO Instruction Buffer to Allow Decoupling of the IFP and OEPs<br />
• Four-Stage Execution Pipelines Featuring Primary Pipeline (pOEP), Secondary Pipeline<br />
(sOEP), and Register File (RGF) Containing Program-Visible General Registers<br />
— 64-Entry Operand Data ATC, Organized as 4-Way Set-Associative, for Fast Virtualto-Physical<br />
Address Translations<br />
— 8- Kbyte, 4-Way Set-Associative, Physically-Mapped Operand Data Cache<br />
— The Operand Data Cache Is Organized in a Banked Structure to Allow Simultaneous<br />
Read/Write Accesses<br />
— Integer Execute Engines Optimized to Perform Most Instruction Executions in a<br />
Single Machine Cycle<br />
—Floating-Point Execute Engine, with Floating-Point Register File, Optimized for Performance<br />
with Extended-Precision-Wide Internal Datapaths.<br />
—Four-Entry Store Buffer and One-Entry Push Buffer That Provide the Performance<br />
Feature of Decoupling the Processor Pipeline from External Memory for Certain<br />
Cache Modes of Operation.<br />
This pipeline architecture supports extremely high data transfer rates within the MC68060<br />
processor. The on-chip instruction and operand data caches provide 600 MBytes/sec @ 50<br />
MHz to the pipelines, while the integer execute engines can support sustained transfer rates<br />
of 1.2 GBytes/sec.<br />
1.4 PROCESSOR OVERVIEW<br />
The following paragraphs provide a general description of the MC68060.<br />
1.4.1 Functional Blocks<br />
Figure 1-1 illustrates a simplified block diagram of the MC68060.<br />
1-5
Introduction<br />
The architecture of the MC68060 processor is implemented in the following major blocks:<br />
• Execution Unit<br />
—Instruction Fetch Unit<br />
—Integer Unit<br />
—FPU<br />
• Memory Units<br />
—Instruction Memory Unit<br />
• Instruction ATC<br />
• Instruction Cache<br />
• Instruction Cache Controller<br />
—Data Memory Unit<br />
• Data ATC<br />
• Data Cache<br />
• Data Cache Controller<br />
• Bus Controller<br />
These major units execute concurrently to maximize sustained performance. Note that the<br />
caches reside on separate buses allowing concurrent instruction fetch, data read, and data<br />
write operations (internal Harvard architecture).<br />
1-6<br />
EXECUTION UNIT<br />
FLOATING-<br />
POINT<br />
UNIT<br />
EA<br />
FETCH<br />
FP<br />
EXECUTE<br />
BRANCH<br />
CACHE<br />
INSTRUCTION FETCH UNIT<br />
pOEP sOEP<br />
DECODE<br />
DS<br />
DECODE<br />
DS<br />
EA AG EA AG<br />
CALCULATE<br />
CALCULATE<br />
OC EA OC EA OC<br />
FETCH<br />
FETCH<br />
EX INT EX INT EX<br />
EXECUTE<br />
EXECUTE<br />
DATA AVAILABLE<br />
WRITE-BACK<br />
INSTRUCTION<br />
BUFFER<br />
INTEGER UNIT<br />
IA<br />
CALCULATE<br />
INSTRUCTION<br />
FETCH<br />
EARLY<br />
DECODE<br />
IAG<br />
IB<br />
IC<br />
IED<br />
DA<br />
WB<br />
OPERAND DATA BUS<br />
INSTRUCTION<br />
ATC<br />
Figure 1-1. MC68060 Block Diagram<br />
<strong>M68060</strong> USER’S MANUAL<br />
INSTRUCTION<br />
CACHE<br />
CONTROLLER<br />
INSTRUCTION MEMORY UNIT<br />
DATA<br />
ATC<br />
DATA<br />
CACHE<br />
CONTROLLER<br />
DATA MEMORY UNIT<br />
INSTRUCTION<br />
CACHE<br />
DATA<br />
CACHE<br />
B<br />
U<br />
S<br />
C<br />
O<br />
N<br />
T<br />
R<br />
O<br />
L<br />
L<br />
E<br />
R<br />
ADDRESS<br />
DATA<br />
CONTROL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
The integer unit implements a subset of the MC68040 instruction set. The FPU implements<br />
a subset of the MC68881/2 coprocessor instruction set. The instruction and data memory<br />
units manage the ATCs and the instruction and data caches. The ATCs provide on-chip storage<br />
for the paged MMU’s most recently used address translations. The data and instruction<br />
caches include the logic necessary to read, write, update, invalidate, and flush the caches.<br />
The bus controller manages the interface between the MMUs and the external bus. Snoop<br />
invalidation is supported to maintain cache consistency by monitoring the external bus when<br />
the processor is not the current master.<br />
1.4.2 Integer Unit<br />
The MC68060’s integer unit carries out logical and arithmetic operations. The integer unit<br />
contains an instruction fetch controller, an instruction execution controller, and a branch target<br />
cache. The superscalar design of the MC68060 provides dual execution pipelines in the<br />
instruction execution controller, providing simultaneous execution.<br />
The superscalar operation of the integer unit can be disabled in software, turning off the second<br />
execution pipeline for debugging. Disabling the superscalar operation also lowers performance<br />
and power consumption.<br />
1.4.2.1 INSTRUCTION FETCH UNIT. The instruction fetch unit contains an instruction<br />
fetch pipeline and the logic that interfaces to the branch cache. The instruction fetch pipeline<br />
consists of four stages, providing the ability to prefetch instructions in advance of their actual<br />
use in the instruction execution controller. The continuous fetching of instructions keeps the<br />
instruction execution controller busy for the greatest possible performance. Every instruction<br />
passes through each of the four stages before entering the instruction execution controller.<br />
The four stages in the instruction fetch pipeline are:<br />
1. Instruction Address Calculation (IAG)—The virtual address of the instruction is determined.<br />
2. Instruction Fetch (IC)—The instruction is fetched from memory.<br />
3. Early Decode (IED)—The instruction is pre-decoded for pipeline control information.<br />
4. Instruction Buffer (IB)—The instruction and its pipeline control information are buffered<br />
until the integer execution pipeline is ready to process the instruction.<br />
The branch cache plays a major role in achieving the performance levels of the MC68060.<br />
The concept of the branch cache is to provide a mechanism that allows the instruction fetch<br />
pipeline to detect and change the instruction stream before the change of flow affects the<br />
instruction execution controller.<br />
The branch cache is examined for a valid branch entry after each instruction fetch address<br />
is generated in the instruction fetch pipeline. If a hit does not occur in the branch target<br />
cache, the instruction fetch pipeline continues to fetch instructions sequentially. If a hit<br />
occurs in the branch cache, indicating a branch taken instruction, the current instruction<br />
stream is discarded and a new instruction stream is fetched starting at the location indicated<br />
by the branch cache.<br />
1-7
Introduction<br />
1.4.2.2 INTEGER UNIT. The integer unit contains dual integer execution pipelines, interface<br />
logic to the FPU, and control logic for data written to the data cache and MMU. The<br />
superscalar design of the dual integer execution pipelines provide for simultaneous instruction<br />
execution, which allows for processing more than one instruction during each machine<br />
clock cycle. The net effect of this is a software invisible pipeline capable of sustained execution<br />
rates of less than one machine clock cycle per instruction for the M68000 instruction<br />
set.<br />
The integer unit’s control logic pulls an instruction pair from the instruction buffer every<br />
machine clock cycle, stopping only if the instruction information is not available or if an integer<br />
execution pipeline hold condition exists. The six stages in the dual integer execution<br />
pipelines are:<br />
1. Decode (DS)—The instruction is fully decoded.<br />
2. Effective Address Calculation (AG)—If the instruction calls for data from memory, the<br />
location of the data is calculated.<br />
3. Effective Address Fetch (OC)—Data is fetched from the memory location.<br />
4. Integer Execution (EX)—The data is manipulated during execution.<br />
5. Data Available (DA)—The result is available.<br />
6. Write-Back (WB)—The resulting data is written back to on-chip caches or external<br />
memory.<br />
The MC68060 is optimized for most integer instructions to execute in one machine clock<br />
cycle. If during the instruction decode stage, the instruction is determined to be a floatingpoint<br />
instruction, it will be passed to the FPU after the effective address calculate stage. If<br />
data is to be written to either the on-chip caches or external memory after instruction execution,<br />
the write-back stage holds the data until memory is ready to receive it.<br />
1.4.2.3 FLOATING-POINT UNIT. Floating-point math is distinguished from integer math,<br />
which deals only with whole numbers and fixed decimal point locations. The IEEE-compatible<br />
MC68060's FPU computes numeric calculations with a variable decimal point location.<br />
Consolidating the FPU on-chip speeds up overall processing and eliminates the interfacing<br />
overhead associated with external accelerators. The MC68060's FPU operates in parallel<br />
with the integer unit. The FPU performs numeric calculations while the integer unit continues<br />
integer processing.<br />
The FPU has been optimized for the most frequently used instructions and data types to provide<br />
the highest possible performance. The FPU can also be disabled in software to reduce<br />
system power consumption.<br />
1-8<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
The MC68060 is compatible with the ANSI/IEEE Standard 754 for Binary Floating-Point<br />
Arithmetic.<br />
The MC68060’s FPU has been optimized to execute the most commonly used<br />
subset of the MC68881/MC68882 instruction sets. Software emulates floating-point instructions<br />
not directly supported in hardware. Refer to Appendix C MC68060 Software Package<br />
for details on software emulation. The MC68060FPSP provides the following features:<br />
• Arithmetic and Transcendental Instructions<br />
• IEEE-Compliant Exception Handlers<br />
• Unimplemented Data Type and Data Format Handlers<br />
1.4.2.4 MEMORY UNITS. The MC68060 contains independent instruction and data memory<br />
units. Each memory unit consists of an 8-Kbyte cache, a cache controller, and an ATC.<br />
The full addressing range of the MC68060 is 4 Gbytes. Even though most MC68060 systems<br />
implement a much smaller physical memory, by using virtual memory techniques, the<br />
system can appear to have a full 4 Gbytes of memory available to each user program. Each<br />
MMU fully supports demand-paged virtual-memory operating systems with either 4- or 8-<br />
Kbyte page sizes. Each MMU protects supervisor areas from accesses by user programs<br />
and provides write protection on a page-by-page basis. For maximum efficiency, each MMU<br />
operates in parallel with other processor activities. The MMUs can be disabled for emulator<br />
and debugging support.<br />
1.4.2.5 ADDRESS TRANSLATION CACHES. The 64-entry, four-way, set-associative<br />
ATCs store recently used logical-to-physical address translation information as page<br />
descriptors for instruction and data accesses. Each MMU initiates address translation by<br />
searching for a descriptor containing the address translation information in the ATC. If the<br />
descriptor does not reside in the ATC, the MMU performs external bus cycles through the<br />
bus controller to search the translation tables in physical memory. After being located, the<br />
page descriptor is loaded into the ATC, and the address is correctly translated for the<br />
access.<br />
1.4.2.6 INSTRUCTION AND DATA CACHES. Studies have shown that typical programs<br />
spend much of their execution time in a few main routines or tight loops. Earlier members of<br />
the M68000 family took advantage of this locality-of-reference phenomenon to varying<br />
degrees. The MC68060 takes further advantage of cache technology with its two, independent,<br />
on-chip physical caches, one for instructions and one for data. The caches reduce the<br />
processor's external bus activity and increase CPU throughput by lowering the effective<br />
memory access time. For a typical system design, the large caches of the MC68060 yield a<br />
very high hit rate, providing a substantial increase in system performance.<br />
The autonomous nature of the caches allows instruction-stream fetches, data-stream<br />
fetches, and external accesses to occur simultaneously with instruction execution. For<br />
example, if the MC68060 requires both an instruction access and an external peripheral<br />
access and if the instruction is resident in the on-chip cache, the peripheral access proceeds<br />
unimpeded rather than being queued behind the instruction fetch. If a data operand is also<br />
required and it is resident in the data cache, it can be accessed without hindering either the<br />
instruction access or the external peripheral access. The parallelism inherent in the<br />
MC68060 also allows multiple instructions that do not require any external accesses to exe-<br />
1-9
Introduction<br />
cute concurrently while the processor is performing an external access for a previous<br />
instruction.<br />
Each MC68060 cache is 8 Kbytes, accessed by physical addresses. The data cache can be<br />
configured as write-through or deferred copyback on a page basis. This choice allows for<br />
optimizing the system design for high performance if deferred copyback is used.<br />
Cachability of data in each memory page is controlled by two bits in the page descriptor.<br />
Cachable pages can be either write-through or copyback, with no write-allocate for misses<br />
to write-through pages.<br />
The MC68060 implements a four-entry store buffer that maximizes system performance by<br />
decoupling the integer pipeline from the external system bus. When needed, the store buffer<br />
allows the pipeline to generate writes every clock cycle until full, even if the system bus runs<br />
at a slower speed than the processor.<br />
1.4.2.6.1 Cache Organization. The instruction and data caches are each organized as<br />
four-way set associative, with 16-byte lines. Each line of data has associated with it an<br />
address tag and state information that shows the line’s validity. In the data cache, the state<br />
information indicates whether the line is invalid, valid, or dirty.<br />
1.4.2.6.2 Cache Coherency. The MC68060 has the ability to watch or snoop the external<br />
bus during accesses by other bus masters, maintaining coherency between the MC68060's<br />
caches and external memory systems. External bus cycles can be flagged on the bus as<br />
snoopable or nonsnoopable. When an external cycle is marked as snoopable, the bus<br />
snooper checks the caches and invalidates the matching data. Although the integer execution<br />
units and the bus snooper circuit have access to the on-chip caches, the snooper has<br />
priority over the execution units.<br />
1.4.3 Bus Controller<br />
The bus is implemented as a nonmultiplexed, fully synchronous protocol that is clocked off<br />
the rising edge of the input clock. The bus controller operates concurrently with all other<br />
functional units of the MC68060 to maximize system throughput. The timing of the bus is<br />
fully configurable to match external memory requirements.<br />
1.5 PROCESSING STATES<br />
The processor is always in one of three states: normal processing, exception processing, or<br />
halted. It is in the normal processing state when executing instructions, fetching instructions<br />
and operands, and storing instruction results.<br />
Exception processing is the transition from program processing to system, interrupt, and<br />
exception handling. Exception processing includes fetching the exception vector, stacking<br />
operations, and refilling the instruction pipe caused after an exception. The processor enters<br />
exception processing when an exceptional internal condition arises such as tracing an<br />
instruction, an instruction results in a trap, or executing specific instructions. External conditions,<br />
such as interrupts and access errors, also cause exceptions. Exception processing<br />
ends when the first instruction of the exception handler begins to execute.<br />
1-10<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
The processor halts when it receives an access error or generates an address error while in<br />
the exception processing state. For example, if during exception processing of one access<br />
error another access error occurs, the MC68060 is unable to complete the transition to normal<br />
processing and cannot save the internal state of the machine. The processor assumes<br />
that the system is not operational and halts. Only an external reset can restart a halted processor.<br />
Note that when the processor executes a STOP or LPSTOP instruction, it is in a special<br />
type of normal processing state, one without bus cycles. The processor stops, but it<br />
does not halt and can be restored by an interrupt or reset.<br />
1.6 PROGRAMMING MODEL<br />
The MC68060 programming model is separated into two privilege modes: supervisor and<br />
user. The integer unit identifies a logical address by accessing either the supervisor or user<br />
address space, maintaining the differentiation between supervisor and user modes. The<br />
MMUs use the indicated privilege mode to control and translate memory accesses, protecting<br />
supervisor code, data, and resources from user program accesses. Refer to 1.1.2.1<br />
Address Translation Differences for details concerning the MC68EC060 address translation.<br />
Programs access registers based on the indicated mode. User programs can only access<br />
registers specific to the user mode; whereas, system software executing in the supervisor<br />
mode can access all registers, using the control registers to perform supervisory functions.<br />
User programs are thus restricted from accessing privileged information, and the operating<br />
system performs management and service tasks for the user programs by coordinating their<br />
activities. This difference allows the supervisor mode to protect system resources from<br />
uncontrolled accesses.<br />
Most instructions execute in either mode, but some instructions that have important system<br />
effects are privileged and can only execute in the supervisor mode. For instance, user programs<br />
cannot execute the STOP or RESET instructions. To prevent a user program from<br />
entering the supervisor mode, except in a controlled manner, instructions that can alter the<br />
S-bit in the status register (SR) are privileged. The TRAP instructions provide controlled<br />
access to operating system services for user programs.<br />
If the S-bit in the SR is set, the processor executes instructions in the supervisor mode.<br />
Because the processor performs all exception processing in the supervisor mode, all bus<br />
cycles generated during exception processing are supervisor references, and all stack<br />
accesses use the active supervisor stack pointer. If the S-bit of the SR is clear, the processor<br />
executes instructions in the user mode. The bus cycles for an instruction executed in the<br />
user mode are user references. The values on the transfer modifier pins indicate either<br />
supervisor or user accesses.<br />
The processor utilizes the user mode and the user programming model when it is in normal<br />
processing. During exception processing, the processor changes from user to supervisor<br />
mode. Exception processing saves the current value of the SR on the active supervisor<br />
stack and then sets the S-bit, forcing the processor into the supervisor mode. To return to<br />
the user mode, a system routine must execute one of the following instructions: MOVE to<br />
SR, ANDI to SR, EORI to SR, ORI to SR, or RTE, which execute in the supervisor mode,<br />
1-11
Introduction<br />
modifying the S-bit of the SR. After these instructions execute, the instruction pipeline is<br />
flushed and is refilled from the appropriate address space.<br />
The MC68060 integrates the functions of the integer unit, FPU, and MMU. The registers<br />
depicted in the programming model (see Figure 1-2) provide operand storage and control<br />
for these three units. The registers are partitioned into two levels of privilege modes: user<br />
and supervisor. The user programming model is the same as the user programming model<br />
of the MC68040, which consists of 16 general-purpose 32-bit registers, two control registers,<br />
eight 80-bit floating-point data registers, a floating-point control register, a floating-point<br />
status register, and a floating-point instruction address register.<br />
Only system programmers can use the supervisor programming model to implement operating<br />
system functions, I/O control, and memory management subsystems. This supervisor/<br />
1-12<br />
31 0<br />
DATA<br />
REGISTERS<br />
ADDRESS<br />
REGISTERS<br />
D0<br />
D1<br />
D2<br />
D3<br />
D4<br />
D5<br />
D6<br />
D7<br />
A0<br />
A1<br />
A2<br />
A3<br />
A4<br />
A5<br />
A6<br />
A7/USP<br />
PC<br />
CCR<br />
31 0<br />
PCR<br />
A7/SSP<br />
(CCR) SR<br />
VBR<br />
SFC<br />
DFC<br />
CACR<br />
URP<br />
SRP<br />
TC<br />
DTT0<br />
DTT1<br />
ITT0<br />
ITT1<br />
BUSCR<br />
79 0<br />
USER PROGRAMMING MODEL<br />
FLOATING-POINT<br />
DATA<br />
REGISTERS<br />
SUPERVISOR PROGRAMMING MODEL<br />
Figure 1-2. Programming Model<br />
<strong>M68060</strong> USER’S MANUAL<br />
FP0<br />
FP1<br />
FP2<br />
FP3<br />
FP4<br />
FP5<br />
FP6<br />
FP7<br />
31 15<br />
0<br />
FP CONTROL REGISTER<br />
0<br />
FPCR<br />
FP STATUS REGISTER<br />
FPSR<br />
FP INSTRUCTION ADDRESS REGISTER<br />
FPIAR<br />
USER STACK POINTER<br />
PROGRAM COUNTER<br />
CONDITION CODE REGISTER<br />
PROCESSOR CONFIGURATION REGISTER<br />
SUPERVISOR STACK POINTER<br />
STATUS REGISTER (CCR IS ALSO SHOWN IN THE USER PROGRAMMING MODEL)<br />
VECTOR BASE REGISTER<br />
SOURCE FUNCTION CODE<br />
DESTINATION FUNCTION CODE<br />
CACHE CONTROL REGISTER<br />
USER ROOT POINTER REGISTER<br />
SUPERVISOR ROOT POINTER REGISTER<br />
TRANSLATION CONTROL REGISTER<br />
DATA TRANSPARENT TRANSLATION REGISTER 0<br />
DATA TRANSPARENT TRANSLATION REGISTER 1<br />
INSTRUCTION TRANSPARENT TRANSLATION REGISTER 0<br />
INSTRUCTION TRANSPARENT TRANSLATION REGISTER 1<br />
BUS CONTROL REGISTER<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
user distinction in the M68000 family architecture allows for the writing of application software<br />
that executes in the user mode and migrates to the MC68060 from any M68000 family<br />
platform without modification. The supervisor programming model contains the control features<br />
that system designers need to modify system software when porting to a new design.<br />
For example, only the supervisor software can read or write to the TTRs of the MC68060.<br />
The existence of the TTRs does not affect the programming resources of user application<br />
programs.<br />
The user programming model includes eight data registers, seven address registers, and a<br />
stack pointer register. The address registers and stack pointer can be used as base address<br />
registers or software stack pointers, and any of the 16 registers can be used as index registers.<br />
Two control registers are available in the user mode—the program counter (PC),<br />
which usually contains the address of the instruction that the MC68060 is executing, and the<br />
lower byte of the SR, which is accessible as the condition code register (CCR). The CCR<br />
contains the condition codes that reflect the results of a previous operation and can be used<br />
for conditional instruction execution in a program.<br />
The supervisor programming model includes the upper byte of the SR, which contains operation<br />
control information. The vector base register (VBR) contains the base address of the<br />
exception vector table, which is used in exception processing. The source function code<br />
(SFC) and destination function code (DFC) registers contain 3-bit function codes. These<br />
function codes can be considered extensions to the 32-bit logical address. The processor<br />
automatically generates function codes to select address spaces for data and program<br />
accesses in the user and supervisor modes. Some instructions use the alternate function<br />
code registers to specify the function codes for various operations.<br />
The processor configuration register (PCR) contains bits which control the internal pipelines<br />
of the MC68060 design.<br />
The bus control register (BUSCR) is used to control software emulation of locked bus transactions.<br />
The cache control register (CACR) controls enabling of the on-chip instruction and data<br />
caches of the MC68060. The supervisor root pointer (SRP) and user root pointer (URP) registers<br />
point to the root of the address translation table tree to be used for supervisor and user<br />
mode accesses.<br />
The translation control register (TCR) enables logical-to-physical address translation and<br />
selects either 4- or 8-Kbyte page sizes. There are four TTRs, two for instruction accesses<br />
and two for data accesses. These registers allow portions of the logical address space to be<br />
transparently mapped and accessed without the use of resident descriptors in an ATC.<br />
The user programming model can also access the entire floating-point programming model.<br />
The eight 80-bit floating-point data registers are analogous to the integer data registers. A<br />
32-bit floating-point control register (FPCR) contains an exception enable byte that enables<br />
and disables traps for each class of floating-point exceptions and a mode byte that sets the<br />
user-selectable rounding and precision modes. A floating-point status register (FPSR) contains<br />
a condition code byte, quotient byte, exception status byte, and accrued exception<br />
1-13
Introduction<br />
byte. A floating-point exception handler can use the address in the 32-bit floating-point<br />
instruction address register (FPIAR) to locate the floating-point instruction that has caused<br />
an exception. Instructions that do not modify the FPIAR can be used to read the FPIAR in<br />
the exception handler without changing the previous value.<br />
1.7 DATA FORMAT SUMMARY<br />
The MC68060 supports the basic data formats of the M68000 family. Some data formats<br />
apply only to the integer unit, some only to the FPU, and some to both. In addition, the<br />
instruction set supports operations on other data formats such as memory addresses.<br />
The operand data formats supported by the integer unit are the standard twos-complement<br />
data formats defined in the M68000 family architecture plus a new data format (16-byte<br />
block) for the MOVE16 instruction. Registers, memory, or instructions themselves can contain<br />
integer unit operands. The operand size for each instruction is either explicitly encoded<br />
in the instruction or implicitly defined by the instruction operation.<br />
Whenever an integer is used in a floating-point operation, the FPU automatically converts it<br />
to an extended-precision floating-point number before using the integer. The FPU implements<br />
single-, double-, and extended-precision floating-point data formats as defined by the<br />
IEEE 754 standard. The FPU does not directly support packed decimal real format. However,<br />
software emulation supports this format via the unimplemented data format vector.<br />
Additionally, each data format has a special encoding that represents one of five data types:<br />
normalized numbers, denormalized numbers, zeros, infinities, and not-a-numbers (NANs).<br />
Table 1-1 lists the data formats for both the integer unit and the FPU. Refer to M68000PM/<br />
AD, M68000 Family Programmer’s Reference <strong>Manual</strong>, for details on data format organization<br />
in registers and memory.<br />
1-14<br />
Table 1-1. Data Formats<br />
Operand Data Format Size Supported In Notes<br />
Bit 1 Bit Integer Unit —<br />
Bit Field 1–32 Bits Integer Unit Field of Consecutive Bits<br />
Binary-Coded Decimal (BCD) 8 Bits Integer Unit Packed: 2 Digits/Byte; Unpacked: 1 Digit/Byte<br />
Byte Integer 8 Bits Integer Unit, FPU —<br />
Word Integer 16 Bits Integer Unit, FPU —<br />
Long-Word Integer 32 Bits Integer Unit, FPU —<br />
16-Byte 128 Bits Integer Unit Memory Only, Aligned to 16-Byte Boundary<br />
Single-Precision Real 32 Bits FPU 1-Bit Sign, 8-Bit Exponent, 23-Bit Fraction<br />
Double-Precision Real 64 Bits FPU 1-Bit Sign, 11-Bit Exponent, 52-Bit Fraction<br />
Extended-Precision Real 96 Bits FPU 1-Bit Sign, 15-Bit Exponent, 64-Bit Mantissa<br />
1.8 ADDRESSING CAPABILITIES SUMMARY<br />
The MC68060 supports the basic addressing modes of the M68000 family. The register indirect<br />
addressing modes support postincrement, predecrement, offset, and indexing, which<br />
are particularly useful for handling data structures common to sophisticated applications and<br />
high-level languages. The program counter indirect mode also has indexing and offset capabilities.<br />
This addressing mode is typically required to support position-independent software.<br />
Besides these addressing modes, the MC68060 provides index sizing and scaling features.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Introduction<br />
An instruction’s addressing mode can specify the value of an operand, a register containing<br />
the operand, or how to derive the effective address of an operand in memory. Each addressing<br />
mode has an assembler syntax. Some instructions imply the addressing mode for an<br />
operand. These instructions include the appropriate fields for operands that use only one<br />
addressing mode. Table 1-2 lists a summary of the effective addressing modes for the<br />
MC68060. Refer to M68000PM/AD, M68000 Family Programmer’s Reference <strong>Manual</strong>, for<br />
details on instruction format and addressing modes.<br />
1.9 INSTRUCTION SET OVERVIEW<br />
Table 1-2. Effective Addressing Modes<br />
Addressing Modes Syntax<br />
Register Direct<br />
Data<br />
Address<br />
Register Indirect<br />
Address<br />
Address with Postincrement<br />
Address with Predecrement<br />
Address with Displacement<br />
Address Register Indirect with Index<br />
8-Bit Displacement<br />
Base Displacement<br />
Memory Indirect<br />
Postindexed<br />
Preindexed<br />
Program Counter Indirect<br />
with Displacement<br />
Program Counter Indirect with Index<br />
8-Bit Displacement<br />
Base Displacement<br />
Program Counter Memory Indirect<br />
Postindexed<br />
Preindexed<br />
Absolute Data Addressing<br />
Short<br />
Long<br />
The instruction set is tailored to support high-level languages and is optimized for those<br />
instructions most commonly executed. The floating-point instructions for the MC68060 are<br />
a commonly used subset of the MC68881/MC68882 instruction set with new arithmetic<br />
instructions to explicitly select single- or double-precision rounding. The remaining unimplemented<br />
instructions are less frequently used and are efficiently emulated in the<br />
MC68060FPSP, maintaining compatibility with the MC68881/MC68882 floating-point coprocessors.<br />
The MC68060 instruction set includes MOVE16 which allows high-speed transfers<br />
of 16-byte blocks between external devices such as memory to memory or coprocessor to<br />
memory. Table 1-3 provides an alphabetized listing of the MC68060 instruction set’s<br />
opcode, operation, and syntax. Refer to Table 1-4 for notations used in Table 1-3. The left<br />
operand in the syntax is always the source operand, and the right operand is the destination<br />
operand. Refer to M68000PM/AD, M68000 Family Programmer’s Reference <strong>Manual</strong>, for<br />
details on instructions used by the MC68060.<br />
Dn<br />
An<br />
(An)<br />
(An)+<br />
–(An)<br />
(d16,An)<br />
(d 8 ,An,Xn)<br />
(bd,An,Xn)<br />
([bd,An],Xn,od)<br />
([bd,An,Xn],od)<br />
(d 16 ,PC)<br />
(d 8 ,PC,Xn)<br />
(bd,PC,Xn)<br />
([bd,PC],Xn,od)<br />
([bd,PC,Xn],od)<br />
(xxx).W<br />
(xxx).L<br />
Immediate #<br />
1-15
Introduction<br />
1-16<br />
Table 1-3. Instruction Set Summary<br />
Opcode Operation Syntax<br />
ABCD BCD Source + BCD Destination + X ˘ Destination<br />
ADD Source + Destination ˘ Destination<br />
<strong>M68060</strong> USER’S MANUAL<br />
ABCD Dy,Dx<br />
ABCD –(Ay),–(Ax)<br />
ADD ,Dn<br />
ADD Dn,<br />
ADDA Source + Destination ˘ Destination ADDA ,An<br />
ADDI Immediate Data + Destination ˘ Destination ADDI #,<br />
ADDQ Immediate Data + Destination ˘ Destination ADDQ #,<br />
ADDX Source + Destination + X ˘ Destination<br />
AND Source Λ Destination ˘ Destination<br />
ADDX Dy,Dx<br />
ADDX –(Ay),–(Ax)<br />
AND ,Dn<br />
AND Dn,<br />
ANDI Immediate Data Λ Destination ˘ Destination ANDI #,<br />
ANDI to CCR Source Λ CCR ˘ CCR ANDI #,CCR<br />
ANDI to SR<br />
If supervisor state<br />
then Source<br />
else TRAP<br />
Λ SR ˘ SR<br />
ASL, ASR Destination Shifted by count ˘ Destination<br />
ANDI #,SR<br />
ASd Dx,Dy<br />
1<br />
ASd #,Dy<br />
ASd <br />
Bcc<br />
If condition true<br />
then PC + dn ˘ PC<br />
Bcc <br />
BCHG<br />
~(bit number of Destination) ˘ Z;<br />
~(bit number of Destination) ˘ (bit number) of Destination<br />
BCHG Dn,<br />
BCHG #,<br />
BCLR<br />
~(bit number of Destination) ˘ Z;<br />
0 ˘ bit number of Destination<br />
BCLR Dn,<br />
BCLR #,<br />
BFCHG ~(bit field of Destination) ˘ bit field of Destination BFCHG {offset:width}<br />
BFCLR 0 ˘ bit field of Destination BFCLR {offset:width}<br />
BFEXTS bit field of Source ˘ Dn BFEXTS {offset:width},Dn<br />
BFEXTU bit offset of Source ˘ Dn BFEXTU {offset:width},Dn<br />
BFFFO bit offset of Source Bit Scan ˘ Dn BFFFO {offset:width},Dn<br />
BFINS Dn ˘ bit field of Destination BFINS Dn,{offset:width}<br />
BFSET 1s ˘ bit field of Destination BFSET {offset:width}<br />
BFTST bit field of Destination BFTST {offset:width}<br />
BKPT<br />
Run breakpoint acknowledge cycle;<br />
TRAP as illegal instruction<br />
BKPT #<br />
BRA PC + dn ˘ PC BRA <br />
BSET<br />
~(bit number of Destination) ˘ Z;<br />
1 ˘ bit number of Destination<br />
BSET Dn,<br />
BSET #,<br />
BSR SP – 4 ˘ SP; PC ˘ (SP); PC + dn ˘ PC BSR <br />
BTST –(bit number of Destination) ˘ Z;<br />
CAS 8<br />
CAS Destination – Compare Operand ˘ cc;<br />
if Z, Update Operand ˘ Destination<br />
else Destination ˘ Compare Operand<br />
CAS2 2<br />
CAS2 Destination 1 – Compare 1 ˘ cc;<br />
if Z, Destination 2 – Compare ˘ cc;<br />
if Z, Update 1 ˘ Destination 1;<br />
Update 2 ˘ Destination 2<br />
else Destination 1 ˘ Compare 1;<br />
Destination 2 ˘ Compare 2<br />
CHK<br />
If Dn < 0 or Dn > Source<br />
then TRAP<br />
CHK2 2 If Rn < LB or If Rn > UB<br />
then TRAP<br />
If supervisor state<br />
CINV<br />
then invalidate selected cache lines<br />
else TRAP<br />
BTST Dn,<br />
BTST #,<br />
CAS Dc,Du,<br />
CAS2 Dc1–Dc2,Du1–Du2,(Rn1)–<br />
(Rn2)<br />
CHK ,Dn<br />
CHK2 ,Rn<br />
CINVL , (An)<br />
CINVP , (An)<br />
CINVA <br />
MOTOROLA
CLR 0 ˘ Destination CLR <br />
CMP Destination – Source ˘ cc CMP ,Dn<br />
CMPA Destination – Source CMPA ,An<br />
CMPI Destination – Immediate Data CMPI #,<br />
CMPM Destination – Source ˘ cc CMPM (Ay)+,(Ax)+<br />
CMP2 2<br />
Opcode Operation Syntax<br />
Compare Rn < LB or Rn > UB<br />
and Set Condition Codes<br />
CMP2 ,Rn<br />
CPUSH<br />
DBcc<br />
If supervisor state<br />
then if data cache push selected dirty data<br />
cache lines; invalidate selected cache lines<br />
else TRAP<br />
If condition false<br />
then (Dn–1 ˘ Dn;<br />
If Dn ≠ –1<br />
then PC + dn ˘ PC)<br />
CPUSHL , (An)<br />
CPUSHP , (An)<br />
CPUSHA <br />
DBcc Dn,<br />
Introduction<br />
DIVS, DIVSL Destination ÷ Source ˘ Destination<br />
DIVS.W ,Dn32 ÷ 16 ˘ 16r:16q<br />
DIVS.L ,Dq32 ÷ 32 ˘ 32q<br />
DIVS.L ,Dr:Dq64 ÷ 32 ˘ 32r:32q 2<br />
DIVSL.L ,Dr:Dq 32 ÷ 32 ˘ 32r:32q<br />
DIVU.W ,Dn32 ÷ 16 ˘ 16r:16q<br />
DIVU, DIVUL Destination ÷ Source ˘ Destination<br />
DIVU.L ,Dq32 ÷ 32 ˘ 32q<br />
DIVU.L ,Dr:Dq64 ÷ 32 ˘ 32r:32q 2<br />
DIVUL.L ,Dr:Dq32 ÷ 32 ˘ 32r:32q<br />
EOR Source ⊕ Destination ˘ Destination EOR Dn,<br />
EORI Immediate Data ⊕ Destination ˘ Destination EORI #,<br />
EORI to CCR Source ⊕ CCR ˘ CCR EORI #,CCR<br />
If supervisor state<br />
EORI to SR then Source ⊕ SR ˘ SR<br />
else TRAP<br />
EORI #,SR<br />
EXG Dx,Dy<br />
EXG Rx ¯ ˘ Ry<br />
EXG Ax,Ay<br />
EXG Dx,Ay<br />
EXG Ay,Dx<br />
EXT<br />
EXTB<br />
Destination Sign – Extended ˘ Destination<br />
FABS Absolute Value of Source ˘ FPn<br />
FADD<br />
FBcc<br />
FCMP<br />
FDBcc 2<br />
FDIV<br />
Source + FPn ˘ FPn<br />
If condition true<br />
then PC + dn ˘ PC<br />
FPn – Source<br />
Table 1-3. Instruction Set Summary (Continued)<br />
If condition true<br />
then no operation<br />
else Dn – 1 ˘ Dn<br />
if Dn ≠ –1 then PC + dn ˘ PC<br />
else execute next instruction<br />
FPn ÷ Source ˘ FPn<br />
EXT.W Dnextend byte to word<br />
EXT.L L Dnextend word to long word<br />
EXTB.L Dn extend byte to long word<br />
FABS. ,FPn<br />
FABS.X FPm,FPn<br />
FABS.X FPn<br />
FrABS. ,FPn3 FrABS.X FPm,FPn3<br />
FrABS.X FPn3<br />
FADD. ,FPn<br />
FADD.X FPm,FPn<br />
FrADD. ,FPn3 FrADD.X FPm,FPn3<br />
FBcc.SIZE <br />
FCMP. ,FPn<br />
FCMP.X FPm,FPn<br />
FDBcc Dn,<br />
FDIV. ,FPn<br />
FDIV.X FPm,FPn<br />
FrDIV. ,FPn 3<br />
FrDIV.X FPm,FPn 3<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 1-17
Introduction<br />
FINT.,FPn<br />
FINT Floating-Point Integer Part<br />
FINT.X FPm,FPn<br />
FINT.X FPn<br />
FINTRZ.,FPn<br />
FINTRZ Floating-Point Integer Part, Round-to-Zero<br />
FINTRZ.X FPm,FPn<br />
FINTRZ.X FPn<br />
FMOVE. ,FPn<br />
FMOVE. FPm,<br />
FMOVE Source ˘ Destination<br />
FMOVE.P FPm,{Dn}<br />
FMOVE.P FPm,{#k}<br />
FrMOVE. ,FPn 3<br />
Opcode Operation Syntax<br />
FMOVE Source ˘ Destination<br />
FMOVE.L ,FPcr<br />
FMOVE.L FPcr,<br />
FMOVEM 9<br />
FMOVEM 9<br />
Register List ˘ Destination<br />
Source ˘ Register List<br />
Register List ˘ Destination<br />
Source ˘ Register List<br />
FMUL Source × FPn ˘ FPn<br />
FNEG<br />
–(Source) ˘ FPn<br />
FNOP None FNOP<br />
FRESTORE<br />
If in supervisor state<br />
then FPU State Frame ˘ Internal State<br />
else TRAP<br />
If in supervisor state<br />
FSAVE<br />
then FPU Internal State ˘ State Frame<br />
else TRAP<br />
FScc2 If condition true<br />
then 1s ˘ Destination<br />
else 0s ˘ Destination<br />
FSGLDIV FPn ÷ Source ˘ FPn<br />
FSGLMUL Source × FPn ˘ FPn<br />
FSQRT<br />
FSUB<br />
Square Root of Source ˘ FPn<br />
FPn – Source ˘ FPn<br />
FTRAPcc 2 If condition true<br />
then TRAP<br />
FTST<br />
Table 1-3. Instruction Set Summary (Continued)<br />
Condition Codes for Operand ˘ FPCC<br />
FMOVEM.X , 4<br />
FMOVEM.X Dn,<br />
FMOVEM.X , 4<br />
FMOVEM.X ,Dn<br />
FMOVEM.L , 5<br />
FMOVEM.L , 5<br />
FMUL. ,FPn<br />
FMUL.X FPm,FPn<br />
FrMUL ,FPn 3<br />
FrMUL.X FPm,FPn 3<br />
FNEG. ,FPn<br />
FNEG.X FPm,FPn<br />
FNEG.X FPn<br />
FrNEG. ,FPn 3<br />
FrNEG.X FPm,FPn3 FrNEG.X FPn 3<br />
FRESTORE <br />
FSAVE <br />
FScc.SIZE <br />
ILLEGAL<br />
SSP – 2 ˘ SSP; Vector Offset ˘ (SSP);<br />
SSP – 4 ˘ SSP; PC ˘ (SSP);<br />
SSp – 2 ˘ SSP; SR ˘ (SSP);<br />
Illegal Instruction Vector Address ˘ PC<br />
ILLEGAL<br />
JMP Destination Address ˘ PC JMP <br />
FSGLDIV. ,FPn<br />
FSGLDIV.X FPm,FPn<br />
FSGMUL. ,FPn<br />
FSGLMUL.X FPm, FPn<br />
FSQRT. ,FPn<br />
FSQRT.X FPm,FPn<br />
FSQRT.X FPn<br />
FrSQRT. ,FPn3 FrSQRT FPm,FPn3<br />
FrSQRT FPn3<br />
FSUB. ,FPn<br />
FSUB.X FPm,FPn<br />
FrSUB. ,FPn3 FrSUB.X FPm,FPn3<br />
FTRAPcc<br />
FTRAPcc.W #<br />
FTRAPcc.L #<br />
FTST. <br />
FTST.X FPm<br />
1-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
JSR<br />
SP – 4 ˘ SP; PC ˘ (SP)<br />
Destination Address ˘ PC<br />
JSR <br />
LEA ˘ An LEA ,An<br />
LINK<br />
SP – 4 ˘ SP; An ˘ (SP)<br />
SP ˘ An, SP+d ˘ SP<br />
If supervisor state<br />
LINK An,dn<br />
immediate data ˘ SR<br />
LPSTOP<br />
SR ˘ broadcast cycle<br />
STOP<br />
else TRAP<br />
LPSTOP #<br />
LSL, LSR Destination Shifted by count ˘ Destination<br />
LSd Dx,Dy1 Opcode Operation Syntax<br />
LSd #,Dy1<br />
LSd 1<br />
MOVE Source ˘ Destination MOVE ,<br />
MOVEA Source ˘ Destination MOVEA ,An<br />
MOVE<br />
from CCR<br />
CCR ˘ Destination MOVE CCR,<br />
MOVE to<br />
CCR<br />
Source ˘ CCR MOVE ,CCR<br />
MOVE from<br />
SR<br />
MOVE to SR<br />
MOVE USP<br />
If supervisor state<br />
then SR ˘ Destination<br />
else TRAP<br />
If supervisor state<br />
then Source ˘ SR<br />
else TRAP<br />
If supervisor state<br />
then USP ˘ An or An ˘ USP<br />
else TRAP<br />
MOVE16 Source block ˘ Destination block<br />
MOVEC<br />
MOVEM<br />
If supervisor state<br />
then Rc ˘ Rn or Rn ˘ Rc<br />
else TRAP<br />
Registers ˘ Destination<br />
Source ˘ Registers<br />
MOVEP 2 Source ˘ Destination<br />
MOVE SR,<br />
MOVE ,SR<br />
MOVE USP,An<br />
MOVE An,USP<br />
MOVE16 (Ax)+, (Ay)+ 6<br />
MOVE16 (xxx).L, (An)<br />
MOVE16 (An), (xxx).L<br />
MOVE16 (An)+, (xxx).L<br />
MOVEC Rc,Rn<br />
MOVEC Rn,Rc<br />
MOVEM , 4<br />
MOVEM ,4<br />
MOVEP Dx,(dn,Ay)<br />
MOVEP (dn,Ay),Dx<br />
MOVEQ Immediate Data ˘ Destination MOVEQ #,Dn<br />
MOVES<br />
Table 1-3. Instruction Set Summary (Continued)<br />
If supervisor state<br />
then Rn ˘ Destination [DFC] or<br />
Source [SFC] ˘ Rn<br />
else TRAP<br />
MULS Source × Destination ˘ Destination<br />
MULU Source × Destination ˘ Destination<br />
MOVES Rn,<br />
MOVES ,Rn<br />
Introduction<br />
MULS.W ,Dn 16 × 16 ˘ 32<br />
MULS.L ,Dl 32 × 32 ˘ 32<br />
MULS.L ,Dh–Dl 32 × 32 ˘ 64 2<br />
MULU.W ,Dn 16 × 16 ˘ 32<br />
MULU.L ,Dl 32 × 32 ˘ 32<br />
MULU.L ,Dh–Dl 32 × 32 ˘ 64 2<br />
NBCD 0 – (Destination10) – X ˘ Destination NBCD <br />
NEG 0 – (Destination) ˘ Destination NEG <br />
NEGX 0 – (Destination) – X ˘ Destination NEGX <br />
NOP None NOP<br />
NOT ~ Destination ˘ Destination NOT <br />
OR Source V Destination ˘ Destination<br />
OR ,Dn<br />
OR Dn,<br />
ORI Immediate Data V Destination ˘ Destination ORI #,<br />
ORI to CCR Source V CCR ˘ CCR ORI #,CCR<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 1-19
Introduction<br />
ORI to SR<br />
PACK<br />
If supervisor state<br />
then Source V SR ˘ SR<br />
else TRAP<br />
Source (Unpacked BCD) + adjustment ˘<br />
Destination (Packed BCD)<br />
ORI #,SR<br />
PEA SP – 4 ˘ SP; ˘ (SP) PEA <br />
PFLUSH7 If supervisor state<br />
then invalidate instruction and data ATC entries<br />
for destination address<br />
else TRAP<br />
If supervisor state<br />
PLPA<br />
then logical address translate to physical<br />
address ˘ An<br />
else TRAP<br />
If supervisor state<br />
RESET<br />
then Assert RSTO Line<br />
else TRAP<br />
ROL, ROR Destination Rotated by count ˘ Destination<br />
ROXL, ROXR Destination Rotated with X by count ˘ Destination<br />
PACK –(Ax),–(Ay),#(adjustment)<br />
PACK Dx,Dy,#(adjustment)<br />
PFLUSH (An)<br />
PFLUSHN (An)<br />
PFLUSHA<br />
PFLUSHAN<br />
PLPAR (An)<br />
PLPAW (An)<br />
RESET<br />
ROd Rx,Dy1<br />
ROXd Dx,Dy 1<br />
ROXd #,Dy 1<br />
ROXd 1<br />
RTD (SP) ˘ PC; SP + 4 + dn ˘ SP RTD #(dn)<br />
If supervisor state<br />
then (SP) ˘ SR; SP + 2 ˘ SP; (SP) ˘ PC;<br />
RTE<br />
SP + 4 ˘ SP; restore state and deallocate<br />
stack according to (SP)<br />
else TRAP<br />
RTE<br />
RTR<br />
(SP) ˘ CCR; SP + 2 ˘ SP;<br />
(SP) ˘ PC; SP + 4 ˘ SP<br />
RTR<br />
RTS (SP) ˘ PC; SP + 4 ˘ SP RTS<br />
SBCD Destination10 – Source10 – X ˘ Destination SBCD Dx,Dy<br />
SBCD –(Ax),–(Ay)<br />
If condition true<br />
Scc<br />
then 1s ˘ Destination<br />
else 0s ˘ Destination<br />
Scc <br />
If supervisor state<br />
STOP<br />
then Immediate Data ˘ SR; STOP<br />
else TRAP<br />
STOP #<br />
SUB Destination – Source ˘ Destination<br />
SUB ,Dn<br />
SUB Dn,<br />
SUBA Destination – Source ˘ Destination SUBA ,An<br />
SUBI Destination – Immediate Data ˘ Destination SUBI #,<br />
SUBQ Destination – Immediate Data ˘ Destination SUBQ #,<br />
SUBX Destination – Source – X ˘ Destination<br />
SUBX Dx,Dy<br />
SUBX –(Ax),–(Ay)<br />
SWAP Register 31–16 ¯ ˘ Register 15–0 SWAP Dn<br />
TAS<br />
Destination Tested ˘ Condition Codes;<br />
1 ˘ bit 7 of Destination<br />
TAS <br />
SSP – 2 ˘ SSP; Format ÷ Offset ˘ (SSP);<br />
TRAP SSP – 4 ˘ SSP; PC ˘ (SSP); SSP – 2 ˘ SSP;<br />
SR ˘ (SSP); Vector Address ˘ PC<br />
TRAP #<br />
TRAPcc<br />
If cc<br />
then TRAP<br />
TRAPcc<br />
TRAPcc.W #<br />
TRAPcc.L #<br />
TRAPV<br />
If V<br />
then TRAP<br />
TRAPV<br />
TST Destination Tested ˘ Condition Codes TST <br />
UNLK An ˘ SP; (SP) ˘ An; SP + 4 ˘ SP UNLK An<br />
UNPK<br />
Table 1-3. Instruction Set Summary (Continued)<br />
Opcode Operation Syntax<br />
Source (Packed BCD) + adjustment ˘ Destination (Unpacked<br />
BCD)<br />
UNPACK –(Ax),–(Ay),#(adjustment)<br />
UNPACK Dx,Dy,#(adjustment)<br />
1-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Table 1-3. Instruction Set Summary (Continued)<br />
1.10 NOTATIONAL CONVENTIONS<br />
Table 1-4 lists the notation conventions used throughout this manual.<br />
Introduction<br />
Opcode Operation Syntax<br />
NOTES:<br />
1.Where d is direction, left or right.<br />
2.Emulation support only, not supported in hardware.<br />
3.Where r is rounding precision, single or double precision.<br />
4.List refers to register.<br />
5.List refers to control registers only.<br />
6.MOVE16 (ax)+,(ay)+ is functionally the same as MOVE16 (ax),(ay)+ when ax = ay. The address register is<br />
only incremented once, and the line is copied over itself rather than to the next line.<br />
7.Not available for the MC68EC060.<br />
8.Emulation support for misaligned operands.<br />
9.Emulation support for FMCVEM with dynamic register list.<br />
Table 1-4. Notational Conventions<br />
Single- And Double-Operand Operations<br />
+ Arithmetic addition or postincrement indicator.<br />
– Arithmetic subtraction or predecrement indicator.<br />
× Arithmetic multiplication.<br />
÷ Arithmetic division or conjunction symbol.<br />
~ Invert; operand is logically complemented.<br />
• Logical AND<br />
+ Logical OR<br />
⊕ Logical exclusive OR<br />
˘ Source operand is moved to destination operand.<br />
¯ ˘ Two operands are exchanged.<br />
Any double-operand operation.<br />
tested Operand is compared to zero and the condition codes are set appropriately.<br />
sign-extended All bits of the upper portion are made equal to the high-order bit of the lower portion.<br />
Other Operations<br />
Equivalent to Format ÷ Offset Word<br />
TRAP<br />
˘ (SSP); SSP – 2 ˘ SSP; PC ˘ (SSP); SSP – 4 ˘ SSP; SR ˘<br />
(SSP); SSP – 2 ˘ SSP; (Vector) ˘ PC<br />
STOP Enter the stopped state, waiting for interrupts.<br />
10 The operand is BCD; operations are performed in decimal.<br />
If <br />
then <br />
else <br />
Test the condition. If true, the operations after “then” are performed. If the condition is false and<br />
the optional “else” clause is present, the operations after “else” are performed. If the condition is<br />
false and else is omitted, the instruction performs no operation. Refer to the Bcc instruction description<br />
as an example.<br />
Register Specification<br />
An Any Address Register n (example: A3 is address register 3)<br />
Ax, Ay Source and destination address registers, respectively.<br />
BR Base Register—An, PC, or suppressed.<br />
Dc Data register D7–D0, used during compare.<br />
Dh, Dl Data registers high- or low-order 32 bits of product.<br />
Dn Any Data Register n (example: D5 is data register 5)<br />
Dr, Dq Data register’s remainder or quotient of divide.<br />
Du Data register D7–D0, used during update.<br />
Dx, Dy Source and destination data registers, respectively.<br />
MRn Any Memory Register n.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 1-21
Introduction<br />
Table 1-4. Notational Conventions (Continued)<br />
Rn Any Address or Data Register<br />
Rx, Ry Any source and destination registers, respectively.<br />
Xn Index Register—An, Dn, or suppressed.<br />
Data Format and Type<br />
+ inf Positive Infinity<br />
<br />
Operand Data Format: Byte (B), Word (W), Long (L), Single (S), Double (D), Extended (X), or<br />
Packed (P).<br />
B, W, L Specifies a signed integer data type (twos complement) of byte, word, or long word.<br />
D Double-precision real data format (64 bits).<br />
k<br />
A twos complement signed integer (–64 to +17) specifying a number’s format to be stored in the<br />
packed decimal format.<br />
P Packed BCD real data format (96 bits, 12 bytes).<br />
S Single-precision real data format (32 bits).<br />
X Extended-precision real data format (96 bits, 16 bits unused).<br />
– inf Negative Infinity<br />
Subfields and Qualifiers<br />
# or # Immediate data following the instruction word(s).<br />
( ) Identifies an indirect address in a register.<br />
[ ] Identifies an indirect address in memory.<br />
bd Base Displacement<br />
dn<br />
Displacement Value, n Bits Wide (example: d16 is a 16-bit displacement).<br />
LSB Least Significant Bit<br />
LSW Least Significant Word<br />
MSB Most Significant Bit<br />
MSW Most Significant Word<br />
od Outer Displacement<br />
SCALE A scale factor (1, 2, 4, or 8, for no-word, word, long-word, or quad-word scaling, respectively).<br />
SIZE The index register’s size (W for word, L for long word).<br />
{offset:width} Bit field selection.<br />
Register Codes<br />
* General Case.<br />
C Carry Bit in CCR<br />
cc Condition Codes from CCR<br />
FC Function Code<br />
N Negative Bit in CCR<br />
U Undefined, Reserved for Motorola Use.<br />
V Overflow Bit in CCR<br />
X Extend Bit in CCR<br />
Z Zero Bit in CCR<br />
— Not Affected or Applicable.<br />
Miscellaneous<br />
Effective Address<br />
Assemble Program Label<br />
List of registers, for example D3–D0.<br />
LB Lower Bound<br />
m Bit m of an Operand<br />
m–n Bits m through n of Operand<br />
UB Upper Bound<br />
1-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
SECTION 2<br />
SIGNAL DESCRIPTION<br />
This section contains brief descriptions of the MC68060 signals in their functional groups<br />
(see Figure 2-1). Each signal’s function is briefly explained, referencing other sections containing<br />
detailed information about the signal and related operations. Table 2-1 lists the<br />
MC68060 signal names, mnemonics, and functional descriptions of the signals. Timing<br />
specifications for these signals can be found in Section 12 Electrical and Thermal Characteristics.<br />
MOTOROLA<br />
NOTE<br />
Assertion and negation are used to specify forcing a signal to a<br />
particular state. Assertion and assert refer to a signal that is active<br />
or true. Negation and negate refer to a signal that is inactive<br />
or false. These terms are used independently of the voltage level<br />
(high or low) that they represent.<br />
Table 2-1. Signal Index<br />
Signal Name Mnemonic Function<br />
Address Bus A31–A0 32-bit address bus used to address any of 4-Gbytes.<br />
Cycle Long-Word Address<br />
CLA Controls the operation of A3 and A2 during bus cycles.<br />
Data Bus D31–D0 32-bit data bus used to transfer up to 32 bits of data per bus transfer.<br />
Transfer Type TT1,TT0<br />
Indicates the general transfer type: normal, MOVE16, alternate logical function<br />
code, and acknowledge.<br />
Transfer Modifier TM2–TM0 Indicates supplemental information about the access.<br />
Transfer Line Number TLN1,TLN0<br />
Indicates which cache line in a set is being pushed or loaded by the current line<br />
transfer cycle.<br />
User-Programmable<br />
Attributes<br />
UPA1,UPA0<br />
User-defined signals, controlled by the corresponding user attribute bits from the<br />
address translation entry.<br />
Read/Write R/W Identifies the transfer as a read or write.<br />
Indicates the data transfer size. These signals, together with A0 and A1,<br />
Transfer Size SIZ1,SIZ0 define the active sections of the data bus. Alternately, BS3–BS0 can be used for<br />
this function.<br />
Bus Lock LOCK<br />
Indicates a bus cycle is part of a read-modify-write operation and that the<br />
sequence of bus cycles should not be interrupted.<br />
Bus Lock End LOCKE Indicates the current bus cycle is the last in a locked sequence of bus cycles.<br />
Cache Inhibit Out CIOUT Indicates the processor will not cache the current bus transfer information.<br />
Byte Select BS3–BS0<br />
Indicate which bytes within a long word are selected and which data bus bytes<br />
are valid.<br />
Transfer Start TS Indicates the beginning of a bus cycle.<br />
Transfer in Progress TIP Asserted for the duration of a bus cycle.<br />
Starting Termination Acknowledge<br />
Signal Sampling<br />
SAS Indicates the MC68060 will begin sampling the termination acknowledge signals.<br />
Transfer Acknowledge TA Asserted to acknowledge a bus transfer.<br />
<strong>M68060</strong> USER’S MANUAL<br />
2-1
Signal Description<br />
Transfer Retry Acknowledge<br />
TRA Indicates the need to rerun the bus cycle.<br />
Transfer Error Acknowledge<br />
TEA Indicates an error condition exists for a bus transfer.<br />
Transfer Cycle Burst Inhibit<br />
TBI Indicates the slave cannot handle a line burst access.<br />
Transfer Cache Inhibit TCI Indicates the current bus transfer should not be cached.<br />
Snoop Control SNOOP Indicates the MC68060 should snoop bus activity while it is not the bus master.<br />
Bus Request BR Asserted by the processor to request bus mastership.<br />
Bus Grant BG Asserted by an arbiter to grant bus mastership privileges to the processor.<br />
Bus Grant Relinquish<br />
Control<br />
2-2<br />
BGR<br />
Bus Tenure Termination BTT<br />
Bus Busy BB<br />
Qualifies BG by indicating the degree of necessity for relinquishing bus ownership<br />
when BG is negated.<br />
Indicates the MC68060 has relinquished the bus in response to the external arbiter’s<br />
negation of BG.<br />
Asserted by the current bus master to indicate it has assumed ownership of the<br />
bus.<br />
Cache Disable CDIS Dynamically disables the internal caches to assist emulator support.<br />
MMU Disable MDIS Disables the translation mechanism of the MMUs.<br />
Reset In RSTI Processor reset.<br />
Reset Out RSTO Asserted during execution of a RESET instruction to reset external devices.<br />
Interrupt Priority Level IPL2–IPL0 Provides an encoded interrupt level to the processor.<br />
Interrupt Pending IPEND Indicates an interrupt is pending.<br />
Autovector AVEC<br />
Used during an interrupt acknowledge transfer to request internal generation of<br />
the vector number.<br />
Processor Status PST4–PST0 Indicates internal processor status.<br />
Processor Clock CLK Clock input used for all internal logic timing.<br />
Clock Enable CLKEN<br />
Defines the speed of the system bus clock to be full, 1/2, or 1/4 the speed of the<br />
processor clock.<br />
JTAG Enable JTAG<br />
Selects between IEEE 1149.1 compliance operation and emulation mode operation.<br />
Test Clock TCK Clock signal for the IEEE P1149.1 test access port (TAP).<br />
Test Mode Select TMS Selects the principal operations of the test-support circuitry.<br />
Test Data Input TDI Serial data input for the TAP.<br />
Test Data Output TDO Serial data output for the TAP.<br />
Test Reset TRST Provides an asynchronous reset of the TAP controller.<br />
Thermal Resistor Connections<br />
THERM1,<br />
THERM0<br />
Table 2-1. Signal Index (Continued)<br />
Signal Name Mnemonic Function<br />
Provides thermal sensing information.<br />
Power Supply VCC Power supply.<br />
Ground GND Ground connection.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
2.1 ADDRESS AND CONTROL SIGNALS<br />
The following paragraphs describe the MC68060 address and control signals.<br />
2.1.1 Address Bus (A31–A0)<br />
MOTOROLA<br />
ADDRESS BUS<br />
AND CONTROL<br />
DATA BUS D31–D0<br />
TRANSFER<br />
ATTRIBUTES<br />
MASTER<br />
TRANSFER<br />
CONTROL<br />
SLAVE<br />
TRANSFER<br />
CONTROL<br />
A31–A0<br />
CLA<br />
TT1<br />
TT0<br />
TM2<br />
TM1<br />
TM0<br />
TLN1<br />
TLN0<br />
UPA1<br />
UPA0<br />
R/W<br />
SIZ1<br />
SIZ0<br />
LOCK<br />
LOCKE<br />
CIOUT<br />
BS0<br />
BS1<br />
BS2<br />
BS3<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
TRA<br />
TEA<br />
TBI<br />
TCI<br />
MC68060<br />
Figure 2-1. Functional Signal Groups<br />
<strong>M68060</strong> USER’S MANUAL<br />
Signal Description<br />
These three-state bidirectional signals provide the address of the first item of a bus transfer<br />
(except for interrupt acknowledge transfers) when the MC68060 is the bus master. When an<br />
alternate bus master is controlling the bus and asserts the SNOOP signal, the address sig-<br />
SNOOP<br />
BR<br />
BG<br />
BGR<br />
BB<br />
BTT<br />
CDIS<br />
MDIS<br />
RSTI<br />
RSTO<br />
IPL2<br />
IPL1<br />
IPL0<br />
IPEND<br />
AVEC<br />
PST4<br />
PST3<br />
PST2<br />
PST1<br />
PST0<br />
CLK<br />
CLKEN<br />
JTAG<br />
TCK<br />
TMS<br />
TDI<br />
TDO<br />
TRST<br />
THERM1<br />
THERM0<br />
VCC<br />
GND<br />
BUS SNOOP CONTROL<br />
BUS ARBITRATION<br />
CONTROL<br />
PROCESSOR<br />
CONTROL<br />
INTERRUPT<br />
CONTROL<br />
STATUS AND<br />
CLOCKS<br />
TEST<br />
THERMAL RESISTOR<br />
CONNECTIONS<br />
POWER SUPPLY<br />
2-3
Signal Description<br />
nals are examined to determine whether the processor should invalidate matching cache<br />
entries to maintain cache coherency.<br />
2.1.2 Cycle Long-Word Address (CLA)<br />
This active-low input signal controls the operation of A3 and A2 during bus cycles. Following<br />
each clock-enabled clock edge in which CLA is asserted, the long-word address for each of<br />
the four transfers encoded on A3 and A2 will increment in a circular wraparound fashion. If<br />
CLA is negated during a clock-enabled clock edge, the values on A3 and A2 will not change.<br />
It is not necessary to synchronize CLA with TA.<br />
2.2 DATA BUS (D31–D0)<br />
These three-state bidirectional signals provide the general-purpose data path between the<br />
MC68060 and all other devices. The data bus can transfer 8, 16, or 32 bits of data per bus<br />
transfer. During a burst bus cycle, the 128 bits of line information are transferred using four<br />
32-bit transfers.<br />
2.3 TRANSFER ATTRIBUTE SIGNALS<br />
The following paragraphs describe the transfer attribute signals, which provide additional<br />
information about the bus transfer cycle. Refer to Section 7 Bus Operation for detailed<br />
information about the relationship of the transfer attribute signals to bus operation.<br />
2.3.1 Transfer Cycle Type (TT1, TT0)<br />
The processor drives these three-state signals to indicate the type of access for the current<br />
bus cycle. During bus cycle transfers by an alternate bus master when the processor is<br />
allowed to snoop bus transactions, TT1 is sampled. Only normal and MOVE16 accesses<br />
can be snooped. Table 2-2 lists the definition of the TTx encoding. The acknowledge access<br />
(TT1 = 1 and TT0 = 1) is used for interrupt acknowledge, breakpoint acknowledge, and lowpower<br />
stop broadcast bus cycles.<br />
2.3.2 Transfer Cycle Modifier (TM2–TM0)<br />
These three-state outputs provide supplemental information for each transfer cycle type.<br />
Table 2-3 lists the encoding for normal (TTx = 00) and MOVE16 (TTx = 01) transfers, and<br />
Table 2-4 lists the encoding for alternate access transfers (TTx = 10). For interrupt acknowledge<br />
transfers, the TMx signals carry the interrupt level being acknowledged. For breakpoint<br />
2-4<br />
Table 2-2. Transfer-Type Encoding<br />
TT1 TT0 Transfer Type<br />
0 0 Normal Access<br />
0 1 MOVE16 Access<br />
1 0<br />
Alternate Logical Function Code Access, Debug<br />
Access<br />
1 1<br />
Acknowledge Access, Low-Power Stop<br />
Broadcast<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Signal Description<br />
acknowledge transfers and low-power stop broadcast cycles, the TMx signals are negated.<br />
When the MC68060 is not the bus master, the TMx signals are in a high-impedance state.<br />
2-5
Signal Description<br />
2-6<br />
Table 2-3. Normal and MOVE16 Access TMx Encoding<br />
TM2 TM1 TM0 Transfer Modifier<br />
0 0 0 Data Cache Push Access<br />
0 0 1 User Data Access*<br />
0 1 0 User Code Access<br />
0 1 1 MMU Table Search Data Access<br />
1 0 0 MMU Table Search Code Access<br />
1 0 1 Supervisor Data Access*<br />
1 1 0 Supervisor Code Access<br />
1 1 1 Reserved<br />
*MOVE16 accesses use only these encodings.<br />
Table 2-4. Alternate Access TMx Encoding<br />
TM2 TM1 TM0 Transfer Modifier<br />
0 0 0 Logical Function Code 0<br />
0 0 1 Debug Access<br />
0 1 0 Reserved<br />
0 1 1 Logical Function Code 3<br />
1 0 0 Logical Function Code 4<br />
1 0 1 Debug Pipe Control Mode Access<br />
1 1 0 Debug Pipe Control Mode Access<br />
1 1 1 Logical Function Code 7<br />
2.3.3 Transfer Line Number (TLN1, TLN0)<br />
These three-state outputs indicate which line in the set of four data or instruction cache lines<br />
is being accessed for normal push and line data read accesses. TLNx signals are undefined<br />
for all other accesses and are placed in a high-impedance state when the processor is not<br />
the bus master.<br />
The TLNx signals can be used in high-performance systems to build an external snoop filter<br />
with a duplicate set of cache tags. The TLNx signals and address bus provide a direct indication<br />
of the state of the data caches and can be used to help maintain the duplicate tag<br />
store. The TLNx signals do not indicate the correct TLN number when an instruction cache<br />
burst fill occurs.<br />
2.3.4 User-Programmable Page Attributes (UPA1, UPA0)<br />
The UPAx signals are three-state outputs. These signals are only valid for normal code,<br />
data, and MOVE16 accesses. For all other accesses (including table search and cache line<br />
push accesses), the UPAx signals are low. When the MC68060 is not the bus master, these<br />
signals are placed in a high-impedance state.<br />
During normal and MOVE16 accesses, if a transparent translation register (TTR) is enabled<br />
and the address and attributes match the TTR values, the UPAx signals are defined by the<br />
logical values of the U1 and U0 bits the TTR. If the MMU is enabled via the translation control<br />
register (TCR) and the address and attributes result in an address translation cache (ATC)<br />
hit, the UPAx signals are defined by the logical values of the U1 and U0 bits in the ATC entry.<br />
If a given logical address is not mapped by the TTRs and if address translation is disabled,<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Signal Description<br />
then the MC68060 invokes default transparent translation. The cache mode, user page<br />
attributes, and other TTR fields for the default translation are defined by the contents of the<br />
TCR. For more information about the UPAx signals, refer to Section 4 Memory Management<br />
Unit.<br />
2.3.5 Read/Write (R/W)<br />
This three-state output signal defines the data transfer direction for the current bus cycle. A<br />
high (logic one) level indicates a read cycle, and a low (logic zero) level indicates a write<br />
cycle. This signal is placed in a high-impedance state when the MC68060 is not the bus<br />
master.<br />
2.3.6 Transfer Size (SIZ1, SIZ0)<br />
These three-state output signals indicate the data size for the bus cycle. These signals are<br />
placed in a high-impedance state when the MC68060 is not the bus master. Table 2-5<br />
shows the definitions of the SIZx encoding.<br />
2.3.7 Bus Lock (LOCK)<br />
This three-state output indicates that the current bus cycle is part of a sequence of locked<br />
bus cycles. An external arbiter can use LOCK with its control of an alternate bus master’s<br />
BG to prevent an alternate bus master from gaining control of the bus and accessing the<br />
same operand between processor accesses for the locked sequence of transfers. Although<br />
LOCK indicates that the processor requests that the bus be locked, the processor will relinquish<br />
the bus if the external arbiter negates BG and asserts BGR.<br />
When the MC68060 is not the bus master, the LOCK signal is set to a high-impedance state.<br />
If the MC68060 relinquishes the bus while LOCK is asserted, LOCK will be negated for one<br />
full clock-enabled clock cycle and then three-stated one clock-enabled clock cycle after the<br />
address bus is idled. If LOCK was already negated in the clock cycle in which the MC68060<br />
relinquishes the bus, it will be three-stated in the same clock cycle the address bus is idled.<br />
Refer to Section 7 Bus Operation for information on locked transfers.<br />
2.3.8 Bus Lock End (LOCKE)<br />
Table 2-5. SIZx Encoding<br />
SIZ1 SIZ0 Transfer Size<br />
0 0 Long Word (4 Bytes)<br />
0 1 Byte<br />
1 0 Word (2 Bytes)<br />
1 1 Line (16 Bytes)<br />
This three-state output indicates that the current bus cycle is the last in a sequence of locked<br />
bus cycles (except in the case in which a retry termination is indicated on the last write of a<br />
read-modify-write sequence).<br />
When the MC68060 is not the bus master, the LOCKE signal is set to a high-impedance<br />
state. If the MC68060 relinquishes the bus while LOCKE is asserted, LOCKE will be negated<br />
2-7
Signal Description<br />
for one full BCLK cycle and then three-stated one BCLK cycle after the address bus is idled.<br />
If LOCKE was already negated in the BCLK cycle in which the MC68060 relinquishes the<br />
bus, it will be three-stated in the same BCLK cycle the address bus is idled.<br />
LOCKE is provided to help make the MC68060 bus compatible with the MC68040-style bus<br />
protocol; however, for new designs, external bus arbitration logic can be simplified with the<br />
use of BGR instead of LOCKE.<br />
Do not use LOCKE. The LOCKE protocol breaks the integrity of the locked read-modifywrite<br />
sequence if it is possible to retry the last write of a read-modify-write operation. The<br />
reason is that when LOCKE is asserted, a bus arbiter can grant the bus to an alternate master<br />
when the current bus cycle is finished (before the retry is attempted). The bus is arbitrated<br />
away, the last write’s retry is deferred until the bus is returned to the processor. In the<br />
meantime, the alternate master can access the same location where the write should have<br />
taken place. Hence, the integrity of the locked read-modify-write sequence is compromised<br />
in this situation.<br />
2.3.9 Cache Inhibit Out (CIOUT)<br />
When asserted, this three-state output indicates that the MC68060 will not cache the current<br />
bus information in its internal caches. Refer to Section 4 Memory Management Unit for<br />
more information on CIOUT function. When the MC68060 is not the bus master, the CIOUT<br />
signal is placed in a high-impedance state.<br />
2.3.10 Byte Select Lines (BS3–BS0)<br />
These three-state outputs indicate which bytes within a long-word transfer are being<br />
selected and which bytes of the data bus will be used for the transfer. BS0 refers to D31–<br />
D24, BS1 refers to D23–D16, BS2 refers to D15–D8, and BS3 refers to D7–D0. These signals<br />
are generated to provide byte data select signals which are decoded from the SIZx, A1,<br />
and A0 signals as shown in Table 2-6. These signals are placed in a high-impedance state<br />
when the MC68060 is not the bus master.<br />
2.4 MASTER TRANSFER CONTROL SIGNALS<br />
The following signals provide control functions for bus cycles when the MC68060 is the bus<br />
master. Refer to Section 7 Bus Operation for detailed information about the relationship<br />
of the bus cycle control signals to bus operation.<br />
2-8<br />
Table 2-6. Data Bus Byte Select Signals<br />
Transfer Size SIZ1 SIZ0 A1 A0<br />
BS0<br />
D31–D24<br />
BS1<br />
D23–D16<br />
BS2<br />
D15–D8<br />
BS3<br />
D7–D0<br />
Byte 0 1 0 0 0 1 1 1<br />
Byte 0 1 0 1 1 0 1 1<br />
Byte 0 1 1 0 1 1 0 1<br />
Byte 0 1 1 1 1 1 1 0<br />
Word 1 0 0 0 0 0 1 1<br />
Word 1 0 1 0 1 1 0 0<br />
Long Word 0 0 x x 0 0 0 0<br />
Line 1 1 x x 0 0 0 0<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
2.4.1 Transfer Start (TS)<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Signal Description<br />
The processor asserts this three-state bidirectional signal for one clock-enabled clock period<br />
to indicate the start of each bus cycle. During alternate bus master accesses, the processor<br />
monitors TS and SNOOP to detect the start of each bus cycle which is to be snooped. TS<br />
is placed in a high-impedance state when the MC68060 is not the bus master. To properly<br />
maintain internal state information, all masters on the bus must have their TS signals tied<br />
together.<br />
2.4.2 Transfer in Progress (TIP)<br />
This three-state output is asserted to indicate that a bus cycle is in progress and is negated<br />
during idle bus cycles if the bus is still granted to the processor. TIP remains asserted during<br />
the time between back-to-back bus cycles.<br />
If the MC68060 relinquishes the bus while TIP is asserted, TIP will be negated for one clock<br />
period after completion of the final transfer and then goes to a high-impedance state one<br />
clock period after the address is idled. Note that this one clock period in which TIP is driven<br />
negated refers to an MC68060 processor clock period, not a full clock-enabled clock period.<br />
If TIP was already negated in the clock period in which the MC68060 relinquishes the bus,<br />
it will be placed in a high-impedance state in the same clock period that the address bus<br />
becomes idle.<br />
2.4.3 Starting Termination Acknowledge Signal Sampling (SAS)<br />
This three-state output is asserted for one clock-enabled clock period to indicate that the<br />
MC68060 will begin sampling TA, TEA, TRA, TBI, TCI, AVEC, and spurious interrupt indication<br />
on the next rising edge of the clock-enabled clock. SAS is negated at all other times<br />
while the MC68060 is the bus master. When the MC68060 relinquishes the bus, SAS is<br />
driven negated for one clock-enabled clock period and then three-stated one clock-enabled<br />
clock period after the address bus is idled. When the MC68060 newly gains bus ownership<br />
and immediately starts a bus cycle with the assertion of TS, SAS remains three-stated until<br />
the clock-enabled clock period after TS is asserted.<br />
2.5 SLAVE TRANSFER CONTROL SIGNALS<br />
The following signals provide control functions for bus transfers when the MC68060 is not<br />
the bus master. Refer to Section 7 Bus Operation for detailed information about the relationship<br />
of the bus cycle control signals to bus operation.<br />
2.5.1 Transfer Acknowledge (TA)<br />
This input indicates the completion of a requested data transfer operation. During transfers<br />
by the MC68060, TA is an input signal from the referenced slave device indicating completion<br />
of the transfer. For the MC68060 to accept the transfer as successful with a transfer<br />
acknowledge, TRA and TEA must be negated when TA is asserted.<br />
2.5.2 Transfer Retry Acknowledge (TRA)<br />
For native-MC68060-style (non-MC68040-style) acknowledge termination, this input signal<br />
may be asserted by the current slave on the first transfer of a bus cycle to indicate the need<br />
2-9
Signal Description<br />
to rerun the current bus cycle. The assertion of TRA on any transfer other than the first transfer<br />
is ignored. The assertion of TRA has precedence over TA, but does not have precedence<br />
over TEA.<br />
If the MC68060 processor is to be used with MC68040-style acknowledge termination, then<br />
TRA must be held negated. In this case, TEA does not have precedence over TA and the<br />
slave must assert both TEA and TA on the first transfer of a bus cycle to cause a retry of the<br />
current bus cycle. The assertion of TEA and TA on any transfer other than the first will be<br />
interpreted by the MC68060 as if only TEA had been asserted, which immediately terminates<br />
the bus cycle with a bus error indication.<br />
2.5.3 Transfer Error Acknowledge (TEA)<br />
The current slave asserts this input signal to indicate an error condition for the current transfer<br />
to immediately terminate the bus cycle. The assertion of TEA has precedence over TRA<br />
and TA for native-MC68060-style acknowledgment termination.<br />
For MC68040-style acknowledge termination, TEA must be asserted with TA negated to<br />
cause the current bus cycle to immediately terminate with a bus error indication. For<br />
MC68040-style acknowledge termination, TRA must be held negated.<br />
2.5.4 Transfer Burst Inhibit (TBI)<br />
This input signal indicates to the processor that the device cannot support burst mode<br />
accesses and that the requested line transfer cycle should be divided into individual longword<br />
bus cycles. Asserting TBI with TA terminates the first data transfer of a line access,<br />
causing the processor to terminate the burst bus cycle and access the remaining data for<br />
the line as three successive long-word transfer cycles.<br />
2.5.5 Transfer Cache Inhibit (TCI)<br />
This input signal inhibits line read data from being loaded into the MC68060 instruction or<br />
data caches. TCI is ignored during all writes and after the first data transfer for both burst<br />
line reads and burst-inhibited line reads. TCI is also ignored during all alternate bus master<br />
transfers.<br />
2.6 SNOOP CONTROL (SNOOP)<br />
This input signal controls the operation of the MC68060 internal snoop logic. The MC68060<br />
examines SNOOP when TS is asserted by an alternate master controlling the bus. If snooping<br />
is disabled (i.e., SNOOP negated) during the clock when TS is asserted, the MC68060<br />
will not snoop the bus transaction. If snooping is enabled (i.e., SNOOP asserted) during the<br />
clock when TS is asserted, the MC68060 will snoop the access and invalidate matching<br />
cache lines for either read or write bus cycles without any external indication that a cache<br />
entry has been invalidated upon cache snoop hits.<br />
Section 5 Caches provides information about the relationship of SNOOP to the caches,<br />
and Section 7 Bus Operation discusses the relationship of SNOOP to bus operation.<br />
2-10<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
2.7 ARBITRATION SIGNALS<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Signal Description<br />
The following control signals support bus mastership control by an external arbiter over the<br />
MC68060. Refer to Section 7 Bus Operation for detailed information about the relationship<br />
of the arbitration signals to bus operation.<br />
2.7.1 Bus Request (BR)<br />
This output signal indicates to an external arbiter that the processor needs to become bus<br />
master for one or more bus cycles. BR is negated when the MC68060 begins an access to<br />
the external bus with no other internal accesses pending, and BR remains negated until<br />
another internal request occurs. The assertion and negation of BR are independent of bus<br />
activity and there are some situations in which the MC68060 asserts BR and then negates<br />
it without having run a bus cycle; this is a disregard request condition. Refer to Section 7<br />
Bus Operation for details about this state.<br />
2.7.2 Bus Grant (BG)<br />
This input signal from an external arbiter indicates that the bus is available to the MC68060<br />
as soon as the current bus cycle completes. The MC68060 assumes bus ownership when<br />
BG is asserted and BB is negated, when BG is asserted and a TS-BTT pair (TS asserted,<br />
followed by BTT asserted) has occurred in the past without another assertion of TS, or when<br />
BG and BTT are asserted and TS is negated. The MC68060 indicates its ownership of the<br />
bus by asserting BB. When the external arbiter negates BG, the MC68060 relinquishes the<br />
bus as soon as the current bus cycle is complete unless a locked sequence of bus cycles is<br />
in progress with BGR negated. In this case, the MC68060 will complete the entire sequence<br />
of locked bus cycles and then indicate that it is relinquishing the bus by asserting BTT and<br />
negating BB.<br />
2.7.3 Bus Grant Relinquish Control (BGR)<br />
This input signal is a qualifier for BG and indicates to the MC68060 the degree of necessity<br />
for relinquishing bus ownership when BG is negated by an external arbiter. BGR controls<br />
MC68060 behavior when BG is negated during sequences of locked bus cycles (LOCK<br />
asserted). When the external arbiter negates BG during a series of locked bus cycles, the<br />
assertion of BGR will cause the MC68060 to relinquish the bus on the last transfer of the<br />
current bus cycle, even though the MC68060 had intended the series to be locked. If BGR<br />
remains negated when BG is negated during locked transfers, then the MC68060 will not<br />
relinquish the bus until the series of locked bus cycles is complete.<br />
2.7.4 Bus Tenure Termination (BTT)<br />
This three-state bidirectional signal is asserted for one clock-enabled clock period and<br />
negated for one clock-enabled clock period to indicate that the MC68060 has relinquished<br />
its bus tenure following the negation of BG by an external arbiter. At all other times, BTT is<br />
in a high-impedance state. When an alternate master is controlling the bus, the MC68060<br />
samples BTT as an input to maintain internal state information and to monitor when the<br />
MC68060 may become the bus master. To properly maintain this internal state information,<br />
all masters on the bus must have their TS signals tied together and their BTT signals tied<br />
together so the MC68060 can keep track of TS-BTT pairs.<br />
2-11
Signal Description<br />
The MC68060 provides the BB signal and protocol to provide compatibility with MC68040style<br />
buses. Either the BTT signal and protocol or the BB signal and protocol (but not both)<br />
should be used. The unused signal, either BTT or BB, must be pulled up with a pullup resistor<br />
and tied to VCC.<br />
Use of the BTT signal and protocol yields higher performance at full bus<br />
speed and high operating frequencies. The use of BB and its associated protocol is not recommended<br />
at full bus speeds. The BTT protocol is discussed in detail in Section 7 Bus Operation.<br />
2.7.5 Bus Busy (BB)<br />
This three-state bidirectional signal indicates that the bus is currently owned. BB is monitored<br />
as a processor input to determine when an alternate bus master has released control<br />
of the bus. The MC68060 samples bus availability on each clock-enabled clock edge. BG<br />
must be asserted and both TS and BB must be negated (indicating the bus is free) before<br />
the MC68060 asserts BB (with the first assertion of TS) as an output to assume ownership<br />
of the bus. The processor keeps BB asserted until the external arbiter negates BG and the<br />
processor completes the bus cycle in progress. When releasing the bus, the processor<br />
negates BB for one clock period, then places it in a high-impedance state and begins to<br />
sample it as an input. Note that the one clock period in which BB is negated is one MC68060<br />
processor clock period, not a full clock-enabled clock period.<br />
The MC68060 provides the BB signal and protocol to support compatibility with MC68040style<br />
buses. Either the BTT signal and protocol or the BB signal and protocol (but not both)<br />
should be used. The unused signal, either BTT or BB, must be pulled up through a pullup<br />
resistor and tied to V CC . Use of the BTT signal and protocol yields higher performance at full<br />
bus speed and high operating frequencies. The use of BB and its associated protocol is not<br />
recommended at full bus speeds. The BTT protocol is discussed in detail in Section 7 Bus<br />
Operation.<br />
2.8 PROCESSOR CONTROL SIGNALS<br />
The following signals control the caches and MMUs and support processor and external<br />
device initialization.<br />
2.8.1 Cache Disable (CDIS)<br />
When asserted, this input signal dynamically disables the on-chip caches on the next internal<br />
cache access boundary. The caches are enabled on the next boundary after CDIS is<br />
negated.<br />
CDIS does not flush the data and instruction caches. Cache entries remain unaltered and<br />
become available after CDIS is negated, unless one of the cache invalidate instructions<br />
(CINVA, CINVP, CINVL) are executed. The execution of one of the cache invalidate instructions<br />
may invalidate entries even if the caches have been disabled with this signal. The<br />
assertion of CDIS does not affect snooping.<br />
Refer to Section 5 Caches for information about the caches.<br />
2-12<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
2.8.2 MMU Disable (MDIS)<br />
Signal Description<br />
When asserted, this input signal dynamically disables the MC68060 internal operand data<br />
and instruction MMUs on the next internal access boundary. While MDIS is asserted, all<br />
accesses bypass the MMU ATCs, and thus translate transparently. The execution of one of<br />
the MMU flush instructions (PFLUSHA, PFLUSHAN, PFLUSH, PFLUSHN) may cause the<br />
deletion of the MMU entries, even if the MMU has been disabled by this signal. The MMUs<br />
are enabled on the next boundary after MDIS is negated. Refer to Section 4 Memory Management<br />
Unit for a description of address translation.<br />
2.8.3 Reset In (RSTI)<br />
The assertion of this input signal causes the MC68060 to enter reset exception processing.<br />
The RSTI signal is an asynchronous input that is internally synchronized to the next rising<br />
clock-enabled clock (CLK) edge. All three-state signals will eventually be set to the highimpedance<br />
state when RSTI is recognized. The assertion of RSTI does not affect the test<br />
pins. Refer to Section 7 Bus Operation for a description of reset operation and to Section<br />
8 Exception Processing for information about the reset exception.<br />
2.8.4 Reset Out (RSTO)<br />
The MC68060 asserts this output during execution of the RESET instruction to initialize<br />
external devices. All bus cycles by the MC68060 are suspended prior to the assertion of<br />
RSTO, but bus arbitration and snooping still function. Refer to Section 7 Bus Operation for<br />
a description of reset out bus operation.<br />
2.9 INTERRUPT CONTROL SIGNALS<br />
The following signals control the interrupt functions.<br />
2.9.1 Interrupt Priority Level (IPL2–IPL0)<br />
These input signals provide an indication of an interrupt condition with the interrupt level<br />
from a peripheral or external prioritizing circuitry encoded. IPL2 is the most significant bit of<br />
the level number. For example, since the IPLx signals are active low, IPL2–IPL0 = 101 corresponds<br />
to an interrupt request at interrupt priority level 2. IPL2–IPL0 = 000 (level 7) is the<br />
highest priority interrupt and cannot be internally masked. IPL2–IPL0 = 111 (level 0) indicates<br />
no interrupt is requested. The IPLx signals are asynchronous inputs that are internally<br />
synchronized to rising clock (CLK) edges.<br />
During a processor reset, the levels on the IPLx lines are registered and used to configure<br />
the various operating modes for the MC68060 bus. Refer to Section 7 Bus Operation for<br />
more information on bus operating modes and Section 8 Exception Processing for information<br />
on interrupts.<br />
2.9.2 Interrupt Pending Status (IPEND)<br />
This output signal indicates that an interrupt request has been recognized internally by the<br />
processor and exceeds the current interrupt priority mask in the status register (SR). External<br />
devices (other bus masters) can use IPEND to predict processor operation on the next<br />
instruction boundaries. IPEND is not intended for use as an interrupt acknowledge to exter-<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 2-13
Signal Description<br />
nal peripheral devices. Refer to Section 7 Bus Operation for bus information related to<br />
interrupts and to Section 8 Exception Processing for interrupt information.<br />
2.9.3 Autovector (AVEC)<br />
This input signal is asserted with TA during an interrupt acknowledge bus cycle to request<br />
internal generation of the vector number. Refer to Section 7 Bus Operation for more information<br />
about automatic vectors.<br />
2.10 STATUS AND CLOCK SIGNALS<br />
The following paragraphs describe the signals that provide timing and the internal processor<br />
status.<br />
2.10.1 Processor Status (PST4–PST0)<br />
These outputs indicate the internal execution unit status. The timing is synchronous with the<br />
MC68060 processor clock (CLK), and the status may have nothing to do with the current<br />
bus transfer. Table 2-7 lists the definition of the PSTx encodings.<br />
The encodings $16, $17, and $1C indicate the present status and do not reflect a specific<br />
stage of the pipe. These encodings persist as long as the processor stays in the indicated<br />
state. The default encoding $00 is indicated if none of the above conditions apply. Most<br />
other encodings indicate that the instruction is in its last instruction execution stage. These<br />
encodings exist for only one CLK period per instruction and are mutually exclusive.<br />
In general, the PSTx bits indicate the following information:<br />
PST4 = Supervisor Mode<br />
PST3 = Branch Instruction<br />
PST2 = Taken Branch Instruction<br />
PST1, PST0 = Number of Instructions Completed that Cycle<br />
2-14 <strong>M68060</strong> USER’S MANUAL MOTOROLA
2.10.2 MC68060 Processor Clock (CLK)<br />
Signal Description<br />
CLK is the synchronous clock of the MC68060. This signal is used internally to clock or<br />
sequence the internal logic of the MC68060 processor and is qualified with CLKEN to clock<br />
all external bus signals.<br />
Since the MC68060 is designed for static operation, CLK can be gated off to lower power<br />
dissipation (e.g., during low-power stopped states). Refer to Section 7 Bus Operation for<br />
more information on low-power stopped states.<br />
2.10.3 Clock Enable (CLKEN)<br />
Table 2-7. PSTx Encoding<br />
Hex PST4 PST3 PST2 PST1 PST0 Internal Processor Status<br />
$00 0 0 0 0 0 Continue Execution in User Mode<br />
$01 0 0 0 0 1 Complete 1 Instruction in User Mode<br />
$02 0 0 0 1 0 Complete 2 Instructions in User Mode<br />
$03 0 0 0 1 1 —<br />
$04 0 0 1 0 0 —<br />
$05 0 0 1 0 1 —<br />
$06 0 0 1 1 0 —<br />
$07 0 0 1 1 1 —<br />
$08 0 1 0 0 0 Emulator Mode Entry Exception Processing<br />
$09 0 1 0 0 1 Complete Not Taken Branch in User Mode<br />
$0A 0 1 0 1 0 Complete Not Taken Branch Plus 1 Instruction in User Mode<br />
$0B 0 1 0 1 1 IED Cycle of Branch to Vector, Emulator Entry Exception<br />
$0C 0 1 1 0 0 —<br />
$0D 0 1 1 0 1 Complete Taken Branch in User Mode<br />
$0E 0 1 1 1 0 Complete Taken Branch Plus 1 Instruction in User Mode<br />
$0F 0 1 1 1 1 Complete Taken Branch Plus 2 Instructions in User Mode<br />
$10 1 0 0 0 0 Continue Execution in Supervisor Mode<br />
$11 1 0 0 0 1 Complete 1 Instruction in Supervisor Mode<br />
$12 1 0 0 1 0 Complete 2 Instructions in Supervisor Mode<br />
$13 1 0 0 1 1 —<br />
$14 1 0 1 0 0 —<br />
$15 1 0 1 0 1 Complete RTE Instruction in Supervisor Mode<br />
$16 1 0 1 1 0 Low-Power Stopped State; Waiting for an Interrupt or Reset<br />
$17 1 0 1 1 1 MC68060 Is Stopped Waiting for an Interrupt<br />
$18 1 1 0 0 0 MC68060 Is Processing an Exception<br />
$19 1 1 0 0 1 Complete Not Taken Branch in Supervisor Mode<br />
$1A 1 1 0 1 0 Complete Not Taken Branch Plus 1 Instruction in Supervisor Mode<br />
$1B 1 1 0 1 1 IED Cycle of Branch to Vector, Exception Processing<br />
$1C 1 1 1 0 0 MC68060 Is Halted<br />
$1D 1 1 1 0 1 Complete Taken Branch in Supervisor Mode<br />
$1E 1 1 1 1 0 Complete Taken Branch Plus 1 Instruction in Supervisor Mode<br />
$1F 1 1 1 1 1 Complete Taken Branch Plus 2 Instructions in Supervisor Mode<br />
This input signal is a qualifier for the MC68060 processor clock (CLK) and is provided to support<br />
lower bus frequency MC68060 designs. The internal MC68060 bus interface controller<br />
will sample, assert, negate, or three-state signals (except for BB and TIP which can three-<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 2-15
Signal Description<br />
state on the rising edge of CLK regardless of the state of the CLKEN) only on those rising<br />
edges of CLK which are spanned by the assertion of CLKEN.<br />
CLKEN may be used to allow the external bus to run at 1/2 or 1/4 the speed of the MC68060<br />
processor clock which controls all internal operations. The MC68060 bus interface controller<br />
will not detect those rising edges of CLK which are spanned with the negation of CLKEN.<br />
To operate the external bus at 1/2 or 1/4 the speed of CLK, CLKEN must be asserted and<br />
stable during the rising edges of CLK which coincide with the system clock running at 1/2 or<br />
1/4 the frequency of the MC68060 processor clock. CLKEN must be negated and stable during<br />
all other rising CLK edges.<br />
For full speed operation of the MC68060 processor, CLKEN must be continuously asserted.<br />
Refer to Section 7 Bus Operation for more information on the MC68060 bus interface and<br />
controller. Refer to Section 12 Electrical and Thermal Characteristics for the timing specifications<br />
of CLK and CLKEN.<br />
2.11 TEST SIGNALS<br />
The MC68060 includes dedicated user-accessible test logic that is fully compatible with the<br />
IEEE 1149.1 Standard Test Access Port and Boundary Scan Architecture. Problems associated<br />
with testing high-density circuit boards have led to the development of this standard<br />
under the IEEE Test Technology Committee and Joint Test Action Group (JTAG) sponsorship.<br />
The MC68060 implementation supports circuit board test strategies based on this<br />
standard. However, the JTAG interface is not intended to provide an in-circuit test to verify<br />
MC68060 operations; therefore, it is impossible to test MC68060 operations using this interface.<br />
Section 9 IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes describes the<br />
MC68060 implementation of IEEE 1149.1 and is intended to be used with the supporting<br />
IEEE document.<br />
2.11.1 JTAG Enable (JTAG)<br />
This input signal is used to select between 1149.1 operation and debug emulation mode.<br />
The 1149.1 test access port (TAP) pins are remapped to emulation mode functions when<br />
this pin is negated. For normal 1149.1 operation, JTAG should be grounded.<br />
2.11.2 Test Clock (TCK)<br />
This input signal is used as a dedicated clock for the test logic. Since clocking of the test<br />
logic is independent of the normal operation of the MC68060, several other components on<br />
a board can share a common test clock with the processor even though each component<br />
may operate from a different system clock. The design of the test logic allows the test clock<br />
to run at low frequencies, or to be gated off entirely as required for test purposes. TCK<br />
should be grounded if it is not used and emulation mode is not to be used.<br />
2.11.3 Test Mode Select (TMS)<br />
This input signal is decoded by the TAP controller and distinguishes the principal operations<br />
of the test support circuitry. TMS should be tied to V CC if it is not used and emulation mode<br />
is not to be used.<br />
2-16 <strong>M68060</strong> USER’S MANUAL MOTOROLA
2.11.4 Test Data In (TDI)<br />
Signal Description<br />
This input signal provides a serial data input to the TAP. TDI should be tied to V CC if it is not<br />
used and emulation mode is not to be used.<br />
2.11.5 Test Data Out (TDO)<br />
This three-state output signal provides a serial data output from the TAP. The TDO output<br />
can be placed in a high-impedance mode to allow parallel connection to board-level test<br />
data paths.<br />
2.11.6 Test Reset (TRST)<br />
This input signal provides an asynchronous reset of the TAP controller. TRST should be<br />
grounded if 1149.1 operation is not to be used.<br />
2.12 THERMAL SENSING PINS (THERM1, THERM0)<br />
THERM1 and THERM0 are connected to an internal thermal resistor and provide information<br />
about the average temperature of the die. The resistance across these two pins is proportional<br />
to the average temperature of the die. The temperature coefficient of the resistor<br />
is approximately 1.2 Ω/°C with a nominal resistance of 400Ω at 25°C.<br />
2.13 POWER SUPPLY CONNECTIONS<br />
The MC68060 requires connection to a V CC power supply, positive with respect to ground.<br />
The V CC and ground connections are grouped to supply adequate current to the various<br />
sections of the processor. Section 13 Ordering Information and Mechanical Data<br />
describes the groupings of the V CC and ground connections.<br />
2.14 SIGNAL SUMMARY<br />
Table 2-8 provides a summary of the electrical characteristics of the MC68060 signals.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 2-17
Signal Description<br />
Table 2-8. Signal Summary<br />
Signal Name Mnemonic<br />
Input/<br />
Output<br />
Active<br />
State<br />
Three-State<br />
Reset<br />
State<br />
Address Bus A31–A0 Input/Output High Yes Three-Stated<br />
Cycle Long-Word Address CLA Input Low — —<br />
Data Bus D31–D0 Input/Output High Yes Three-Stated<br />
Transfer Type 1 TT1 Input/Output High Yes Three-Stated<br />
Transfer Type 0 TT0 Output High Yes Three-Stated<br />
Transfer Modifier TM2–TM0 Output High Yes Three-Stated<br />
Transfer Line Number TLN1,TLN0 Output High Yes Three-Stated<br />
User-Programmable Attributes UPA1,UPA0 Output High Yes Three-Stated<br />
Read/Write R/W Output High/Low Yes Three-Stated<br />
Transfer Size SIZ1,SIZ0 Output High Yes Three-Stated<br />
Bus Lock LOCK Output Low Yes Three-Stated<br />
Bus Lock End LOCKE Output Low Yes Three-Stated<br />
Cache Inhibit Out CIOUT Output Low Yes Three-Stated<br />
Byte Select BS3–BS0 Output Low Yes Three-Stated<br />
Transfer Start TS Input/Output Low Yes Three-Stated<br />
Transfer in Progress TIP Output Low Yes Three-Stated<br />
Starting Termination Acknowledge Signal Sampling SAS Output Low Yes Three-Stated<br />
Transfer Acknowledge TA Input Low — —<br />
Transfer Retry Acknowledge TRA Input Low — —<br />
Transfer Error Acknowledge TEA Input Low — —<br />
Transfer Burst Inhibit TBI Input Low — —<br />
Transfer Cache Inhibit TCI Input Low — —<br />
Snoop Control SNOOP Input Low — —<br />
Bus Request BR Output Low No Negated<br />
Bus Grant BG Input Low — —<br />
Bus Grant Relinquish Control BGR Input Low — —<br />
Bus Busy BB Input/Output Low Yes Three-Stated<br />
Bus Tenure Termination BTT Input/Output Low Yes Three-Stated<br />
Cache Disable CDIS Input Low — —<br />
MMU Disable MDIS Input Low — —<br />
Reset In RSTI Input Low — —<br />
Reset Out RSTO Output Low No Negated<br />
Interrupt Priority Level IPL2–IPL0 Input Low — —<br />
Interrupt Pending IPEND Output Low No Negated<br />
Autovector AVEC Input Low — —<br />
Processor Status PST4–PST0 Output High No 10000<br />
Processor Clock CLK Input — — —<br />
Clock Enable CLKEN Input Low — —<br />
JTAG Enable JTAG Input Low — —<br />
Test Clock TCK Input — — —<br />
Test Mode Select TMS Input High — —<br />
Test Data Input TDI Input High — —<br />
Test Data Output TDO Output High Yes Three-Stated<br />
Test Reset TRST Input Low — —<br />
Thermal Resistor Connections<br />
THERM1,<br />
THERM0<br />
— — — —<br />
Power Supply VCC Input — — —<br />
Ground GND Input — — —<br />
2-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
SECTION 3<br />
INTEGER UNIT<br />
This section describes the organization of the MC68060 integer unit and presents a brief<br />
description of the associated registers. Refer to Section 4 Memory Management Unit for<br />
details concerning the paged memory management unit (MMU) programming model and to<br />
Section 6 Floating-Point Unit for details concerning the floating-point unit (FPU) programming<br />
model.<br />
3.1 INTEGER UNIT EXECUTION PIPELINES<br />
The MC68060 integer unit execution pipelines are four-stage pipelines which perform final<br />
instruction decode, effective address calculation, and execution or integer operations. The<br />
operand execution pipelines (OEPs) are referred to individually as the primary OEP (pOEP)<br />
and the secondary OEP (sOEP). Figure 3-1 shows the integer unit of the MC68060.<br />
EXECUTION UNIT<br />
FLOATING-<br />
POINT<br />
UNIT<br />
EA<br />
FETCH<br />
FP<br />
EXECUTE<br />
MOTOROLA<br />
BRANCH<br />
CACHE<br />
INSTRUCTION FETCH UNIT<br />
pOEP sOEP<br />
DECODE<br />
DS<br />
DECODE<br />
DS<br />
EA AG EA AG<br />
CALCULATE<br />
CALCULATE<br />
OC EA OC EA OC<br />
FETCH<br />
FETCH<br />
EX INT EX INT EX<br />
EXECUTE<br />
EXECUTE<br />
DATA AVAILABLE<br />
WRITE-BACK<br />
INSTRUCTION<br />
BUFFER<br />
INTEGER UNIT<br />
IA<br />
CALCULATE<br />
INSTRUCTION<br />
FETCH<br />
EARLY<br />
DECODE<br />
IAG<br />
IB<br />
IC<br />
IED<br />
DA<br />
WB<br />
OPERAND DATA BUS<br />
INSTRUCTION<br />
ATC<br />
Figure 3-1. MC68060 Integer Unit Pipeline<br />
<strong>M68060</strong> USER’S MANUAL<br />
INSTRUCTION<br />
CACHE<br />
CONTROLLER<br />
INSTRUCTION MEMORY UNIT<br />
DATA<br />
ATC<br />
DATA<br />
CACHE<br />
CONTROLLER<br />
DATA MEMORY UNIT<br />
INSTRUCTION<br />
CACHE<br />
DATA<br />
CACHE<br />
B<br />
U<br />
S<br />
C<br />
O<br />
N<br />
T<br />
R<br />
O<br />
L<br />
L<br />
E<br />
R<br />
ADDRESS<br />
DATA<br />
CONTROL<br />
3-1
Integer Unit<br />
The operation of the instruction fetch unit (IFU) and the OEPs are decoupled by a 96-byte<br />
FIFO instruction buffer. The IFU prefetches instructions every processor clock cycle, stopping<br />
only if the instruction buffer is full or encountering a wait condition due to instruction<br />
fetch address translation or cache miss. The OEPs attempt to read instructions from the<br />
instruction buffer and execute them every clock cycle, stopping only if full instruction information<br />
is not present in the buffer or due to operand pipeline wait conditions.<br />
3.2 INTEGER UNIT REGISTER DESCRIPTION<br />
The following paragraphs describe the integer unit registers in the user and supervisor programming<br />
models. Refer to Section 4 Memory Management Unit for details on the MMU<br />
programming model and Section 6 Floating-Point Unit for details on the FPU programming<br />
model.<br />
3.2.1 Integer Unit User Programming Model<br />
Figure 3-2 illustrates the integer unit portion of the user programming model. The model is<br />
the same as for previous M68000 family microprocessors, consisting of the following registers:<br />
• 16 General-Purpose 32-Bit Registers (D7–D0, A7–A0)<br />
• 32-Bit Program Counter (PC)<br />
• 8-Bit Condition Code Register (CCR)<br />
3.2.1.1 DATA REGISTERS (D7–D0). Registers D7–D0 are used as data registers for bit<br />
and bit field (1- to 32-bit), byte (8-bit), word (16-bit), long-word (32-bit), and quad-word (64bit)<br />
operations. These registers may also be used as index registers.<br />
3.2.1.2 ADDRESS REGISTERS (A6–A0). These registers can be used as software stack<br />
pointers, index registers, or base address registers. The address registers may be used for<br />
word and long-word operations.<br />
3.2.1.3 USER STACK POINTER (A7). A7 is used as a hardware stack pointer during<br />
implicit or explicit stacking for subroutine calls and exception handling. The register designation<br />
A7 refers to the user stack pointer (USP) in the user programming model and to the<br />
3-2<br />
31<br />
31<br />
31<br />
15<br />
15<br />
15<br />
Figure 3-2. Integer Unit User Programming Model<br />
<strong>M68060</strong> USER’S MANUAL<br />
7<br />
0<br />
0<br />
0<br />
0<br />
A0<br />
A1<br />
A2<br />
A3<br />
A4<br />
A5<br />
A6<br />
A7<br />
(USP)<br />
PC<br />
CCR<br />
ADDRESS<br />
REGISTERS<br />
USER<br />
STACK<br />
POINTER<br />
PROGRAM<br />
COUNTER<br />
CONDITION<br />
CODE<br />
REGISTER<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Integer Unit<br />
supervisor stack pointer (SSP) in the supervisor programming model. When the S-bit in the<br />
status register (SR) is clear, the USP is the active stack pointer.<br />
A subroutine call saves the program counter (PC) on the active system stack, and the return<br />
restores the PC from the active system stack. Both the PC and the SR are saved on the<br />
supervisor stack during the processing of exceptions and interrupts. Thus, the execution of<br />
supervisor level code is independent of user code and the condition of the user stack. Conversely,<br />
user programs use the USP independently of supervisor stack requirements.<br />
3.2.1.4 PROGRAM COUNTER. The PC contains the address of the currently executing<br />
instruction. During instruction execution and exception processing, the processor automatically<br />
increments the contents of the PC or places a new value in the PC, as appropriate.<br />
For some addressing modes, the PC can be used as a pointer for PC-relative addressing.<br />
3.2.1.5 CONDITION CODE REGISTER. The CCR is the least significant byte of the processor<br />
SR. Bits 3–0 represent a condition of a result generated by a processor operation. Bit 4,<br />
the extend bit (X-bit), is an operand for multiprecision computations. The carry bit (C-bit) and<br />
the X-bit are separate in the M68000 family to simplify programming techniques that use<br />
them.<br />
3.2.2 Integer Unit Supervisor Programming Model<br />
Only system programmers use the supervisor programming model (see Figure 3-3) to implement<br />
sensitive operating system functions, I/O control, and MMU subsystems. All accesses<br />
that affect the control features of the MC68060 are in the supervisor programming model.<br />
Thus, all application software is written to run in the user mode and migrates to the<br />
MC68060 from any M68000 platform without modification.<br />
31 15<br />
15 7 0<br />
(CCR)<br />
31 0<br />
31 2<br />
31 0<br />
A7 (SSP)<br />
Figure 3-3. Integer Unit Supervisor Programming Model<br />
0<br />
0<br />
SR<br />
VBR<br />
SFC<br />
DFC<br />
SUPERVISOR STACK POINTER<br />
STATUS REGISTER<br />
VECTOR BASE REGISTER<br />
ALTERNATE SOURCE AND DESTINATION<br />
FUNCTION CODE REGISTERS<br />
PCR PROCESSOR CONFIGURATION REGISTER<br />
3-3
Integer Unit<br />
The supervisor programming model consists of the registers available to the user as well as<br />
the following control registers:<br />
• 32-Bit Supervisor Stack Pointer (SSP, A7)<br />
• 16-Bit Status Register (SR)<br />
• 32-Bit Vector Base Register (VBR)<br />
• Two 32-Bit Alternate Function Code Registers: Source Function Code (SFC) and Destination<br />
Function Code (DFC)<br />
• 32-Bit Processor Configuration Register (PCR)<br />
The following paragraphs describe the supervisor programming model registers. Additional<br />
information on the SSP, SR, and VBR registers can be found in Section 8 Exception Processing.<br />
3.2.2.1 SUPERVISOR STACK POINTER. When the MC68060 is operating at the supervisor<br />
level, instructions that use the system stack implicitly, or access address register A7<br />
explicitly, use the SSP. The SSP is a general-purpose register and can be used as a software<br />
stack pointer, index register, or base address register. The SSP can be used for word<br />
and long-word operations. The initial value of the SSP is loaded from the reset exception<br />
vector, address offset 0.<br />
3.2.2.2 STATUS REGISTER. The SR (see Figure 3-4) stores the processor status and<br />
includes the CCR, the interrupt priority mask, and other control bits. In the supervisor mode,<br />
software can access the entire SR. The control bits indicate the following states for the processor:<br />
trace mode (T-bit), supervisor or user mode (S-bit), and master or interrupt state (M).<br />
3.2.2.3 VECTOR BASE REGISTER. The VBR contains the base address of the exception<br />
vector table in memory. The displacement of an exception vector is added to the value in<br />
this register to access the vector table. Refer to Section 8 Exception Processing for information<br />
on exception vectors.<br />
3-4<br />
TRACE ENABLE<br />
SUPERVISOR/USER STATE<br />
SYSTEM BYTE<br />
T 0 S M 0 I2 I1 I0 0 0 0 X N Z V C<br />
INTERRUPT<br />
PRIORITY MASK<br />
Figure 3-4. Status Register<br />
<strong>M68060</strong> USER’S MANUAL<br />
USER BYTE<br />
(CONDITION CODE REGISTER)<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
CARRY<br />
OVERFLOW<br />
NEGATIVE<br />
MASTER/INTERRUPT STATE EXTEND<br />
ZERO<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Integer Unit<br />
3.2.2.4 ALTERNATE FUNCTION CODE REGISTERS. The alternate function code registers<br />
contain 3-bit function codes. Function codes can be considered extensions of the 32-bit<br />
logical address that optionally provides as many as eight 4-Gbyte address spaces. The processor<br />
automatically generates function codes to select address spaces for data and programs<br />
at the user and supervisor modes. Certain instructions use the SFC and DFC<br />
registers to specify the function codes for operations.<br />
3.2.2.5 PROCESSOR CONFIGURATION REGISTER. The PCR is an 32-bit register which<br />
controls the operations of the MC68060 internal pipelines and contains a software readable<br />
revision number. The PCR is shown in Figure 3-5.<br />
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 8 7 6 2 1 0<br />
0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 Revision Number EDEBUG Reserved DFP ESS<br />
Figure 3-5. Processor Configuration Register<br />
Bits 31–16—Identification<br />
These bits are configured with the value which identifies this device as an MC68060.<br />
These bits are ignored when writing to the PCR.<br />
See Appendix A MC68LC060 and Appendix B MC68EC060 for MC68LC060 and<br />
MC68EC060, respectively, identification field values.<br />
Bits 15–8—Revision Number<br />
Bits 15–8 contain the 8-bit device revision number. The first revision is 00000000. These<br />
bits are ignored when writing to the PCR.<br />
EDEBUG—Enable Debug Features<br />
When this bit is set, the MC68060 outputs internal control information on the address bus<br />
(A31–A0) and data bus (D31–D0) during idle bus cycles. This capability is implemented<br />
to support debug of designs that include the MC68060. When this bit is cleared, operation<br />
proceeds in a normal manner and no internal information is output on idle bus cycles. This<br />
bit is cleared at reset.<br />
Bits 6–2—Reserved by Motorola for future use and must always be zero.<br />
DFP—Disable Floating-Point Unit<br />
When this bit is set, the on-chip FPU is disabled and any attempt to execute a floatingpoint<br />
instruction generates a line F emulator exception. When this bit is cleared, the FPU<br />
executes all floating-point instructions. This bit is cleared at reset. Note that before this bit<br />
is set via the MOVEC instruction, an FNOP must be executed to ensure that all floatingpoint<br />
exceptions are caught and handled. This would prevent unexpected floating-point<br />
related exceptions to be reported when the FPU is re-enabled at a later time.<br />
ESS—Enable Superscalar Dispatch<br />
When this bit is set, the ability of the MC68060 to execute multiple instructions per<br />
machine cycle is enabled. When this bit is cleared, the ability to execute multiple instructions<br />
per cycle is disabled and the MC68060 operates at a slower rate with lower performance.<br />
This bit is cleared at reset.<br />
3-5
SECTION 4<br />
MEMORY MANAGEMENT UNIT<br />
MOTOROLA<br />
NOTE<br />
This section does not apply to the MC68EC060. Refer to<br />
Appendix B MC68EC060 for details.<br />
The MC68060 supports a demand-paged virtual memory environment. Demand means that<br />
programs request permission to use memory area by accessing logical addresses, and<br />
paged means that memory is divided into blocks of equal size, called page frames. Each<br />
page frame is divided into pages of the same size. The operating system assigns pages to<br />
page frames as they are required to meet the needs of the program.<br />
The MC68060 memory management includes the following features:<br />
• Independent Instruction and Data Memory Management Units (MMUs)<br />
• 32-Bit Logical Address Translation to 32-Bit Physical Address<br />
• User-Defined 2-Bit Physical Address Extension<br />
• Addresses Translated in Parallel with Indexing into Data or Instruction Cache<br />
• 64-Entry Four-Way Set-Associative Address Translation Cache (ATC) for Each MMU<br />
(128 Total Entries)<br />
• Global Bit Allowing Flushes of All Nonglobal Entries from ATCs<br />
• Selectable 4- or 8-Kbyte Page Size<br />
• Separate Supervisor and User Translation Tables<br />
• Two Independent Blocks for Each MMU Can Be Defined as Transparent (Untranslated)<br />
• Three-Level Translation Tables with Optional Indirection<br />
• Supervisor and Write Protections<br />
• History Bits Automatically Maintained in Descriptors<br />
• External Translation Disable Input Signal (MDIS) for Emulator Support<br />
• Caching Mode Selected on Page Basis<br />
• Default Transparent Translation<br />
• Default Cache Mode and User Attributes<br />
The MMUs completely overlap address translation time with other processing activities<br />
when the translation is resident in the corresponding ATC. ATC accesses operate in parallel<br />
with indexing into the on-chip instruction and data caches. The MMU MDIS signal dynamically<br />
disables address translation for emulation and diagnostic support.<br />
<strong>M68060</strong> USER’S MANUAL<br />
4-1
Memory Management Unit<br />
Figure 4-1 illustrates the MMUs contained in the two memory units, one for instructions (supporting<br />
instruction prefetches) and one for data (supporting all other accesses). Each MMU<br />
contains a 64-entry ATC, two transparent translation registers (TTRs), and control logic. The<br />
ATCs hold recently used logical to physical address translations, cache mode and protection<br />
information, and whether or not the page has been written. The TTRs are used for defining<br />
the cache modes, enabling protection modes and defining user page attributes for large<br />
regions of untranslated address space. Each MMU also allows enabling a default cache<br />
mode, protection, and user page attributes for address regions not covered by the ATC or<br />
TTRs.<br />
One of the principal functions of the MMU is to provide logical to physical address translation<br />
using translation tables stored in memory. As an MMU receives a request from the corresponding<br />
pipe unit, its ATC is searched for the translation, using the upper logical address<br />
bits as a tag. If the translation is resident (or one of the TTRs hit causing transparent translation),<br />
the MMU provides the physical address for the corresponding cache lookup. If the<br />
translation is not in the ATC (and the TTRs miss), then a table search is done using translation<br />
tables stored in memory. When the translation is obtained, it is used for the cache<br />
lookup, and is placed in the ATC for future use. The table search is performed automatically<br />
by the MC68060 using on-chip logic.<br />
4-2<br />
EXECUTION UNIT<br />
FLOATING-<br />
POINT<br />
UNIT<br />
EA<br />
FETCH<br />
FP<br />
EXECUTE<br />
BRANCH<br />
CACHE<br />
INSTRUCTION FETCH UNIT<br />
pOEP sOEP<br />
DECODE<br />
DS<br />
DECODE<br />
DS<br />
EA AG EA AG<br />
CALCULATE<br />
CALCULATE<br />
OC EA OC EA OC<br />
FETCH<br />
FETCH<br />
EX INT EX INT EX<br />
EXECUTE<br />
EXECUTE<br />
DATA AVAILABLE<br />
WRITE-BACK<br />
INSTRUCTION<br />
BUFFER<br />
INTEGER UNIT<br />
IA<br />
CALCULATE<br />
INSTRUCTION<br />
FETCH<br />
EARLY<br />
DECODE<br />
IAG<br />
IB<br />
IC<br />
IED<br />
DA<br />
WB<br />
OPERAND DATA BUS<br />
INSTRUCTION<br />
ATC<br />
Figure 4-1. Memory Management Unit<br />
<strong>M68060</strong> USER’S MANUAL<br />
INSTRUCTION<br />
CACHE<br />
CONTROLLER<br />
INSTRUCTION MEMORY UNIT<br />
DATA<br />
ATC<br />
DATA<br />
CACHE<br />
CONTROLLER<br />
DATA MEMORY UNIT<br />
INSTRUCTION<br />
CACHE<br />
DATA<br />
CACHE<br />
B<br />
U<br />
S<br />
C<br />
O<br />
N<br />
T<br />
R<br />
O<br />
L<br />
L<br />
E<br />
R<br />
ADDRESS<br />
DATA<br />
CONTROL<br />
MOTOROLA
4.1 MEMORY MANAGEMENT PROGRAMMING MODEL<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
The memory management programming model is part of the supervisor programming model<br />
for the MC68060. The seven registers that control and provide status information for<br />
address translation in the MC68060 are: the user root pointer register (URP), the supervisor<br />
root pointer register (SRP), the translation control register (TCR), and four independent<br />
transparent translation registers (ITTR0, ITTR1, DTTR0, and DTTR1). Only programs that<br />
execute in the supervisor mode can directly access these registers. Figure 4-2 illustrates the<br />
memory management programming model.<br />
31 0<br />
31 0<br />
31<br />
31 0<br />
31 0<br />
31 0<br />
31 0<br />
Figure 4-2. Memory Management Programming Model<br />
4.1.1 User and Supervisor Root Pointer Registers<br />
The SRP and URP registers each contain the physical address of the translation table’s root,<br />
which the MMU uses for supervisor and user accesses, respectively. The URP points to the<br />
translation table for the current user task. When a new task begins execution, the operating<br />
system typically writes a new root pointer to the URP. A new translation table address<br />
implies that the contents of the ATCs may no longer be valid. Writing a root pointer register<br />
does not affect the contents of the ATCs. A PFLUSH instruction should be executed to flush<br />
the ATCs before loading a new root pointer value, if necessary. Figure 4-3 illustrates the format<br />
of the 32-bit URP and SRP registers. Bits 8–0 of an address loaded into the URP or the<br />
SRP must be zero. Transfers of data to and from these 32-bit registers are long-word transfers.<br />
31 9 8 0<br />
USER ROOT POINTER 0 0 0 0 0 0 0 0 0<br />
SUPERVISOR ROOT POINTER 0 0 0 0 0 0 0 0 0<br />
Figure 4-3. URP and SRP Register Formats<br />
0<br />
URP<br />
SRP<br />
TCR<br />
DTTR0<br />
DTTR1<br />
ITTR0<br />
ITTR1<br />
USER ROOT POINTER REGISTER<br />
SUPERVISOR ROOT POINTER REGISTER<br />
TRANSLATION CONTROL REGISTER<br />
DATA TRANSPARENT TRANSLATION REGISTER 0<br />
DATA TRANSPARENT TRANSLATION REGISTER 1<br />
INSTRUCTION TRANSPARENT TRANSLATION<br />
REGISTER 0<br />
INSTRUCTION TRANSPARENT TRANSLATION<br />
REGISTER 1<br />
4-3
Memory Management Unit<br />
4.1.2 Translation Control Register<br />
The 32-bit TCR contains control bits which select translation properties. The operating system<br />
must flush the ATCs before enabling address translation since the TCR accesses and<br />
reset do not flush the ATCs. All unimplemented bits of this register are read as zeros and<br />
must always be written as zeros. The MC68060 always uses long-word transfers to access<br />
this 32-bit register. All bits are cleared by reset. Figure 4-4 illustrates the TCR.<br />
31 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 E P NAD NAI FOTC FITC DCO DUO DWO DCI DUI 0<br />
Bits 31–16—Reserved by Motorola. Always read as zero.<br />
E—Enable<br />
This bit enables and disables paged address translation.<br />
0 = Disable<br />
1 = Enable<br />
A reset operation clears this bit. When translation is disabled, logical addresses are used<br />
as physical addresses. The MMU instruction, PFLUSH, can be executed successfully<br />
despite the state of the E-bit. If translation is disabled and an access does not match a<br />
transparent translation register (TTR), the default attributes for the access on the TTR is<br />
defined by the DCO, DUO, DCI, DWO, DUI (default TTR) bits in TCR.<br />
P—Page Size<br />
This bit selects the memory page size.<br />
0 = 4 Kbytes<br />
1 = 8 Kbytes<br />
NAD—No Allocate Mode (Data ATC)<br />
This bit freezes the data ATC in the current state, by enforcing a no-allocate policy for all<br />
accesses. Accesses can still hit, misses will cause a table search. A write access which<br />
finds a corresponding valid read will update the M-bit and the entry remains valid.<br />
0 = Disabled<br />
1 = Enable<br />
NAI—No Allocate Mode (Instruction ATC)<br />
This bit freezes the instruction ATC in the current state, by enforcing a no-allocate policy<br />
for all accesses. Accesses can still hit, misses will cause a table search.<br />
0 = Disabled<br />
1 = Enable<br />
FOTC—1/2-Cache Mode (Data ATC)<br />
0 = The data ATC operates with 64 entries.<br />
1 = The data ATC operates with 32 entries.<br />
4-4<br />
Figure 4-4. Translation Control Register Format<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
FITC—1/2-Cache Mode (Instruction ATC)<br />
0 = The instruction ATC operates with 64 entries.<br />
1 = The instruction ATC operates with 32 entries.<br />
DCO—Default Cache Mode (Data Cache)<br />
00 = Writethrough, cachable<br />
01 = Copyback, cachable<br />
10 = Cache-inhibited, precise exception model<br />
11 = Cache-inhibited, imprecise exception model<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
DUO—Default UPA bits (Data Cache)<br />
These bits are two user-defined bits for operand accesses (see 4.2.2.3 Descriptor Field<br />
Definitions).<br />
DWO—Default Write Protect (Data Cache)<br />
0 = Reads and writes are allowed.<br />
1 = Reads are allowed, writes cause a protection exception.<br />
DCI—Default Cache Mode (Instruction Cache)<br />
00 = Writethrough, cachable<br />
01 = Copyback, cachable<br />
10 = Cache-inhibited, precise exception model<br />
11 = Cache-inhibited, imprecise exception model<br />
DUI—Default UPA Bits (Instruction Cache)<br />
These bits are two user-defined bits for instruction prefetch bus cycles (see 4.2.2.3<br />
Descriptor Field Definitions)<br />
Bit 0—Reserved by Motorola. Always read as zero.<br />
4-5
Memory Management Unit<br />
4.1.3 Transparent Translation Registers<br />
The data transparent translation registers (DTTR0 and DTTR1) and instruction transparent<br />
translation registers (ITTR0 and ITTR1) are 32-bit registers that define blocks of logical<br />
address space that are untranslated by the MMU (the logical address is the physical<br />
address). The TTRs operate independently of the E-bit in the TCR and the state of the MDIS<br />
signal. Data transfers to and from these registers are long-word transfers. The TTR fields<br />
are defined following Figure 4-5, which illustrates TTR format. Bits 12–10, 7, 4, 3, 1, and 0<br />
always read as zero.<br />
31 24 23 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
LOGICAL ADDRESS BASE LOGICAL ADDRESS MASK E S-FIELD 0 0 0 U1 U0 0 CM 0 0 W 0 0<br />
Bits 31–24—Logical Address Base<br />
This 8-bit field is compared with address bits A31–A24. Addresses that match in this comparison<br />
(and are otherwise eligible) are transparently translated.<br />
Bits 23–16—Logical Address Mask<br />
Since this 8-bit field contains a mask for the Logical Address Mask field, setting a bit in<br />
this field causes the corresponding bit in the Logical Address Base field to be ignored.<br />
Blocks of memory larger than 16 Mbytes can be transparently translated by setting some<br />
of the logical address mask bits to ones. The low-order bits of this field can be set to define<br />
contiguous blocks larger than 16 Mbytes. The mask can be used to define multiple noncontiguous<br />
blocks of addresses.<br />
E—Enable<br />
This bit enables or disables transparent translation of the block defined by this register:<br />
0 = Transparent translation disabled<br />
1 = Transparent translation enabled<br />
S—Supervisor Mode<br />
This field specifies the way FC2 is used in matching an address:<br />
00 = Match only if FC2 = 0 (user mode access)<br />
01 = Match only if FC2 = 1 (supervisor mode access)<br />
1X<br />
= Ignore FC2 when matching<br />
U0, U1—User Page Attributes<br />
The user defines these bits, and the MC68060 does not interpret them. U0 and U1 are<br />
echoed to the UPA0 and UPA1 signals, respectively, if an external bus transfer results<br />
4-6<br />
Figure 4-5. Transparent Translation Register Format<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
from an access. These bits can be programmed by the user to support external addressing,<br />
bus snooping, or other applications.<br />
CM—Cache Mode<br />
This field selects the cache mode and access precision as follows:<br />
00 = Cachable, Writethrough<br />
01 = Cachable, Copyback<br />
10 = Cache-Inhibited, Precise Exception Model<br />
11 = Cache-Inhibited, Imprecise Exception Model<br />
Section 5 Caches provides detailed information on caching modes.<br />
W—Write Protect<br />
This bit indicates the write privilege of the TTR block.<br />
0 = Read and write accesses permitted<br />
1 = Write accesses not permitted<br />
Bits 4,3,1,0—Reserved by Motorola.<br />
4.2 LOGICAL ADDRESS TRANSLATION<br />
The primary function of the MMUs is to translate logical addresses to physical addresses.<br />
The MMUs perform translations according to control information in translation tables. The<br />
operating system creates these translation tables and stores them in memory. The processor<br />
then searches through a translation table as needed and stores the resulting translation<br />
in an ATC.<br />
4.2.1 Translation Tables<br />
Both instruction and data access use the same translation tree. Separate translations trees<br />
are available for user and supervisor accesses.<br />
Figure 4-6 illustrates the three-level tree structure of a general translation table supported<br />
by the MC68060. The root- and pointer-level tables contain the base addresses of the tables<br />
at the next level. The page-level tables contain either the physical address for the translation<br />
or a pointer to the memory location containing the physical address. Only a portion of the<br />
translation table for the entire logical address space is required to be resident in memory at<br />
any time—specifically, only the portion of the table that translates the logical addresses of<br />
the currently executing process. Portions of translation tables can be dynamically allocated<br />
as the process requires additional memory.<br />
The current privilege mode determines the use of the URP or SRP for translation of the<br />
access. The root pointer contains the base address of the translation table’s root-level table.<br />
The translation table consists of several linked tables of descriptors. The table descriptors<br />
of the root- and pointer-levels can have resident or invalid descriptor types. The page<br />
descriptors of the page-level table have resident, indirect, or invalid descriptor types. The<br />
page descriptors of the page-level table can be resident, indirect, or invalid. A page descriptor<br />
defines the physical address of a page frame in memory that corresponds to the logical<br />
address of a page. An indirect descriptor, which contains a pointer to the actual page<br />
4-7
Memory Management Unit<br />
descriptor, can be used when two or more logical addresses access a single page descriptor.<br />
The table search uses logical addresses to access the translation tables. Figure 4-7 illustrates<br />
a logical address format, which is segmented into four fields: root index (RI), pointer<br />
index (PI), page index (PGI), and page offset. The first three fields extracted from the logical<br />
address index the base address for each table level. The seven bits of the logical address<br />
RI field are multiplied by 4 or shifted to the left by two bits. This sum is concatenated with<br />
the upper 23 bits of the appropriate root pointer (URP or SRP) to yield the physical address<br />
of a root-level table descriptor. Each of the 128 root-level table descriptors corresponds to<br />
a 32-Mbyte block of memory and points to the base of a pointer-level table.<br />
The seven bits of a logical address PI field are multiplied by 4 (shifted to the left by two bits)<br />
and concatenated with the fetched root-level descriptor’s upper 23 bits to produce the physical<br />
address of the pointer-level table descriptor. Each of the 128 pointer-level table descriptors<br />
corresponds to a 256-Kbyte block of memory.<br />
4-8<br />
ROOT POINTER<br />
Figure 4-6. Translation Table Structure<br />
Figure 4-7. Logical Address Format<br />
<strong>M68060</strong> USER’S MANUAL<br />
FIRST<br />
LEVEL<br />
SECOND<br />
LEVEL<br />
THIRD<br />
LEVEL<br />
ROOT<br />
TABLES<br />
POINTER<br />
TABLES<br />
PAGE<br />
TABLES<br />
31 25 24 18 17 13 12 11 0<br />
7 BITS<br />
7 BITS<br />
8K PAGE<br />
4K PAGE<br />
13 BITS - 8K PAGE<br />
12 BITS - 4K PAGE<br />
ROOT INDEX FIELD<br />
(RI)<br />
POINTER INDEX FIELD<br />
(PI)<br />
PAGE INDEX FIELD<br />
(PGI)<br />
PAGE OFFSET<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
For 8-Kbyte pages, the five bits of the PGI field are multiplied by 4 (shifted to the left by two<br />
bits) and concatenated with the fetched pointer-level descriptor’s upper 25 bits to produce<br />
the physical address of the 8-Kbyte page descriptor. The upper 19 bits of the page descriptor<br />
are the page frame’s physical address. There are 32 8-Kbyte page descriptors in a pagelevel<br />
table.<br />
Similarly, for 4-Kbyte pages, the six bits of the PGI field are multiplied by 4 (shifted to the left<br />
by two bits) and concatenated with the fetched pointer-level descriptor’s upper 24 bits to produce<br />
the physical address of the 4-Kbyte page descriptor. The upper 20 bits of the page<br />
descriptor are the page frame’s physical address. There are 64 4-Kbyte page descriptors in<br />
a page-level table.<br />
Write-protect status is accumulated from each level’s descriptor and combined with the status<br />
from the page descriptor to form the ATC entry status. The MC68060 creates the ATC<br />
entry from the page frame address and the associated status bits and uses this address and<br />
attributes to generate a bus access. Refer to 4.3 Address Translation Caches for details<br />
on ATC entries.<br />
If the descriptor from a page table is an indirect descriptor, the page descriptor pointed to by<br />
this descriptor is fetched. Invalid descriptors can be used at any level of the tree except the<br />
root. When a table search for a normal translation encounters an invalid descriptor, the processor<br />
takes an access error exception. The invalid descriptor can be used to identify either<br />
a page or branch of the tree that has been stored on an external device and is not resident<br />
in memory or a portion of the translation table that has not yet been defined. In these two<br />
cases, the exception routine can either restore the page from disk or add to the translation<br />
table. Figure 4-8 and Figure 4-9 illustrate detailed flowcharts of table search and descriptor<br />
fetch operations.<br />
A table search terminates successfully when a page descriptor is encountered. The occurrence<br />
of an invalid descriptor or a transfer error acknowledge also terminates a table search,<br />
and the MC68060 takes an access error exception immediately on the data access and is<br />
delayed for instruction fetches until the instruction is ready to be executed. The exception<br />
handler should distinguish between anticipated conditions and true error conditions. The<br />
exception handler can correct an invalid descriptor that indicates a nonresident page or one<br />
that identifies a portion of the translation table yet to be allocated. An access error due to a<br />
system malfunction can require the exception handler to write an error message and terminate<br />
the task. The fault status long word (FSLW) of the access error stack frame provides<br />
detailed information regarding the cause of the exception. Refer to Section 8 Exception<br />
Processing for more information on exception handling.<br />
The processor does not use the data cache when performing a table search. Therefore,<br />
translation tables must not be placed in copyback space, since the normal accesses which<br />
build the translation tables would be cached and not written to external memory, but the processor<br />
only uses tables in external memory. This is a functional difference between the<br />
MC68060 and the MC68040.<br />
Table and page descriptors must not be left in a state that is incoherent to the processor.<br />
Violation of this restriction can result in an undefined operation. Page descriptors must not<br />
4-9
Memory Management Unit<br />
4-10<br />
EXIT TABLE SEARCH<br />
ABBREVIATIONS:<br />
PFA - PAGE FRAME ADDRESS<br />
DF[ ] - DESCRIPTOR FIELD<br />
WP - ACCUMULATED WRITE-<br />
PROTECTION STATUS<br />
ASSIGNMENT OPERATOR<br />
➧<br />
'INVALID'<br />
'INVALID'<br />
'INVALID'<br />
OTHERWISE<br />
ENTRY<br />
SELECT ROOT POINTER<br />
FC2 = 0:URP, 1:SRP<br />
(INITIALIZE ACCRUED<br />
STATUS)<br />
➧WP 0<br />
UPDATE FALSE<br />
TYPE 'POINTER'<br />
➧<br />
FETCH ROOT<br />
DESCRIPTOR<br />
FETCH POINTER<br />
DESCRIPTOR<br />
FETCH PAGE<br />
DESCRIPTOR<br />
TYPE 'INDIRECT'<br />
➧<br />
➧<br />
(CHECK DESCRIPTOR TYPE)<br />
'RESIDENT'<br />
(CHECK DESCRIPTOR TYPE)<br />
'RESIDENT'<br />
TYPE 'PAGE'<br />
➧<br />
(CHECK DESCRIPTOR TYPE)<br />
'INDIRECT'<br />
FETCH INDIRECT<br />
DESCRIPTOR<br />
(CHECK DESCRIPTOR TYPE)<br />
'RESIDENT'<br />
'RESIDENT'<br />
Figure 4-8. Detailed Flowchart of Table Search Operation<br />
<strong>M68060</strong> USER’S MANUAL<br />
PFA = PHYSICAL ADDRESS<br />
FIELD OF DESCRIPTOR<br />
CREATE ATC ENTRY<br />
ATC TAG FC2, LA, DF[G]<br />
ATC ENTRY PFA, DF[U1,U0,S,CM,M],WP<br />
➧ ➧<br />
EXIT TABLE SEARCH<br />
MOTOROLA
MOTOROLA<br />
EXIT TABLE SEARCH<br />
RETURN<br />
FETCH DESCRIPTOR<br />
AT PA = TA + (INDEX*4)<br />
IF SCHEDULED, EXECUTE<br />
WRITE ACCESS (U 1) FOR<br />
PREVIOUS DESCRIPTOR<br />
SCHEDULE<br />
WRITE ACCESS<br />
U 1<br />
(SEE NOTE)<br />
➧<br />
WP = WP V W<br />
NOTE : DUE TO ACCESS PIPELINING, A POINTER<br />
DESCRIPTOR WRITE ACCESS TO UPDATE<br />
THE U-BIT OCCURS AFTER THE READ OF<br />
THE NEXT LEVEL DESCRIPTOR.<br />
ABBREVIATIONS:<br />
WP – ACCUMULATED WRITE-<br />
PROTECTION STATUS<br />
V – LOGICAL "OR" OPERATOR<br />
– ASSIGNMENT OPERATOR<br />
➧<br />
'INVALID'<br />
TYPE = 'PAGE' OR 'POINTER'<br />
(INDEX = RI, PI, OR PGI)<br />
➧<br />
(SEE NOTE)<br />
OTHERWISE<br />
U = 0<br />
'RESIDENT'<br />
RETURN<br />
FETCH DESCRIPTOR &<br />
UPDATE HISTORY AND STATUS<br />
U = 1<br />
NORMAL TERMINATION<br />
OF ALL BUS TRANSFERS<br />
TYPE =<br />
'POINTER'<br />
U = 1<br />
TYPE = 'INDIRECT'<br />
FETCH DESCRIPTOR AT<br />
PA = DESCRIPTOR ADDRESS<br />
TYPE = 'PAGE'<br />
OR 'INDIRECT'<br />
READ ACCESS<br />
'RESIDENT'<br />
WP = WP V W<br />
EXECUTE<br />
LOCKED<br />
RMW ACCESS<br />
U 1<br />
Figure 4-9. Detailed Flowchart of Descriptor Fetch Operation<br />
<strong>M68060</strong> USER’S MANUAL<br />
'INVALID'<br />
OR 'INDIRECT'<br />
EXECUTE<br />
WRITE ACCESS<br />
U 1, M 1<br />
Memory Management Unit<br />
U = 0 &<br />
U = 1 &<br />
U = 0 (WP = 1 OR M = 1) (WP = 1 OR M = 1)<br />
➧<br />
WRITE ACCESS<br />
WP = 0 & M = 0<br />
➧<br />
➧<br />
RETURN<br />
OTHERWISE<br />
NORMAL TERMINATION<br />
OF ALL BUS TRANSFERS<br />
RETURN EXIT TABLE SEARCH<br />
4-11
Memory Management Unit<br />
have an encoding of U-bit = 0, M-bit = 1, and PDT field = 01 or 11. This encoding indicates<br />
that the page descriptor is resident, not used, and modified. The processor’s table search<br />
algorithm never leaves a descriptor in this state. This state is possible through direct manipulation<br />
by the operating system for this specific instance.<br />
4.2.2 Descriptors<br />
There are three types of descriptors used in the translation tables, root, pointer, and page.<br />
Root table descriptors are used in root-level tables and pointer table descriptors are used in<br />
pointer-level tables. Descriptors in the page-level tables contain either a page descriptor for<br />
the translation or an indirect descriptor that points to a memory location containing the page<br />
descriptor. The P-bit in the TCR selects the page size as either 4 or 8 Kbytes.<br />
4.2.2.1 TABLE DESCRIPTORS. Figure 4-10 illustrates the formats of the root and pointer<br />
table descriptors.<br />
31 9 8 7 6 5 4 3 2 1 0<br />
POINTER TABLE ADDRESS<br />
ROOT TABLE DESCRIPTOR (ROOT LEVEL)<br />
X X X X X U W UDT<br />
31 9 8 7 6 5 4 3 2 1 0<br />
PAGE TABLE ADDRESS<br />
POINTER TABLE DESCRIPTOR (POINTER LEVEL)<br />
X X X X X U W UDT<br />
4.2.2.2 PAGE DESCRIPTORS. Figure 4-11 illustrates the page descriptors for both<br />
4-Kbyte and 8-Kbyte page sizes. Refer to Section 5 Caches for details concerning caching<br />
page descriptors.<br />
4-12<br />
Figure 4-10. Table Descriptor Formats<br />
31 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
PHYSICAL ADDRESS<br />
4K PAGE DESCRIPTOR (PAGE LEVEL)<br />
UR G U1 U0 S CM M U W PDT<br />
31 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
PHYSICAL ADDRESS<br />
8K PAGE DESCRIPTOR (PAGE LEVEL)<br />
UR UR G U1 U0 S CM M U W PDT<br />
31 7 6 5 4 3 2 1 0<br />
DESCRIPTOR ADDRESS PDT<br />
INDIRECT PAGE DESCRIPTOR (PAGE LEVEL)<br />
Figure 4-11. Page Descriptor Formats<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
4.2.2.3 DESCRIPTOR FIELD DEFINITIONS. The field definitions for the table- and pagelevel<br />
descriptors are listed in alphabetical order:<br />
CM—Cache Mode<br />
This field selects the cache mode and accesses serialization as follows:<br />
00 = Cachable, Writethrough<br />
01 = Cachable, Copyback<br />
10 = Cache-Inhibited, Precise exception model<br />
11 = Cache-Inhibited, Imprecise exception model<br />
Section 5 Caches provides detailed information on caching modes.<br />
Descriptor Address<br />
This 30-bit field, which contains the physical address of a page descriptor, is only used in<br />
indirect descriptors.<br />
G—Global<br />
When this bit is set, it indicates the entry is global which gives the user the option of grouping<br />
entries as global or nonglobal for use when PFLUSHing the ATC, and has no other<br />
meaning. PFLUSH instruction variants that specify nonglobal entries do not invalidate global<br />
entries, even when all other selection criteria are satisfied. If these PFLUSH variants<br />
are not used, then system software can use this bit.<br />
M—Modified<br />
This bit identifies a page which has been written to by the processor. The MC68060 sets<br />
the M-bit in the corresponding page descriptor before a write operation to a page for which<br />
the M-bit is clear, except for write-protect or supervisor violations in which case the M-bit<br />
is not set. The read portion of a locked read-modify-write access is considered a write for<br />
updating purposes. The MC68060 never clears this bit.<br />
PDT—Page Descriptor Type<br />
This field identifies the descriptor as an invalid descriptor, a page descriptor for a resident<br />
page, or an indirect pointer to another page descriptor.<br />
00 = Invalid<br />
This code indicates that the descriptor is invalid. An invalid descriptor can represent<br />
a nonresident page or a logical address range that is out of bounds. All other<br />
bits in the descriptor are ignored. When an invalid descriptor is encountered, an<br />
ATC entry is not created.<br />
01 or 11 = Resident<br />
These codes indicate that the page is resident.<br />
10 = Indirect<br />
This code indicates that the descriptor is an indirect descriptor. Bits 31–2 contain<br />
the physical address of the page descriptor. This encoding is invalid for a page<br />
descriptor pointed to by an indirect descriptor (that is, only one level of indirection<br />
is allowed).<br />
4-13
Memory Management Unit<br />
Physical Address—<br />
This 20-bit field contains the physical base address of a page in memory. The logical<br />
address supplies the low-order bits of the address required to index into the page. When<br />
the page size is 8-Kbyte, the least significant bit of this field is not used.<br />
S—Supervisor Protected<br />
This bit identifies a page as supervisor only. Only programs operating in the supervisor<br />
mode are allowed to access the portion of the logical address space mapped by this<br />
descriptor when the S-bit is set. If the bit is clear, both supervisor and user accesses are<br />
allowed.<br />
Page Table Address<br />
This field contains the physical base address of a table of page descriptors. The low-order<br />
bits of the address required to index into the page table are supplied by the logical<br />
address.<br />
U—Used<br />
The processor automatically sets this bit when a descriptor is accessed in which the U-bit<br />
is clear. In a page descriptor table, this bit is set to indicate that the page corresponding<br />
to the descriptor has been accessed. In a pointer table, this bit is set to indicate that the<br />
pointer has been accessed by the MC68060 as part of a table search. The U-bit is<br />
updated before the MC68060 allows a page to be accessed. The processor never clears<br />
this bit.<br />
U0, U1—User Page Attributes<br />
These bits are user defined and the processor does not interpret them. U0 and U1 are<br />
echoed to the UPA0 and UPA1 signals, respectively, if an external bus transfer results<br />
from the access. Applications for these bits include extended addressing and snoop protocol<br />
selection.<br />
UDT—Upper Level Descriptor Type<br />
These bits indicate whether the next level table descriptor is resident.<br />
00 or 01 = Invalid<br />
These codes indicate that the table at the next level is not resident or that the logical<br />
address is out of bounds. All other bits in the descriptor are ignored. When an<br />
invalid descriptor is encountered, an ATC entry is not created.<br />
10 or 11 = Resident<br />
These codes indicate that the page is resident.<br />
UR—User Reserved<br />
These single bit fields are reserved for use by the user.<br />
W—Write Protected<br />
Setting the W-bit in a table descriptor write protects all pages accessed with that descriptor.<br />
When the W-bit is set, a write access or a locked read-modify-write access to the logical<br />
address corresponding to this entry causes an access error exception to be taken.<br />
4-14<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
X—Motorola Reserved<br />
These bit fields are reserved for future use by Motorola.<br />
4.2.3 Translation Table Example<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
Figure 4-12 illustrates an access example to the logical address $76543210 while in the<br />
supervisor mode with an 8-Kbyte memory page size. The RI field of the logical address, $3B,<br />
is mapped into bits 8–2 of the SRP value to select a 32-bit root table descriptor at a rootlevel<br />
table. The selected root table descriptor points to the base of a pointer-level table, and<br />
the PI field of the logical address, $15, is mapped into bits 8–2 of this base address to select<br />
a pointer descriptor within the table. This pointer table descriptor points to the base of a<br />
page-level table, and the PGI field of the logical address, $1, is mapped into bits 6–2 of this<br />
base address to select a page descriptor within the table.<br />
$76543210 =<br />
TABLE ENTRY # =<br />
ADDRESS OFFSET =<br />
SUPERVISOR<br />
MODE<br />
ROOT INDEX POINTER INDEX PAGE INDEX PAGE OFFSET<br />
0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 1 X X X X X X X X X X X X X<br />
$3B $15 $01<br />
SRP<br />
ROOT LEVEL<br />
TABLES<br />
LOGICAL ADDRESS<br />
$EC $54 $04<br />
$3B<br />
TABLE $00<br />
POINTER LEVEL<br />
TABLES<br />
Figure 4-12. Example Translation Table<br />
TABLE $00 TABLE $00<br />
TABLE $3B TABLE $15<br />
$00001800 $15 $00003000 $01<br />
FRAME ADDRESS<br />
TABLE $7F TABLE $1F<br />
PAGE LEVEL<br />
TABLES<br />
4-15
Memory Management Unit<br />
4.2.4 Variations in Translation Table Structure<br />
Several aspects of the MMU translation table structure are software configurable, allowing<br />
the system designer flexibility to optimize the performance of the MMUs for a particular system.<br />
The following paragraphs discuss the variations of the translation table structure.<br />
4.2.4.1 INDIRECT ACTION. The MC68060 provides the ability to replace an entry in a page<br />
table with a pointer to an alternate entry. The indirection capability allows multiple tasks to<br />
share a physical page while maintaining only a single set of history information for the page<br />
(i.e., the modified indication is maintained only in the single descriptor). The indirection<br />
capability also allows the page frame to appear at arbitrarily different addresses in the logical<br />
address spaces of each task.<br />
Using the indirection capability, single entries or entire tables can be shared between multiple<br />
tasks. Figure 4-13 illustrates two tasks sharing a page using indirect descriptors.<br />
4-16<br />
$76543210 =<br />
TABLE ENTRY # =<br />
ADDRESS OFFSET =<br />
TASK A<br />
TASK B<br />
ROOT INDEX POINTER INDEX PAGE INDEX PAGE OFFSET<br />
0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 1 X X X X X X X X X X X X X<br />
$3B $15 $01<br />
ROOT POINTER<br />
ROOT POINTER<br />
ROOT-LEVEL<br />
TABLES<br />
LOGICAL ADDRESS<br />
$EC $54 $04<br />
$3B<br />
TABLE $00<br />
Figure 4-13. Translation Table Using Indirect Descriptors<br />
<strong>M68060</strong> USER’S MANUAL<br />
TABLE $00 TABLE $00<br />
TABLE $3B TABLE $15<br />
$00001800 $15 $00003000 $01 $80000010<br />
TABLE $7F TABLE $1F<br />
POINTER-LEVEL<br />
TABLES<br />
FRAME ADDRESS<br />
PAGE-LEVEL<br />
TABLES<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
When the MC68060 has completed a normal table search, it examines the PDT field of the<br />
last entry fetched from the page tables. If the PDT field contains an indirect ($2) encoding,<br />
it indicates that the address contained in the highest order 30 bits of the descriptor is a<br />
pointer to the page descriptor that is to be used to map the logical address. The processor<br />
then fetches the page descriptor from this address and uses the physical address field of<br />
the page descriptor as the physical mapping for the logical address.<br />
The page descriptor located at the address given by the indirect descriptor must not have a<br />
PDT field with an indirect encoding (it must be either a resident descriptor or invalid). Otherwise,<br />
the descriptor is treated as invalid, and the MC68060 takes an access error exception.<br />
4.2.4.2 TABLE SHARING BETWEEN TASKS. More than one task can share a pointer- or<br />
page-level table by placing a pointer to a shared table in the address translation tables. The<br />
upper (nonshared) tables can contain different write-protected settings, allowing different<br />
tasks to use the memory areas with different write permissions. In Figure 4-14, two tasks<br />
share the memory translated by the table at the pointer table level. Task A cannot write to<br />
the shared area; task B, however, has the W-bit clear in its pointer to the shared table so<br />
that it can read and write the shared area. Also, the shared area appears at different logical<br />
addresses for each task. Figure 4-14 illustrates shared tables in a translation table structure.<br />
4.2.4.3 TABLE PAGING. The entire translation table for an active task need not be resident<br />
in main memory. In the same way that only the working set of pages must be allocated in<br />
main memory, only the tables that describe the resident set of pages need be available.<br />
Placing the invalid code ($0 or $1) in the UDT field of the table descriptor that points to the<br />
absent table(s) implements this paging of tables. When a task attempts to use an address<br />
that an absent table would translate, the MC68060 is unable to locate a translation and takes<br />
an access error exception when the access is needed (immediately for operand accesses<br />
and when the instruction is needed for instructions).<br />
The operating system determines that the invalid code in the descriptor corresponds to nonresident<br />
tables. This determination can be facilitated by using the unused bits in the descriptor<br />
to store status information concerning the invalid encoding. The MC68060 does not<br />
interpret or modify an invalid descriptor’s fields except for the UDT field. This interpretation<br />
allows the operating system to store system-defined information in the remaining bits. Information<br />
typically stored includes the reason for the invalid encoding (tables paged out, region<br />
unallocated, etc.) and possibly the disk address for nonresident tables. Figure 4-15 illustrates<br />
an address translation table in which only a single page table (table $15) is resident;<br />
all other page tables are not resident.<br />
4.2.4.4 DYNAMICALLY ALLOCATED TABLES. Similar to paged tables, a complete translation<br />
table need not exist for an active task. The operating system can dynamically allocate<br />
the translation table based on requests for access to particular areas.<br />
Since it is difficult and less efficient to predict and reserve memory in advance for a task, an<br />
operating system may choose to allocate no memory for a task until a demand is made<br />
requesting access. This access may be to a previously unused area or for data that is no<br />
longer resident in memory. If the access error handler adds to and updates the translation<br />
4-17
Memory Management Unit<br />
table for each demand, then the process of making such demands builds the translation<br />
table.<br />
For example, consider an operating system that is preparing the system to execute a previously<br />
unexecuted task that has no translation table. Rather than guessing what the memoryusage<br />
requirements of the task are, the operating system creates a translation table for the<br />
task that maps one page corresponding to the initial value of the program counter (PC) for<br />
that task and one page corresponding to the initial stack pointer of the task, leaving the other<br />
branches with invalid descriptors. All other branches of the translation table for this task<br />
remain unallocated until the task requests access to the areas mapped by these branches.<br />
This technique allows the operating system to construct a minimal translation table for each<br />
task, conserving physical memory utilization and minimizing operating system overhead.<br />
4-18<br />
$76543210 =<br />
TABLE ENTRY # =<br />
ADDRESS OFFSET =<br />
TASK A<br />
TASK B<br />
ROOT INDEX POINTER INDEX PAGE INDEX PAGE OFFSET<br />
0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 1 X X X X X X X X X X X X X<br />
$3B $15 $01<br />
ROOT POINTER<br />
ROOT POINTER<br />
$3B<br />
ROOT-LEVEL<br />
TABLES<br />
LOGICAL ADDRESS<br />
$EC $54 $04<br />
TABLE $00 TABLE $00 TABLE $00<br />
W-BIT SET<br />
W-BIT CLEAR<br />
Figure 4-14. Translation Table Using Shared Tables<br />
<strong>M68060</strong> USER’S MANUAL<br />
TABLE $3B TABLE $15<br />
$15 $00003000<br />
$01 FRAME ADDRESS*<br />
POINTER-LEVEL<br />
TABLES<br />
* PAGE FRAME ADDRESS SHARED BY TASK A AND B; WRITE PROTECTED FROM TASK A.<br />
PAGE-LEVEL<br />
TABLES<br />
MOTOROLA
4.2.5 Table Search Accesses<br />
MOTOROLA<br />
$76543210 =<br />
TABLE ENTRY # =<br />
ADDRESS OFFSET =<br />
SRP<br />
$3B<br />
SUPERVISOR<br />
TABLE $00 TABLE $00<br />
UDT = INVALID<br />
UDT = INVALID<br />
UDT = RESIDENT<br />
UDT = INVALID<br />
UDT = INVALID<br />
LOGICAL ADDRESS<br />
ROOT INDEX POINTER INDEX PAGE INDEX PAGE OFFSET<br />
Figure 4-15. Translation Table with Nonresident Tables<br />
<strong>M68060</strong> USER’S MANUAL<br />
TABLE $3B<br />
UDT = INVALID<br />
Memory Management Unit<br />
0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 1 X X X X X X X X X X X X X<br />
$3B $15 $01<br />
$EC $54 $04<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
ROOT-LEVEL<br />
TABLES<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
$15<br />
UDT = INVALID<br />
UDT = RESIDENT<br />
UDT = INVALID<br />
$01 FRAME ADDRESS<br />
UDT = INVALID<br />
TABLE $7F<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
POINTER-LEVEL<br />
TABLES<br />
TABLE $00<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
TABLE $15<br />
TABLE $1F<br />
NONRESIDENT<br />
(PAGED OR<br />
UNALLOCATED)<br />
PAGE-LEVEL<br />
TABLES<br />
Table search accesses bypass the data cache. No allocation is done and no cache search<br />
is performed. Translation tables must not be placed in copyback space, since the normal<br />
accesses which build the translation tables would be cached and not written to external<br />
memory, but the processor only uses tables in external memory.<br />
During a table search, the U- and M-bits of the table descriptors are examined. For any<br />
access, if the U-bit is not set, the processor sets it using a complete read-modify-write<br />
sequence with the LOCK pin asserted. LOCK is asserted in this case to avoid loss of the<br />
status in certain multiprocessor applications which share translation tables. For a write<br />
access, if the M-bit in the page descriptor is not set, and if the page is not write-protected<br />
(W = 0) and the access is not a supervisor violation (for user accesses, the S-bit of the page<br />
descriptor must be clear), then the M-bit is set using a simple write. The U- and M-bits are<br />
4-19
Memory Management Unit<br />
updated before the MC68060 allows a page to be accessed. Table 4-1 lists the page<br />
descriptor update operations for each combination of U-bit, M-bit, write-protected, and read<br />
or write access type.<br />
An alternate address space access is a special case that is immediately used as a physical<br />
address without translation. Because the MC68060 implements a merged instruction and<br />
data space, instruction address spaces (SFC/DFC = $6 or $2) using the MOVES instruction<br />
are converted into data references (SFC/DFC = $5 or $1). The data memory unit handles<br />
these translated accesses as normal data accesses. If the access fails due to an ATC fault<br />
or a physical bus error, the resulting access error stack frame contains the converted function<br />
code in the TM field for the faulted access. If the MOVES instruction is used to write<br />
instruction address space, then to maintain cache coherency, the corresponding addresses<br />
must be invalidated in the instruction cache. The SFC and DFC values and results for normal<br />
(TT = 0) and for MOVES (TT = 10) accesses are listed in Table 4-2.<br />
4.2.6 Address Translation Protection<br />
The MC68060 MMUs provide separate translation tables for supervisor and user address<br />
spaces. The translation tables contain both mapping and protection information. Each table<br />
and page descriptor includes a write-protect (W) bit that can be set to provide write protec-<br />
4-20<br />
Table 4-1. Updating U-Bit and M-Bit for Page Descriptors<br />
Previous Status<br />
U-Bit M-Bit<br />
WP Bit<br />
Access<br />
Type<br />
Page Descriptor<br />
Update Operation<br />
New Status<br />
U-Bit M-Bit<br />
0 0<br />
Locked RMW Access to Set U 1 0<br />
0<br />
1<br />
1<br />
0<br />
X Read<br />
Locked RMW Access to Set U<br />
None<br />
1<br />
1<br />
1<br />
0<br />
1 1 None 1 1<br />
0 0<br />
Write to Set U and M 1 1<br />
0<br />
1<br />
1<br />
0<br />
0<br />
Write to Set U<br />
Write to Set M<br />
1<br />
1<br />
1<br />
1<br />
1<br />
0<br />
1<br />
0<br />
Write<br />
None<br />
None<br />
1<br />
0<br />
1<br />
0<br />
0<br />
1<br />
1<br />
0<br />
1<br />
None<br />
None<br />
0<br />
1<br />
1<br />
0<br />
1 1 None 1 1<br />
NOTE: WP indicates the accumulated write-protect status.<br />
Table 4-2. SFC and DFC Values<br />
SFC/DFC Value<br />
TT<br />
Results<br />
TM<br />
000 10 000<br />
001 00 001<br />
010 00 001<br />
011 10 011<br />
100 10 100<br />
101 00 101<br />
110 00 101<br />
111 10 111<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Memory Management Unit<br />
tion at any level. Page descriptors also contain a supervisor-only (S) bit that can limit access<br />
to programs operating at the supervisor privilege level.<br />
The protection mechanisms can be used individually or in any combination to protect:<br />
• Supervisor address space from accesses by user programs.<br />
• User address space from accesses by other user programs.<br />
• Supervisor and user program spaces from write accesses (implicitly supported by<br />
designating all memory pages used for program storage as write protected).<br />
• One or more pages of memory from write accesses.<br />
4.2.6.1 SUPERVISOR AND USER TRANSLATION TABLES. One way of protecting<br />
supervisor and user address spaces from unauthorized accesses is to use separate supervisor<br />
and user translation tables. Separate trees protect supervisor programs and data from<br />
accesses by user programs and user programs and data from access by supervisor programs.<br />
Supervisor programs may access user space through the MOVES instruction. With<br />
a user-space SFC/DFC, the MOVES access will be translated according to the user-mode<br />
translation tables. This translation table can be common to all tasks. Figure 4-16 illustrates<br />
separate translation tables for supervisor accesses and for two user tasks that share the<br />
common supervisor space. Each user task has a translation table with unique mappings for<br />
the logical addresses in its user address space.<br />
FOR TASK 'A'<br />
URP FOR TASK 'A'<br />
FOR TASK 'B'<br />
URP FOR TASK 'B'<br />
POINTER<br />
COMMON SRP<br />
USER A LEVEL TABLE<br />
Figure 4-16. Translation Table Structure for Two Tasks<br />
•<br />
•<br />
•<br />
USER A LEVEL TABLE<br />
•<br />
•<br />
•<br />
SUPERVISOR A LEVEL TABLE<br />
•<br />
•<br />
•<br />
TRANSLATION<br />
TABLE FOR<br />
TASK 'A'<br />
TRANSLATION<br />
TABLE FOR<br />
TASK 'B'<br />
TRANSLATION<br />
TABLE FOR<br />
ALL SUPERVISOR<br />
ACCESSES<br />
4-21
Memory Management Unit<br />
4.2.6.2 SUPERVISOR ONLY. A second mechanism protects supervisor programs and data<br />
without requiring segmenting of the logical address space into supervisor and user address<br />
spaces. Page descriptors contain S-bits to protect areas of memory from access by user<br />
programs. When a table search for a user access encounters an S-bit set in a page descriptor,<br />
the table search ends, and an access error exception is taken immediately for data<br />
accesses, or when the instruction is needed for instruction accesses. The S-bit can be used<br />
to protect one or more pages from user program access. Supervisor and user mode<br />
accesses can share descriptors by using indirect descriptors or by sharing tables. The entire<br />
user and supervisor address spaces can be mapped together by loading the same root<br />
pointer address into both the SRP and URP registers.<br />
4.2.6.3 WRITE PROTECT. The MC68060 provides write protection independent of other<br />
protection mechanisms. All table and page descriptors contain W-bits to protect areas of<br />
memory from write accesses of any kind, including supervisor writes. On a read-only<br />
access, if the ATC misses, and a W-bit (write-protect) is set in one or more of the table<br />
descriptors, the table search completes normally and the ATC is loaded with the internal Wbit<br />
set. Subsequent read-only accesses are allowed, but a subsequent write or read-modifywrite<br />
access to that address will immediately take the access error exception as a write-protect<br />
violation. The ATC entry and the related translation table entries are unchanged. On a<br />
write or read-modify-write access, if the ATC misses and a W-bit is found set in any table<br />
descriptor, the table search will terminate immediately and the access error exception is<br />
taken. In this case the ATC is not loaded, and the translation table history bits (U and M) for<br />
that descriptor are not updated. The W-bit can be used to protect the entire area of memory<br />
defined by a branch of the translation table or protect only one or more pages from write<br />
accesses. Figure 4-17 illustrates a memory map of the logical address space organized to<br />
use supervisor-only and write-protect bits for protection. Figure 4-18 illustrates an example<br />
translation table for this technique.<br />
SUPERVISOR AND USER SPACE<br />
THIS AREA IS SUPERVISOR ONLY, READ-ONLY<br />
THIS AREA IS SUPERVISOR ONLY, READ/WRITE<br />
THIS AREA IS SUPERVISOR OR USER, READ-ONLY<br />
THIS AREA IS SUPERVISOR OR USER, READ/WRITE<br />
Figure 4-17. Logical Address Map with Shared<br />
Supervisor and User Address Spaces<br />
4-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
PRIVILEGE<br />
MODE<br />
NOTE: X = DON'T CARE<br />
SRP<br />
URP<br />
URP & SRP POINT<br />
TO SAME A LEVEL<br />
TABLE<br />
W =1<br />
W = 0<br />
W = 1<br />
W = 0<br />
ROOT-LEVEL<br />
TABLE<br />
Memory Management Unit<br />
THIS PAGE<br />
SUPERVISOR ONLY,<br />
READ ONLY<br />
S = 1,W = X<br />
THIS PAGE<br />
SUPERVISOR ONLY,<br />
READ/WRITE<br />
W = 0 S = 1,W = 0<br />
THIS PAGE<br />
SUPERVISOR/USER,<br />
READ ONLY<br />
W = X S = 0,W = X<br />
THIS PAGE<br />
SUPERVISOR/USER,<br />
READ/WRITE<br />
W = 0 S = 0,W = 0<br />
POINTER-LEVEL<br />
TABLE<br />
PAGE-LEVEL<br />
TABLE<br />
Figure 4-18. Translation Table Using S-Bit and W-Bit To Set Protection<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 4-23<br />
W = X
Memory Management Unit<br />
4.3 ADDRESS TRANSLATION CACHES<br />
The ATCs in the MMUs are four-way set-associative caches that each store 64 logical-tophysical<br />
address translations and associated page information similar in form to the corresponding<br />
page descriptors in memory. The purpose of the ATC is to provide a fast mechanism<br />
for address translation by avoiding the overhead associated with a table search of the<br />
logical-to-physical mapping of recently used logical addresses. Figure 4-19 illustrates the<br />
organization of the ATC.<br />
31<br />
F<br />
C<br />
2<br />
17<br />
PAGE FRAME PAGE OFFSET<br />
16<br />
PAGE SIZE<br />
MUX<br />
4<br />
1<br />
1<br />
16<br />
SET<br />
SELECT<br />
3<br />
1<br />
12<br />
12<br />
SET 0<br />
SET 1<br />
SET 15<br />
17<br />
0<br />
TAG ENTRY<br />
•<br />
•<br />
•<br />
COMPARATOR<br />
0<br />
Figure 4-19. ATC Organization<br />
Each ATC entry consists of a physical address, attribute information from a corresponding<br />
page descriptor, and a tag that contains a logical address and status information. Figure 4-<br />
20, which illustrates the entry and tag fields, is followed by field definitions listed in alphabetical<br />
order.<br />
4-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
1<br />
•<br />
•<br />
•<br />
TAG ENTRY<br />
2<br />
3<br />
HIT 3<br />
HIT 2<br />
HIT 1<br />
HIT 0<br />
29<br />
1<br />
MUX<br />
PAGE SIZE<br />
29<br />
MUX<br />
HIT<br />
DETECT<br />
PA(11–0)<br />
PA(12)<br />
19<br />
PA(31–13)<br />
9<br />
STATUS<br />
LINE SELECT<br />
HIT
U1<br />
ENTRY<br />
U0 CM M W PHYSICAL ADDRESS*<br />
V G FC2 LOGICAL ADDRESS*<br />
TAG<br />
*FOR 4-KBYTE PAGE SIZES, THIS FIELD USES ADDRESS BITS 31–12; FOR 8-KBYTE PAGE SIZES, BITS 31–13.<br />
Figure 4-20. ATC Entry and Tag Fields<br />
CM—Cache Mode<br />
This field selects the cache mode and accesses serialization as follows:<br />
00 = Cachable, Writethrough<br />
01 = Cachable, Copyback<br />
10 = Noncachable, Precise<br />
11 = Noncachable, Imprecise<br />
Section 5 Caches provides detailed information on caching modes.<br />
Memory Management Unit<br />
FC2—Function Code Bit 2 (Supervisor/User)<br />
This bit contains the function code corresponding to the logical address in this entry. FC2<br />
is set for supervisor mode accesses and cleared for user mode accesses.<br />
G—Global<br />
When set, this bit indicates the entry is global. Global entries are not invalidated by the<br />
PFLUSH instruction variants that specify nonglobal entries, even when all other selection<br />
criteria are satisfied.<br />
Logical Address<br />
This 16-bit field contains the most significant logical address bits for this entry. All 16 bits<br />
of this field are used in the comparison of this entry to an incoming logical address when<br />
the page size is 4 Kbytes. For 8-Kbytes pages, the least significant bit of this field is<br />
ignored.<br />
M—Modified<br />
The modified bit is set when a valid write access to the logical address corresponding to<br />
the entry occurs. If the M-bit is clear and a write access to this logical address is<br />
attempted, the MC68060 suspends the access, initiates a table search to set the M-bit in<br />
the page descriptor, and writes over the old ATC entry with the current page descriptor<br />
information. The MMU then allows the original write access to be performed. This procedure<br />
ensures that the first write operation to a page sets the M-bit in both the ATC and the<br />
page descriptor in the translation tables, even when a previous read operation to the page<br />
had created an entry for that page in the ATC with the M-bit clear.<br />
Physical Address<br />
The upper bits of the translated physical address are contained in this field.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 4-25
Memory Management Unit<br />
U0, U1—User Page Attributes<br />
These user-defined bits are not interpreted by the MC68060. U0 and U1 are echoed to<br />
the UPA0 and UPA1 signals, respectively, if an external bus transfer results from the<br />
access.<br />
V—Valid<br />
When set, this bit indicates that the entry is valid. This bit is set when the MC68060 loads<br />
an entry. A flush operation by a PFLUSH or PFLUSHA instruction that selects this entry<br />
clears the bit.<br />
W—Write Protected<br />
This write-protect bit is set when a W-bit is set in any of the descriptors encountered during<br />
the table search for this entry. Setting a W-bit in a table descriptor write protects all<br />
pages accessed with that descriptor. When the W-bit is set, a write access or a locked<br />
read-modify-write access to the logical address corresponding to this entry causes an<br />
access error exception to be taken immediately.<br />
For each access to a memory unit, the MMU uses the four bits of the logical address located<br />
just above the page offset (LA16–LA13 for 8K pages, LA15–LA12 for 4K pages) to index<br />
into the ATC. The tags are compared with the remaining upper bits of the logical address<br />
and FC2. If one of the tags matches and is valid, then the multiplexer chooses the corresponding<br />
entry to produce the physical address and status information. The ATC outputs<br />
the corresponding physical address to the cache controller, which accesses the data within<br />
the cache and/or requests an external bus cycle. Each ATC entry contains a logical address,<br />
a physical address, and status bits.<br />
When the ATC does not contain the translation for a logical address, a miss occurs. The<br />
MMU aborts the current access and searches the translation tables in memory for the correct<br />
translation. If the table search completes without any errors, the MMU stores the translation<br />
in the ATC and provides the physical address and attributes for the access. Otherwise,<br />
if any bus errors (TEA asserted) or invalid descriptors are encountered, the ATC is not modified<br />
and an access error exception is taken. The MC68040 differs from the MC68060 in that<br />
the MC68040 ATC contains an R-bit. An R-bit is not needed on the MC68060 because the<br />
ATC is not updated when an access error occurs and therefore all ATC entries represent<br />
usable translations.<br />
There are some variations in the logical-to-physical mapping because of the two page sizes.<br />
If the page size is 4 Kbytes, then logical address bit 12 is used to access the ATC's memory,<br />
the tag comparators use bit 16, and physical address bit 12 is an ATC output. If the page<br />
size is 8 Kbytes, then logical address bit 16 is used to access the ATC's memory, and physical<br />
address bit 12 is driven by logical address bit 12. It is advisable that a translation always<br />
be disabled before changing size and that the ATCs are flushed before enabling translation<br />
again.<br />
The MMU is organized such that other operations always completely overlap the translation<br />
time of the ATCs; thus, no performance penalty is associated with ATC searches. The<br />
address translation occurs in parallel with indexing into the on-chip instruction and data<br />
caches.<br />
4-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Memory Management Unit<br />
The MMU replaces an invalid entry when the ATC stores a new address translation. When<br />
all entries in an ATC set are valid, the ATC selects a valid entry to be replaced, using a<br />
pseudo round robin replacement algorithm. A 2-bit counter, which is incremented for each<br />
ATC access, points to the entry to replace when an access misses in the ATC. ATC hit rates<br />
are application and page-size dependent, but hit rates ranging from 98% to greater than<br />
99% can be expected. These high rates are achieved because the ATCs are relatively large<br />
(64 entries) and utilization efficiency is high with 8-Kbyte and 4-Kbyte page sizes.<br />
4.4 TRANSPARENT TRANSLATION<br />
Four independent TTRs (DTT0 and DTT1 in the data MMU, ITT0 and ITT1 in the instruction<br />
MMU) define four blocks of logical address space to be translated to physical address<br />
space. These logical address spaces must be at least 16 Mbytes and can overlap or be separate.<br />
Each TTR can be disabled and completely ignored. The following description<br />
assumes that the TTRs are enabled.<br />
When an MMU receives an address to be translated, the privilege mode and the eight highorder<br />
bits of the address are compared to the logical address spaces defined by the two<br />
TTRs for the corresponding MMU. The logical address space for each TTR is defined by an<br />
S-field, logical base address field, and logical address mask field. The S-field allows matching<br />
either user or supervisor accesses or both accesses. When a bit in the logical address<br />
mask field is set, the corresponding bit of the logical base address is ignored in the address<br />
comparison. Setting successively higher order bits in the address mask increases the size<br />
of the physical address space.<br />
The address for the current bus cycle and a TTR address match when the privilege mode<br />
and logical base address bits are equal. Each TTR can specify write protection for the block.<br />
When write protection is enabled for a block, write or locked read-modify-write accesses to<br />
the block are aborted.<br />
By appropriately configuring a TTR, flexible transparent mappings can be specified (refer to<br />
4.1.3 Transparent Translation Registers for field identification). For instance, to transparently<br />
translate the user address space, the S-field is set to $0, and the logical address mask<br />
is set to $FF in both an instruction and data TTR. To transparently translate supervisor<br />
accesses of addresses $00000000–$0FFFFFFF with write protection, the logical base<br />
address field is set to $0x, the logical address mask is set to $0F, the W-bit is set to one,<br />
and the S-field is set to $1. It is not necessary for the mask field to specify a contiguous block<br />
of memory. The inclusion of independent TTRs in both the instruction and data MMUs provides<br />
an exception to the merged instruction and data address space, allowing different<br />
translations for instruction and operand accesses. Also, since the instruction memory unit is<br />
only used for instruction prefetches, different instruction and data TTRs can cause PC relative<br />
operand fetches to be translated differently from instruction prefetches.<br />
If either of the TTRs matched during an access to a memory unit (either instruction or data),<br />
the access is transparently translated. If both registers match, the TT0 status bits are used<br />
for the access. Transparent translation can also be implemented by the translation tables of<br />
the translation tables if the physical addresses of pages are set equal to their logical<br />
addresses.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 4-27
Memory Management Unit<br />
If the paged MMU is disabled (the E-bit in the TCR register is clear) and the TTRs are disabled<br />
or do not match, then the status and protection attributes are defined by the default<br />
translation bits (DCO, DUO, DWO, DCI, and DUI) in the TCR.<br />
4.5 ADDRESS TRANSLATION SUMMARY<br />
If the paged MMU is enabled (the E-bit in the TCR is set), the instruction and data MMUs<br />
process translations by first comparing the logical address and privilege mode with the<br />
parameters of the TTRs if they are enabled. If there is a match, the MMU uses the logical<br />
address as a physical address for the access. If there is no match, the MMU compares the<br />
logical address and privilege mode with the tag portions of the entries in the ATC and uses<br />
the corresponding physical address for the access when a match occurs. When neither a<br />
TTR nor a valid ATC entry matches, the MMU initiates a table search operation to obtain the<br />
corresponding physical address from the translation table. When a table search is required,<br />
the processor suspends instruction execution activity and, at the end of a successful table<br />
search, stores the address mapping in the appropriate ATC and retries the access. The<br />
MMU creates a valid ATC entry for the logical address. If the table search encounters an<br />
invalid descriptor, or a write-protect for a write, or is a user access and encounters a supervisor-only<br />
flag, then the access error exception is taken whenever the access is needed<br />
(immediately for operands and deferred for instruction fetches).<br />
If a write or locked read-modify-write access results in an ATC hit but the page is write protected,<br />
the access is aborted, and an access error exception is taken. If the page is not write<br />
protected and the modified bit of the ATC entry is clear, a table search proceeds to set the<br />
modified bit in both the page descriptor in memory and in the ATC; the access is retried. The<br />
ATC provides the address translation for the access if the modified bit of the ATC entry is<br />
set for a write or locked read-modify-write access to an unprotected page and if none of the<br />
TTRs (instruction or data, as appropriate) match.<br />
Figure 4-21 illustrates a general flowchart for address translation. The top branch of the flowchart<br />
applies to transparent translation. The bottom three branches apply to ATC translation.<br />
4.6 RSTI AND MDIS EFFECT ON THE MMU<br />
The following paragraph describes how the MMU is affected by the RSTI and MDIS pins.<br />
4.6.1 Effect of RSTI on the MMUs<br />
When the MC68060 is reset by the assertion of the reset input signal, the E-bits of the TCR<br />
and TTRs are cleared, disabling address translation. This reset causes logical addresses to<br />
be passed through as physical addresses, allowing an operating system to set up the translation<br />
tables and MMU registers as required. After the translation tables and registers are<br />
initialized, the E-bit of the TCR can be set, enabling paged address translation. While<br />
address translation is disabled, the default TTR is used. The default TTR attribute bits are<br />
cleared upon reset, so that immediately after assertion of RSTI the attributes will specify<br />
write-through cachable mode, no write protection, user page attribute bits cleared, and 1/2cache<br />
mode disabled.<br />
A reset of the processor does not invalidate any entries in the ATCs page size. A PFLUSH<br />
instruction must be executed to flush all existing valid entries from the ATCs after a reset<br />
4-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
ABORT CYCLE<br />
TABLE SEARCH<br />
OPERATION<br />
ABORT CYCLE<br />
ATC MISS<br />
[(W = 1) AND<br />
(WRITE OR LOCKED RMW CYCLE)<br />
TAKE ACCESS ERROR<br />
EXCEPTION<br />
(M = 0) AND<br />
(WRITE OR LOCKED RMW CYCLE)<br />
ENTRY<br />
OTHERWISE<br />
ATC HIT<br />
OTHERWISE<br />
PA ATC ENTRY [PA]<br />
UPA ATC ENTRY [U1,U0]<br />
CM ATC ENTRY [CM]<br />
➧<br />
➧ ➧<br />
OTHERWISE<br />
EXIT<br />
* Refers to either instruction or data transparent translation register.<br />
OTHERWISE<br />
PA LOGICAL ADDRESS<br />
UPA TTR1* [U1,U0]<br />
CM TTR1* [CM]<br />
➧<br />
➧<br />
➧<br />
LOGICAL ADDRESS<br />
MATCHES WITH<br />
TTRx*<br />
TAKE ACCESS ERROR<br />
EXCEPTION<br />
Figure 4-21. Address Translation Flowchart<br />
Memory Management Unit<br />
operation and before translation is enabled. PFLUSH can be executed even if the E-bit is<br />
cleared.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 4-29<br />
EXIT<br />
OTHERWISE<br />
(TTR1*[W] = 1) AND<br />
(WRITE OR LOCKED<br />
RMW ACCESS)<br />
ABORT CYCLE<br />
LOGICAL ADDRESS<br />
MATCHES WITH TTR0*<br />
(TTR0*[W] = 1) AND<br />
(WRITE OR LOCKED<br />
RMW ACCESS)<br />
OTHERWISE<br />
PA LOGICAL ADDRESS<br />
UPA TTR0* [U1,U0]<br />
CM TTR0* [CM]<br />
➧<br />
➧<br />
➧<br />
EXIT
Memory Management Unit<br />
4.6.2 Effect of MDIS on Address Translation<br />
The assertion of MDIS prevents the MMUs from performing ATC searches and the execution<br />
unit from performing table searches. With address translation disabled, logical<br />
addresses are used as physical addresses. MDIS disables the MMUs on the next internal<br />
access boundary when asserted and enables the MMUs on the next boundary after the signal<br />
is negated. The assertion of this signal does not affect the operation of the transparent<br />
translation registers or execution of the PFLUSH instruction.<br />
4.7 MMU INSTRUCTIONS<br />
The MC68060 instruction set includes three privileged instructions that perform MMU operations.<br />
The following paragraphs briefly describe each of these instructions. For detailed<br />
descriptions of these instructions, refer to M68000PR/AD, M68000 Family Programmer's<br />
Reference <strong>Manual</strong>.<br />
4.7.1 MOVEC<br />
The MOVEC instruction transfers data between an integer data register and any of the<br />
MC68060 control and status registers. The operating system uses the MOVEC instruction<br />
to control and monitor MMU operation by manipulating and reading the seven MMU registers.<br />
4.7.2 PFLUSH<br />
The PFLUSH instruction invalidates (flushes) address translation descriptors in the specified<br />
ATC(s). PFLUSHA, a version of the PFLUSH instruction, flushes all entries. The<br />
PFLUSH instruction flushes a user or supervisor entry with a specified logical address. The<br />
PFLUSHAN and PFLUSHN instruction variants qualify entry selection further by flushing<br />
only entries that are nonglobal, indicated by a cleared G-bit in the entry.<br />
4.7.3 PLPA<br />
The PLPA instruction ensures that an ATC is loaded with a valid translation, and returns the<br />
related physical address. If there is a hit in the ATC, and the access has write and supervisor<br />
privilege as specified, the PLPA returns the related physical address. If the PLPA misses in<br />
the ATC, a table search is performed. A successful table search results in the ATC being<br />
loaded with a valid translation; a table search which encounters an invalid descriptor, writeprotection<br />
violation, bus error or a supervisor violation will cause the access error exception<br />
to be taken. There are two variants of PLPA, which are PLPAR and PLPAW, which check<br />
the privilege and set the table and ATC history bits as if a read or write access, respectively,<br />
were being performed.<br />
4-30 <strong>M68060</strong> USER’S MANUAL MOTOROLA
SECTION 5<br />
CACHES<br />
The MC68060 contains two independent 8-Kbyte, on-chip caches which can be accessed<br />
simultaneously for instruction and operand data. The caches improve system performance<br />
by providing low latency data to the MC68060 instruction and data pipes. This decouples<br />
processor performance from system memory performance and increases bus availability for<br />
alternate bus masters.<br />
As shown in Figure 5-1, the instruction and data caches are contained in the instruction and<br />
data memory units. The appropriate memory unit independently services instruction<br />
prefetch from the instruction fetch unit (IFU) and data requests from the operand pipe unit<br />
(OPU). The memory units translate the logical address in parallel with indexing into the<br />
cache. If the translated (physical) address matches one of the cache entries, the access hits<br />
in the cache. For a read operation, the memory unit supplies the data to the IPU instruction<br />
buffer or the OPU, and for a write operation, the memory unit updates the cache. If the<br />
access does not match one of the cache entries (misses in the cache) or a write access must<br />
be written through to memory, the appropriate memory unit sends an external bus request<br />
to the bus controller. The bus controller then reads or writes the required data. In the event<br />
that the bus controller receives an external bus request from both memory units, the bus<br />
controller invokes its priority scheme to choose between IPU and OPU requests.<br />
To maintain cache coherency, the MC68060 provides automatic snoop-invalidation when it<br />
is not the bus master. Unlike the MC68040, the MC68060 cannot not source or sink cache<br />
data during alternate bus master accesses.<br />
The MC68060 implements a bus snooper that maintains cache coherency by monitoring an<br />
alternate bus master access to memory and invalidating matching cache lines during the<br />
alternate bus master access. The MC68060 requires that memory pages shared with other<br />
bus masters be cache inhibited or marked cachable writethrough (instead of copyback).<br />
When a processor writes to writethrough pages, external memory is always updated through<br />
an external bus access after updating the cache, keeping memory and cached data consistent.<br />
5.1 CACHE OPERATION<br />
Both four-way set-associative caches have 128 sets of four 16-byte lines. Each set in both<br />
caches has a tag (consisting of the upper 21 bits of the physical address), status information,<br />
and four long words (128 bits) of data. The status information for the instruction cache is a<br />
single valid bit for the line. The status information for the data cache is a valid bit and a dirty<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
5-1
Caches<br />
bit for the line. Note that only the data cache supports dirty cache lines. Figure 5-2 illustrates<br />
the instruction cache line format and Figure 5-3 illustrates the data cache line format.<br />
The cache stores an entire line, providing validity on a line-by-line basis. Only burst mode<br />
accesses that successfully read four long words can be cached.<br />
A cache line is always in one of three states: invalid, valid, or dirty. For invalid lines, the Vbit<br />
is clear, causing the cache line to be ignored during lookups. Valid lines have their V-bit<br />
set and D-bit cleared, the line contains valid data consistent with memory. Dirty cache lines<br />
5-2<br />
EXECUTION UNIT<br />
FLOATING-<br />
POINT<br />
UNIT<br />
EA<br />
FETCH<br />
FP<br />
EXECUTE<br />
BRANCH<br />
CACHE<br />
INSTRUCTION FETCH UNIT<br />
pOEP sOEP<br />
DECODE<br />
DS<br />
DECODE<br />
DS<br />
EA AG EA AG<br />
CALCULATE<br />
CALCULATE<br />
OC EA OC EA OC<br />
FETCH<br />
FETCH<br />
EX<br />
INT EX INT EX<br />
EXECUTE<br />
EXECUTE<br />
DATA AVAILABLE<br />
WRITE-BACK<br />
INSTRUCTION<br />
BUFFER<br />
INTEGER UNIT<br />
IA<br />
CALCULATE<br />
INSTRUCTION<br />
FETCH<br />
EARLY<br />
DECODE<br />
IAG<br />
IB<br />
IC<br />
IED<br />
DA<br />
WB<br />
OPERAND DATA BUS<br />
INSTRUCTION<br />
ATC<br />
Figure 5-1. MC68060 Instruction and Data Caches<br />
TAG<br />
WHERE:<br />
V LW3 LW2 LW1 LW0<br />
TAG—21-BIT PHYSICAL ADDRESS TAG<br />
V—VALID BIT FOR LINE<br />
LWn—LONG WORD n (32-BIT) DATA ENTRY<br />
Figure 5-2. Instruction Cache Line Format<br />
TAG V D LW3 LW2 LW1 LW0<br />
WHERE:<br />
TAG—21-BIT PHYSICAL ADDRESS TAG<br />
V—VALID BIT FOR LINE<br />
D—DIRTY BIT FOR LINE<br />
LWn—LONG WORD n (32-BIT) DATA ENTRY<br />
Figure 5-3. Data Cache Line Format<br />
<strong>M68060</strong> USER’S MANUAL<br />
INSTRUCTION<br />
CACHE<br />
CONTROLLER<br />
INSTRUCTION MEMORY UNIT<br />
DATA<br />
ATC<br />
DATA<br />
CACHE<br />
CONTROLLER<br />
DATA MEMORY UNIT<br />
INSTRUCTION<br />
CACHE<br />
DATA<br />
CACHE<br />
B<br />
U<br />
S<br />
C<br />
O<br />
N<br />
T<br />
R<br />
O<br />
L<br />
L<br />
E<br />
R<br />
ADDRESS<br />
DATA<br />
CONTROL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
have the V-bit and D-bit set, indicating that the line has valid entries that have not been written<br />
to memory. A cache line changes states from valid or dirty to invalid if the execution of<br />
the CINV or CPUSH instruction explicitly invalidates the cache line or if a snooped access<br />
hits the cache line. Both caches should be explicitly cleared using the CINVA instruction<br />
after a hardware reset of the processor since reset does not invalidate the cache lines.<br />
Figure 5-4 illustrates the general flow of a caching operation. The caches use the physical<br />
addresses, and to simplify the discussion, the discussion of the translation of logical to physical<br />
addresses is omitted.<br />
31 11 10<br />
4 3 0<br />
TAG DATA/TAG REFERENCE INDEX<br />
PA31-PA11<br />
PHYSICAL ADDRESS<br />
TRANSLATED<br />
PHYSICAL<br />
ADDRESS<br />
PA31–PA11<br />
PHYSICAL<br />
SET SELECT<br />
PA10–PA4<br />
SET 0<br />
SET 1<br />
SET 128<br />
COMPARATOR<br />
TAG STATUS<br />
TAG STATUS<br />
Figure 5-4. Caching Operation<br />
To determine if the physical address is already allocated in the cache, the lower physical<br />
address bits 10–4 are used to index into the cache and select 1 of 128 sets of cache lines.<br />
Physical address bits 31–11 are used as a tag reference or to update the cache line tag<br />
0<br />
1<br />
LINE 0<br />
2<br />
LINE 1<br />
3<br />
LINE 2<br />
LINE 3<br />
LW0 LW1 LW2 LW3<br />
LW0 LW1 LW2 LW3<br />
HIT 3<br />
HIT 2<br />
HIT 1<br />
HIT 0<br />
MUX<br />
LOGICAL OR<br />
DATA OR<br />
INSTRUCTION<br />
LINE SELECT<br />
HIT<br />
5-3
Caches<br />
field. The four tags from the selected cache set are compared with the tag reference. If any<br />
one of the four tags matches the tag reference and the tag status is either valid or dirty, then<br />
a cache hit has occurred. A cache hit indicates that the data entries (LW3–LW0) in that<br />
cache line contain valid data (for a read access) or is written with new data (for a write access).<br />
To allocate an entry into the cache, the physical address bits 10–4 are used to index into the<br />
cache and select one of the 128 sets of cache lines. The status of each of the four cache<br />
lines is examined. The cache control logic first looks for an invalid cache line to use for the<br />
new entry. If no invalid cache lines are available, then one of the four cache lines must be<br />
deallocated to host the new entry. The cache controller uses a pseudo round-robin replacement<br />
algorithm to determine which cache line will be deallocated and replaced.<br />
In the process of deallocation, a cache line that is valid and not dirty is invalidated. A dirty<br />
cache line is placed in a push buffer (to do an external cache line write push) before being<br />
invalidated. Once a cache line is invalidated, it is replaced with the new entry.<br />
When a cache line is selected to host a new cache entry, the new physical address bits 31–<br />
11 are written to the tag, the data bits LW3–LW0 are updated with the new memory data,<br />
and the cache line status is changed to a valid state. Allocating a new entry into the cache<br />
is always associated with a visible cache line read bus cycle externally.<br />
Read cycles that miss in the cache allocate normally as described in the previous paragraphs.<br />
Write cycles that miss in the cache do not allocate on a cachable writethrough page,<br />
but do allocate on a cachable copyback page. The allocation process initiates a line read to<br />
allocate a valid entry in the cache as previously described, and is immediately followed by<br />
a write to the newly allocated cache line changing the cache line status to dirty. No external<br />
write to memory occurs.<br />
Read hits do not change the cache status of the cache line that hit and no deallocation and<br />
replacement occurs. Write hits on cachable writethrough pages perform an external write<br />
bus cycle; write hits on cachable copyback pages do not perform an external bus cycle.<br />
If the instruction cache hits on an instruction fetch access, one long word is driven onto the<br />
internal instruction data bus. If the operand data cache hits on an operand read access, 32bits<br />
or 64-bits (for double-precision floating-point accesses) are driven onto the internal operand<br />
data bus. If the data cache hits on a write access, the data is written to the appropriate<br />
portion of the accessed cache line. If the data access is misaligned, then the operand cache<br />
controller breaks up the access into a sequence of smaller aligned fetches to the data cache.<br />
Any misaligned operand reference generates at least two cache accesses. Since the entry<br />
validity is provided only on a line basis, the entire line must be loaded from system memory<br />
on a cache miss in order for a cache to be able to contain any valid information for that line<br />
address.<br />
Non-cachable addresses (i.e., those designated as cache inhibited by the memory management<br />
unit (MMU) page descriptor or transparent translation register) bypass the cache to allow<br />
support for I/O, etc. Valid data cache entries that match during non-cachable address<br />
accesses are pushed and invalidated if dirty and are invalidated if not dirty.<br />
5-4<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
Operands of locked instructions (CAS and TAS) and operand references while the lock bit<br />
in the bus control register is set which miss in the data cache do not allocate for reads or<br />
writes regardless of the caching mode, and therefore will bypass the cache. Locked instructions<br />
that hit in the data cache invalidate a matching valid entry or will push and invalidate a<br />
matching dirty entry. The locked operand access will then bypass the cache.<br />
5.2 CACHE CONTROL REGISTER<br />
The cache control register (CACR) is a 32-bit register which contains control information for<br />
the instruction and data caches. A MOVEC sets all of the bits in the CACR. A hardware reset<br />
clears the CACR, disabling both caches; however, reset does not affect the tags, state information,<br />
and data within the caches. The CACR is illustrated in Figure 5-5.<br />
31 30 29 28 27 26 24 23 22 21 20 16 15 14 13 12 0<br />
EDC NAD ESB DPI FOC 0 0 0 EBC CABC CUBC 0 0 0 0 0 EIC NAI FIC 0 0 0 0 0 0 0 0 0 0 0 0 0<br />
EDC—Enable Data Cache<br />
0 = Data cache is disabled.<br />
1 = Data cache is enabled.<br />
Figure 5-5. Cache Control Register<br />
NAD—No Allocate Mode (Data Cache)<br />
0 = Read and write misses will allocate in the data cache.<br />
1 = Read and write misses will not allocate in the data cache.<br />
ESB—Enable Store Buffer<br />
0 = All writes to writethrough or cache-inhibited imprecise pages will bypass the store<br />
buffer and generate bus cycles directly.<br />
1 = The four entry first-in-first-out (FIFO) store buffer to the MC68060 is enabled. This<br />
buffer is used to defer pending writes to writethrough or cache-inhibited imprecise<br />
pages to maximize performance.<br />
Locked write accesses and accesses to cache-inhibited precise pages always bypass the<br />
store buffer.<br />
DPI—Disable CPUSH Invalidation<br />
0 = Each cache line is invalidated as it is pushed. Affects only the data cache.<br />
1 = CPUSHed lines remain valid in the cache.<br />
FOC—1/2 Cache Operation Mode Enable (Data Cache)<br />
0 = The data cache operates in normal, full-cache mode.<br />
1 = The data cache operates in 1/2-cache mode.<br />
5-5
Caches<br />
Bits 26–24—Reserved.<br />
EBC—Enable Branch Cache<br />
0 = The branch cache is disabled and branch cache information is not used in the<br />
branch prediction strategy.<br />
1 = The on-chip branch cache is enabled. Branches are cached. A predicted branch<br />
executes more quickly, and often can be folded onto another instruction.<br />
CABC—Clear All Entries in the Branch Cache<br />
This bit is always read as zero.<br />
0 = No operation is done on the branch cache.<br />
1 = The entire content of the MC68060 branch cache is invalidated.<br />
CUBC—Clear All User Entries in the Branch Cache<br />
This bit is always read as zero.<br />
0 = No operation is performed on the branch cache.<br />
1 = All user-mode entries in the MC68060 branch cache are invailidated; supervisormode<br />
branch cache entries remain valid.<br />
Bits 20–16—Reserved.<br />
EIC—Enable Instruction Cache<br />
0 = Instruction cache is disabled.<br />
1 = Instruction cache is enabled.<br />
NAI—No Allocate Mode (Instruction Cache)<br />
0 = Accesses that miss in the instruction cache will allocate.<br />
1 = The instruction cache will continue to supply instructions to the processor, but an<br />
access that misses will not allocate.<br />
FIC—1/2 Cache Operation Mode Enable (Instruction Cache)<br />
0 = The instruction cache operates in normal, full-cache mode.<br />
1 = The instruction cache operates in 1/2-cache mode.<br />
Bits 13–0—Reserved.<br />
5.3 CACHE MANAGEMENT<br />
The caches are individually enabled and configured by using the MOVEC instruction to<br />
access the CACR. A hardware reset clears the CACR, disabling both caches and removing<br />
all configuration information; however, reset does not affect the tags, state information, and<br />
data within the caches. The CINV instruction must clear the caches before enabling them.<br />
The MC68060 cannot cache page descriptors.<br />
System hardware can assert the cache disable (CDIS) signal to dynamically disable the both<br />
the instruction and data caches, regardless of the state of the enable bits in the CACR. The<br />
caches are disabled immediately after the current access completes. If CDIS is asserted<br />
during the access for the first half of a misaligned operand spanning two cache lines, the<br />
5-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
data cache is disabled for the second half of the operand. Internal accesses always bypass<br />
the instruction and data caches while CDIS is recognized, and the contents of the caches<br />
are unchanged. Disabling the caches with CDIS does not affect snoop operations. CDIS is<br />
intended primarily for use by in-circuit emulators to allow swapping between the tags and<br />
emulator memories.<br />
The privileged CINV and CPUSH instructions support cache management, by selectively<br />
pushing and/or invalidating an individual cache line, a full page, or an entire cache, for either<br />
or both instruction and data caches. CINV allows selective invalidation of cache entries. The<br />
CPUSH instruction will either push and invalidate all matching lines, or push and leave the<br />
line valid, depending on the state of the DPI bit of the CACR register. (Note that only CPUSH<br />
instructions which specify the data cache are affected by the DPI bit. Since the instruction<br />
cache cannot have dirty data, a CPUSH specifying the instruction cache is interpreted as a<br />
CINV instruction.) Because of the size of the caches, pushing pages or an entire cache may<br />
incur a significant time penalty. Therefore, the CPUSH instruction may be interrupted to<br />
avoid large interrupt latencies. The state of the CDIS signal or the cache enable or no-allocate<br />
bits in the CACR does not affect the operation of CINV and CPUSH.<br />
5.4 CACHING MODES<br />
Every cache access has an associated caching mode from the MMU that determines how<br />
the cache handles the access. An access can be cachable in either the writethrough or<br />
copyback modes, or it can be cache inhibited in precise or imprecise modes. The CM field<br />
(from the transparent translation register (TTR) or MMU translation table page descriptor)<br />
corresponding to the logical address of the access normally specifies, on a page-by-page<br />
basis, one of these caching modes. When the cache is enabled and memory management<br />
is disabled, the default caching mode is writethrough.<br />
The MMU provides the cache mode user page attributes (UPAx) and write protection for<br />
each access. This information may come from a TTR which matches or from the MMU translation<br />
tables via the ATC. If both the TTR and the ATC match the access, the TTR provides<br />
the information. If the paging MMU is disabled (TCR bit clear) and neither TTR matches,<br />
then the cache mode, UPAx, and write protection will be that which is specified in the default<br />
bits of the TCR. After reset, the defaults are writethrough cache mode, UPAx bits are zero,<br />
and all addresses may be written.<br />
The TTRs and MMUs allow the defaults to be overridden. In addition, some instructions and<br />
integer unit operations perform data accesses that have an implicit caching mode associated<br />
with them. The following paragraphs discuss the different caching accesses and their<br />
related cache modes.<br />
5.4.1 Cachable Accesses<br />
If the CM field of a page descriptor, TTR, or default field of the TCR indicates writethrough<br />
or copyback, then the access is cachable. A read access to a writethrough or copyback page<br />
is read from the cache if matching data is found. Otherwise, the data is read from memory<br />
and used to update the cache. Since instruction cache accesses are always reads, the<br />
selection of writethrough or copyback modes do not affect them. The following paragraphs<br />
describe the writethrough and copyback modes in detail.<br />
5-7
Caches<br />
5.4.1.1 WRITETHROUGH MODE. Accesses to pages specified as writethrough are always<br />
written to the external address, although the cycle can be buffered (depending on the state<br />
of the ESB bit in the CACR). Writes in writethrough mode are handled with a no-write-allocate<br />
policy—i.e., writes that miss in the data cache are written to memory or the write buffer,<br />
but do not cause the corresponding line in memory to be loaded into the cache. Write<br />
accesses that hit always write through to memory and update matching cache lines. Specifying<br />
writethrough mode for the shared pages maintains cache coherency for shared memory<br />
areas in a multiprocessing environment. The cache supplies data to instruction or data<br />
read accesses that hit in the appropriate cache; misses cause a new cache line to be loaded<br />
into the cache, unless no-allocate mode is selected (NAD or NAI is set) via the CACR.<br />
5.4.1.2 COPYBACK MODE. Copyback pages are typically used for local data structures or<br />
stacks to minimize external bus usage and reduce write access latency. Write accesses to<br />
pages specified as copyback that hit in the data cache update the cache line and set the<br />
corresponding D-bit without an external bus access. The dirty cached data is only written to<br />
memory if the line is replaced due to a miss, or a writethrough or cache-inhibited access<br />
which hits the dirty line, or a CPUSH which pushes the line. If a write access misses in the<br />
cache, then the needed cache line is read from memory and the cache is updated if the NAD<br />
bit in the CACR is clear. If a write miss occurs when the NAD bit is set, the cache is not<br />
updated. When a miss causes a dirty cache line to be selected for replacement, the current<br />
cache line data is moved to the push buffer. The replacement line is read into the cache, and<br />
the push buffer contents are written to external memory.<br />
5.4.2 Cache-Inhibited Accesses<br />
Address space regions containing targets such as I/O devices and shared data structures<br />
in multiprocessing systems can be designated cache inhibited. If a page descriptor’s CM<br />
field indicates precise or imprecise, then the access is cache inhibited. The caching operation<br />
is identical for both cache-inhibited modes. The difference between these inhibited<br />
cache modes has to do with recovery from an exception (either external bus error, or interrupt).<br />
If the CM field of a matching address indicates either precise or imprecise modes, the cache<br />
controller bypasses the cache and performs an external bus transfer. The data associated<br />
with the access is not cached internally, and the cache inhibited out (CIOUT) signal is<br />
asserted during the bus cycle to indicate to external memory that the access should not be<br />
cached. If the data cache line is already resident in an internal cache and the current cache<br />
mode for that page becomes cache inhibited, either through an operating system change,<br />
or due to a shared physical page, then the caches provide additional support for cache<br />
coherency, by pushing the line if dirty or invalidating the line if it is valid.<br />
If the CM field indicates precise mode, then the sequence of read and write accesses to the<br />
page is guaranteed to match the sequence of the instruction order. In imprecise mode, the<br />
operand pipeline allows read accesses that hit in the cache to occur before completion of a<br />
pending write from a previous instruction. Writes will not be deferred past operand read<br />
accesses that miss in the cache (i.e. that must be read from the bus). Precise operation<br />
forces operand read accesses for an instruction to occur only once by preventing the instruction<br />
from being interrupted after the operand fetch stage. Otherwise, if not in precise mode<br />
5-8<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
and an exception occurs, the instruction is aborted, and the operand may be accessed again<br />
when the instruction is restarted. These guarantees apply only when the CM field indicates<br />
the precise mode and the accesses are aligned. Regardless of the selected cache mode,<br />
locked accesses are implicitly precise. Locked accesses are performed by the MC68060 for<br />
the operands of the TAS and CAS instructions, and for updating history information in the<br />
translation tables during table search operations.<br />
5.4.3 Special Accesses<br />
Several other processor operations result in accesses that have special caching characteristics<br />
besides those with an implied cache-inhibited access in the precise mode. Exception<br />
stack accesses and exception vector fetches that miss in the cache do not allocate cache<br />
lines in the data cache, preventing replacement of a cache line. Cache hits by these<br />
accesses are handled in the normal manner according to the caching mode specified for the<br />
accessed address.<br />
MC68060-initiated MMU table searches bypass the cache.<br />
Accesses by the MOVE16 instruction also do not allocate cache lines in the data cache for<br />
either read or write misses. Read hits on either valid or dirty cache lines are read from the<br />
cache. Write hits invalidate a matching line and perform an external access. Interacting with<br />
the cache in this manner prevents a large block move or block initialization implemented with<br />
a MOVE16 from being cached, since the data may not be needed immediately.<br />
5.5 CACHE PROTOCOL<br />
The cache protocol for processor and snooped accesses is described in the following paragraphs.<br />
In all cases, an external bus transfer will cause a cache line state to change only if<br />
the bus transfer is marked as snoopable on the bus by asserting the SNOOP signal. The<br />
protocols described in the following paragraphs assume that the data is cachable (i.e.,<br />
writethrough and copyback).<br />
5.5.1 Read Miss<br />
A processor read that misses in the cache causes the cache controller to request a bus<br />
transaction that reads the needed line from memory and supplies the required data to the<br />
integer unit. The line is placed in the cache in the valid state, unless the no-allocate bit (NAD<br />
for the data cache or NAI for the instruction cache) for the corresponding cache in the CACR<br />
is set. Snooped external reads that miss in the cache have no affect on the cache.<br />
5.5.2 Write Miss<br />
The cache controller handles processor writes that miss in the cache differently for<br />
writethrough and copyback pages. Write misses to copyback pages cause a line read from<br />
the external bus to load the cache line (unless the corresponding no-allocate bit, NAD or<br />
NAI, in the CACR is set). The new cache line is then updated with the write data, and the Dbit<br />
for the line is set, leaving the cache line in the dirty state. Write misses to writethrough<br />
pages write directly to memory without loading the corresponding cache line in the cache.<br />
Snooped external writes that miss in the cache have no affect on the cache.<br />
5-9
Caches<br />
5.5.3 Read Hit<br />
On a read hit, the appropriate cache provides the data to the requesting pipe unit. In most<br />
cases no bus transaction is performed, and the state of the cache line does not change.<br />
However, when a writethrough read hit to a line containing dirty data occurs, the dirty line is<br />
pushed and the cache line state changes to valid before the data is provided to the requesting<br />
pipe unit.<br />
A snooped external read hit invaildates the cache line that is hit.<br />
5.5.4 Write Hit<br />
The cache controller handles processor writes that hit in the cache differently for<br />
writethrough and copyback pages. For write hits to a writethrough page, the portions of the<br />
cache line(s) corresponding to the size of the access are updated with the data, and the data<br />
is also written to external memory. The cache line state does not change. A writethrough<br />
access to a line containing dirty data results in the dirty line being pushed and then witten to<br />
memory. If the access is copyback, the cache controller updates the cache line and sets the<br />
D-bit for the line. An external write is not performed, and the cache line state changes to, or<br />
remains in, the dirty state.<br />
An alternate bus master can assert the SNOOP signal for a write that it initiates, which will<br />
invalidate any corresponding entry in the internal cache.<br />
5.6 CACHE COHERENCY<br />
The MC68060 provides several different mechanisms to assist in maintaining cache coherency<br />
in multimaster systems. Both writethrough and copyback memory update techniques<br />
are supported to maintain coherency between the data cache and memory.<br />
Alternate bus master accesses can reference data that the MC68060 may have cached,<br />
causing coherency problems if the accesses are not handled properly. The MC68060<br />
snoops the bus during alternate bus master transfers if SNOOP is asserted. Snoop hits<br />
invalidate the cache line in all cases (read, write, long word, word, byte) for MOVE16 and<br />
normal accesses. Since the processor may be accessing data in its caches even when it<br />
does not have the bus, a snoop has priority over the processor, to maintain cache coherency.<br />
The snooping protocol and caching mechanism supported by the MC68060 requires that<br />
pages shared with any other bus master be marked cachable writethrough or cache inhibited<br />
(either precise or imprecise). This procedure allows each processor to cache shared<br />
data for read access while forcing a processor write to shared data to appear as an external<br />
write to memory, which the other processors can snoop. If shared data is stored in copyback<br />
pages, cache coherency is not guaranteed.<br />
Coherency between the instruction cache and the data cache must be maintained in software<br />
since the instruction cache does not monitor data accesses. Processor writes that<br />
modify code segments (i.e., resulting from self-modifying code or from code executed to<br />
load a new page from disk) access memory through the data memory unit. Because the<br />
instruction cache does not monitor these data accesses, stale data occurs in the instruction<br />
5-10<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
cache if the corresponding data in memory is modified. Invalidating instruction cache lines<br />
before writing to the corresponding memory lines can prevent this coherency problem, but<br />
only if the data cache line is in writethrough or cache-inhibited mode. A cache coherency<br />
problem could arise if the data cache line is configured as copyback.<br />
To fully support self-modifying code in any situation, it is imperative that a CPUSHA instruction<br />
specifying both caches be executed before the execution of the first self-modified<br />
instruction. The CPUSHA instruction has the effect of ensuring that there is no stale data in<br />
memory, the pipeline is flushed, and instruction prefetches are repeated and taken from<br />
external memory.<br />
5.7 MEMORY ACCESSES FOR CACHE MAINTENANCE<br />
The cache controller in each memory unit performs all maintenance activities that supply<br />
data from the cache to the instruction and operand pipeline units. The activities include<br />
requesting accesses to the bus interface unit for reading new cache lines and writing dirty<br />
cache lines to memory. The following paragraphs describe the memory accesses resulting<br />
from cache fill operations (by both caches) and push operations (by the data cache). Refer<br />
to Section 7 Bus Operation for detailed information about the bus cycles required.<br />
5.7.1 Cache Filling<br />
When a new cache line is required, the cache controller requests a line read from the bus<br />
controller. The bus controller requests a burst read transfer by indicating a line access with<br />
the size signals (SIZ1, SIZ0) and indicates which line in the set is being loaded with the<br />
transfer line number signals (TLN1, TLN0). TLN1 and TLN0 are undefined for the instruction<br />
cache. These pins indicate the appropriate line numbers for cache transfers. Table 5-1 lists<br />
the definition of the TLNx encoding.<br />
Table 5-1. TLNx Encoding<br />
TLN1 TLN0 Line<br />
0 0 Zero<br />
0 1 One<br />
1 0 Two<br />
1 1 Three<br />
The responding device sequentially supplies four long words of data and can assert the<br />
transfer cache inhibit signal (TCI) if the line is not cachable. If the responding device does<br />
not support the burst mode, it should assert the TBI signal for the first long word of the line<br />
access. The bus controller responds by terminating the line access and completes the<br />
remainder of the line read as three, sequential, long-word reads.<br />
Bus controller line accesses implicitly request burst mode operations from external memory.<br />
To operate in the burst mode, the device or external hardware must be able to increment<br />
the low-order address bits as described in Section 7 Bus Operation.<br />
The device indicates<br />
its ability to support the burst access by acknowledging the initial long-word transfer with<br />
transfer acknowledge (TA) asserted and TBI negated. This procedure causes the processor<br />
to continue to drive the address and bus control signals and to latch a new data value for<br />
the cache line at the completion of each subsequent cycle (as defined by TA) for a total of<br />
5-11
Caches<br />
four cycles. The bursting mechanism requires addresses to wrap around so that the entire<br />
four long words in the cache line are filled in a single operation.<br />
When a cache line read is initiated, the first cycle attempts to load the line entry corresponding<br />
to the address requested by the IFU. Subsequent transfers are for the remaining entries<br />
in the cache line. In the case of a misaligned access in which the operand spans two line<br />
entries, the first cycle corresponds to the line entry containing the portion of the operand at<br />
the lower address.<br />
Line read data is handled differently by the instruction cache and the data cache. In the<br />
instruction cache, the first long word fetched is immediately available to the IFU. It is also<br />
put in a line read buffer. The data for the rest of the line is also put in this buffer as it is<br />
received. If subsequent IFU requests are sequential and within the address range in the line<br />
read buffer, these requests hit in the instruction read buffer as data becomes available. If<br />
subsequent IFU requests are not sequential, or are outside the address range in the read<br />
buffer, the IFU stalls until the line is completely fetched. In the data cache, the first long word<br />
or first two long words are available to the integer or floating-point units. The amount of data<br />
which is available immediately depends on the size and alignment of the operation that initiated<br />
the cache miss. These long words along with the remainder of the line fetch are also<br />
put in the data line read buffer. All subsequent data cache requests stall until the line is completely<br />
fetched. A misaligned access which spans two cache lines is handled by the data<br />
cache unit as two separate accesses.<br />
The assertion of TCI during the first cycle of a burst read operation inhibits loading of the<br />
buffered line into the cache, but it does not cause the burst transfer (or pseudo-burst transfer<br />
if TBI is asserted with TCI) to be terminated early. If TCI is asserted during the first data<br />
transfer cycle for a read operand, the initial bypass of data for both instruction and data<br />
accesses takes place normally, as described above in the paragraph on line reads. The line<br />
read buffers in both caches are filled normally. The instruction cache unit will allow sequential<br />
access in the address range of the line read buffer until the last long word of the burst is<br />
transferred from the bus controller. No additional data from the line is available from the data<br />
cache unit. When the line fetch is completed, the contents of both line buffers are discarded.<br />
No data is transferred to either cache memory. The assertion of TCI is ignored during the<br />
second, third, or fourth cycle of a burst operation and is ignored for write operations.<br />
A bus error occurring during a burst operation causes the burst operation to abort. If the bus<br />
error occurs during the first cycle of a burst, the data from the bus is ignored. If the access<br />
is a data cycle, exception processing proceeds immediately. If the cycle is for an instruction<br />
prefetch, a bus error exception is not taken immediately, but will be taken if the instruction<br />
flow subsequently causes the instruction to be attempted. Refer to Section 7 Bus Operation<br />
for more information about pipeline operation.<br />
For either cache, when a bus error occurs on the second cycle or later, the burst operation<br />
is aborted and the line buffer is invalidated. The processor may or may not take an exception,<br />
depending on the status of the pending data request. If the bus error cycle contains a<br />
portion of a data operand that the processor is specifically waiting for (e.g., the second half<br />
of a misaligned operand), the processor immediately takes an exception. Otherwise, no<br />
exception occurs, and the cache line fill is repeated the next time data within the line is<br />
5-12<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
required. In the case of an instruction cache line fill, the unneeded data from the aborted<br />
cycle is completely ignored.<br />
The MC68060 supports native retry functionality using the TRA signal, as well as MC68040compatible<br />
retry functionality using TA and TEA. The MC68040-compatible retry functions<br />
as the 040. For either type, on the initial access of a line read, a retry termination causes a<br />
retry of the bus cycle. A MC68040-compatible retry signaled during the remaining cycles of<br />
the line access (either burst or pseudo-burst) is recognized as a bus error, and the processor<br />
handles it as described in the previous paragraphs. Assertion of the TRA signal (native<br />
retry) during the remaining cycles of the line access is ignored.<br />
5.7.2 Cache Pushes<br />
When the cache controller selects a dirty data cache line for replacement, memory must be<br />
updated with the dirty data before the line is replaced. Cache pushes occur for line replacement,<br />
as required for the execution of the CPUSH instruction, and when a writethrough or<br />
cache-inhibited access hits a dirty cache line. To reduce the requested data’s latency in the<br />
new line, the dirty line being replaced is temporarily placed in a push buffer while the new<br />
line is fetched from memory. When a line is allocated to the push buffer, an alternate bus<br />
master can snoop it, but the execution units cannot access it. After the bus transfer for the<br />
new line successfully completes, the dirty cache line is copied back to memory, and the push<br />
buffer is invalidated. If the operation to access the replacement line is abnormally terminated<br />
or the external cache inhibit signal is asserted, the line in the push buffer is restored back<br />
into its original position in the cache and validated.<br />
A cache line is written to memory using a line push transfer if it is dirty. A push transfer is<br />
distinguished from a normal write transfer by an encoding of 000 on the transfer modifier signals<br />
(TM2–TM0) for the push. Refer to Section 8 Exception Processing for information on<br />
the case of a bus error terminating a push transfer.<br />
A dirty cache line hit by a cache-inhibited access is pushed before the external bus access<br />
occurs.<br />
5.8 PUSH BUFFER<br />
The MC68060 processor implements a push buffer to reduce latency for requested new data<br />
on a cache miss by temporarily putting displaced dirty data into the push buffer while the<br />
new data is fetched from memory. While the dirty line resides in the push buffer, it can be<br />
snooped by an external bus master. The push buffer contains 16 bytes of storage (one displaced<br />
cache line).<br />
If a data cache miss displaces a dirty line, the miss reference is immediately placed on the<br />
system bus. While waiting for the response, the current contents of the data cache location<br />
are loaded into the push buffer. Once the bus transaction (burst read) completes, the<br />
MC68060 is able to generate the appropriate line write bus transaction to store the contents<br />
of the push buffer into memory.<br />
5-13
Caches<br />
5.9 STORE BUFFER<br />
The MC68060 processor provides a four-entry store buffer (16 bytes maximum). This store<br />
buffer is a FIFO buffer that can be used for deferring pending writes to imprecise pages to<br />
maximize performance.<br />
For operand writes destined for the store buffer, the operand execution pipeline incurs no<br />
stalls. The store buffer effectively provides a measure of decoupling between the pipeline’s<br />
ability to generate writes (one write per cycle maximum) and the ability of the system bus to<br />
retire those writes (one write per two cycles minimum). When writing to imprecise pages,<br />
only in the event the store buffer becomes full and there is a write operation in the EX cycle<br />
of the operand execution pipeline will a stall be incurred.<br />
If the store buffer is not utilized (store buffer disabled or cache inhibited, precise mode), system<br />
bus cycles are generated directly for each pipeline write operation. The instruction is<br />
held in the EX cycle of the operand execution pipeline (OEP) until bus transfer termination<br />
is received. This means each write operation is stalled for a minimum of five cycles in the<br />
EX cycle when the store buffer is not utilized.<br />
A store buffer enable bit is contained in the CACR. This bit can be set and cleared via the<br />
MOVEC instruction. Upon reset, this bit is cleared and all writes are precise. When the bit is<br />
set, the cache mode generated by the MMU is used. The store buffer is utilized by the cachable/writethrough<br />
and the cache-inhibited/imprecise modes.<br />
The store buffer can queue data up to four bytes in width per entry. Each entry matches a<br />
corresponding bus cycle it will generate; therefore, a misaligned long-word write to a<br />
writethrough page will create two entries if the address is to an odd word boundary, three<br />
entries if to an odd byte boundary—one per bus cycle.<br />
A misaligned write access which straddles a precise/imprecise page boundary will use the<br />
store buffer for the imprecise portion of the write.<br />
5.10 PUSH BUFFER AND STORE BUFFER BUS OPERATION<br />
Once either the store buffer or the push buffer has valid data, the MC68060 bus controller<br />
uses the next available bus cycle to generate the appropriate write cycles. In the event that<br />
during the continued instruction execution by the processor pipeline another system bus<br />
cycle is required (e.g., data cache miss to process, address translation cache (ATC)<br />
tablesearch to perform), the pipeline will stall until both push and store buffers are empty<br />
before generating the required system bus transaction.<br />
Certain instructions and exception processing which synchronize the MC68060 processor<br />
pipeline guarantee both push and store buffers are empty before proceeding.<br />
5.11 BRANCH CACHE<br />
The branch cache plays a major role in achieving the performance levels of the MC68060<br />
processor. The branch cache provides a table associating branch program counter values<br />
with the corresponding branch target virtual addresses. The fundamental concept is to pro-<br />
5-14<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
vide a mechanism that allows the instruction fetch pipeline to detect and change instruction<br />
streams before the change-of-flow instructions enter an operand execution pipeline.<br />
The branch cache implementation is made up of a five-state prediction model based on past<br />
execution history, in addition to the current program counter/branch target virtual address<br />
association logic.<br />
For each instruction fetch address generated, the branch cache is examined to see if a valid<br />
branch entry is present. If there is not a branch cache hit, the instruction fetch unit continues<br />
to fetch instructions sequentially. If a branch cache hit occurs indicating a “taken branch”,<br />
the instruction fetch unit discards the current instruction steam and begins fetching at the<br />
location indicated by the branch target address. As long as the branch cache prediction is<br />
correct, which happens a very significant percentage of the time, the change-of-flow of the<br />
instruction stream is “invisible” to the OEP and performance is maximized. If the branch<br />
cache prediction is wrong, the internal pipelines are “cancelled” and the correct instruction<br />
flow is established.<br />
The branch cache must be cleared by the operating system on all context switches (using<br />
the MOVEC to CACR instruction), because it is virtually-mapped.<br />
The branch cache is automatically cleared by the hardware as part of any cache invalidate<br />
(CINV) or any cache push and invalidate (CPUSH) instruction operating on the instruction<br />
cache.<br />
Programs that use the TRAPF instruction extension word as a possible branch target destination<br />
intefere with proper operation of the branch target cache, resulting in an access error<br />
exception. This condition is indicated by the BPE bit in the FSLW of the access error stack.<br />
5.12 CACHE OPERATION SUMMARY<br />
The instruction and data caches function independently when servicing access requests<br />
from the integer unit. The following paragraphs discuss the operational details for the caches<br />
and present state diagrams depicting the cache line state transitions.<br />
5.12.1 Instruction Cache<br />
The integer unit uses the instruction cache to store instruction prefetches as it requests<br />
them. Instruction prefetches are normally requested from sequential memory locations<br />
except when a change of program flow occurs (e.g., a branch taken) or when an instruction<br />
that can modify the status register (SR) is executed, in which case the instruction pipe is<br />
automatically flushed and refilled. The instruction cache supports a line-based protocol that<br />
allows individual cache lines to be in either the invalid or valid states.<br />
For instruction prefetch requests that hit in the cache, the long word containing the instruction<br />
is places onto the internal instruction data bus. When an access misses in the cache,<br />
the cache controller requests the line containing the required data from memory and places<br />
it in the cache. If available, an invalid line is selected and updated with the tag and data from<br />
memory. The line state then changes from invalid to valid by setting the V-bit. If all lines in<br />
the set are already valid, a pseudo round-robin replacement algorithm is used to select one<br />
5-15
Caches<br />
of the four cache lines replacing the tag and data contents of the line with the new line information.<br />
Figure 5-6 illustrates the instruction-cache line state transitions resulting from processor<br />
and snoop controller accesses. Transitions are labeled with a capital letter, indicating<br />
the previous state, followed by a number indicating the specific case listed in Table 5-2.<br />
5-16<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
Cache Operation<br />
5.12.2 Data Cache<br />
MOTOROLA<br />
IPU Read Miss I1<br />
Table 5-2. Instruction Cache Line State Transitions<br />
Current State<br />
Invalid Cases Valid Cases<br />
Read line from memory; supply data to<br />
IPU and update cache; go to valid state.<br />
IPU Read Hit I2 Not Possible. V2<br />
<strong>M68060</strong> USER’S MANUAL<br />
Caches<br />
Read line from memory; supply data to<br />
V1 IPU and update cache (replacing old<br />
line); remain in current state.<br />
Suppply data to IPU; remain in current<br />
state.<br />
Cache Invalidate or Push<br />
(CINV or CPUSH)<br />
I3 No action; remain in current state. V3 No action; go to invalid state.<br />
Alternate Master Snoop Hit<br />
(Read or Write)<br />
I4 Not possible. V4 No action; go to invalid state.<br />
Alternate Master Snoop Miss I5 Not possible. V5 No action; remain in current state.<br />
TCI Asserted on Read Miss<br />
(during the First Access)<br />
I6<br />
Read line for memory; Supply data to<br />
the IPU; remain in current state.<br />
I3—CINV/CPUSH<br />
I6—TCI ASSERTED<br />
I1—IPU READ MISS<br />
V6 Not Possible.<br />
INVALID VALID<br />
V3—CINV/CPUSH<br />
V4—SNOOP READ/WRITE HIT<br />
V1—IPU READ MISS<br />
V2—IPU READ HIT<br />
V5—SNOOP MISS<br />
Figure 5-6. Instruction Cache Line State Diagram<br />
The integer unit uses the data cache to store operand data as it requires or generates the<br />
data. The data cache supports a line-based protocol allowing individual cache lines to be in<br />
one of three states: invalid, valid, or dirty. To maintain coherency with memory, the data<br />
cache supports both writethrough and copyback modes, specified by the CM field for the<br />
page.<br />
5-17
Caches<br />
Read misses and write misses to copyback pages cause the cache controller to read a new<br />
cache line from memory into the cache. If available, an invalid line in the selected set is<br />
updated with the tag and data from memory. The line state then changes from invalid to valid<br />
by setting the V-bit for the line. If all lines in the set are already valid or dirty, the pseudo<br />
round-robin replacement algorithm is used to select one of the four lines and replace the tag<br />
and data contents of the line with the new line information. Before replacement, dirty lines<br />
are temporarily buffered and later copied back to memory after the new line has been read<br />
from memory. Snoops always check both the push buffer and the cache. Figure 5-7 illustrates<br />
the three possible states for a data cache line, with the possible transitions caused by<br />
either the processor or snooped accesses. Transitions are labeled with a capital letter, indicating<br />
the previous state, followed by a number indicating the specific case listed in Table<br />
5-3.<br />
5-18<br />
CI5— CINV<br />
CI6— CPUSH<br />
WI3—CPU WRITE MISS<br />
WI5—CINV<br />
WI6—CPUSH<br />
CD2— CPU READ HIT<br />
CD3—CPU WRITE MISS<br />
CD4—CPU WRITE HIT<br />
Figure 5-7. Data Cache Line State Diagrams<br />
<strong>M68060</strong> USER’S MANUAL<br />
CV1—CPU READ MISS<br />
CV2—CPU READ HIT<br />
COPYBACK<br />
INVALID<br />
CI1—CPU READ MISS<br />
CV5—CINV<br />
CV6—CPUSH<br />
CV7—SNOOP HIT<br />
CI3— CPU<br />
COPYBACK<br />
VALID<br />
WRITE MISS CD1—CPU<br />
CD5—CINV<br />
CD6—CPUSH<br />
READ MISS<br />
CD7—SNOOP HIT<br />
CV3—CPU WRITE MISS<br />
CV4—CPU WRITE HIT<br />
COPYBACK<br />
DIRTY<br />
COPYBACK CACHING MODE<br />
WV1—CPU READ MISS<br />
WV2—CPU READ HIT<br />
WV3—CPU WRITE MISS<br />
WV4—CPU WRITE HIT<br />
WRITE-<br />
THROUGH<br />
INVALID<br />
WI1— CPU READ MISS<br />
WV5— CINV<br />
WV6— CPUSH<br />
WV7—SNOOP HIT<br />
WRITE-<br />
THROUGH<br />
VALID<br />
WRITETHROUGH CACHING MODE<br />
MOTOROLA
Caches<br />
Cache<br />
Operation<br />
OPU Read<br />
Miss<br />
OPU Read<br />
Hit<br />
OPU Write<br />
Miss<br />
(Copyback<br />
Mode)<br />
OPU Write<br />
Miss<br />
(Writethrou<br />
gh Mode)<br />
OPU Write<br />
Hit (Copyback<br />
Mode)<br />
OPU Write<br />
Hit<br />
(Writethrou<br />
gh Mode)<br />
Cache Invalidate<br />
5-19<br />
Cache<br />
Push<br />
Alternate<br />
Master<br />
Snoop Hit<br />
(C,W)I1<br />
Table 5-3. Data Cache Line State Transitions<br />
Current State<br />
Invalid Cases Valid Cases Dirty Cases<br />
Read line from memory<br />
and update cache; Supply<br />
data to OPU; Go to<br />
valid state.<br />
(C,W)V1<br />
(C,W)I2 Not possible. (C,W)V2<br />
CI3<br />
WI3<br />
Read line from memory<br />
and update cache; Write<br />
data to cache; Go to dirty<br />
state.<br />
Write data to memory;<br />
Remain in current state.<br />
CV3<br />
WV3<br />
CI4 Not possible. CV$<br />
WI4 Not possible. WV4<br />
(C,W)I5<br />
(C,W)I6<br />
No action; Remain in current<br />
state.<br />
No action; Remain in current<br />
state.<br />
(C,W)V5<br />
(C,W)V6<br />
(C,W)I7 Not possible. (C,W)V7<br />
Read new line from memory<br />
and update cache;<br />
supply data to OPU; Remain<br />
in current state.<br />
Supply data to OPU; Remain<br />
in current state.<br />
Read new line from memory<br />
and update cache;<br />
Write data to cache; Go<br />
to dirty state.<br />
<strong>M68060</strong> USER’S MANUAL<br />
CD1<br />
CD2<br />
CD3<br />
Write data to memory;<br />
Remain in current state. WD<br />
3<br />
Write data to cache; Go<br />
to dirty state.<br />
Write data to memory<br />
and to cache; Remain in<br />
current state.<br />
No action; Go to invalid<br />
state.<br />
No action; Go to invalid<br />
state.<br />
No action; Go to invalid<br />
state.<br />
CD4<br />
WD<br />
4<br />
CD5<br />
CD6<br />
CD7<br />
Push dirty cache line to<br />
push buffer; Read new<br />
line from memory and update<br />
cache; Supply data<br />
to OPU; Write push buffer<br />
contents to memory; Go<br />
to valid state.<br />
Supply data to OPU; Remain<br />
in current state.<br />
Push dirty cache line to<br />
push buffer; Read new<br />
line from memory and update<br />
cache; Write push<br />
buffer contents to memory;<br />
Remain in current<br />
state.<br />
Write data to memory;<br />
Remain in current state.<br />
Write data to cache; Remain<br />
in current state.<br />
Push dirty cache line to<br />
memory; Write data to<br />
memory and to cache;<br />
Go to valid state.<br />
No action (dirty data lost);<br />
Go to invalid state.<br />
Push dirty cache line to<br />
memory; Go to invalid<br />
state or remain in current<br />
state, depending on the<br />
DPI bit the the CACR.<br />
No action (dirty data lost);<br />
Go to invalid state.<br />
MOTOROLA
SECTION 6<br />
FLOATING-POINT UNIT<br />
MOTOROLA<br />
NOTE<br />
This section does not apply to the MC68LC060 or MC68EC060.<br />
Refer to Appendix A MC68LC060 and Appendix B<br />
MC68EC060 for details.<br />
Floating-point math refers to numeric calculations with a variable decimal point location. It<br />
is distinguished from integer math, which deals only with whole numbers and fixed decimal<br />
point locations. Historically, general-purpose microprocessors have had to depend on addon<br />
coprocessors and accelerators such as the MC68881/MC68882 for fast floating-point<br />
capabilities. The MC68060 features a built-in floating-point unit (FPU). Consolidating this<br />
important function on chip speeds up the overall processing and eliminates interfacing overhead<br />
required for external accelerators. The MC68060 FPU operates in parallel with the<br />
integer unit. The FPU does the numeric calculation while the integer unit performs other<br />
tasks. When used with Motorola-supplied emulation software, the <strong>M68060</strong> software package<br />
(<strong>M68060</strong>SP), the MC68060 FPU is fully compliant with the ANSI/IEEE 754–1985 Standard<br />
for Binary Floating-Point Arithmetic.<br />
The on-chip FPU (shown in Figure 6-1) consists of four functional units: FPADD, FPMUL,<br />
FPDIV, and FPMISC. These functional units exist in parallel with the integer unit. The<br />
decode of floating-point operations is done in the same pipeline stage as integer instructions,<br />
and operands are fetched by the same logic which feeds the integer unit. The floatingpoint<br />
functional units are located in the primary pipeline of the integer unit. Only one floatingpoint<br />
functional unit at a time can be active. The FPU allows no concurrency between floating-point<br />
instructions to achieve a streamlined floating-point exception model.<br />
The FPADD unit performs floating-point addition and subtraction, compare, absolute value,<br />
negate, floating-point to integer and integer to floating-point conversions, and move-in and<br />
move-out of floating-point data when the precision and destination are not single, double, or<br />
extended precision. Results produced in this unit are rounded to the desired precision and<br />
rounding mode. The FPMUL unit performs floating-point multiply and rounding to desired<br />
precision and rounding mode. The FPDIV unit performs floating-point divide, square root,<br />
and move-in and move-out of floating-point data when the precision and destination are single,<br />
double, or extended precision. Results produced in the FDIV unit are rounded to the<br />
desired precision and rounding mode. The FPMISC unit handles the remaining functions<br />
within the FPU. This includes logic for FSAVE and FRESTORE, logic for FMOVEM, and<br />
exception logic. The floating-point control register (FPCR) and floating-point status register<br />
(FPSR) reside within this block. All of these functional units access the floating-point register<br />
file, which contains the program-visible register set.<br />
<strong>M68060</strong> USER’S MANUAL<br />
6-1
Floating-Point Unit<br />
The MC68060 FPU has been optimized for the most frequently used instructions and data<br />
types. The MC68060 fully conforms to the ANSI/IEEE 754–1985 Standard for Binary Floating-Point<br />
Arithmetic.<br />
In addition, the MC68060 processor maintains compatibility with the<br />
Motorola extended-precision architecture and is user object code compatible with the<br />
MC68881/MC68882 floating-point coprocessors and the MC68040 microprocessor FPU.<br />
With the inclusion of the <strong>M68060</strong>SP, the MC68060 provides MC68881/MC68882-compatible<br />
software functions. Details on the <strong>M68060</strong>SP are provided in Appendix C MC68060<br />
Software Package.<br />
6.1 FLOATING-POINT USER PROGRAMMING MODEL<br />
Figure 6-2 illustrates the floating-point portion of the user programming model. The following<br />
paragraphs describe the FPU portion of the user programming model for the MC68060. The<br />
model, which is identical to the programming model for the MC68881/MC68882 floatingpoint<br />
coprocessors, consists of the following registers:<br />
• Eight 80-Bit Floating-Point Data Registers (FP7–FP0)<br />
• 16-Bit Floating-Point Control Register (FPCR)<br />
• 32-Bit Floating-Point Status Register (FPSR)<br />
• 32-Bit Floating-Point Instruction Address Register (FPIAR)<br />
6-2<br />
EXECUTION UNIT<br />
FLOATING-<br />
POINT<br />
UNIT<br />
EA<br />
FETCH<br />
FP<br />
EXECUTE<br />
BRANCH<br />
CACHE<br />
INSTRUCTION FETCH UNIT<br />
pOEP sOEP<br />
DECODE<br />
DS<br />
DECODE<br />
DS<br />
EA AG EA AG<br />
CALCULATE<br />
CALCULATE<br />
OC EA OC EA OC<br />
FETCH<br />
FETCH<br />
EX<br />
INT EX INT EX<br />
EXECUTE<br />
EXECUTE<br />
DATA AVAILABLE<br />
WRITE-BACK<br />
INSTRUCTION<br />
BUFFER<br />
INTEGER UNIT<br />
IA<br />
CALCULATE<br />
INSTRUCTION<br />
FETCH<br />
EARLY<br />
DECODE<br />
IAG<br />
IB<br />
IC<br />
IED<br />
DA<br />
WB<br />
OPERAND DATA BUS<br />
INSTRUCTION<br />
ATC<br />
Figure 6-1. Floating-Point Unit Block Diagram<br />
<strong>M68060</strong> USER’S MANUAL<br />
INSTRUCTION<br />
CACHE<br />
CONTROLLER<br />
INSTRUCTION MEMORY UNIT<br />
DATA<br />
ATC<br />
DATA<br />
CACHE<br />
CONTROLLER<br />
DATA MEMORY UNIT<br />
INSTRUCTION<br />
CACHE<br />
DATA<br />
CACHE<br />
B<br />
U<br />
S<br />
C<br />
O<br />
N<br />
T<br />
R<br />
O<br />
L<br />
L<br />
E<br />
R<br />
ADDRESS<br />
DATA<br />
CONTROL<br />
MOTOROLA
79 64<br />
63 0<br />
6.1.1 Floating-Point Data Registers (FP7–FP0)<br />
MOTOROLA<br />
31<br />
Figure 6-2. Floating-Point User Programming Model<br />
<strong>M68060</strong> USER’S MANUAL<br />
Floating-Point Unit<br />
The floating-point data registers are analogous to the integer data registers of the M68000<br />
family. The floating-point data registers always contain extended-precision numbers. All<br />
external operands, regardless of the data format, are converted to extended-precision values<br />
before being used in any calculation or stored in a floating-point data register. A reset<br />
or a restore operation of the null state sets FP7–FP0 to positive, nonsignaling not-a-numbers<br />
(NANs).<br />
6.1.2 Floating-Point Control Register (FPCR)<br />
0<br />
31 24 23<br />
CONDITION<br />
CODE<br />
31<br />
QUOTIENT<br />
16 15<br />
8 7<br />
EXCEPTION<br />
ENABLE<br />
16 15<br />
EXCEPTION<br />
STATUS<br />
MODE<br />
CONTROL<br />
The FPCR (see Figure 6-3) contains an exception enable (ENABLE) byte that enables or<br />
disables traps for each class of floating-point exceptions and a mode control (MODE) byte<br />
that sets the user-selectable modes. The user can read or write to the FPCR. Motorola<br />
reserves bits 31–16 for future definition; these bits are always read as zero and are ignored<br />
during write operations. The reset function or a restore operation of the null state clears the<br />
FPCR. When cleared, this register provides the IEEE 754 standard defaults.<br />
6.1.2.1 EXCEPTION ENABLE BYTE. Each bit of the ENABLE byte (see Figure 6-3) corresponds<br />
to a floating-point exception class. The user can separately enable traps for each<br />
class of floating-point exceptions.<br />
6.1.2.2 MODE CONTROL BYTE. The MODE byte (see Figure 6-3) controls the userselectable<br />
rounding modes and precisions. Zeros in this byte select the IEEE 754 standard<br />
defaults. The rounding mode field (RND) specifies how inexact results are rounded, and the<br />
rounding precision field (PREC) selects the boundary for rounding the mantissa.<br />
8 7<br />
ACCRUED<br />
EXCEPTION<br />
0<br />
0<br />
0<br />
FP0<br />
FP1<br />
FP2<br />
FP3<br />
FP4<br />
FP5<br />
FP6<br />
FP7<br />
FPCR<br />
FPSR<br />
FPIAR<br />
FLOATING-POINT<br />
DATA REGISTERS<br />
FLOATING-POINT<br />
CONTROL<br />
REGISTER<br />
FLOATING-POINT<br />
STATUS<br />
REGISTER<br />
FLOATING-POINT<br />
INSTRUCTION<br />
ADDRESS<br />
REGISTER<br />
6-3
Floating-Point Unit<br />
The processor supports four rounding modes specified by the IEEE 754 standard. These<br />
modes are round to nearest (RN), round toward zero (RZ), round toward plus infinity (RP),<br />
and round toward minus infinity (RM). The RP and RM modes are directed rounding modes<br />
that are useful in interval arithmetic. Rounding is accomplished through the intermediate<br />
result. Single-precision results are rounded to a 24-bit boundary; double-precision results<br />
are rounded to a 53-bit boundary; and extended-precision results are rounded to a 64-bit<br />
boundary. Table 6-1 lists the encoding for the rounding mode. Table 6-2 lists the encoding<br />
for rounding precision.<br />
6.1.3 Floating-Point Status Register (FPSR)<br />
The FPSR (see Figure 6-2) contains a floating-point condition code byte (FPCC), a quotient<br />
byte, a floating-point exception status byte (EXC), and a floating-point accrued exception<br />
byte (AEXC). The user can read or write to all defined bits in the FPSR. Execution of most<br />
floating-point instructions modifies this register. The reset function or a restore operation of<br />
the null state clears the FPSR. Floating-point conditional operations are not guaranteed if<br />
the FPSR is written directly, because the FPSR is only valid as a result of a floating-point<br />
instruction.<br />
6-4<br />
EXCEPTION ENABLE<br />
15 14 13<br />
12 11 10 9 8 7 6 5 4 3 2 1 0<br />
BSUN SNAN OPERR OVFL UNFL DZ INEX2 INEX1 PREC RND 0<br />
Figure 6-3.<br />
Floating-Point Control Register Format<br />
Table 6-1. RND Encoding<br />
Encoding Rounding Mode<br />
0 0 To Nearest (RN)<br />
0 1 Toward Zero (RZ)<br />
1 0 Toward Minus Infinity (RM)<br />
1 1 Toward Plus Infinity (RP)<br />
Table 6-2. PREC Encoding<br />
Encoding Rounding Precision<br />
0 0 Extend (X)<br />
0 1 Single (S)<br />
1 0 Double (D)<br />
1 1 Undefined<br />
<strong>M68060</strong> USER’S MANUAL<br />
MODE CONTROL<br />
ROUNDING MODE<br />
ROUNDING PRECISION<br />
INEXACT DECIMAL INPUT<br />
INEXACT OPERATION<br />
DIVIDE-BY-ZERO<br />
UNDERFLOW<br />
OVERFLOW<br />
OPERAND ERROR<br />
SIGNALING NOT-A-NUMBER<br />
BRANCH/SET ON UNORDERED<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Floating-Point Unit<br />
6.1.3.1 FLOATING-POINT CONDITION CODE BYTE. The FPCC byte (see Figure 6-4)<br />
contains four condition code bits that are set at the end of all arithmetic instructions involving<br />
the floating-point data registers. These bits are sign of mantissa (N), zero (Z), infinity (I), and<br />
NAN. The FMOVE FPm, < ea><br />
, FMOVEM FPm, and FMOVE FPCR instructions do not affect<br />
the FPCC.<br />
31 30 29 28 27 26 25 24<br />
0<br />
N Z I NAN<br />
Figure 6-4. Floating-Point Condition Code (FPSR)<br />
To aid programmers of floating-point subroutine libraries, the MC68060 implements the four<br />
FPCC bits in hardware instead of only implementing the four IEEE conditions. An instruction<br />
derives the IEEE conditions when needed. For example, the programmers of a complex<br />
arithmetic multiply subroutine usually prefer to handle special data types, such as zeros,<br />
infinities, or NANs, separately from normal data types. The floating-point condition codes<br />
allow users to efficiently detect and handle these special values.<br />
6.1.3.2 QUOTIENT BYTE. The quotient byte (see Figure 6-5) provides compatibility with<br />
the MC68881/MC68882. This byte is set at the completion of the modulo (FMOD) or IEEE<br />
remainder (FREM) instruction, and contains the seven least significant bits of the unsigned<br />
quotient as well as the sign of the entire quotient.<br />
The quotient bits can be used in argument reduction for transcendentals and other functions.<br />
For example, seven bits are more than enough to determine the quadrant of a circle in which<br />
an operand resides. The quotient field (bits 22–16) remains set until the user clears it.<br />
Figure 6-5. Floating-Point Quotient Byte (FPSR)<br />
NOT-A-NUMBER OR UNORDERED<br />
INFINITY<br />
6.1.3.3 EXCEPTION STATUS BYTE. The EXC byte (see Figure 6-6) contains a bit for each<br />
floating-point exception that can occur during the most recent arithmetic instruction or move<br />
operation. The start of most operations clears this byte; however, operations that cannot<br />
generate floating-point exceptions (the FMOVEM and FMOVE control register instructions)<br />
do not clear this byte. An exception handler can use this byte to determine which floatingpoint<br />
exception(s) caused a trap.<br />
ZERO<br />
NEGATIVE<br />
23 22 21 20 19 18 17 16<br />
S QUOTIENT<br />
SEVEN LEAST SIGNIFICANT<br />
BITS OF QUOTIENT<br />
SIGN OF QUOTIENT<br />
6-5
Floating-Point Unit<br />
6.1.3.4 ACCRUED EXCEPTION BYTE. The AEXC byte contains five exception bits (see<br />
Figure 6-7) that the IEEE 754 standard requires for exception-disabled operations. These<br />
exceptions are logical combinations of the bits in the EXC byte. The AEXC byte contains the<br />
history of all floating-point exceptions that have occurred since the user last cleared the<br />
AEXC byte. In normal operations, only the user clears this byte by writing to the FPSR; however,<br />
a reset or a restore operation of the null state can also clear the AEXC byte.<br />
6-6<br />
BRANCH/SET ON<br />
UNORDERED<br />
SIGNALING NOT-A-NUMBER<br />
OPERAND ERROR<br />
OVERFLOW<br />
15 14 13 12 11 10 9 8<br />
BSUN<br />
SNAN OPERR OVFL UNFL DZ INEX2 INEX1<br />
Figure 6-6. Floating-Point Exception Status Byte (FPSR)<br />
7 6 5 4 3 2 0<br />
IOP OVFL UNFL DZ INEX<br />
RESERVED<br />
Figure 6-7. Floating-Point Accrued Exception Byte (FPSR)<br />
Many users elect to disable traps for all or part of the floating-point exception classes. The<br />
AEXC byte makes it unnecessary to poll the EXC byte after each floating-point instruction.<br />
At the end of most operations (FMOVEM and FMOVE excluded), the bits in the EXC byte<br />
are logically combined to form an AEXC value that is logically ORed into the existing AEXC<br />
byte. This operation creates sticky floating-point exception bits in the AEXC byte that the<br />
user needs to poll only once (i.e., at the end of a series of floating-point operations). A sticky<br />
bit is one that remains set until the user clears it.<br />
Setting or clearing the AEXC bits neither causes nor prevents an exception. The following<br />
equations show the comparative relationship between the EXC byte and AEXC byte. Comparing<br />
the current value in the AEXC bit with a combination of bits in the EXC byte derives<br />
a new value in the corresponding AEXC bit. These equations apply to setting the AEXC bits<br />
at the end of each operation affecting the AEXC byte:<br />
<strong>M68060</strong> USER’S MANUAL<br />
INEXACT<br />
DIVIDE-BY-ZERO<br />
UNDERFLOW<br />
OVERFLOW<br />
INEXACT DECIMAL<br />
INPUT<br />
INEXACT OPERATION<br />
DIVIDE-BY-ZERO<br />
UNDERFLOW<br />
INVALID OPERATION<br />
MOTOROLA
6.1.4 Floating-Point Instruction Address Register (FPIAR)<br />
MOTOROLA<br />
New AEXC Bit = Old AEXC Bit + EXC Bits<br />
IOP = IOP + (BSUN + SNAN + OPERR)<br />
OVFL = OVFL + (OVFL)<br />
UNFL = UNFL + (UNFL • INEX2)<br />
DZ = DZ + (DZ)<br />
INEX = INEX + (INEX1 + INEX2 + OVFL)<br />
<strong>M68060</strong> USER’S MANUAL<br />
Floating-Point Unit<br />
For the subset of the floating-point instructions that generate exception traps, the FPU loads<br />
the 32-bit FPIAR with the logical address of the instruction before executing the instruction.<br />
Because the integer unit can execute instructions while the FPU executes floating-point<br />
instructions, the program counter (PC) value stacked by the MC68060 in response to a floating-point<br />
exception handler may not point to the offending instruction. Therefore, a floatingpoint<br />
exception handler uses the address in the FPIAR to locate a floating-point instruction<br />
that has caused an exception. Since the FMOVE to/from the FPCR, FPSR, or FPIAR and<br />
FMOVEM instructions cannot generate floating-point exceptions, these instructions do not<br />
modify the FPIAR. However, they can be used to read the FPIAR in an exception handler<br />
without changing the previous value. A reset or a restore operation of the null state clears<br />
the FPIAR.<br />
6.2 FLOATING-POINT DATA FORMATS AND DATA TYPES<br />
The M68000 floating-point model (MC68881, MC68882, MC68040, and MC68060) supports<br />
the following floating-point data formats: single precision, double precision, extended<br />
precision, and packed decimal. The M68000 floating-point model supports the following<br />
data types: normalized, zeros, infinities, unnormalized numbers, denormalized numbers,<br />
and NANs. The MC68060 supports part of the M68000 floating-point model in hardware.<br />
Table 6-3 lists the floating-point data formats and data types supported by the MC68060.<br />
Table 6-4 through Table 6-7 summarize the floating-point data formats and data types<br />
details.<br />
Table 6-3. MC68060 FPU Data Formats and Data Types<br />
Data Formats<br />
Number Types<br />
Single-<br />
Precision<br />
Real<br />
Double-<br />
Precision<br />
Real<br />
Extended-<br />
Precision<br />
Real<br />
Packed-<br />
Decimal<br />
Real<br />
Byte<br />
Integer<br />
Word<br />
Integer<br />
Long-Word<br />
Integer<br />
Normalized * * * † * * *<br />
Zero * * * † * * *<br />
Infinity * * * † — — —<br />
NAN * * * † — — —<br />
Denormalized † † † † — — —<br />
Unnormalized — — † † — — —<br />
*<br />
Data Format/Type Supported by On-Chip MC68060 FPU Hardware<br />
†<br />
Data Format/Type Supported by Software (<strong>M68060</strong>SP)<br />
6-7
Floating-Point Unit<br />
6-8<br />
Table 6-4. Single-Precision Real Format Summary<br />
Data Format<br />
31 30 23 22 0<br />
s e f<br />
Field Size In Bits<br />
Sign (s) 1<br />
Biased Exponent (e) 8<br />
Fraction (f) 23<br />
Total 32<br />
Interpretation of Sign<br />
Positive Fraction s = 0<br />
Negative Fraction s = 1<br />
Normalized Numbers<br />
Bias of Biased Exponent +127 ($7F)<br />
Range of Biased Exponent 0 < e < 255 ($FF)<br />
Range of Fraction Zero or Nonzero<br />
Fraction 1.f<br />
Relation to Representation of Real Numbers (–1) s × 2e–127 Denormalized Numbers<br />
× 1.f<br />
Biased Exponent Format Minimum 0 ($00)<br />
Bias of Biased Exponent +126 ($7E)<br />
Range of Fraction Nonzero<br />
Fraction 0.f<br />
Relation to Representation of Real Numbers (–1) s × 2 –126<br />
Signed Zeros<br />
× 0.f<br />
Biased Exponent Format Minimum 0 ($00)<br />
Fraction<br />
Signed Infinities<br />
0.f = 0.0<br />
Biased Exponent Format Maximum 255 ($FF)<br />
Fraction<br />
NANs<br />
0.f = 0.0<br />
Sign Don’t Care<br />
Biased Exponent Format Maximum 255 ($FF)<br />
Fraction Nonzero<br />
Representation of Fraction<br />
Nonsignaling<br />
Signaling<br />
Nonzero Bit Pattern Created by User<br />
Fraction When Created by FPU<br />
Approximate Ranges<br />
<strong>M68060</strong> USER’S MANUAL<br />
1xxxx…xxxx<br />
0xxxx…xxxx<br />
xxxxx…xxxx<br />
11111…1111<br />
Maximum Positive Normalized 3.4 × 1038 Minimum Positive Normalized 1.2 × 10 –38<br />
Minimum Positive Denormalized 1.4 × 10 –45<br />
MOTOROLA
MOTOROLA<br />
Table 6-5. Double-Precision Real Format Summary<br />
Data Format<br />
63 62 52 51 0<br />
s e f<br />
Field Size (in Bits)<br />
Sign (s) 1<br />
Biased Exponent (e) 11<br />
Fraction (f) 52<br />
Total 64<br />
Interpretation of Sign<br />
Positive Fraction s = 0<br />
Negative Fraction s = 1<br />
Normalized Numbers<br />
Bias of Biased Exponent +1023 ($3FF)<br />
Range of Biased Exponent 0 < e < 2047 ($7FF)<br />
Range of Fraction Zero or Nonzero<br />
Fraction 1.f<br />
Relation to Representation of Real Numbers (–1) s × 2e–1023 Denormalized Numbers<br />
× 1.f<br />
Biased Exponent Format Minimum 0 ($000)<br />
Bias of Biased Exponent +1022 ($3FE)<br />
Range of Fraction Nonzero<br />
Fraction 0.f<br />
Relation to Representation of Real Numbers (–1) s × 2 –1022<br />
Signed Zeros<br />
× 0.f<br />
Biased Exponent Format Minimum 0 ($00)<br />
Fraction (Mantissa/Significand)<br />
Signed Infinities<br />
0.f = 0.0<br />
Biased Exponent Format Maximum 2047 ($7FF)<br />
Fraction<br />
NANs<br />
0.f = 0.0<br />
Sign 0 or 1<br />
Biased Exponent Format Maximum 2047 ($7FF)<br />
Fraction Nonzero<br />
Representation of Fraction<br />
Nonsignaling<br />
Signaling<br />
Nonzero Bit Pattern Created by User<br />
Fraction When Created by FPU<br />
Approximate Ranges<br />
<strong>M68060</strong> USER’S MANUAL<br />
.1xxxx…xxxx<br />
.0xxxx…xxxx<br />
.xxxxx…xxxx<br />
.11111…1111<br />
Maximum Positive Normalized 1.8 x 10 308<br />
Minimum Positive Normalized 2.2 x 10 –308<br />
Minimum Positive Denormalized 4.9 x 10 –324<br />
Floating-Point Unit<br />
6-9
Floating-Point Unit<br />
6-10<br />
Table 6-6. Extended-Precision Real Format Summary<br />
Data Format<br />
95 94 80 79 64 63<br />
62 0<br />
s e u j<br />
f<br />
Field Size (in Bits)<br />
Sign (s)<br />
1<br />
Biased Exponent (e)<br />
15<br />
Zero, Reserved (u)<br />
16<br />
Explicit Integer Bit (j)<br />
1<br />
Mantissa (f)<br />
63<br />
Total<br />
96<br />
Interpretation of Unused Bits<br />
Input<br />
Don’t Care<br />
Output<br />
All Zeros<br />
Interpretation of Sign<br />
Positive Mantissa<br />
s = 0<br />
Negative Mantissa<br />
s = 1<br />
Normalized Numbers<br />
Bias of Biased Exponent<br />
+16383 ($3FFF)<br />
Range of Biased Exponent<br />
0 < = e < 32767 ($7FFF)<br />
Explicit Integer Bit<br />
1<br />
Range of Mantissa<br />
Zero or Nonzero<br />
Mantissa (Explicit Integer Bit and Fraction)<br />
1.f<br />
Relation to Representation of Real Numbers<br />
(–1) s × 2e–16383 Denormalized Numbers<br />
× j.f<br />
Biased Exponent Format Minimum 0 ($0000)<br />
Bias of Biased Exponent +16383 ($3FFF)<br />
Explicit Integer Bit 0<br />
Range of Mantissa Nonzero<br />
Mantissa (Explicit Integer Bit and Fraction) 0.f<br />
Relation to Representation of Real Numbers (–1) s × 2 –16383 × 0.f<br />
Signed Zeros<br />
Biased Exponent Format Minimum 0 ($0000)<br />
Mantissa (Explicit Integer Bit and Fraction) 0.0<br />
Signed Infinities<br />
Biased Exponent Format Maximum 32767 ($7FFF)<br />
Explicit Integer Bit Don’t Care<br />
Mantissa (Explicit Integer Bit and Fraction)<br />
NANs<br />
x.000…0000<br />
Sign Don’t Care<br />
Explicit Integer Bit Don’t Care<br />
Biased Exponent Format Maximum 32767 ($7FFF)<br />
Mantissa Nonzero<br />
Representation of Mantissa<br />
Nonsignaling<br />
Signaling<br />
Nonzero Bit Pattern Created by User<br />
Mantissa When Created by FPU<br />
<strong>M68060</strong> USER’S MANUAL<br />
x.1xxxx…xxxx<br />
x.0xxxx…xxxx<br />
x.xxxxx…xxxx<br />
1.11111…1111<br />
MOTOROLA
Table 6-6. Extended-Precision Real Format Summary (Continued)<br />
Approximate Ranges<br />
Maximum Positive Normalized 1.2 × 104932 Minimum Positive Normalized 1.7 × 10 –4932<br />
Minimum Positive Denormalized 1.7 × 10 –4951<br />
Table 6-7. Packed Decimal Real Format Summary<br />
95 64<br />
SM SE Y Y EXP2 EXP1 EXP0 (EXP3) X X X X X X X X INTEGER<br />
63 32<br />
FRAC15 FRAC14 FRAC13 FRAC12 FRAC11 FRAC10 FRAC9 FRAC8<br />
31 0<br />
FRAC7 FRAC6 FRAC5 FRAC4 FRAC3 FRAC2 FRAC1<br />
FRAC0<br />
Data Type SM SE Y Y<br />
Floating-Point Unit<br />
–In-Range 1 0/1 X X $000–$999 $XXX0–$XXX9 $00…01–$99…99<br />
NOTE: EXP3 is generated only during an FMOVE OUT if the source is too large to be represented<br />
with a three-digit exponent. Otherwise, it is a don’t care.<br />
6.3 COMPUTATIONAL ACCURACY<br />
3-Digit<br />
Exponent<br />
1-Digit<br />
Integer<br />
16-Digit Fraction<br />
±Infinity 0/1 1 1 1 $FFF $XXXX $00…00<br />
±NAN 0/1 1 1 1 $FFF $XXXX Nonzero<br />
±SNAN 0/1 1 1 1 $FFF $XXXX Nonzero<br />
+Zero 0 0/1 X X $000–$999 $XXX0 $00…00<br />
–Zero 1 0/1 X X $000–$999 $XXX0 $00…00<br />
+In-Range 0 0/1 X X $000–$999 $XXX0–$XXX9 $00…01–$99…99<br />
Whenever an attempt is made to represent a real number in a binary format of finite precision,<br />
there is a possibility that the number can not be represented exactly. This is commonly<br />
referred to as a round-off error. Furthermore, when two inexact numbers are used in a calculation,<br />
the error present in each number is reflected, and possibly aggravated, in the<br />
result. All FPU calculations use an intermediate result. When the MC68060 performs an<br />
operation, the calculation is carried out using extended-precision inputs, and the intermediate<br />
result is calculated as if to produce infinite precision. After the calculation is complete,<br />
the intermediate result is rounded to the selected precision and stored in the destination.<br />
The FPCR RND and PREC encodings (see Table 6-1 and Table 6-2) provide emulation for<br />
devices that only support single and double precision. By setting the rounding precision to<br />
single, the MC68060 will perform all calculations as if only 24 bits of precision were available<br />
for the result. Setting the rounding precision to double does the same to 53 bits of precision.<br />
The execution speed of all instructions is the same whether using single- or double-precision<br />
rounding. When using these two forced rounding precisions, the MC68060 produces the<br />
same results as any other device that conforms to the IEEE 754 standard, but does not support<br />
extended precision. The results are the same when performing the same operation in<br />
extended precision and storing the results in single- or double-precision format.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-11
Floating-Point Unit<br />
The FPU performs all floating-point internal operations in extended precision. It supports<br />
mixed-mode arithmetic by converting single- and double-precision operands to extendedprecision<br />
values before performing the specified operation. The FPU converts all memory<br />
data formats to extended precision before using it in a floating-point operation or loading it<br />
in a floating-point data register. The FPU also converts extended-precision data formats in<br />
a floating-point data register to any data format and either stores it in a memory destination<br />
or in an integer data register.<br />
If the external operand is a denormalized number or unnormalized number, the number is<br />
normalized before an operation is performed. However, an external denormalized number<br />
moved into a floating-point data register is stored as a denormalized number.<br />
If an external operand is an unnormalized number, the number is normalized before it is<br />
used in an arithmetic operation. If the external operand is an unnormalized zero (i.e., with a<br />
mantissa of all zeros), the number is converted to a normalized zero before the specified<br />
operation is performed. The regular use of unnormalized inputs not only defeats the purpose<br />
of the IEEE 754 standard, but also can produce gross inaccuracies in the results.<br />
6.3.1 Intermediate Result<br />
Figure 6-8 illustrates the intermediate result format. The intermediate result’s exponent for<br />
some dyadic operations (e.g., multiply and divide) can easily overflow or underflow the 15bit<br />
exponent of the destination floating-point register. To simplify the overflow and underflow<br />
detection, intermediate results in the FPU maintain a 16-bit, twos-complement integer exponent.<br />
Detection of an overflow or underflow intermediate result always converts the 16-bit<br />
exponent into a 15-bit biased exponent before being stored in a floating-point data register.<br />
The FPU internally maintains the 67-bit mantissa for rounding purposes. The mantissa is<br />
always rounded to 64 bits (or less, depending on the selected rounding precision) before it<br />
is stored in a floating-point data register.<br />
16-BIT EXPONENT 63-BIT FRACTION<br />
INTEGER BIT<br />
OVERFLOW BIT<br />
LSB OF FRACTION<br />
GUARD BIT<br />
ROUND BIT<br />
STICKY BIT<br />
Figure 6-8. Intermediate Result Format<br />
If the destination is a floating-point data register, the result is in the extended-precision format<br />
and is rounded to the precision specified by the FPCR PREC bits before being stored.<br />
All mantissa bits beyond the selected precision are zero. If the single- or double-precision<br />
mode is selected, the exponent value is in the correct range even if it is stored in extendedprecision<br />
format. If the destination is a memory location, the FPCR PREC bits are ignored.<br />
In this case, a number in the extended-precision format is taken from the source floatingpoint<br />
data register, rounded to the destination format precision, and then written to memory.<br />
6-12 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
Depending on the selected rounding mode or destination data format in effect, the location<br />
of the least significant bit of the mantissa and the locations of the guard, round, and sticky<br />
bits in the 67-bit intermediate result mantissa varies. The guard and round bits are always<br />
calculated exactly. The sticky bit is used to create the illusion of an infinitely wide intermediate<br />
result. As the arrow illustrates in Figure 6-8, the sticky bit is the logical OR of all the bits<br />
in the infinitely precise result to the right of the round bit. During the calculation stage of an<br />
arithmetic operation, any nonzero bits generated that are to the right of the round bit set the<br />
sticky bit to one. Because of the sticky bit, the rounded intermediate result for all required<br />
IEEE arithmetic operations in the RN mode is in error by no more than one-half unit in the<br />
last place.<br />
6.3.2 Rounding the Result<br />
Range control is the process of rounding the mantissa of the intermediate result to the specified<br />
precision and checking the 16-bit intermediate exponent to ensure that it is within the<br />
representable range of the selected rounding-precision format. Range control ensures correct<br />
emulation of a device that only supports single- or double-precision arithmetic. If the<br />
intermediate result’s exponent exceeds the range of the selected precision, the exponent<br />
value appropriate for an underflow or overflow is stored as the result in the 16-bit extendedprecision<br />
format exponent. For example, if the data format and rounding mode is single-precision<br />
RM and the result of an arithmetic operation overflows the magnitude of the singleprecision<br />
format, the largest normalized single-precision value is stored as an extended-precision<br />
number in the destination floating-point data register (i.e., an unbiased 15-bit exponent<br />
of $00FF and a mantissa of $FFFFFF0000000000). If an infinity is the appropriate<br />
result for an underflow or overflow, the infinity value for the destination data format is stored<br />
as the result (i.e., an exponent with the maximum value and a mantissa of zero).<br />
Figure 6-9 illustrates the algorithm that is used to round an intermediate result to the<br />
selected rounding precision and destination data format. If the destination is a floating-point<br />
data register, either the selected rounding precision specified by the FPCR PREC bits or by<br />
the instruction itself determines the rounding boundary. For example, FSADD and FDADD<br />
specify single- and double-precision rounding regardless of the precision specified in the<br />
FPCR PREC bits. If the destination is external memory or an integer data register, the destination<br />
data format determines the rounding boundary. If the rounded result of an operation<br />
is not exact, then the INEX2 bit is set in the FPSR EXC byte.<br />
The three additional bits beyond the extended-precision format allow the FPU to perform all<br />
calculations as though it were performing calculations using a float engine with infinite bit<br />
precision. The result is always correct for the specified destination’s data format before performing<br />
rounding (unless an overflow or underflow error occurs). The specified rounding<br />
operation then produces a number that is as close as possible to the infinitely precise intermediate<br />
value and still representable in the selected precision. The following tie-case example<br />
illustrates how the 67-bit mantissa allows the FPU to meet the error bound of the IEEE<br />
specification:<br />
The least significant bit of the rounded result does not increment even though the guard bit<br />
is set in the intermediate result. The IEEE 754 standard specifies that tie cases should be<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-13
Floating-Point Unit<br />
ADD 1 TO<br />
LSB<br />
SHIFT MANTISSA<br />
RIGHT 1 BIT,<br />
ADD 1 TO EXPONENT<br />
Figure 6-9. Rounding Algorithm Flowchart<br />
Result Integer 63-Bit Fraction Guard Round Sticky<br />
Intermediate x xxx…x00 1 0 0<br />
Rounded-to-Nearest x xxx…x00 0 0 0<br />
handled in this manner. If the destination data format is extended and there is a difference<br />
between the infinitely precise intermediate result and the round-to-nearest result, the relative<br />
difference is 2 –64 (the value of the guard bit). This error is equal to one-half of the least<br />
significant bit’s value and is the worst case error that can be introduced when using the RN<br />
6-14 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
ENTRY<br />
INEX2 ➧ 1<br />
SELECT ROUNDING MODE<br />
RN RM<br />
RP<br />
RZ<br />
GUARD AND LSB = 1,<br />
ROUND AND STICKY = 0<br />
OR<br />
GUARD = 1<br />
ROUND OR STICKY = 1<br />
POS NEG POS NEG<br />
INTERMEDIATE<br />
RESULT<br />
ADD 1 TO<br />
LSB<br />
INTERMEDIATE<br />
RESULT<br />
OVERFLOW = 1<br />
GUARD ➧ 0<br />
ROUND ➧ 0<br />
STICKY ➧ 0<br />
GUARD, ROUND,<br />
AND STICKY BITS = 0<br />
GUARD, ROUND,<br />
AND STICKY ARE<br />
CHOPPED<br />
EXACT RESULT<br />
EXIT EXIT
Floating-Point Unit<br />
mode. Thus, the term one-half unit in the last place correctly identifies the error bound for<br />
this operation. This error specification is the relative error present in the result; the absolute<br />
error bound is equal to 2 exponent x 2 –64 . The following example illustrates the error bound<br />
for the other rounding modes:<br />
Result Integer 63-Bit Fraction Guard Round Sticky<br />
Intermediate x xxx…x00 1 1 1<br />
Rounded-to-Zero x xxx…x00 0 0 0<br />
The difference between the infinitely precise result and the rounded result is 2 –64 + 2 –65 +<br />
2 –66 , which is slightly less than 2 –63 (the value of the least significant bit). Thus, the error<br />
bound for this operation is not more than one unit in the last place. For all arithmetic operations,<br />
the FPU meets these error bounds, providing accurate and repeatable results.<br />
6.4 POSTPROCESSING OPERATION<br />
Most operations end with a postprocessing step. The FPU provides two steps in postprocessing.<br />
First, the condition code bits in the FPSR are set or cleared at the end of each arithmetic<br />
operation or move operation to a single floating-point data register. The condition code<br />
bits are consistently set based on the result of the operation. Second, the FPU supports 32<br />
conditional tests that allow floating-point conditional instructions to test floating-point conditions<br />
in exactly the same way as the integer conditional instructions test the integer condition<br />
codes. The combination of consistently set condition code bits and the simple programming<br />
of conditional instructions gives the MC68060 a very flexible, high-performance method of<br />
altering program flow based on floating-point results. While reading the summary for each<br />
instruction, it should be assumed that an instruction performs postprocessing unless the<br />
summary specifically states that the instruction does not do so. The following paragraphs<br />
describe postprocessing in detail.<br />
6.4.1 Underflow, Round, and Overflow<br />
During the calculation of an arithmetic result, the FPU arithmetic logic unit (ALU) has more<br />
precision and range than the 80-bit extended-precision format. However, the final result of<br />
these operations is an extended-precision floating-point value. In some cases, an intermediate<br />
result becomes either smaller or larger than can be represented in extended precision.<br />
Also, the operation can generate a larger exponent or more bits of precision than can be represented<br />
in the chosen rounding precision. For these reasons, every arithmetic instruction<br />
ends by rounding the result and checking for overflow and underflow.<br />
At the completion of an arithmetic operation, the intermediate result is checked to see if it is<br />
too small to be represented as a normalized number in the selected precision. If so, the<br />
UNFL bit is set in the FPSR EXC byte. The MC68060 then takes a nonmaskable underflow<br />
exception and executes the <strong>M68060</strong>SP underflow exception handler, denormalizing the<br />
result. Denormalizing a number causes a loss of accuracy, but a zero is not returned unless<br />
a gross underflow occurs. If a number has grossly underflowed, the MC68060 takes a nonmaskable<br />
underflow exception, and the <strong>M68060</strong>SP returns a zero or the smallest denormalized<br />
number with the correct sign, depending on the rounding mode in effect.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-15
Floating-Point Unit<br />
If no underflow occurs, the intermediate result is rounded according to the user-selected<br />
rounding precision and rounding mode. After rounding, the INEX2 bit of the FPSR EXC byte<br />
is set accordingly. Finally, the magnitude of the result is checked to see if it is too large to<br />
be represented in the current rounding precision. If so, the OVFL bit of the FPSR EXC byte<br />
is set, and the MC68060 takes a nonmaskable overflow exception and executes the<br />
<strong>M68060</strong>SP overflow exception handler. The <strong>M68060</strong>SP returns a correctly signed infinity or<br />
a correctly signed largest normalized number, depending on the rounding mode in effect.<br />
6.4.2 Conditional Testing<br />
Unlike the integer arithmetic condition codes, an instruction either always sets the floatingpoint<br />
condition codes in the same way or it does not change them at all. Therefore, the<br />
instruction descriptions do not include floating-point condition code settings. The following<br />
paragraphs describe how floating-point condition codes are set for all instructions that modify<br />
condition codes. Refer to 6.1.3.1 Floating-Point Condition Code Byte for a description<br />
of the FPCC byte.<br />
The data type of the operation’s result determines how the four condition code bits are set.<br />
Table 6-8 lists the condition code bit setting for each data type. The MC68060 generates<br />
only eight of the 16 possible combinations. Loading the FPCC with one of the other combinations<br />
and executing a conditional instruction can produce an unexpected branch condition.<br />
Table 6-8. Floating-Point Condition Code Encoding<br />
Data Type N Z I NAN<br />
+ Normalized or Denormalized 0 0 0 0<br />
– Normalized or Denormalized 1 0 0 0<br />
+ 0 0 1 0 0<br />
– 0 1 1 0 0<br />
+ Infinity 0 0 1 0<br />
– Infinity 1 0 1 0<br />
+ NAN 0 0 0 1<br />
– NAN 1 0 0 1<br />
The inclusion of the NAN data type in the IEEE floating-point number system requires each<br />
conditional test to include the NAN condition code bit in its Boolean equation. Because a<br />
comparison of a NAN with any other data type is unordered (i.e., it is impossible to determine<br />
if a NAN is bigger or smaller than an in-range number), the compare instruction sets the<br />
NAN condition code bit when an unordered compare is attempted. All arithmetic instructions<br />
also set the FPCC NAN bit if the result of an operation is a NAN. The conditional instructions<br />
interpret the NAN condition code bit equal to one as the unordered condition.<br />
The IEEE 754 standard defines four conditions: equal to (EQ), greater than (GT), less than<br />
(LT), and unordered (UN). In addition, the standard only requires the generation of the condition<br />
codes as a result of a floating-point compare operation. The FPU tests for these conditions<br />
and 28 others at the end of any operation affecting the condition codes. For purposes<br />
of the floating-point conditional branch, set byte on condition, decrement and branch on condition,<br />
and trap on condition instructions, the MC68060 logically combines the four FPCC<br />
bits to form 32 conditional tests. The 32 conditional tests are separated into two groups—16<br />
6-16 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
tests that set the BSUN bit in the FPSR status byte if an unordered condition is present when<br />
the conditional test is attempted (IEEE nonaware tests), and 16 tests that do not cause the<br />
BSUN bit in the FPSR status byte (IEEE aware tests). The set of IEEE nonaware tests is<br />
best used:<br />
• When porting a program from a system that does not support the IEEE 754 standard to<br />
a conforming system, or<br />
• When generating high-level language code that does not support IEEE floating-point<br />
concepts (i.e., the unordered condition).<br />
An unordered condition occurs when one or both of the operands in a floating-point compare<br />
operation is a NAN. The inclusion of the unordered condition in floating-point branches<br />
destroys the familiar trichotomy relationship (greater than, equal, less than) that exists for<br />
integers. For example, the opposite of floating-point branch greater than (FBGT) is not floating-point<br />
branch less than or equal (FBLE). Rather, the opposite condition is floating-point<br />
branch not greater than (FBNGT). If the result of the previous instruction was unordered,<br />
FBNGT is true; whereas, both FBGT and FBLE would be false since unordered fails both of<br />
these tests. Compiler programmers should be particularly careful of the lack of trichotomy in<br />
the floating-point branches since it is common for compilers to invert the sense of conditions.<br />
When using the IEEE nonaware tests, the BSUN bit and the NAN bit are set in the FPSR,<br />
unless the branch is an FBEQ or an FBNE. If the BSUN exception is enabled in the FPCR,<br />
an exception is taken. Therefore, the IEEE nonaware program may be interrupted if an<br />
unexpected condition occurs.<br />
Compilers and programmers who are knowledgeable of the IEEE 754 standard should use<br />
the IEEE aware tests in programs that contain ordered and unordered conditions. Since the<br />
ordered or unordered attribute is explicitly included in the conditional test, the BSUN bit is<br />
not set in the FPSR EXC byte when the unordered condition occurs.<br />
Table 6-9 summarizes the conditional mnemonics, definitions, equations, predicates, and<br />
whether the BSUN bit is set in the FPSR EXC byte for the 32 floating-point conditional tests.<br />
The equation column lists the combination of FPCC bits for each test in the form of an equation.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-17
Floating-Point Unit<br />
Table 6-9. Floating-Point Conditional Tests<br />
Mnemonic Definition Equation Predicate BSUN Bit Set<br />
IEEE Nonaware Tests<br />
EQ Equal Z 000001 No<br />
NE Not Equal Z 001110 No<br />
GT Greater Than NAN + Z + N 010010 Yes<br />
NGT Not Greater Than NAN + Z + N 011101 Yes<br />
GE Greater Than or Equal Z + (NAN + N) 010011 Yes<br />
NGE Not Greater Than or Equal NAN + (N • Z) 011100 Yes<br />
LT Less Than N • (NAN + Z) 010100 Yes<br />
NLT Not Less Than NAN + (Z + N) 011011 Yes<br />
LE Less Than or Equal Z + (N • NAN) 010101 Yes<br />
NLE Not Less Than or Equal NAN + (N + Z) 011010 Yes<br />
GL Greater or Less Than NAN + Z 010110 Yes<br />
NGL Not Greater or Less Than NAN + Z 011001 Yes<br />
GLE Greater, Less, or Equal NAN 010111 Yes<br />
NGLE Not Greater, Less, or Equal NAN 011000 Yes<br />
IEEE Aware Tests<br />
EQ Equal Z 000001 No<br />
NE Not Equal Z 001110 No<br />
OGT Ordered Greater Than NAN + Z + N 000010 No<br />
ULE Unordered or Less or Equal NAN + Z + N 001101 No<br />
OGE Ordered Greater Than or Equal Z + (NAN + N) 000011 No<br />
ULT Unordered or Less Than NAN + (N • Z) 001100 No<br />
OLT Ordered Less Than N • (NAN + Z) 000100 No<br />
UGE Unordered or Greater or Equal NAN + (Z + N) 001011 No<br />
OLE Ordered Less Than or Equal Z + (N • NAN) 000101 No<br />
UGT Unordered or Greater Than NAN + (N + Z) 001010 No<br />
OGL Ordered Greater or Less Than NAN + Z 000110 No<br />
UEQ Unordered or Equal NAN + Z 001001 No<br />
OR Ordered NAN 000111 No<br />
UN Unordered NAN 001000 No<br />
Miscellaneous Tests<br />
F False False 000000 No<br />
T True True 001111 No<br />
SF Signaling False False 010000 Yes<br />
ST Signaling True True 011111 Yes<br />
SEQ Signaling Equal Z 010001 Yes<br />
SNE Signaling Not Equal Z 011110 Yes<br />
NOTE: All condition codes with an overbar indicate cleared bits; all other bits are set.<br />
6-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
6.5 FLOATING-POINT EXCEPTIONS<br />
Floating-Point Unit<br />
There are two classes of floating-point-related exceptions: nonarithmetic floating-point<br />
exceptions and arithmetic floating-point exceptions. The latter relates to the handling of<br />
arithmetic exceptions caused by floating-point activity, and the former includes unimplemented<br />
floating-point instructions, unsupported data types and unimplemented effective<br />
addresses not related to the handling of arithmetic exceptions. The floating-point format<br />
error exception is considered an integer unit exception (see Section 8 Exception Processing).<br />
The following paragraphs detail floating-point exceptions and how the MC68060 and<br />
<strong>M68060</strong>SP handle them. Table 6-10 lists the vector numbers related to floating-point exceptions.<br />
Vector<br />
Number<br />
11<br />
55<br />
60<br />
48<br />
49<br />
50<br />
51<br />
52<br />
53<br />
54<br />
Vector Offset<br />
(Hex)<br />
02C<br />
0DC<br />
0F4<br />
0C0<br />
0C4<br />
0C8<br />
0CC<br />
0D0<br />
0D4<br />
0D8<br />
Table 6-10. Floating-Point Exception Vectors<br />
Frame<br />
Format<br />
2<br />
0,2,3<br />
0<br />
0<br />
0,3<br />
0<br />
0,3<br />
0,3<br />
0,3<br />
0,3<br />
Program<br />
Counter<br />
next<br />
next<br />
fault<br />
fault<br />
next<br />
next<br />
next<br />
next<br />
next<br />
next<br />
The following paragraphs detail nonarithmetic floating-point exceptions.<br />
6.5.1 Unimplemented Floating-Point Instructions<br />
Assignment<br />
Floating-Point Unimplemented Instruction Exception<br />
Floating-Point Unimplemented Data Type<br />
Unimplemented Effective Address Exception<br />
Floating-Point Branch or Set on Unordered Condition<br />
Floating-Point Inexact Result<br />
Floating-Point Divide-by-Zero<br />
Floating-Point Underflow<br />
Floating-Point Operand Error<br />
Floating-Point Overflow<br />
Floating-Point SNAN<br />
For floating-point pre-instruction exceptions, the PC points to the next floating-point instruction and the stack frame of format<br />
0 is generated. For post-instruction exceptions, the PC points to the next instruction and the frame of format 3 is generated.<br />
Table 6-11 lists the floating-point instructions which are unimplemented on the MC68060.<br />
Refer to 8.2.4 Illegal Instruction and Unimplemented Instruction Exceptions for background<br />
material. Motorola provides the <strong>M68060</strong>SP, a software package that includes floating-point<br />
emulation for the MC68060. Refer to Appendix C for software porting information.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-19
Floating-Point Unit<br />
Table 6-11. Unimplemented Instructions<br />
Monadic Operations<br />
FACOS FLOGN<br />
FASIN FLOGNP1<br />
FATAN FMOVECR<br />
FATANH FSIN<br />
FCOS FSINCOS<br />
FCOSH FSINH<br />
FETOX FTAN<br />
FETOXM1 FTANH<br />
FGETEXP FTENTOX<br />
FGETMAN FTWOTOX<br />
FLOG10 FLOG2<br />
Dyadic Operations<br />
FMOD FREM<br />
FSCALE —<br />
Miscellaneous<br />
FTRAPcc FDBcc<br />
FScc —<br />
Unimplemented Effective Address<br />
FMOVEM.X (dynamic register list)<br />
FMOVEM.L #immediate, list<br />
of 2 or 3 control registers<br />
F.X #immediate,FPn F.P #immediate,FPn<br />
A floating-point unimplemented instruction exception occurs when the processor attempts<br />
to execute an instruction word pattern that begins with $F, the processor recognizes this bit<br />
pattern as an MC68881 instruction, the FPU is enabled via the processor control register<br />
(PCR), but the floating-point instruction is not implemented in the MC68060 FPU. This<br />
exception corresponds to vector number 11 and shares this vector with the floating-point disabled<br />
and the unimplemented F-line exceptions. A stack frame of type 2 is generated when<br />
this exception is reported. The stacked PC points to the logical address of the next instruction<br />
after the floating-point instruction. In addition, the effective address of the floating-point<br />
operand in memory (if any) is calculated and stored in the effective address field.<br />
When an unimplemented floating-point instruction is encountered, the processor waits for<br />
all previous floating-point instructions to complete execution. Pending exceptions are taken<br />
and handled prior to the execution of the unimplemented instruction.<br />
The processor begins exception processing for the unimplemented floating-point instruction<br />
by making an internal copy of the current status register (SR). The processor then enters<br />
the supervisor mode and clears the trace bit. The processor creates a format $2 stack frame<br />
and saves the vector offset, PC, internal copy of the SR, and calculated effective address in<br />
the stack frame. The saved PC value is the logical address of the instruction that follows the<br />
unimplemented floating-point instruction. The processor generates exception vector number<br />
11 for the unimplemented F-line instruction exception vector, fetches the address of the<br />
F-line exception handler from the processor’s exception vector table, pushes the format $2<br />
stack frame on the system stack, and begins execution of the exception handler after<br />
prefetching instructions to fill the pipeline.<br />
6-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
The <strong>M68060</strong>SP emulates the unimplemented floating-point instruction in software, maintaining<br />
user-object-code compatibility. Refer to Section 8 Exception Processingfor details<br />
about exception vectors and format $2 stack frames.<br />
The <strong>M68060</strong>SP uses the FPIAR to determine the instruction needing emulation and uses<br />
the effective address field to fetch the memory operand, if any. Once the instruction has<br />
been emulated and the result is reached, the <strong>M68060</strong>SP moves the result into the appropriate<br />
destination floating-point data register or memory location and returns to normal instruction<br />
flow using the RTE instruction.<br />
The <strong>M68060</strong>SP not only emulates the instruction, but in addition, it ensures that if any floating-point<br />
arithmetic exceptional conditions arise from the emulation of the unimplemented<br />
instruction and if the corresponding floating-point arithmetic exception is enabled, the<br />
<strong>M68060</strong>SP restores the floating-point state frame back into the FPU in the desired exceptional<br />
state. This effectively imitates the action of the MC68060-implemented instructions.<br />
6.5.2 Unsupported Floating-Point Data Types<br />
An unsupported data type exception occurs when either operand to an implemented floating-point<br />
instruction is denormalized (for single-, double-, and extended-precision operands),<br />
unnormalized (for extended-precision operands), or either the source or destination<br />
data format is packed decimal real. These data types are unimplemented in the MC68060<br />
and must be emulated in software.<br />
NOTE<br />
In this manual, all references to the unsupported floating-point<br />
data types also refer to the unimplemented data types.<br />
When the processor encounters an unsupported data type, the procedure taken is identical<br />
to that used when an unimplemented instruction is taken. Unsupported data types with operands<br />
for register-to-register or memory-to-register instructions cause a pre-instruction<br />
exception. When an unsupported data type is detected for an FMOVE OUT instruction, a<br />
post-instruction exception is generated immediately. A format $0 (for the pre-instruction<br />
exception caused by unnormalized or denormalized operands), format $3 (for the postinstruction<br />
exception caused by unnormalized or denormalized operands), or format $2<br />
(caused by packed decimal real) stack frame is saved, and vector number 55 is fetched.<br />
Note that a denormalized value generated as the result of a floating-point operation generates<br />
a nonmaskable underflow exception instead of an unsupported data type exception.<br />
Figure 6-10 lists the floating-point state frame fields for unsupported data type exceptions.<br />
The <strong>M68060</strong>SP uses the FPIAR to determine the instruction that caused the exception. The<br />
effective address field of the stack frame format $2 points to the offending source operand<br />
in memory (if any). The effective address field of the stack frame format $3 points to the destination<br />
operand in memory (if any). The <strong>M68060</strong>SP provides the routines needed to complete<br />
the instruction and stores the result to the proper destination, whether it be in a floatingpoint<br />
data register, integer data register, or external memory. Once the destination is written,<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-21
Floating-Point Unit<br />
the floating-point state frame is discarded, and normal execution is resumed by using the<br />
RTE instruction.<br />
The <strong>M68060</strong>SP not only emulates the instruction, but in addition, it ensures that if any floating-point<br />
arithmetic exceptional conditions arise from the instruction emulation with the<br />
unsupported data type instruction and if the corresponding floating-point arithmetic exception<br />
is enabled, the <strong>M68060</strong>SP restores the floating-point state frame back into the FPU in<br />
the desired exceptional state. This effectively imitates the action of the MC68060-implemented<br />
instructions.<br />
6.5.3 Unimplemented Effective Address Exception<br />
The unimplemented effective address exception corresponds to vector number 60, and<br />
occurs when the processor attempts to execute a floating-point instruction that contains an<br />
extended-precision or packed BCD immediate operand, or when the processor attempts to<br />
execute an FMOVEM.L instruction with an immediate addressing mode to more than one<br />
floating-point control register (FPCR, FPSR, FPIAR), or when the processor attempts an<br />
FMOVEM.X instruction using a dynamic register list. The stack frame of type $0 is generated<br />
when this exception is reported. The stacked PC points to the logical address of the instruction<br />
that caused the exception.<br />
The <strong>M68060</strong>SP uses the stacked PC to point to the instruction that needs to be emulated.<br />
The <strong>M68060</strong>SP emulates the instruction, increments the stacked PC and returns to the normal<br />
program flow.<br />
The <strong>M68060</strong>SP not only emulates the instruction, but in addition, it ensures that if any floating-point<br />
arithmetic exceptional conditions arise from the instruction emulation including the<br />
unimplemented effective address and if the corresponding floating-point arithmetic exception<br />
is enabled, the <strong>M68060</strong>SP restores the floating-point state frame back into the FPU in<br />
the desired exceptional state. This effectively imitates the action of the MC68060 implemented<br />
instructions.<br />
6.6 FLOATING-POINT ARITHMETIC EXCEPTIONS<br />
The MC68060, with the aid of the <strong>M68060</strong>SP, provides the full MC68881 instruction set,<br />
effective address, data type, and exception handling compatibility. From the perspective of<br />
the user-supplied exception handlers, the information provided by the MC68060 or the<br />
MC68060/<strong>M68060</strong>SP combination are consistent in that no distinction needs to be made by<br />
the user handler between native MC68060 instructions and non-native instructions or data<br />
types. This section discusses the operation of the MC68060, with the aid of the <strong>M68060</strong>SP,<br />
and how information is perceived and used by the user-supplied exception handler. It is<br />
assumed in this section that the <strong>M68060</strong>SP is already ported properly to the MC68060 system.<br />
6-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
The following eight user floating-point arithmetic exceptions are listed in order of priority.<br />
• Branch/Set on Unordered (BSUN)<br />
• Signaling Not-A-Number (SNAN)<br />
• Operand Error (OPERR)<br />
• Overflow (OVFL)<br />
• Underflow (UNFL)<br />
• Divide-by-Zero (DZ)<br />
• Inexact 2 (INEX2)<br />
• Inexact 1 (INEX1)<br />
INEX1 exception is the condition that exists when a packed decimal operand cannot be converted<br />
exactly to the extended-precision format in the current rounding mode. Since the<br />
MC68060 does not directly support packed decimal real operands, the processor never sets<br />
INEX1 bit in the FPSR EXC byte, but provides it as a latch so that the <strong>M68060</strong>SP (emulation<br />
software) can report the exception.<br />
The processor takes a floating-point arithmetic exception in one of two situations. The first<br />
situation occurs when the user program enables an arithmetic exception by setting a bit in<br />
the FPCR ENABLE byte and the corresponding bit in the FPSR EXC byte matches the bit<br />
in the FPCR ENABLE byte as a result of program execution. This is referred to as a<br />
maskable exception condition since it is possible to prevent an exception from occurring. All<br />
exceptions except the OVFL and UNFL are maskable. For the SNAN, OPERR, DZ, and<br />
INEX enabled exception cases, some assistance from the <strong>M68060</strong>SP is required to provide<br />
MC68881-compatible operation. Therefore, the <strong>M68060</strong>SP supervisor exception handler is<br />
executed before handing control over to the user-supplied exception handler.<br />
Note that a user write operation to the FPSR, which sets a bit in the EXC byte, does not<br />
cause an exception to be taken, regardless of the value in the ENABLE byte. When a user<br />
writes to the ENABLE byte that enables a class of floating-point exceptions, a previously<br />
generated floating-point exception does not cause an exception to be taken, regardless of<br />
the value in the FPSR EXC byte. The user can clear a bit in the FPCR ENABLE byte, disabling<br />
each corresponding exception.<br />
The second situation that will cause the processor to take a floating-point arithmetic exception<br />
occurs when the processor encounters an OVFL or UNFL condition. These exceptional<br />
conditions are non-maskable, requiring the <strong>M68060</strong>SP to correct a defaulting result generated<br />
by the MC68060 that is different from the result generated by an MC68881/MC68882<br />
executing the same code. After correcting the result, the <strong>M68060</strong>SP exception handler<br />
hands control over to a user-defined exception handler if the exception has been enabled in<br />
the FPCR ENABLE byte or returns to the main program flow if the exception is disabled.<br />
As outlined in 6.5.1 Unimplemented Floating-Point Instructions to 6.5.3 Unimplemented<br />
Effective Address Exception, there are certain conditions such that the<br />
<strong>M68060</strong>SP reports floating-point arithmetic exceptions as part of handling an unimplemented<br />
floating-point instruction, unimplemented effective address, or unsupported data<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-23
Floating-Point Unit<br />
type exception. The <strong>M68060</strong>SP passes control over to the user-supplied exception handler,<br />
if needed.<br />
A single instruction execution can generate multiple exceptions. When multiple exceptions<br />
occur with exceptions enabled for more than one exception class, the highest priority exception<br />
is reported; the lower priority exceptions are never reported or taken. The previous list<br />
of arithmetic floating-point exceptions is in order of priority. The bits of the ENABLE byte are<br />
organized in decreasing priority, with bit 15 being the highest and bit 8 the lowest. The exception<br />
handler must check for multiple exceptions. The address of the exception handler is<br />
derived from the vector number corresponding to the exception. The following is a list of multiple<br />
instruction exceptions that can occur:<br />
• SNAN and INEX1<br />
• OPERR and INEX2<br />
• OPERR and INEX1<br />
• OVFL and INEX2 and/or INEX1<br />
• UNFL and INEX2 and/or INEX1<br />
• INEX2 and INEX1<br />
6.6.1 Branch/Set on Unordered (BSUN)<br />
The BSUN exception is the result of performing an IEEE nonaware conditional test associated<br />
with the FBcc, FDBcc, FTRAPcc, and FScc instructions when an unordered condition<br />
is present. Refer to 6.4.2 Conditional Testing for information on conditional tests.<br />
If a floating-point exception is pending from a previous floating-point instruction, a preinstruction<br />
exception is taken to handle that exception. After the appropriate exception handler<br />
is executed, the conditional instruction is restarted. When the previous floating-point<br />
instruction has completed including related exception handling, the conditional predicate is<br />
evaluated and checked for a BSUN exception before executing the conditional instruction.<br />
A BSUN exception is generated in hardware through the FBcc instruction only. All other<br />
BSUN-generating instructions (FDBcc, FTRAPcc, and FScc) are emulated via the<br />
<strong>M68060</strong>SP. No <strong>M68060</strong>SP BSUN handler is provided since the processor already provides<br />
MC68881-compatible operation when reporting a BSUN exception.<br />
A BSUN exception occurs if the conditional predicate is one of the IEEE nonaware branches<br />
and the FPCC NAN bit is set. When this condition is detected, the BSUN bit in the FPSR<br />
EXC byte is set.<br />
6.6.1.1 TRAP DISABLED RESULTS (FPCR BSUN BIT CLEARED). The floating-point<br />
condition is evaluated as if it were the equivalent IEEE aware conditional predicate. No<br />
exceptions are taken.<br />
6.6.1.2 TRAP ENABLED RESULTS (FPCR BSUN BIT SET). The processor takes a floating-point<br />
pre-instruction exception. A $0 stack frame is saved, and vector number 48 is generated<br />
to access the BSUN exception vector. The BSUN entry in the processor’s vector<br />
table points to the user BSUN exception handler.<br />
6-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
The user BSUN exception handler must execute an FSAVE as its first floating-point instruction.<br />
FSAVE allows other floating-point instructions to execute without reporting the BSUN<br />
exception again, although none of the state frame values are useful in the execution of the<br />
user BSUN exception handler. The BSUN exception is unique in that the exception is taken<br />
before the conditional predicate is evaluated. If the user BSUN exception handler does not<br />
set the PC to the instruction following the one that caused BSUN exception when returning,<br />
the exception is executed again. Therefore, it is the responsibility of the user BSUN exception<br />
handler to prevent the conditional instruction from taking the BSUN exception again.<br />
There are four ways to prevent taking the exception again:<br />
1. Incrementing the stored PC in the stack bypasses the conditional instruction. This<br />
technique applies to situations where a fall-through is desired. Note that accurate calculation<br />
of the PC increment requires detailed knowledge of the size of the conditional<br />
instruction being bypassed.<br />
2. Clearing the NAN bit prevents the exception from being taken again. However, this<br />
alone cannot deterministically control the result’s indication (true or false) that would<br />
be returned when the conditional instruction re-executes.<br />
3. Disabling the BSUN bit also prevents the exception from being taken again. Like the<br />
second method, this method cannot control the result indication (true or false) that<br />
would be returned when the conditional instruction re-executes.<br />
4. Examining the conditional predicate and setting the FPCC NAN bit accordingly prevents<br />
the exception from being taken again. This technique gives the most control<br />
since it is possible to predetermine the direction of program flow. Bit 7 of the F-line operation<br />
word indicates where the conditional predicate is located. If bit 7 is set, the conditional<br />
predicate is the lower six bits of the F-line operation word. Otherwise, the<br />
conditional predicate is the lower six bits of the instruction word, which immediately follows<br />
the F-line operation word. Using the conditional predicate and the table for IEEE<br />
nonaware test in 6.4.2 Conditional Testing, the condition codes can be set to return<br />
a known result indication when the conditional instruction is re-executed.<br />
Prior to exiting the user BSUN exception handler, the user exception handler discards the<br />
floating-point state frame before executing the RTE to return to normal program flow.<br />
6.6.2 Signaling Not-a-Number (SNAN)<br />
An SNAN is used as an escape mechanism for a user-defined, non-IEEE data type. The processor<br />
never creates an SNAN as a result of an operation; a NAN created by an operand<br />
error exception is always a nonsignaling NAN. When an operand is an SNAN involved in an<br />
arithmetic instruction, the SNAN bit is set in the FPSR EXC byte. Since the FMOVEM,<br />
FMOVE FPCR, and FSAVE instructions do not modify the status bits, they cannot generate<br />
exceptions. Therefore, these instructions are useful for manipulating SNANs.<br />
6.6.2.1 TRAP DISABLED RESULTS (FPCR SNAN BIT CLEARED). If the destination<br />
data format is S, D, X, or P, then the most significant bit of the fraction is set to one and the<br />
resulting nonsignaling NAN is transferred to the destination. No bits other than the SNAN bit<br />
of the NAN are modified, although the input NAN is truncated if necessary. If the destination<br />
data format is B, W, or L, then the 8, 16, or 32 most significant bits of the SNAN significand,<br />
with the SNAN bit set, are written to the destination.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-25
Floating-Point Unit<br />
6.6.2.2 TRAP ENABLED RESULTS (FPCR SNAN BIT SET). If the destination is not a<br />
floating-point data register (FMOVE OUT instruction), the destination (memory or integer<br />
data register) is written with the same data as though the trap were disabled (FPCR SNAN<br />
bit clear), and then control is passed to the user SNAN handler as a post-instruction exception.<br />
If desired, the user SNAN handler can overwrite the result.<br />
For floating-point data register destinations, the source (if register-to-register instruction)<br />
and destination floating-point data registers are not modified. Control is passed to the user<br />
SNAN handler as a pre-instruction exception when the next floating-point instruction is<br />
encountered. In this case, the SNAN user handler should supply the result.<br />
The SNAN user handler must execute an FSAVE instruction as the first floating-point<br />
instruction to prevent the FPU from taking more exceptions. The FSAVE frame generates a<br />
floating-point frame that contains the source operand that has been converted to extended<br />
precision. If the destination is a floating-point data register, it contains the original value. The<br />
FPIAR points to the floating-point instruction that caused the exception. In addition, if the<br />
offending instruction is FMOVE OUT, an integer stack frame format $3 is created as a result<br />
of a post-instruction exception, the effective address of the destination memory operand is<br />
provided. The effective address field is undefined if the destination is an integer data register.<br />
The user SNAN exception handler may discard the floating-point state frame once the handler<br />
has completed. The RTE instruction must be executed to return to normal instruction<br />
flow.<br />
6.6.3 Operand Error<br />
The operand error exception encompasses problems arising in a variety of operations,<br />
including those errors not frequent or important enough to merit a specific exceptional condition.<br />
Basically, an operand error occurs when an operation has no mathematical interpretation<br />
for the given operands. Table 6-12 lists the possible operand errors, both native and<br />
non-native to the MC68060, which the <strong>M68060</strong>SP unimplemented instruction exception<br />
handler can report. When an operand error occurs, the OPERR bit is set in the FPSR EXC<br />
byte.<br />
6-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Table 6-12. Possible Operand Errors Exceptions<br />
Floating-Point Unit<br />
Instruction Condition Causing Operand Error<br />
Native to MC68060<br />
FADD [(+∞) + (–∞)] or [(–∞) + (+∞)]<br />
FDIV (0 ÷ 0) or (∞ ÷ ∞)<br />
FMOVE to B,W,or L Integer overflow, source is nonsignaling NAN or ±∞<br />
FMUL One operand is 0 and other is +∞<br />
FSQRT (Source < 0) or (−∞)<br />
FSUB [(+∞) – (+∞)] or [(–∞) – (–∞)]<br />
Non-Native to MC68060<br />
FACOS Source is ±∞, > +1, or < –1<br />
FASIN Source is ±∞, > +1, or < –1<br />
FATANH Source is ±∞, > +1, or < –1<br />
FCOS Source is ±∞<br />
FGETEXP Source is ±∞<br />
FGETMAN Source is ±∞<br />
FLOG10 Source is < 0 or −∞<br />
FLOG2 Source is < 0 or −∞<br />
FLOGN Source is < 0 or −∞<br />
FLOGNP1 Source is ≤ 1 or −∞<br />
FMOD Floating-point data register is ±∞ or source is 0, other operand is not a NAN<br />
FMOVE to P Source exponent > 999 (decimal) or k-factor > 17<br />
FREM Floating-point data register is ±∞ or source is 0, other operand is not a NAN<br />
FSCALE Source is ±∞, other operand not a NAN<br />
FSGLDIV (0 ÷ 0) or(∞ ÷ ∞)<br />
FSGLMUL One operand is 0, other operand is ∞<br />
FSIN Source is ±∞<br />
FSINCOS Source is ±∞<br />
FTAN Source is ±∞<br />
6.6.3.1 TRAP DISABLED RESULTS (FPCR OPERR BIT CLEARED). For an FMOVE<br />
OUT instruction with the format S, D, or X, an OPERR is impossible. For an FMOVE OUT<br />
instruction with the format B, W, or L, an OPERR is possible only on an integer overflow, if<br />
the source is an infinity, or if the source is a NAN. On the integer overflow and infinity source<br />
cases, the largest positive or negative integer that can fit in the specified destination size (B,<br />
W, or L) is stored. On the NAN source case, the 8, 16, or 32 most significant bits of the NAN<br />
significand is stored in the B, W, or L destination.<br />
For FMOVE OUT with the format P (packed decimal), if the k-factor is greater than +17, the<br />
result returned is a packed decimal string that assumes a k-factor equal to +17. For packed<br />
decimal results where the absolute value of the exponent is greater than 999, the decimal<br />
string is returned with the three least significant exponent digits in EXP2, EXP1, and EXP0.<br />
The fourth digit, EXP3, is supplied in the most significant four bits of the third byte in the<br />
string.<br />
For all other OPERR cases, the destination is a floating-point data register. An extendedprecision<br />
non-signaling NAN is stored in the destination.<br />
6.6.3.2 TRAP ENABLED RESULTS (FPCR OPERR BIT SET). For the FMOVE OUT<br />
cases, the destination is written as if the trap were disabled, and then control is passed to<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-27
Floating-Point Unit<br />
the user OPERR handler, as a post-instruction exception. If desired, the user OPERR handler<br />
can overwrite the default result.<br />
If the destination is a floating-point data register, the register is not modified. Control is<br />
passed to the user OPERR handler as a pre-instruction exception when the next floatingpoint<br />
instruction is encountered. In this case, the user OPERR handler should generate the<br />
appropriate result.<br />
The OPERR user handler must execute an FSAVE instruction as the first floating-point<br />
instruction to prevent the FPU from taking more exceptions. The FSAVE frame generates a<br />
floating-point frame that contains the source operand that has been converted to extended<br />
precision. If the destination is a floating-point data register, the register contains the original,<br />
unmodified value. The FPIAR points to the floating-point instruction that caused the exception.<br />
In addition, if the offending instruction is an FMOVE OUT, an integer stack frame format<br />
$3 is created as a result of a post-instruction exception, the effective address of the destination<br />
memory operand is provided. The effective address field is undefined if the destination<br />
is an integer data register.<br />
The user OPERR exception handler may discard the floating-point state frame once the<br />
handler has completed. The RTE instruction must be executed to return to normal instruction<br />
flow.<br />
6.6.4 Overflow<br />
An overflow exception is detected for arithmetic operations in which the destination is a floating-point<br />
data register or memory when the intermediate result’s exponent is greater than or<br />
equal to the maximum exponent value of the selected rounding precision. Overflow can only<br />
occur when the destination is in the S-, D-, or X-precision format; all other data format overflows<br />
are handled as operand errors. At the end of any operation that could potentially overflow,<br />
the intermediate result is checked for underflow, rounded, and then checked for<br />
overflow before it is stored to the destination. If overflow occurs, the OVFL bit is set in the<br />
FPSR EXC byte.<br />
Even if the intermediate result is small enough to be represented as an extended-precision<br />
number, an overflow can occur. The intermediate result is rounded to the selected precision,<br />
and the rounded result is stored in the extended-precision format. If the magnitude of the<br />
intermediate result exceeds the range of the selected rounding precision format, an overflow<br />
occurs.<br />
The MC68060 is implemented such that when the OVFL bit is set in the FPSR EXC byte as<br />
a result of a floating-point instruction, the processor always takes a nonmaskable overflow<br />
exception. If the destination is a floating-point data register, then the register is not affected,<br />
and a pre-instruction exception is reported. If the destination is a memory or integer data<br />
register, an undefined result is stored, and a post-instruction exception is taken immediately.<br />
Execution begins at the <strong>M68060</strong>SP OVFL exception handler to provide MC68881-compatible<br />
operation. The <strong>M68060</strong>SP then determines whether or not control is passed back to normal<br />
instruction flow (the OVFL bit in the FPCR exception enable byte is cleared), to the user<br />
OVFL handler (the OVFL bit in the FPCR exception enable byte is set), or to the user INEX<br />
handler (the OVFL bit in the FPCR exception enable byte is cleared, but the INEX bit in the<br />
6-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
FPCR exception enable byte is set and the corresponding INEX bit in the FPSR EXC byte<br />
is also set).<br />
6.6.4.1 TRAP DISABLED RESULTS (FPCR OVFL BIT CLEARED). The values defined<br />
in Table 6-13 are stored in the destination based on the rounding mode defined in the FPCR<br />
MODE byte. The result is rounded according to the rounding precision defined in the FPCR<br />
MODE byte if the destination is a floating-point data register. If the destination is in memory<br />
or an integer data register, then the rounding precision in the FPCR MODE byte is ignored,<br />
and the given destination format defines the rounding precision. If the instruction has a<br />
forced rounding precision (e.g., FSADD, FDMUL), the instruction defines the rounding precision.<br />
Table 6-13. Overflow Rounding Mode Values<br />
Rounding Mode Result<br />
RN Infinity, with the sign of the intermediate result.<br />
RZ Largest magnitude number, with the sign of the intermediate result.<br />
RM For positive overflow, largest positive number; for negative overflow, – infinity.<br />
RP For positive overflow, + infinity; for negative overflow, largest negative number.<br />
6.6.4.2 TRAP ENABLED RESULTS (FPCR OVFL BIT SET). The result stored in the destination<br />
is the same as the result stored when the trap is disabled before control is passed<br />
to the user OVFL handler. For an FMOVE OUT instruction, the operand is stored in memory<br />
or integer data register, and then control is passed to the user OVFL handler as a postinstruction<br />
exception. If the destination is a floating-point data register, control is passed to<br />
the user OVFL handler as a pre-instruction exception when the next floating-point operation<br />
is encountered.<br />
The user OVFL handler must execute an FSAVE instruction as the first floating-point instruction<br />
to prevent further exceptions from being taken. The address of the instruction that<br />
causes the overflow is available to the user OVFL handler in the FPIAR. By examining the<br />
instruction, the user OVFL handler can determine the arithmetic operation type and destination<br />
location. The exception operand is stored in the floating-point state frame (generated by<br />
the FSAVE). When an overflow occurs, the exception operand is defined differently for various<br />
destination types:<br />
1. FMOVE OUT instruction (memory or integer data register destination)—the value in<br />
the exception operand is the intermediate result mantissa rounded to the destination<br />
precision, with a 15-bit exponent biased as a normal extended-precision number. In<br />
the case of a memory destination, the evaluated effective address of the operand is<br />
available in the integer stack frame format $3. This allows the user OVFL handler to<br />
overwrite the default result, if necessary, without recalculating the effective address.<br />
2. Floating-point data register destination—the value in the exception operand is the intermediate<br />
result rounded to extended precision, with an exponent bias of $3FFF–<br />
$6000 rather than $3FFF. The additional bias of –$6000 is used so that it is possible<br />
to represent the larger exponent in a 15-bit format.<br />
In addition to normal overflow, the exponential instructions (e x , 10x , 2x , SINH, COSH, and<br />
FSCALE) may generate results that grossly overflow the 16-bit exponent of the internal<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-29
Floating-Point Unit<br />
intermediate result format. When such an overflow occurs (called a catastrophic overflow),<br />
the exception operand exponent value is set to $0000. This value is easily distinguished<br />
from the exception operand exponent values produced by normal overflow processing.<br />
If an INEX2 or INEX1 exceptional condition exists and the INEX exception is enabled, it is<br />
the responsibility of the user OVFL handler to handle the lower priority inexact exception.<br />
The user OVFL exception handler may discard the floating-point state frame once the handler<br />
has completed. The RTE instruction must be executed to return to normal instruction<br />
flow.<br />
6.6.5 Underflow<br />
An underflow exception occurs when the intermediate result of an arithmetic operation is too<br />
small to be represented as a normalized number in a floating-point data register or memory<br />
using the selected rounding precision. An arithmetic operation is too small when the intermediate<br />
result exponent is less than or equal to the minimum exponent value of the selected<br />
rounding precision. Underflow is not detected for intermediate result exponents that are<br />
equal to the extended-precision minimum exponent since the explicit integer part bit permits<br />
representation of normalized numbers with a minimum extended-precision exponent.<br />
Underflow can only occur when the destination format is single, double, or extended precision.<br />
When the destination format is byte, word, or long word, the conversion underflows to<br />
zero without causing either an underflow or an operand error. At the end of any operation<br />
that could potentially underflow, the intermediate result is checked for underflow, rounded,<br />
and checked for overflow before it is stored at the destination. If an underflow occurs, the<br />
UNFL bit is set in the FPSR EXC byte.<br />
Even if the intermediate result is large enough to be represented as an extended-precision<br />
number, an underflow can occur. The intermediate result is rounded to the selected precision,<br />
and the rounded result is stored in extended-precision format. If the magnitude of the<br />
intermediate result is too small to be represented in the selected rounding precision, an<br />
underflow occurs.<br />
The IEEE 754 standard defines two causes of an underflow: 1) when the absolute value of<br />
the number is less than the minimum number that can be represented by a normalized number<br />
in a specific data format, or 2) when loss of accuracy occurs while attempting to calculate<br />
such a number (a loss of accuracy also causes an inexact exception). The IEEE 754 standard<br />
specifies that if the underflow exception is disabled, an underflow should only be signaled<br />
when both of these cases are satisfied (i.e., the result is too small to be represented<br />
with a given format and there is a loss of accuracy during calculation of the final result). If<br />
the exception is enabled, the underflow should be signaled any time a very small result is<br />
produced, regardless of whether accuracy is lost in calculating it.<br />
The processor UNFL bit in the FPSR AEXC byte implements the IEEE exception disabled<br />
definition since it is only set when a very small number is generated and accuracy has been<br />
lost when calculating that number. The UNFL bit in the FPSR EXC byte implements the<br />
IEEE exception enabled definition since it is set any time a tiny number is generated.<br />
The MC68060 is implemented such that when the UNFL bit of the FPCR is set, the processor<br />
always takes an exception regardless of whether or not the user UNFL exception han-<br />
6-30 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
dler is enabled. If the destination is a floating-point data register, the register is not affected,<br />
and a pre-instruction exception is reported. If the destination is a memory or integer data<br />
register, then an undefined result is stored, and a post-instruction exception is taken immediately.<br />
In addition, the processor incorrectly reports an underflow exception if the result of<br />
a floating-point multiply is a normalized number with an exponent of $0000. Exception processing<br />
begins with the <strong>M68060</strong>SP UNFL exception handler to provide MC68881-compatible<br />
operation. The <strong>M68060</strong>SP then determines whether or not control is passed back to<br />
normal instruction flow (the OVFL bit in the FPCR exception enable byte is cleared), to the<br />
user OVFL handler (the OVFL bit in the FPCR exception enable byte is set) or the user INEX<br />
handler (the OVFL bit in the FPCR exception enable byte is cleared, but the INEX bit in the<br />
FPCR exception enable byte is set and the corresponding INEX bit in the FPSR EXC byte<br />
is also set).<br />
6.6.5.1 TRAP DISABLED RESULTS (FPCR UNFL BIT CLEARED). The result that is<br />
stored in the destination is either a denormalized number or zero. Denormalization is accomplished<br />
by shifting the mantissa of the intermediate result to the right while incrementing the<br />
exponent until it is equal to the denormalized exponent value for the destination format. The<br />
denormalized intermediate result is rounded to the selected rounding precision or destination<br />
format.<br />
If, in the process of denormalizing the intermediate result, all of the significant bits are shifted<br />
off to the right, the selected rounding mode determines the value to be stored at the destination,<br />
as shown in Table 6-14.<br />
Table 6-14. Underflow Rounding Mode Values<br />
Rounding Mode Result<br />
RN Zero, with the sign of the intermediate result.<br />
RZ Zero, with the sign of the intermediate result.<br />
RM<br />
For positive overflow, + zero; for negative underflow, smallest denormalized negative<br />
number.<br />
RP<br />
For positive overflow, smallest denormalized positive number; for negative underflow,<br />
–zero.<br />
6.6.5.2 TRAP ENABLED RESULTS (FPCR UNFL BIT SET). The result stored in the destination<br />
is the same as the result stored when traps are disabled. For an FMOVE OUT, the<br />
operand is stored in the destination memory or integer data register before control is passed<br />
to the user UNFL handler as a post-instruction exception. Otherwise, if the destination is a<br />
floating-point data register, control is passed to the user UNFL handler as a pre-instruction<br />
exception when the next floating-point instruction is encountered.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-31
Floating-Point Unit<br />
The user UNFL handler must execute an FSAVE instruction as the first floating-point instruction<br />
to prevent further exceptions from reporting. The address of the instruction that causes<br />
the overflow is available to the user UNFL handler in the FPIAR. By examining the instruction,<br />
the user UNFL handler can determine the arithmetic operation type and destination<br />
location. The exception operand is stored in the floating-point state frame (generated by the<br />
FSAVE). When an underflow occurs, the exception operand is defined differently for various<br />
destination types:<br />
1. FMOVE OUT (memory or integer data register destination)—the value in the exception<br />
operand is the intermediate result mantissa rounded to the destination precision,<br />
with a 15-bit exponent biased as a normal extended-precision number. In the case of<br />
a memory destination, the evaluated effective address of the operand is available in<br />
the stack frame format $3. This allows the user UNFL handler to overwrite the default<br />
result, if necessary, without recalculating the effective address.<br />
2. Floating-point data register destination—the value in the exception operand is the intermediate<br />
result mantissa rounded to extended precision, with an exponent bias of<br />
$3FFF + $6000 rather than $3FFF. The additional bias of +$6000 is used so that it is<br />
possible to represent the smaller exponent in a 15-bit format.<br />
In addition to normal underflow, the exponential instructions (e x , 10 x , 2 x , SINH, COSH, and<br />
FSCALE) may generate results that grossly underflow the 16-bit exponent of the internal intermediate<br />
format. When such an underflow occurs (called a catastrophic underflow), the<br />
exception operand exponent value is set to $0000. This value is easily distinguished from<br />
the exception operand exponent values produced by normal underflow processing.<br />
If an INEX2 or INEX1 exceptional condition exists and the user INEX exception is enabled,<br />
it is the responsibility of the user UNFL exception handler to handle this lower priority inexact<br />
exception. The user UNFL exception handler may discard the floating-point state frame<br />
once the handler has completed. The RTE instruction must be executed to return to normal<br />
instruction flow.<br />
6.6.6 Divide-by-Zero<br />
This exception happens when a zero divisor occurs for a divide instruction or when a transcendental<br />
function is asymptotic with infinity as the asymptote. Table 6-15 lists the instructions<br />
that can cause the divide-by-zero exception. Note that only the FDIV and FSGLDIV<br />
instructions are native to the MC68060. The other conditions occur only if the <strong>M68060</strong>SP is<br />
used. When a divide-by-zero is detected, the DZ bit is set in the FPSR EXC byte. The divideby-zero<br />
exception only has maskable exceptional conditions. An exception is taken only if<br />
the DZ bit is set in FPSR EXC byte and the corresponding bit in the FPCR exception enable<br />
byte is set.<br />
6-32 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
6.6.6.1 TRAP DISABLED RESULTS (FPCR DZ BIT CLEARED). The destination floatingpoint<br />
data register is written with a result that is dependent on the instruction that caused the<br />
DZ exception.<br />
1. For the FDIV and FSGLDIV instructions, an infinity with the sign set to the exclusive<br />
OR of the signs of the input operands is stored in the destination.<br />
2. For the FLOGx instructions, a –∞ is stored in the destination.<br />
3. For the FATANH instruction, a +∞ is stored in the destination if the source operand is<br />
a –1, otherwise, a –∞ is stored in the destination if the source operand is +1.<br />
6.6.6.2 TRAP ENABLED RESULTS (FPCR DZ BIT SET). The destination floating-point<br />
data register is not modified. Control is passed to the user DZ handler as a pre-instruction<br />
exception when the next floating-point instruction is encountered. The user DZ handler must<br />
generate a result to store in the destination.<br />
The user DZ handler must execute an FSAVE instruction as the first floating-point instruction<br />
to prevent further exceptions from reporting. The address of the instruction that causes the<br />
overflow is available to the user DZ handler in the FPIAR. By examining the instruction, the<br />
user DZ handler can determine the arithmetic operation type and destination location. The<br />
exception operand is stored in the floating-point state frame (generated by the FSAVE). The<br />
exception operand contains the source operand converted to the extended-precision format.<br />
When the user DZ exception handler has completed, the floating-point frame may be discarded.<br />
The RTE instruction must be executed to return to normal instruction flow.<br />
6.6.7 Inexact Result<br />
Table 6-15. Possible Divide-by-Zero Exceptions<br />
Instruction Operand Value<br />
FDIV Source operand = 0 and floating-point data register is not a NAN, ∞, or zero<br />
FLOG10 Source operand = 0<br />
FLOG2 Source operand = 0<br />
FLOGN Source operand = 0<br />
FTAN Source operand is an odd multiple of ±π ÷ 2<br />
FSGLDIV Source operand = 0 and floating-point data register is not a NAN, ∞, or zero<br />
FATANH Source operand = ±1<br />
FLOGNP1 Source operand = –1<br />
The processor provides two inexact bits in the FPSR EXC byte to help distinguish between<br />
inexact results generated by emulated decimal input (INEX1 exceptions) and other inexact<br />
results (INEX2 exceptions). These two bits are useful in instructions where both types of<br />
inexact results can occur (e.g., FDIV.P #7E-1,FP3). In this case, the packed decimal to<br />
extended-precision conversion of the immediate source operand causes an inexact error to<br />
occur that is signaled as INEX1 exception. Furthermore, the subsequent divide could also<br />
produce an inexact result and cause INEX2 to be set in the FPCR EXC byte. Note that only<br />
one inexact exception vector number is generated by the processor. If either of the two inexact<br />
exceptions is enabled, the processor fetches the inexact exception vector, and the user<br />
INEX exception handler is initiated. INEX refers to both exceptions in the following paragraphs.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-33
Floating-Point Unit<br />
The INEX2 exception is the condition that exists when any operation, except the input of a<br />
packed decimal number, creates a floating-point intermediate result whose infinitely precise<br />
mantissa has too many significant bits to be represented exactly in the selected rounding<br />
precision or in the destination data format. If this condition occurs, the INEX2 bit is set in the<br />
FPSR EXC byte, and the infinitely precise result is rounded. Table 6-16 lists these rounding<br />
mode values.<br />
Table 6-16. Rounding Mode Values<br />
Rounding Mode Result<br />
The representable value nearest to the infinitely precise intermediate value is the<br />
RN<br />
result. If the two nearest representable values are equally near (a tie), then the one<br />
with the least significant bit equal to zero (even) is the result. This is sometimes<br />
referred to as “round to nearest, even.”<br />
The result is the value closest to and no greater in magnitude than the infinitely<br />
RZ precise intermediate result. This is sometimes referred to as the “chop mode,”<br />
since the effect is to clear the bits to the right of the rounding point.<br />
RM<br />
The result is the value closest to and no greater than the infinitely precise intermediate<br />
result (possibly minus infinity).<br />
RP<br />
The result is the value closest to and no less than the infinitely precise intermediate<br />
result (possibly plus infinity).<br />
The INEX1 and INEX2 exceptions are always maskable. Therefore, any INEX exception<br />
goes directly to the user INEX exception handler. When an INEX2 or INEX1 bit in the FPSR<br />
EXC byte is set, the rounded result (listed in Table 6-16), is written to the destination. The<br />
FPCR MODE bits determine the rounding mode. The PREC bits in the FPCR determine the<br />
rounding precision if the destination is a floating-point data register; otherwise, if the destination<br />
is memory or an integer data register, the destination format determines the rounding<br />
precision. If one of the instructions has a forced precision, the instruction determines the<br />
rounding precision. If the INEX2 or INEX1 condition exists and if the corresponding INEX bit<br />
in the FPCR exception enable byte is set, then the user INEX exception handler is taken.<br />
6.6.7.1 TRAP DISABLED RESULTS (FPCR INEX1 BIT AND INEX2 BIT CLEARED. The<br />
result is rounded and then written to the destination.<br />
6.6.7.2 TRAP ENABLED RESULTS (EITHER FPCR INEX1 BIT OR INEX2 BIT SET).<br />
The result is rounded and then written to the destination as in the trap disabled case. For an<br />
FMOVE OUT instruction, control is passed to the user INEX handler as a post-instruction<br />
exception. Otherwise, for other floating-point instructions that have floating-point data register<br />
destinations, control is passed to the user INEX handler as a pre-instruction exception<br />
when the next floating-point instruction is encountered.<br />
The user INEX exception handler must execute an FSAVE as its first floating-point instruction.<br />
At this point, the destination contains the rounding mode values as listed in Table 6-16,<br />
and the user INEX exception handler can choose to modify these values. If the inexact conversion<br />
is the only exception that occurs during the execution of an instruction, the value of<br />
the exception operand is invalid. If multiple exceptions occur during an instruction, the<br />
exception operand value is related to a higher priority exception. The FPIAR points to the<br />
instruction that caused the exception. If the instruction is an FMOVE OUT, the integer stack<br />
frame format $3 contains the effective address of the destination memory operand. If the<br />
destination is an integer data register, the effective address field is undefined.<br />
6-34 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Floating-Point Unit<br />
When the user INEX exception handler has completed, the floating-point frame may be discarded.<br />
The RTE instruction must be executed to return to normal instruction flow.<br />
NOTE<br />
The IEEE 754 standard specifies that inexactness should be signaled<br />
on overflow as well as for rounding. The processor implements<br />
this via the INEX bit in the FPSR AEXC byte. However,<br />
the standard also indicates that the inexact exception should be<br />
taken if an overflow occurs with the OVFL bit disabled and the<br />
INEX bit enabled in the FPSR AEXC byte. Therefore, the processor<br />
takes the inexact exception if this combination of conditions<br />
occurs, even though the INEX1 or INEX2 bit may not be set<br />
in the FPSR EXC byte. In this case, the INEX bit is set in the<br />
FPSR AEXC byte, and the OVFL bit is set in both the FPSR EXC<br />
and AEXC bytes.<br />
6.7 FLOATING-POINT STATE FRAMES<br />
All floating-point arithmetic exception handlers must have FSAVE as the first floating-point<br />
instruction; any other floating-point instruction causes another exception to be reported.<br />
Once the FSAVE instruction has executed, the exception handler should use only the<br />
FMOVEM instruction to read or write to the floating-point data registers since FMOVEM cannot<br />
generate further exceptions or change the FPCR.<br />
An FSAVE instruction is executed to save the current floating-point internal state for context<br />
switches and floating-point exception handling. When an FSAVE is executed, the processor<br />
waits until the FPU either completes the instruction or is unable to perform further processing<br />
due to a pending exception that must be serviced.<br />
FSAVE operations always write a floating-point state frame containing three long words.<br />
The exception operand, is part of the EXCP frame. This exception operand retains its value<br />
when FRESTOREd as an EXCP frame into the processor and then FSAVEd at a later time.<br />
The FSAVE frame contents are shown in Figure 6-10 and the status word contents are<br />
shown in Figure 6-11.<br />
31 16 15<br />
0<br />
EXCP Operand Exponent Status Word<br />
EXCP Operand Upper 32 bits<br />
EXCP Operand Lower 32 bits<br />
Figure 6-10. Floating-Point State Frame<br />
Bits 15–8 of the first long word of the floating-point frame define the frame format. The legal<br />
formats for the MC68060 are:<br />
$00 Null Frame (NULL)<br />
$60 Idle Frame (IDLE)<br />
$E0 Exception Frame (EXCP)<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-35
Floating-Point Unit<br />
15<br />
Frame Format<br />
$00—Null Frame<br />
$60—Idle Frame<br />
$E0—Exception Frame<br />
V2–V0—Exception Vector<br />
000—BSUN<br />
001—INEX2 | INEX1<br />
010—DZ<br />
011—UNFL<br />
100—OPERR<br />
101—OVFL<br />
110—SNAN<br />
111—UNSUP<br />
FRAME FORMAT<br />
0 0 0 0 0<br />
Figure 6-11. Status Word Contents<br />
FSAVE on the MC68060 only generates one size frame (three long words), which creates a<br />
significant performance benefit, and one of these three frame types. An attempt to<br />
FRESTORE a frame format other than $00, $60, or $E0 results in a format error exception.<br />
The format of the first long word of the MC68060 floating-point frame has changed from<br />
that of previous M68000 microprocessors. The MC68060 frame format (bits 15–8) is a<br />
consolidation of the version number and size format information (bits 31–16) on previous<br />
parts. In addition, on the MC68060, this information resides in the lower word of the long<br />
word while the upper word is used for the exception operand exponent in EXCP frames.<br />
Therefore, FRESTORE of a frame on an MC68060 created by FSAVE on a non-MC68060<br />
microprocessor and FRESTORE of a frame on a non-MC68060 microprocessor created by<br />
FSAVE on an MC68060 will not guarantee a format error exception will be detected and<br />
thus must never be attempted.<br />
When an FSAVE is executed, the floating-point frame reflects the state of the FPU at the<br />
time of the FSAVE. Internally, the FPU can be in the NULL, IDLE or EXCP states. Upon<br />
reset, the FPU is in the NULL state. In the NULL state, all floating-point registers contain<br />
nonsignaling NANs and the FPCR, FPSR, and FPIAR contain zeroes. The FPU remains in<br />
this state until the execution of an implemented floating-point instruction (except FSAVE).<br />
At this point, the FPU transitions from a NULL state to an IDLE state. An FRESTORE of<br />
NULL returns the FPU to the NULL state. The EXCP state is entered as a result of either a<br />
floating-point exception or an unsupported data type exception. V2–V0 indicates the<br />
exception types that are associated with the EXCP state.<br />
An FSAVE instruction always clears the internal exception status bit at the completion of<br />
the FSAVE. An FRESTORE of EXCP may be used to place the FPU in the exception state.<br />
The FRESTORE of an EXCP state is used in the <strong>M68060</strong>SP to provide to the user<br />
exception handler the illusion that the <strong>M68060</strong>SP handler never existed at all. The user<br />
exception handler is entered with the FPU in the proper exception state. The user<br />
6-36 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
8<br />
7 3<br />
2<br />
1<br />
0<br />
V2 V1 V0
Floating-Point Unit<br />
exception handler then executes an FSAVE instruction to clear the internal exception<br />
status bit in the FPU. To return to normal operation, the user exception handler may either<br />
clear the most significant bit of the frame format (changing the frame format from $E0 to<br />
$60, creating an IDLE frame) prior to FRESTOREing the IDLE state frame, or discarding<br />
the floating-point frame before executing the RTE. Given that the state frames are of a<br />
fixed size (three long words), it is quicker to simply discard the state frame.<br />
The exception operand provided in the floating-point frame is dependent on the highest priority<br />
exception that is reported. The exception operand as generated by the processor when<br />
the exception is first reported may be undefined. The <strong>M68060</strong>SP calculates the proper<br />
exception operand and executes an FRESTORE of the EXCP frame with the proper exception<br />
operand value in the floating-point frame. When the user exception handler is entered,<br />
the required FSAVE inside the user exception handler generates the floating-point frame<br />
and retrieves the exception operand, as calculated by the <strong>M68060</strong>SP.<br />
The exception operand provided to the user exception handler is defined as follows for the<br />
possible exceptions:<br />
BSUN User Handler—Undefined.<br />
SNAN, OPERR, DZ—Source operand in extended-precision format.<br />
OVFL—Intermediate result in extended-precision format, but with exponent bias of $3FFF–<br />
$6000 instead of $3FFF. If catastrophic overflow, $0.<br />
UNFL—Intermediate result in extended-precision format but with exponent bias of<br />
$3FFF+$6000 instead of $3FFF. If catastrophic underflow, $0.<br />
INEX—Undefined if INEX only. Otherwise if either SNAN, OPERR, UNFL, or OVFL also set<br />
in FPSR, use exception operand defined for either SNAN, OPERR, UNFL, or OVFL.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 6-37
SECTION 7<br />
BUS OPERATION<br />
The MC68060 bus interface supports synchronous data transfers between the processor<br />
and other devices in the system. This section provides a functional description of the bus,<br />
the signals that control the bus, and the bus cycles provided for data transfer operations.<br />
Operation of the bus is defined for transfers initiated by the processor as a bus master and<br />
for transfers initiated by an alternate bus master which the processor snoops as a slave<br />
device. Descriptions of the error and halt conditions, bus arbitration, and the reset operation<br />
are also included. For timing specifications, refer to Section 12 Electrical and Thermal<br />
Characteristics.<br />
7.1 BUS CHARACTERISTICS<br />
The MC68060 uses the address bus (A31A0) to specify the address for a data transfer and<br />
the data bus (D31–D0) to transfer the data. Control and attribute signals indicate the beginning<br />
and type of a bus cycle as well as the address space and size of the transfer. The<br />
selected device then controls the length of the cycle by terminating it using the control signals.<br />
The MC68060 CLK is distributed internally to provide logic timing. CLKEN indicates important<br />
rising CLK edges for the bus interface controller but does not directly affect internal<br />
operation or timing of the MC68060. Its main purpose is to allow for easier system design.<br />
CLKEN makes possible full-, half-, and quarter-speed bus operation by providing a signal to<br />
qualify valid rising CLK edges. In general, on rising CLK edges in which CLKEN is asserted,<br />
inputs are sampled and outputs begin to change. However, there are some inputs that are<br />
sampled and outputs that transition on rising CLK edges when CLKEN is negated.<br />
Inputs to the MC68060 (other than the IPLx and RSTI signals) are synchronously sampled<br />
and must be stable during the sample window defined by tsu<br />
and thi<br />
(see Figure 7-1) to guarantee<br />
proper operation. The asynchronous IPLx and RSTI signals are sampled on the rising<br />
edge of CLK, but are internally synchronized to resolve the input to a valid level before being<br />
used. Since the timing specifications for the MC68060 are referenced to the rising edge of<br />
CLK, they are valid only for the specified operating frequency and must be scaled for lower<br />
operating frequencies.<br />
Outputs to the MC68060 begin to transition on rising CLK edges in which CLKEN is<br />
asserted. However, when BB and TIP transition from being asserted to being three-stated,<br />
they are driven negated for one CLK before they are three-stated. Refer to Figure 7-2, Figure<br />
7-3, and Figure 7-4 for an illustration. Furthermore, the processor status signals (PSTx),<br />
RSTO, and IPEND output signals are updated on rising edges of CLK regardless of the<br />
CLKEN input.<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
7-1
Bus Operation<br />
7-2<br />
CLK<br />
CLKEN<br />
OUTPUTS<br />
INPUTS<br />
NOTES:<br />
1. td = Propagation delay of signal relative to CLK rising edge.<br />
2. tho = Output hold time relative to CLK rising edge.<br />
3. tsu = Required input setup time relative to CLK rising edge.<br />
4. thi = Required input hold time relative to CLK rising edge.<br />
CLK<br />
CLKEN<br />
BCLK<br />
BB or TIP<br />
THREE-STATING FROM<br />
ASSERTED STATE<br />
CLK<br />
CLKEN<br />
BCLK<br />
BB or TIP<br />
THREE-STATING FROM<br />
ASSERTED STATE<br />
Figure 7-1. Signal Relationships to Clocks<br />
tsu<br />
tho<br />
Figure 7-2. Full-Speed Clock<br />
Figure 7-3. Half-Speed Clock<br />
t hi<br />
<strong>M68060</strong> USER’S MANUAL<br />
t d<br />
MOTOROLA
MOTOROLA<br />
CLK<br />
CLKEN<br />
BCLK<br />
BB or TIP<br />
THREE-STATING FROM<br />
ASSERTED STATE<br />
Figure 7-4. Quarter-Speed Clock<br />
<strong>M68060</strong> USER’S MANUAL<br />
Bus Operation<br />
7.2 FULL-, HALF-, AND QUARTER-SPEED BUS OPERATION AND BCLK<br />
To simplify the description of full-, half-, and quarter-speed bus operation, the term “bus<br />
clock” or “BCLK” is introduced to describe the effective frequency of bus operation. The bus<br />
clock is analogous to the MC68040 clock input called BCLK. The MC68040 BCLK defines<br />
when input signals are sampled and when output signals begin to transition. Once the relationship<br />
of CLK, CLKEN, and the virtual BCLK is established, it is possible to describe the<br />
MC68060 bus more easily, relative to BCLK.<br />
CLKEN allows the bus to synchronize to BCLK which is running at half or quarter speed of<br />
the processor clock (CLK). On rising CLK edges in which CLKEN is asserted, inputs to the<br />
processor are recognized and outputs of the processor may begin to assert, negate, or<br />
three-state. On rising CLK edges in which CLKEN is negated, no inputs are recognized and<br />
no outputs begin to change (except BB and TIP). Figure 7-1 illustrates the general relationship<br />
between CLK, CLKEN, and most input and output signals.<br />
For brevity, the term “full-speed bus” is introduced to refer to systems in which BCLK is running<br />
at the same frequency as CLK. The term “half-speed bus” refers to systems in which<br />
BCLK is running at half the frequency of CLK. For those familiar with the MC68040, the halfspeed<br />
bus is analogous to the MC68040 implementation. The term “quarter-speed bus”<br />
refers to systems in which BCLK is running at one quarter the frequency of CLK. The<br />
MC68060 clocking mechanism is designed so that systems designed today can be<br />
upgraded with higher-frequency MC68060s, without forcing the rest of the system to operate<br />
at the same higher processor frequency. This flexibility also allows the MC68060 to be used<br />
in existing MC68040 system designs.<br />
A full-speed bus design is achieved by continuously asserting CLKEN as shown in Figure<br />
7-2. A half speed bus is achieved by asserting CLKEN about every other rising edge of CLK.<br />
Figure 7-3 shows a timing diagram of the relationship between CLK, CLKEN, and BCLK for<br />
half-speed bus operation. A quarter-speed bus is achieved by asserting CLKEN once about<br />
every four rising edges of CLK. Figure 7-4 shows a timing diagram of the relationship<br />
between CLK, CLKEN, and BCLK for quarter-speed bus operation.<br />
Note that once BCLK has been established, inputs and outputs appear to be synchronized<br />
to this virtual BCLK. To simplify the description of MC68060 bus operation, the rising edges<br />
7-3
Bus Operation<br />
of BCLK represent the rising edges of CLK in which CLKEN is asserted. However, there are<br />
cases in which the BCLK concept does not apply.<br />
The BCLK concept does not apply to the IPLx and RSTI input signals. These inputs are sampled<br />
every CLK edge. The processor status (PSTx), RSTO, and IPEND outputs do not follow<br />
the BCLK concept, either, since these outputs can change on any CLK rising edge, regardless<br />
of CLKEN. The BB and TIP signals generally follow the BCLK concept except when<br />
these signals are already driven asserted by the processor and then three-stated. This<br />
occurs when the bus is arbitrated away from the processor immediately after an active bus<br />
cycle. These outputs are actively negated for one CLK period before three-stating. Figure 7-<br />
2, Figure 7-3, and Figure 7-4 illustrate the behavior of BB and TIP in the case mentioned.<br />
The BB signal is not recommended for use in full-speed bus designs since bus contention<br />
is possible when tied to alternate masters’ BB pins.<br />
Other implementations of CLKEN are not supported.<br />
7.3 ACKNOWLEDGE TERMINATION IGNORE STATE CAPABILITY<br />
The MC68060 provides the capability to ignore termination acknowledgments to assist in<br />
system designs. Independent ignore state counters for read and write, primary (initial) transfer,<br />
and secondary (burst) transfer are used during bus cycles to determine which BCLK rising<br />
edges transfer acknowledge termination signals should be ignored or sampled.<br />
This special mode is selected during a reset operation. Please refer to 7.14 Special Modes<br />
of Operation for details on how to enable this mode.<br />
7.4 BUS CONTROL REGISTER<br />
The bus control register (BUSCR) is accessed via the MOVEC instruction. Its main purpose<br />
is to provide a way to control the external LOCK and LOCKE signals in software. This feature<br />
is essential in emulating the CAS2 instruction and in providing a means to control bus<br />
arbitration activity during critical code segments. Figure 7-5 shows the BUSCR format.<br />
L—Lock Bit<br />
0 = Negate external LOCK signal.<br />
1 = Assert external LOCK signal.<br />
SL—Shadow Copy, Lock Bit<br />
0 = LOCK negated sequence at time of exception.<br />
1 = LOCK asserted at time of exception.<br />
7-4<br />
31 30 29 28 27<br />
0<br />
L SL LE SLE<br />
Reserved for Future Use<br />
Figure 7-5. Bus Control Register Format<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
LE—Lock End Bit<br />
0 = Negate external LOCKE signal.<br />
1 = Assert external LOCKE signal.<br />
SLE—Shadow Copy, Lock End Bit<br />
0 = LOCKE asserted at time of exception.<br />
1 = LOCKE negated at time of exception.<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Bus Operation<br />
The external LOCK signal is asserted starting with the assertion of TS for the bus cycle of<br />
the next operand read or write after setting the L-bit in the BUSCR. The external LOCKE<br />
signal is asserted starting with the assertion of TS for the bus cycle of the next operand write<br />
after setting the LE bit in the BUSCR. Both the LOCK and LOCKE external signals are<br />
negated the cycle after the final TA assertion associated with the TS that asserted LOCKE.<br />
The final operand write cycle must not be misaligned. A final write to the BUSCR must be<br />
made in order to clear the L and LE bits even though the external signals have already<br />
negated. The L and LE bits are cleared when the processor is reset.<br />
The SL and SLE bits in the BUSCR are provided to retain a copy of the L and LE bits at the<br />
time of an exception. When an exception occurs, the MC68060 copies the L and LE bits to<br />
the SL and SLE bits respectively, negates the external LOCK and LOCKE pins, and clears<br />
the L and LE bits. It is recommended that all interrupts be masked prior to the use of BUSCR.<br />
If the cause of the exception is an access error, a bit in the fault status long word (FSLW) in<br />
the access error frame is used to signify that a locked sequence was being executed at the<br />
time of the fault.<br />
7.5 DATA TRANSFER MECHANISM<br />
Figure 7-6 illustrates how the bus designates operands for transfers on a byte boundary system.<br />
The integer unit handles floating-point operands as a sequence of related long-word<br />
operands. These designations are used in the figures and descriptions that follow.<br />
31<br />
OP0<br />
24 23<br />
16 15<br />
Figure 7-6. Internal Operand Representation<br />
Figure 7-7 illustrates general multiplexing between an internal register and the external bus.<br />
The internal register connects to the external data bus through the internal data bus and<br />
multiplexer. The data multiplexer establishes the necessary connections for different combinations<br />
of address and data sizes.<br />
Unlike the MC68020 and MC68030 processors, the MC68060 does not support dynamic<br />
bus sizing and expects the referenced device to accept the requested access width. The<br />
MC68150 dynamic bus sizer is designed to allow the 32-bit MC68060 bus to communicate<br />
8 7<br />
OP1 OP2 OP3<br />
OP2 OP3<br />
OP3<br />
0<br />
LONG-WORD OPERAND<br />
WORD OPERAND<br />
BYTE OPERAND<br />
7-5
Bus Operation<br />
bidirectionally with 32-, 16-, or 8-bit peripherals and memories. It dynamically recognizes the<br />
size of the selected peripheral or memory device and then reads or writes the appropriate<br />
data from that location. Refer to MC68150/D, MC68150 Dynamic Bus Sizer,<br />
for information<br />
on this device.<br />
7-6<br />
REGISTER<br />
MULTIPLEXER<br />
EXTERNAL<br />
DATA BUS<br />
ADDRESS<br />
$xxxxxxx0<br />
31 24 23 16 15 8 7<br />
0<br />
OP0 OP1 OP2 OP3<br />
ROUTING<br />
D31–D24 D23–D16 D15–D8 D7–D0<br />
31 24 23 16 15 8 7<br />
0<br />
BS0 BS1 BS2 BS3<br />
Figure 7-7. Data Multiplexing<br />
Blocks of memory that must be contiguous, such as for code storage or program stacks,<br />
must be 32 bits wide. Byte- and word-sized I/O ports that return an interrupt vector during<br />
interrupt acknowledge cycles must be mapped into the low-order 8 or 16 bits, respectively,<br />
of the data bus.<br />
The multiplexer takes the four bytes of a long-word transfer and routes them to their required<br />
positions. For example, OP0 would normally be routed to D31–D24 on an aligned long-word<br />
transfer, but it can also be routed to any other byte position supporting a misaligned data<br />
transfer. The same is true for any of the other operand bytes. The transfer size (SIZ0 and<br />
SIZ1) and byte offset (A1 and A0) signals determine the positioning of the bytes (see Table<br />
7-1) or alternatively, BS3–BS0 may be used instead of SIZx, A1, and A0. The BSx pins<br />
determine which byte sections are active. The size indicated on the SIZx signals corresponds<br />
to the size of the operand transfer for the entire bus cycle (except for burst-inhibited<br />
bus cycles). During an operand transfer, A31–A2 indicate the long-word base address for<br />
the first byte of the operand to be accessed; A1 and A0 indicate the byte offset from the<br />
base. For long-word or line bus cycles, external logic must ignore address bits A1 and A0<br />
for proper operation.<br />
<strong>M68060</strong> USER’S MANUAL<br />
INTERNAL TO<br />
THE MC68060<br />
EXTERNAL BUS<br />
MOTOROLA
MOTOROLA<br />
Transfer Size<br />
Byte<br />
Word<br />
Table 7-1. Data Bus Requirements for Read and Write Cycles<br />
Signal Encoding Active Data Bus Sections and Byte Enables<br />
SIZ1 SIZ0 A1 A0<br />
0<br />
0<br />
0<br />
0<br />
1<br />
1<br />
1<br />
1<br />
1<br />
1<br />
0<br />
0<br />
0<br />
0<br />
1<br />
1<br />
0<br />
1<br />
0<br />
1<br />
0<br />
1<br />
0<br />
0<br />
D31–D24<br />
BS0<br />
OP3<br />
—<br />
—<br />
—<br />
OP2<br />
—<br />
D23–D16<br />
BS1<br />
—<br />
OP3<br />
—<br />
—<br />
OP3<br />
—<br />
<strong>M68060</strong> USER’S MANUAL<br />
D15–D8<br />
BS2<br />
—<br />
—<br />
OP3<br />
—<br />
—<br />
OP2<br />
Bus Operation<br />
D7–D0<br />
BS3<br />
—<br />
—<br />
—<br />
OP3<br />
—<br />
OP3<br />
Long Word 0 0 X X OP0 OP1 OP2 OP3<br />
Line 1 1 X X OP0 OP1 OP2 OP3<br />
Table 7-1 lists the combinations of the SIZx, A1, and A0 signals, collectively called byte<br />
enable signals, that are used for each of the four sections of the data bus. Alternatively, the<br />
BSx signals may be used for byte selection. In Table 7-1, OP0–OP3 indicates the portion of<br />
the requested operand that is read or written during that bus transfer. For line and long-word<br />
transfers, all bytes are valid as listed and can correspond to portions of the requested operand<br />
or to data required to fill the remainder of the cache line. The bytes labeled with a dash<br />
are not required; they are ignored on read transfers and driven with undefined data on write<br />
transfers. Not selecting these bytes prevents incorrect accesses in sensitive areas such as<br />
I/O devices. Figure 7-8 illustrates a logic diagram for one method for generating byte select<br />
signals from SIZx, A1, and A0 and the associated PAL equation. The logic shown in Figure<br />
7-8 is equivalent to the internal logic used to generate the external byte select signals (BSx)<br />
provided by the processor. Byte enable signals derived from the SIZx, A1, and A0 signals,<br />
or alternatively, the external BSx signals, can be combined with the address or other<br />
attributes signals to generate the decode logic of a system.<br />
The MC68060 provides BSx so that it is unnecessary to use the SIZx, A1, and A0 signals to<br />
generate byte selects using external logic. This aids in high-speed system design. Figure 7-<br />
7, Figure 7-8, and Table 7-1 show the relationship between SIZx, A1, A0, and BSx.<br />
A brief summary of the bus signal encoding for each access type is listed in Table 7-2. Additional<br />
information on the encoding for the MC68060 signals can be found in Section 2 Signal<br />
Description.<br />
7-7
Bus Operation<br />
7-8<br />
A0<br />
A1<br />
SIZ0<br />
SIZ1<br />
UPPER UPPER DATA SELECT<br />
D31–D24<br />
BS0<br />
UPPER MIDDLE DATA SELECT<br />
D23–D16<br />
BS1<br />
LOWER MIDDLE DATA SELECT<br />
D15–D8<br />
BS2<br />
LOWER LOWER DATA SELECT<br />
D7–D0<br />
BS3<br />
PAL16L8<br />
U1<br />
MC68060 Byte Data Select Generation.<br />
A0 A1 SIZ0 SIZ1 NC NC NC NC NC GND NC UUD UMD LMD LLD<br />
NC NC NC NC VCC<br />
/UUD = /A0 * /A1<br />
; directly addressed, any size<br />
+ /SIZ1 * /SIZ0 ; enable every byte for long-word size<br />
+ SIZ1 * SIZ0 ; enable every byte for line size<br />
/UMD = A0 * /A1<br />
; directly addressed, any size<br />
+ /A1 * /SIZ1 ; word aligned, size is word or line<br />
+ SIZ1 * SIZ0 ; enable every byte for long-word size<br />
+ /SIZ1 * /SIZ0 ; enable every byte for line size<br />
/LMD = /A0 * /A1<br />
; directly addressed, any size<br />
+ /SIZ1 * /SIZ0 ; enable every byte for long-word size<br />
+ SIZ1 * SIZ0 ; enable every byte for line size<br />
/LLD = A0 * /A1<br />
; directly addressed, any size<br />
+ /A1 * /SIZ1 ; word aligned, word or line size<br />
+ SIZ1 * SIZ0 ; enable every byte for long-word size<br />
+ /SIZ1 * /SIZ0<br />
; enable every byte for line size<br />
Figure 7-8. Byte Select Signal Generation and PAL Equation<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
Bus<br />
Signal<br />
A31–A0<br />
UPA1,<br />
UPA0<br />
7.6 MISALIGNED OPERANDS<br />
MOTOROLA<br />
Table 7-2. Summary of Access Types vs. Bus Signal Encoding<br />
Data<br />
Cache<br />
Push<br />
Access<br />
Access<br />
Address<br />
$0<br />
Normal<br />
Data/<br />
Code<br />
Access<br />
Access<br />
Address<br />
MMU<br />
Source1 Table<br />
Search<br />
Access<br />
Entry<br />
Address<br />
$0<br />
MOVE16<br />
Access<br />
Access<br />
Address<br />
Alternate<br />
Access<br />
Access<br />
Address<br />
<strong>M68060</strong> USER’S MANUAL<br />
Interrupt<br />
Acknowledge<br />
LPSTOP<br />
Broadcast<br />
Cycle<br />
Bus Operation<br />
Breakpoint<br />
Acknowledge<br />
$FFFFFFFF $FFFFFFFE $00000000<br />
MMU<br />
Source 1 $0 $0 $0 $0<br />
SIZ1,<br />
SIZ0<br />
L/Line B/W/L/Line Long Word Line B/W/L Byte Word Byte<br />
TT1, TT0 $0 $0 $0 $1 $2<br />
Function<br />
$3 $3 $3<br />
Code=0,3,<br />
TM2–<br />
TM0<br />
$0 $1,2,5, or 6 $3 or 4 $1 or 5<br />
4,7<br />
Debug<br />
Access=<br />
1,5,6<br />
Int. Level $1–7 $0 $0<br />
TLN1,<br />
TLN0<br />
Cache Set<br />
Entry<br />
Cache Set<br />
Entry2 Undefined Undefined Undefined Undefined Undefined Undefined<br />
R/W Write Read/Write Read/Write Read/Write Read/Write Read Write Read<br />
LOCK<br />
LOCKE<br />
Negated<br />
CIOUT Negated<br />
Asserted/<br />
Negated 3<br />
MMU<br />
Source 1<br />
Asserted/<br />
Negated 3 Negated Negated Negated Negated Negated<br />
Negated<br />
MMU<br />
Source 1 Asserted Negated Negated Negated<br />
NOTES<br />
1) The UPA1, UPA0, and CIOUT signals are determined by the U1, U0, and CM bit fields, respectively,<br />
corresponding to the access address.<br />
2) The TLNx signals are defined only for normal push accesses and normal data line read accesses.<br />
3) The LOCK signal is asserted during TAS and CAS operand accesses and for some table search update<br />
sequences. LOCKE is asserted for the last bus cycle of a locked sequence of bus cycles. LOCK and LOCKE<br />
may also be asserted after the execution of a MOVEC instruction that sets the L or LE bit, respectively, in the<br />
BUSCR (see 7.4 Bus Control Register).<br />
4) Refer to Section 2 Signal Description for definitions of the TMx signal encoding for normal, MOVE16, and<br />
alternate accesses.<br />
All MC68060 data formats can be located in memory on any byte boundary. A byte operand<br />
is properly aligned at any address, a word operand is misaligned at an odd address, and a<br />
long word is misaligned at an address that is not evenly divisible by four. However, since<br />
operands can reside at any byte boundary, they can be misaligned. Although the MC68060<br />
does not enforce any alignment restrictions for data operands (including program counter<br />
(PC) relative data addressing), some performance degradation occurs when additional bus<br />
cycles are required for long-word or word operands that are misaligned. For maximum performance,<br />
data items should be aligned on their natural boundaries. All instruction words<br />
and extension words must reside on word boundaries. Attempting to prefetch an instruction<br />
word at an odd address causes an address error exception. Refer to Section 8 Exception<br />
Processing for details on address error exceptions.<br />
The MC68060 data memory unit converts misaligned operand accesses that are noncachable<br />
to a sequence of aligned accesses. These aligned accesses are then sent to the bus<br />
controller for completion, always resulting in aligned bus transfers. Misaligned operand<br />
accesses that miss in the data cache are cachable and are not aligned before line filling.<br />
Refer to Section 5 Caches for details on line fill and the data cache.<br />
7-9
Bus Operation<br />
Figure 7-9 illustrates the transfer of a long-word operand from an odd address requiring<br />
more than one bus cycle. For the first transfer or bus cycle, the SIZx signals specify a byte<br />
transfer, and the byte offset is $1. The slave device supplies the byte and acknowledges the<br />
data transfer. When the processor starts the second cycle, the SIZx signals specify a word<br />
transfer with a byte offset of $2. The next two bytes are transferred during this cycle. The<br />
processor then initiates the third cycle, with the SIZx signals indicating a byte transfer. The<br />
byte offset is now $0; the port supplies the final byte and the operation is complete. This<br />
example is similar to the one illustrated in Figure 7-10 except that the operand is word sized<br />
and the transfer requires only two bus cycles. Figure 7-11 illustrates a functional timing diagram<br />
for a misaligned long-word read transfer.<br />
7-10<br />
MOVE.L D0,$XXXXXXX1<br />
REGISTER<br />
31 24 23 16 15 8 7<br />
0<br />
OP0 OP1 OP2 OP3<br />
DATA BUS<br />
31 24 23 16 15 8 7<br />
0<br />
X OP0 X X<br />
X X OP1 OP2<br />
OP3 X X X<br />
MEMORY<br />
31 24 23 16 15 8 7<br />
0<br />
XXX OP0 OP1 OP2<br />
OP3 XXX XXX XXX<br />
Figure 7-9. Example of a Misaligned Long-Word Transfer<br />
MOVE.W D0,$XXXXXXX3<br />
Register<br />
31 24 23 16 15 8 7<br />
0<br />
— — OP2 OP3<br />
DATA BUS<br />
31 24 23 16 15 8 7<br />
0<br />
— — — OP2<br />
OP3 — — —<br />
MEMORY<br />
31 24 23 16 15 8 7<br />
0<br />
XXX XXX XXX OP2<br />
OP3 XXX XXX XXX<br />
Figure 7-10. Example of Misaligned Word Transfer<br />
<strong>M68060</strong> USER’S MANUAL<br />
TRANSFER 1<br />
TRANSFER 2<br />
TRANSFER 3<br />
TRANSFER 1<br />
TRANSFER 2<br />
MOTOROLA
MOTOROLA<br />
BCLK<br />
A31–A2<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TS<br />
TIP<br />
R/W<br />
A1–A0<br />
SIZ1–SIZ0<br />
TA<br />
BS0<br />
BS1<br />
BS2<br />
BS3<br />
D31–D24<br />
D23–D16<br />
D15–D8<br />
D7–D0<br />
C1 C2 C1 C2 C1 C2<br />
BYTE<br />
READ<br />
1 2 0<br />
BYTE WORD BYTE<br />
BYTE 0<br />
WORD<br />
READ<br />
Figure 7-11. Misaligned Long-Word Read Bus Cycle Timing<br />
<strong>M68060</strong> USER’S MANUAL<br />
Bus Operation<br />
The combination of operand size and alignment determines the number of bus cycles<br />
required to perform a particular memory access. Table 7-3 lists the number of bus cycles<br />
required for different operand sizes with all possible alignment conditions for read and write<br />
cycles. The table confirms that alignment significantly affects bus cycle throughput for noncachable<br />
accesses. For example, in Figure 7-9 the misaligned long-word operand took three<br />
bus cycles because the byte offset = $1. If the byte offset = $0, then it would have taken one<br />
BYTE 1<br />
BYTE 2<br />
BYTE<br />
READ<br />
BYTE 3<br />
7-11
Bus Operation<br />
bus cycle. The MC68060 system designer and programmer should account for these<br />
effects, particularly in time-critical applications.<br />
7.7 PROCESSOR DATA TRANSFERS<br />
The transfer of data between the processor and other devices involves the address bus,<br />
data bus, and control and attribute signals. The address and data buses are normally parallel,<br />
nonmultiplexed buses, supporting byte, word, long-word, and line (16-byte) bus cycles.<br />
Line transfers are normally performed using an efficient burst transfer, which provides an<br />
initial address and time-multiplexes the data bus to transfer four long words of information<br />
to or from the slave device. Slave devices that do not support bursting can burst-inhibit the<br />
first long word of a line transfer, forcing the bus master to complete the access using three<br />
additional long-word bus cycles. All bus input and output signals are synchronized with<br />
respect to the rising edge of the BCLK signal. The MC68060 moves data on the bus by issuing<br />
control signals and using a handshake protocol to ensure correct data movement. The<br />
following paragraphs describe the bus cycles for byte, word, long-word, and line read, write,<br />
and read-modify-write transfers.<br />
In general, the bus cycle protocol supported by the MC68060 processor is similar to that<br />
supported by the MC68040 processor. In addition to the basic MC68060 protocol, there are<br />
special modes that can be selected during reset by selectively setting the IPLx and data bus<br />
D15–D0. For the purpose of simplifying the description of the MC68060 bus, this sub-section,<br />
7.7 Processor Data Transfers,<br />
describes the behavior of the MC68060 processor<br />
assuming that none of the special modes are selected during reset. For the description of<br />
the MC68060 bus cycle protocol when the special modes are enabled, refer to 7.14 Special<br />
Modes of Operation.<br />
7.7.1 Byte, Word, and Long-Word Read Transfer Cycles<br />
During a read transfer, the processor receives data from a memory or peripheral device.<br />
Since the data read for a byte, word, or long-word access is not placed in either of the internal<br />
caches by definition, the processor ignores the transfer cache inhibit (TCI) signal when<br />
registering the data. The bus controller performs byte, word, and long-word read transfers<br />
for the following cases:<br />
• Accesses to a disabled cache<br />
• Accesses to a memory page that is specified noncachable<br />
• Accesses that are implicitly noncachable (locked read-modify-write accesses, accesses<br />
to an alternate logical address space via the MOVES instruction, and table searches)<br />
7-12<br />
Table 7-3. Memory Alignment Influence on<br />
Noncachable and Writethrough Bus Cycles<br />
Transfer Size<br />
Number of Bus Cycles<br />
$0* $1* $2* $3*<br />
Instruction 1 N/A N/A N/A<br />
Byte Operand 1 1 1 1<br />
Word Operand 1 2 1 2<br />
Long-Word Operand 1 3 2 3<br />
*Where the byte offset (A1 and A0) equals this encoding.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Bus Operation<br />
• Accesses that do not allocate in the data cache on a read miss (exception vector fetches,<br />
and exception stack deallocation for an RTE instruction)<br />
• The first transfer of a line read is terminated with transfer burst inhibit (TBI), forcing completion<br />
of the line access using three additional long-word read transfers<br />
Figure 7-12 is a flowchart for byte, word, and long-word read transfers. Bus operations are<br />
similar for each case and vary only with the size indicated and the portion of the data bus<br />
used for the transfer. Figure 7-13 is a functional timing diagram for byte, word, and longword<br />
read transfers.<br />
PROCESSOR SYSTEM<br />
1) SET R/W TO READ<br />
2) DRIVE ADDRESS ON A31–A0<br />
3) DRIVE UPA1–UPA0, TM2–TM0, CIOUT,<br />
TLN1–TLN0, LOCK, LOCKE, BS3–BS0<br />
4) DRIVE SIZ1–SIZ0 TO BYTE, WORD, OR LONG<br />
5) ASSERT TS FOR ONE BCLK<br />
6) ASSERT TIP<br />
7) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER READ PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) REGISTER DATA<br />
2) NEGATE LOCK, LOCKE IF NECESSARY<br />
1) DECODE ADDRESS<br />
2) PLACE DATA ON APPROPRIATE BYTE<br />
LANES BASED ON SIZ1–SIZ0, A1–A0, OR<br />
BS3–BS0<br />
3) ASSERT TA AROUND RISING EDGE OF<br />
BCLK.<br />
1) NEGATE TIP OR START NEXT CYCLE 1) THREE-STATE D31–D0<br />
Figure 7-12. Byte, Word, and Long-Word Read Cycle Flowchart<br />
Clock 1 (C1)<br />
The read cycle starts in C1. During C1, the processor places valid values on the address<br />
bus and transfer attributes. For user and supervisor mode accesses, which the corresponding<br />
memory unit translates, the user-programmable attribute signals (UPAx) are<br />
driven with the values from the matching user bits (U1 and U0). The transfer type (TTx)<br />
and transfer modifier (TMx) signals identify the specific access type. The read/write (R/W)<br />
signal is driven high for a read cycle. Cache inhibit out (CIOUT) is asserted since the access<br />
is identified as noncachable. Refer to Section 4 Memory Management Unit for information<br />
on the MC68060 and MC68LC060 memory units and Appendix B MC68EC060<br />
for information on the MC68EC060 memory unit.<br />
7-13
Bus Operation<br />
7-14<br />
BCLK<br />
ADDRESS AND<br />
ATTRIBUTES<br />
R/W<br />
A1–A0<br />
SIZ1–SIZ0<br />
TS<br />
TIP<br />
TA<br />
SAS<br />
BS0<br />
BS1<br />
BS2<br />
BS3<br />
D31–D24<br />
D23–D16<br />
D15–D8<br />
D7–D0<br />
C1 C2<br />
1 2 0<br />
BYTE<br />
BYTE READ<br />
C1 CW C2 C1 C2<br />
WORD<br />
WORD READ<br />
WITH WAIT<br />
Figure 7-13. Byte, Word, and Long-Word Read Bus Cycle Timing<br />
The processor asserts transfer start (TS) during C1 to indicate the beginning of a bus cycle.<br />
If not already asserted from a previous bus cycle, the transfer in progress (TIP) signal<br />
is also asserted at this time to indicate that a bus cycle is active.<br />
<strong>M68060</strong> USER’S MANUAL<br />
LONG<br />
LONG-WORD<br />
READ<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Bus Operation<br />
Clock 2 (C2)<br />
During C2, the processor negates TS. The selected peripheral device uses R/W, SIZ1,<br />
SIZ0, A1, and A0 or BSx to place its information on the data bus. With the exception of<br />
the R/W signal, these signals also select any or all of the operand bytes (D31–D24, D23–<br />
D16, D15–D8, and D7–D0). If the first clock after C1 is not a wait state (CW), then the<br />
selected peripheral device asserts the transfer acknowledge (TA) signal.<br />
The MC68060 implements a special mode called the acknowledge termination ignore<br />
state capability to aid in high-frequency designs. In this mode, the processor begins sampling<br />
termination signals such as TA after a user-programmed number of BCLK rising<br />
edges has expired. The SAS signal is provided as a status output to indicate which BCLK<br />
rising edge the processor begins to sample the termination signals. If this mode is disabled,<br />
SAS is asserted during C2 to indicate that the processor immediately begins sampling<br />
the termination signals. Refer to 7.14.1 Acknowledge Termination Ignore State<br />
Capability for details on this special mode.<br />
Assuming that the acknowledge termination ignore state capability is disabled, at the end<br />
of the first clock cycle C2, the processor samples the level of TA and if asserted, registers<br />
the current value on the data bus; the bus cycle terminates, and the data is passed to the<br />
processor’s appropriate memory unit. If TA is not recognized asserted at the end of the<br />
clock cycle, the processor ignores the data and inserts a wait state instead of terminating<br />
the transfer. The processor continues to sample TA on successive rising edges of BCLK<br />
until TA is recognized asserted. Only when TA is recognized asserted is data passed to<br />
the processor’s appropriate memory unit.<br />
When the processor recognizes TA at the end of a clock cycle and terminates the bus cycle,<br />
TIP remains asserted if the processor is ready to begin another bus cycle. Otherwise,<br />
the processor negates TIP during the next clock.<br />
7.7.2 Line Read Transfer<br />
The processor uses line read transfers to access a 16-byte operand for a MOVE16 instruction<br />
and to support cache line filling. A line read accesses a block of four long words, aligned<br />
to a 16-byte memory boundary, by supplying a starting address that points to one of the long<br />
words and requires the memory device to sequentially drive each long word on the data bus.<br />
The selected device must internally increment A3 and A2 of the supplied address for each<br />
transfer, causing the address to wrap around at the end of the block if CLA is not used. Otherwise,<br />
the external device may request the processor to increment A3 and A2 in a circular<br />
wrap-around fashion via the CLA input. Refer to 7.7.7 Using CLA to Increment A3 and A2<br />
for details on CLA operation. The address and transfer attributes supplied by the processor<br />
remain stable during the transfers, and the selected device terminates each transfer by driving<br />
the long word on the data bus and asserting TA. A line transfer performed in this manner<br />
with a single address is referred to as a line burst transfer.<br />
The MC68060 supports burst-inhibited line transfers for memory devices that are unable to<br />
support bursting. For this type of bus cycle, the selected device supplies the first long word<br />
pointed to by the processor address and asserts transfer burst inhibit (TBI) with TA for the<br />
first transfer of the line access. The processor responds by terminating the line burst transfer<br />
and accessing the remainder of the line, using three long-word read bus cycles. Although<br />
the selected device can then treat the line bus cycle as four, independent, long-word bus<br />
7-15
Bus Operation<br />
cycles, the bus controller still treats the four transfers as a single line bus cycle and does not<br />
allow other unrelated processor accesses or bus arbitration to intervene between the transfers.<br />
TBI is ignored after the first long-word transfer.<br />
Line reads to support cache line filling can be cache inhibited by asserting transfer cache<br />
inhibit (TCI) with TA for the first long-word transfer of the line. The assertion of TCI does not<br />
affect completion of the line transfer, but the bus controller registers and passes it to the<br />
memory controller for use. TCI is ignored after the first long-word transfer of a line burst bus<br />
cycle and during the three long-word bus cycles of a burst-inhibited line transfer.<br />
The address placed on the address bus by the processor for line bus cycle does not necessarily<br />
point to the most significant byte of each long word because A1 and A0 are copied<br />
from the original operand address supplied to the memory unit by the integer unit for line<br />
reads. These two bits are also unchanged for the three long-word bus cycles of a burstinhibited<br />
line transfer. The selected device should ignore A1 and A0 for long-word and line<br />
read transfers.<br />
The address of an instruction fetch will always be aligned to a long-word boundary<br />
($xxxxxxx0, $xxxxxxx4, $xxxxxxx8, or $xxxxxxxC). This is unlike the MC68040 in which the<br />
prefetches occur on half-line boundaries. Therefore, compilers should attempt to locate<br />
branch targets on long-word boundaries to minimize branch stalls. For example, if the target<br />
of a branch is an instruction that starts at $1000000E, the following burst sequence will occur<br />
upon a cache miss: $1000000C, $10000000, $10000004, then $10000008. Figure 7-14 and<br />
Figure 7-15 illustrate a flowchart and functional timing diagram for a line read bus transfer.<br />
Clock 1 (C1)<br />
The line read cycle starts in C1. During C1, the processor places valid values on the address<br />
bus and transfer attributes. For user and supervisor mode accesses that are translated<br />
by the corresponding memory unit, the UPAx signals are driven with the values from<br />
the matching U1 and U0 bits. The TTx and TMx signals identify the specific access type.<br />
The R/W signal is driven high for a read cycle, and the size signals (SIZx) indicate line<br />
size. CIOUT is asserted for a MOVE16 operand read if the access is identified as noncachable.<br />
Refer to Section 4 Memory Management Unit for information on the<br />
MC68060 and MC68LC060 memory units and Appendix B MC68EC060 for information<br />
on the MC68EC060 memory unit.<br />
The processor asserts TS during C1 to indicate the beginning of a bus cycle. If not already<br />
asserted from a previous bus cycle, TIP is also asserted at this time to indicate that a bus<br />
cycle is active.<br />
Clock 2 (C2)<br />
During C2, the processor negates TS. The selected device uses R/W and SIZx to place<br />
the data on the data bus. (The first transfer must supply the long word at the corresponding<br />
long-word boundary.) Concurrently, the selected device asserts TA and either negates<br />
TBI to indicate it can or asserts TBI to indicate it cannot support a burst transfer.<br />
The MC68060 implements a special mode called the acknowledge termination ignore<br />
state capability to aid in high-frequency designs. In this mode, the processor begins sampling<br />
termination signals such as TA after a user-programmed number of BCLK rising<br />
7-16<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
PROCESSOR SYSTEM<br />
1) SET R/W TO READ<br />
2) DRIVE ADDRESS ON A31–A0<br />
3) DRIVE UP A1–UPA0, TT1–TT0, TM2–TM0,<br />
CIOUT, TLN1–TLN0, LOCK, LOCKE, BS3–BS0<br />
4) DRIVE SIZ1–SIZ0 TO LINE<br />
5) ASSERT TS FOR ONE BCLK<br />
6) ASSERT TIP<br />
7) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER READ PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) REGISTER DATA<br />
2) SAMPLE TBI AND TCI<br />
3) INCREMENT A3–A2 IF CLA ASSERTED<br />
TBI ASSERTED TBI NEGATED<br />
1) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION<br />
IGNORE STATE CAPABILITY<br />
DISABLED. ELSE, ASSERT SAS<br />
AFTER READ SECONDARY<br />
IGNORE STATE COUNTER HAS<br />
EXPIRED.<br />
1) REGISTER DATA<br />
2) INCREMENT A3–A2 IF CLA<br />
ASSERTED<br />
Figure 7-14. Line Read Cycle Flowchart<br />
<strong>M68060</strong> USER’S MANUAL<br />
1) DECODE ADDRESS<br />
2) PLACE DATA ON D31–D0<br />
3) ASSERT TA FOR ONE BCLK<br />
4) ASSERT CLA TO INCREMENT A3–A2<br />
5) ASSERT TBI OR TCI AS NEEDED<br />
1) DECODE ADDRESS<br />
2) PLACE DATA ON D31–D0<br />
3) ASSERT TA FOR ONE BCLK<br />
4) ASSERT CLA TO INCREMENT A3–A2<br />
4 LW DONE 4 LW NOT DONE<br />
1) NEGATE LOCK, LOCKE IF<br />
NECESSARY<br />
1) NEGATE TIP OR START NEXT<br />
CYCLE<br />
CONTINUE WITH FIG. 7-16<br />
1) THREE-STATE D31–D0<br />
Bus Operation<br />
edges has expired. The signal SAS is provided as a status output to indicate which BCLK<br />
rising edge the processor begins to sample the termination signals. If this mode is dis-<br />
7-17
Bus Operation<br />
abled, SAS is asserted during C2 to indicate that the processor immediately begins sampling<br />
the terminations signals. Refer to 7.14.1 Acknowledge Termination Ignore State<br />
Capability for details on this special mode.<br />
Assuming that the acknowledge termination ignore state capability is disabled, the processor<br />
samples the level of TA, TBI, and TCI and registers the current value on the data<br />
bus at the end of C2. If TA is asserted, the transfer terminates and the data is passed to<br />
the appropriate memory unit. If TA is not recognized asserted, the processor ignores the<br />
data and inserts wait states instead of terminating the transfer. The processor continues<br />
to sample TA, TBI, and TCI on successive rising edges of BCLK until TA is recognized<br />
7-18<br />
BCLK<br />
A31–A4<br />
A1–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
R/W<br />
SIZ1–SIZ0<br />
BS3–BS0<br />
CIOUT<br />
CLA<br />
TS<br />
TIP<br />
TA<br />
TBI<br />
C1 C2 C3 C4 C5<br />
A3–A2 01<br />
10 11 00<br />
SAS<br />
D31–D0<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.<br />
Figure 7-15. Line Read Transfer Timing<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
Bus Operation<br />
asserted. The registered data and the value of TCI are then passed to the appropriate<br />
memory unit.<br />
If TBI was negated with the assertion of TA, the processor continues the cycle with C3.<br />
Otherwise, if TBI was asserted, the line transfer is burst inhibited, and the processor reads<br />
the remaining three long words using long-word read bus cycles. The processor increments<br />
A3 and A2 for each read, and the new address is placed on the address bus for<br />
each bus cycle. Refer to 7.7.1 Byte, Word, and Long-Word Read Transfer Cycles for<br />
information on long-word reads. If no wait states are generated, a burst-inhibited line read<br />
completes in eight clocks instead of the five required for a burst read.<br />
Clock 3 (C3)<br />
The processor holds the address and transfer attribute signals constant during C3 if CLA<br />
is negated. The selected device must either increment A3 and A2 to reference the next<br />
long word to transfer, place the data on the data bus, and assert TA, or alteratively assert<br />
the CLA input to request the processor to increment A3 and A2. Refer to 7.7.7 Using CLA<br />
to Increment A3 and A2 for details on CLA operation.<br />
As in the description of C2, using acknowledge termination ignore state capability, the processor<br />
ignores any termination signal, such as TA, until a user-programmable number of<br />
BCLK edges has expired. And, as in the description in C2, SAS indicates the first BCLK<br />
rising edge in which acknowledge termination signals become significant. If this mode is<br />
disabled, SAS stays asserted in C3 to indicate that the processor will sample TA immediately.<br />
Refer to 7.14.1 Acknowledge Termination Ignore State Capability for details on<br />
this mode.<br />
Assuming that the acknowledge termination ignore state capability is disabled, the processor<br />
samples the level of TA and registers the current value on the data bus at the end<br />
of C3. If TA is asserted, the transfer terminates and the second long word of data is<br />
passed to the appropriate memory unit. If TA is not recognized asserted at the end of C3,<br />
the processor ignores the latched data and inserts wait states instead of terminating the<br />
transfer. The processor continues to sample TA on successive rising edges of BCLK until<br />
it is recognized asserted. The registered data is then passed to the appropriate memory<br />
unit.<br />
Clock 4 (C4)<br />
This clock is identical to C3 except that once TA is recognized asserted, the registered<br />
value corresponds to the third long word of data for the burst.<br />
Clock 5 (C5)<br />
This clock is identical to C3 except that once TA is recognized, the registered value corresponds<br />
to the fourth long word of data for the burst. After the processor recognizes the<br />
last TA assertion and terminates the line read bus cycle, TIP remains asserted if the processor<br />
is ready to begin another bus cycle. Otherwise, the processor negates TIP during<br />
the next clock.<br />
Figure 7-16 and Figure 7-17 illustrate a flowchart and functional timing diagram for a<br />
burst-inhibited line read bus cycle.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-19
Bus Operation<br />
1) INCREMENT A3–A2<br />
2) DRIVE SIZ1–SIZ0 TO LONG<br />
3) ASSERT TS FOR ONE BCLK<br />
4) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER READ PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) REGISTER DATA<br />
PROCESSOR SYSTEM<br />
4 LW DONE<br />
1) NEGATE LOCK, LOCKE IF NECESSARY<br />
CONTINUED FROM FIGURE 7-14<br />
Figure 7-16. Burst-Inhibited Line Read Cycle Flowchart<br />
7.7.3 Byte, Word, and Long-Word Write Cycles<br />
1) DECODE ADDRESS<br />
2) PLACE DATA ON D31–D0<br />
3) ASSERT TA FOR ONE BCLK<br />
4) NEGATE CLA<br />
1) NEGATE TIP OR START NEXT CYCLE 1) THREE-STATE D31–D0<br />
4 LW NOT DONE<br />
During a write transfer, the processor transfers data to a memory or peripheral device. The<br />
level on the TCI signal is ignored by the processor during all write cycles. The bus controller<br />
performs byte, word, and long-word write transfers for the following cases:<br />
• Accesses to a disabled cache<br />
• Accesses to a memory page that is specified noncachable<br />
• Accesses that are implicitly noncachable (locked read-modify-write accesses, accesses<br />
to an alternate logical address space via the MOVES instruction, and table searches)<br />
• Writes to writethrough pages<br />
• Accesses that do not allocate in the data cache on a write miss (exception stacking)<br />
• The first transfer of a line write is terminated with TBI, forcing completion of the line access<br />
using three additional long-word write transfers<br />
• Cache line pushes for lines containing a single dirty long word.<br />
Figure 7-18 and Figure 7-19 illustrate a flowchart and functional timing diagram for byte,<br />
word, and long-word write bus transfers.<br />
7-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
A31–A4<br />
A1–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
R/W<br />
SIZ1–SIZ0<br />
BS3–BS0<br />
CIOUT<br />
CLA<br />
A3–A2<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
TBI<br />
D31–D0<br />
C1 C2 C3 C4 C5 C6 C7 C8<br />
INHIBITED<br />
LINE READ<br />
LINE LONG LONG LONG<br />
01<br />
LONG-WORD<br />
READ<br />
10 11 00<br />
LONG-WORD<br />
READ<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.<br />
LONG-WORD<br />
READ<br />
Figure 7-17. Burst-Inhibited Line Read Bus Cycle Timing<br />
Bus Operation<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-21
Bus Operation<br />
PROCESSOR SYSTEM<br />
1) SET R/W TO WRITE<br />
2) DRIVE ADDRESS ON A31–A0<br />
3) DRIVE UPA1–UPA0, TT1–TT0, TM2–TM0,<br />
CIOUT, TLN1–TLN0, LOCK, LOCKE, BS3–BS0<br />
4) DRIVE SIZ1–SIZ0 TO BYTE, WORD, OR LONG<br />
5) ASSERT TS FOR ONE BCLK<br />
6) ASSERT TIP<br />
7) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER WRITE PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
8) DRIVE D31–D0 WITH APPROPRIATE DATA<br />
1) THREE-STATE DATA BUS<br />
2) NEGATE LOCK, LOCKE IF NECESSARY<br />
1) NEGATE TIP OR START NEXT CYCLE<br />
1) DECODE ADDRESS<br />
2) LATCH DATA FROM APPROPRIATE BYTE<br />
LANES BASED ON SIZ1–SIZ0, A1–A0, OR<br />
BS3–BS0<br />
3) ASSERT TA FOR ONE BCLK<br />
Figure 7-18. Byte, Word, and Long-Word Write Transfer Flowchart<br />
7-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
R/W<br />
A1–A0<br />
SIZ1–SIZ0<br />
TS<br />
TIP<br />
TA<br />
SAS<br />
BS0<br />
BS1<br />
BS2<br />
BS3<br />
D31–D0<br />
C1 C2<br />
PRE<br />
DRIVE<br />
1 2 0<br />
BYTE<br />
BYTE WRITE<br />
C1 CW C2 C1 C2<br />
PRE<br />
DRIVE<br />
WORD<br />
WORD WRITE<br />
WITH WAIT<br />
PRE<br />
DRIVE<br />
Figure 7-19. Long-Word Write Bus Cycle Timing<br />
Bus Operation<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-23<br />
LONG<br />
LONG-WORD<br />
WRITE<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.
Bus Operation<br />
Clock 1 (C1)<br />
The write cycle starts in C1. During C1, the processor places valid values on the address<br />
bus and transfer attributes. The processor asserts TS during C1 to indicate the beginning<br />
of a bus cycle. If not already asserted from a previous bus cycle, the TIP signal is also<br />
asserted at this time to indicate that a bus cycle is active.<br />
The processor pre-conditions the data bus during C1 to improve AC timing. The process<br />
of pre-conditioning involves reinforcing the logic level that is already at the data pin. If the<br />
voltage level is originally zero volts, nothing is done; if the voltage level is 3.3 V, that voltage<br />
level is reinforced; however, if the voltage level is originally 5 V, the processor drives<br />
that data pin from 5 V down to 3.3 V. Note that no active logic change is done at this time.<br />
The actual logic level change is done in C2. This pre-conditioning affects operation primarily<br />
when using the processor in a 5-V system.<br />
For user and supervisor mode accesses, which the corresponding memory unit translates,<br />
the UPAx signals are driven with the values from the U1 and U0 bits for the area.<br />
The TTx and TMx signals identify the specific access type. The R/W signal is driven low<br />
for a write cycle. CIOUT is asserted if the access is identified as noncachable or if the access<br />
references an alternate address space. Refer to Section 4 Memory Management<br />
Unit for information on the MC68060 and MC68LC060 memory units and Appendix B<br />
MC68EC060 for information on the MC68EC060 memory unit.<br />
Clock 2 (C2)<br />
During C2, the processor negates TS and drives the appropriate bytes of the data bus with<br />
the data to be written. All other bytes are driven with undefined values. The selected device<br />
uses R/W, SIZ1, SIZ0, A1, A0, or BS3–BS0, and CIOUT to register only the required<br />
information from the data bus. With the exception of R/W and CIOUT, these signals also<br />
select any or all of the bytes (D31–D24, D23–D16, D15–D8, and D7–D0). If C2 is not a<br />
wait state (CW), then the selected peripheral device asserts the TA signal.<br />
The MC68060 implements a special mode called the acknowledge termination ignore<br />
state capability to aid in high-frequency designs. In this mode, the processor begins the<br />
sampling of termination signals such as TA after a user-programmed number of BCLK rising<br />
edges has expired. The SAS signal is provided as a status output to indicate which<br />
BCLK rising edge the processor begins to sample the termination signals. If this mode is<br />
disabled, SAS is asserted during C2 to indicate that the processor immediately begins<br />
sampling the terminations signals. Refer to 7.14.1 Acknowledge Termination Ignore<br />
State Capability for details on this special mode.<br />
Assuming that the acknowledge termination ignore state capability is disabled, at the end<br />
of the C2, the processor samples the level of TA, terminating the bus cycle if TA is asserted.<br />
If TA is not recognized asserted at the end of the clock cycle, the processor ignores<br />
the data and inserts a wait state instead of terminating the transfer. The processor continues<br />
to sample TA on successive rising edges of BCLK until TA is recognized asserted.<br />
The data bus then three-states and the bus cycle ends.<br />
When the processor recognizes TA at the rising BCLK edge and terminates the bus cycle,<br />
TIP remains asserted if the processor is ready to begin another bus cycle. Otherwise, the<br />
7-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
processor negates TIP during the next clock. The processor also three-states the data bus<br />
during the next clock following termination of the write transfer.<br />
7.7.4 Line Write Cycles<br />
The processor uses line write bus cycles to access a 16-byte operand for a MOVE16 instruction<br />
and to support cache line pushes. Both burst and burst-inhibited transfers are supported.<br />
Figure 7-20 and Figure 7-22 illustrate a flowchart and functional timing diagram for<br />
a line write bus cycle.<br />
Clock 1 (C1)<br />
The line write cycle starts in C1. During C1, the processor places valid values on the address<br />
bus and transfer attributes. The processor asserts TS during C1 to indicate the beginning<br />
of a bus cycle. If not already asserted from a previous bus cycle, the TIP signal is<br />
also asserted at this time to indicate that a bus cycle is active.<br />
The processor pre-conditions the data bus during C1 to improve AC timing. The process<br />
of pre-conditioning involves reinforcing the logic level that is already at the data pin. If the<br />
voltage level is originally zero volts, nothing is done; if the voltage level is 3.3 V, that voltage<br />
level is reinforced; however, if the voltage level is originally 5 V, the processor drives<br />
that data pin from 5 V down to 3.3 V. Note that no active logic change is done at this time.<br />
The actual logic level change is done in C2. This pre-conditioning affects operation primarily<br />
when using the processor in a 5-V system.<br />
For user and supervisor mode accesses that are translated by the corresponding memory<br />
unit, UPAx signals are driven with the values from the matching U1 and U0 bits. The TTx<br />
and TMx signals identify the specific access type. The R/W signal is driven low for a write<br />
cycle, and the SIZx signals indicate line size. Refer to Section 4 Memory Management<br />
Unit for information on the MC68060 and MC68LC060 memory units and Appendix B<br />
MC68EC060 for information on the MC68EC060 memory unit.<br />
Clock 2 (C2)<br />
During C2, the processor negates TS and drives the data bus with the data to be written.<br />
The selected device uses R/W, SIZ1, SIZ0, or BSx to register the data on the data bus.<br />
Concurrently, the selected device asserts TA and either negates TBI to indicate it can or<br />
asserts TBI to indicate it cannot support a burst transfer.<br />
The MC68060 implements a special mode called the acknowledge termination ignore<br />
state capability to aid in high-frequency designs. In this mode, the processor begins sampling<br />
termination signals such as TA after a user-programmed number of BCLK rising<br />
edges has expired. The SAS signal is provided as a status output to indicate which BCLK<br />
rising edge the processor begins to sample the termination signals. If this mode is disabled,<br />
SAS is asserted during C2 to indicate that the processor immediately begins sampling<br />
the terminations signals. Refer to 7.14.1 Acknowledge Termination Ignore State<br />
Capability for details on this special mode.<br />
Assuming that the acknowledge termination ignore state capability is disabled, the processor<br />
samples the level of TA and TBI at end of C2. If TA is asserted, the transfer terminates.<br />
If TA is not recognized asserted, the processor inserts wait states instead of<br />
terminating the transfer. The processor continues to sample TA and TBI on successive<br />
rising edges of BCLK until TA is recognized asserted. If TBI was negated with the asser-<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-25
Bus Operation<br />
PROCESSOR SYSTEM<br />
1) SET R/W TO WRITE<br />
2) DRIVE ADDRESS ON A31–A0<br />
3) DRIVE UPA1–UPA0, TT1–TT0, TM2–TM0,<br />
CIOUT, TLN1–TLN0, LOCK, LOCKE, BS3–BS0<br />
4) DRIVE SIZ1–SIZ0 TO LINE<br />
5) ASSERT TS FOR ONE BCLK<br />
6) ASSERT TIP<br />
7) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER WRITE PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
8) PLACE DATA ON D31–D0<br />
1) SAMPLE TBI AND TCI<br />
2) INCREMENT A3–A2 IF CLA ASSERTED<br />
TBI ASSERTED TBI NEGATED<br />
1) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION<br />
IGNORE STATE CAPABILITY<br />
DISABLED. ELSE, ASSERT SAS<br />
AFTER WRITE SECONDARY<br />
IGNORE STATE COUNTER HAS<br />
EXPIRED.<br />
1) INCREMENT A3–A2 IF CLA<br />
ASSERTED<br />
2) PLACE DATA ON D31–D0<br />
4 LW DONE<br />
1) NEGATE LOCK, LOCKE IF<br />
NECESSARY<br />
1) NEGATE TIP OR START NEXT<br />
CYCLE<br />
CONTINUE WITH FIG. 7-21<br />
1) DECODE ADDRESS<br />
2) REGISTER DATA FROM D31–D0<br />
3) ASSERT TA FOR ONE BCLK<br />
4) ASSERT CLA TO INCREMENT A3–A2<br />
5) ASSERT TBI OR TCI AS NEEDED<br />
1) DECODE ADDRESS<br />
2) REGISTER DATA FROM D31–D0<br />
3) ASSERT TA FOR ONE CLOCK<br />
4) ASSERT CLA TO INCREMENT A3–A2<br />
4 LW NOT DONE<br />
Figure 7-20. Line Write Cycle Flowchart<br />
tion of TA, the processor continues the cycle with C3. Otherwise, if TBI was asserted, the<br />
line transfer is burst inhibited and the processor writes the remaining three long words using<br />
long-word write bus cycles. In this case, the processor increments A3 and A2 for each<br />
write, and the new address is placed on the address bus for each bus cycle. Refer to 7.7.3<br />
Byte, Word, and Long-Word Write Cycles for information on long-word writes. If no wait<br />
7-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
PROCESSOR SYSTEM<br />
1) INCREMENT A3–A2<br />
2) DRIVE SIZ1–SIZ0 TO LONG<br />
3) ASSERT TS FOR ONE BCLK<br />
4) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER WRITE PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
5) PLACE DATA ON D31–D0<br />
1) THREE-STATE D31–D0<br />
2) NEGATE LOCK, LOCKE IF NECESSARY<br />
1) NEGATE TIP OR START NEXT CYCLE<br />
CONTINUED FROM FIGURE 7-20<br />
4 LW DONE<br />
1) DECODE ADDRESS<br />
2) REGISTER DATA FROM D31–D0<br />
3) ASSERT TA FOR ONE BCLK<br />
4) NEGATE CLA<br />
4 LW NOT DONE<br />
Figure 7-21. Line Write Burst-Inhibited Cycle Flowchart<br />
Bus Operation<br />
states are generated, a burst-inhibited line write completes in eight clocks instead of the<br />
five required for a burst write.<br />
Clock 3 (C3)<br />
The processor drives the second long word of data on the data bus and holds the address<br />
and transfer attribute signals constant during C3. The selected device either increments<br />
A3 and A2 to reference the next long word, or requests the processor to increment A3 and<br />
A2 via the CLA input.<br />
The selected device then registers this data from the data bus and asserts TA. At the end<br />
of C3, assuming the acknowledge termination ignore state capability is disabled, the processor<br />
samples the level of TA; if TA is asserted, the transfer terminates.<br />
If TA is not recognized asserted at the end of C3, the processor inserts wait states instead<br />
of terminating the transfer. The processor continues to sample TA on successive rising<br />
edges of BCLK until TA is recognized asserted.<br />
Clock 4 (C4)<br />
This clock is identical to C3 except that the value driven on the data bus corresponds to<br />
the third long word of data for the burst.<br />
Clock 5 (C5)<br />
This clock is identical to C3 except that the value driven on the data bus corresponds to<br />
the fourth long word of data for the burst. After the processor recognizes the last TA as-<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-27
Bus Operation<br />
BCLK<br />
A31–A4<br />
A1–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
R/W<br />
SIZ1–SIZ0<br />
BS3–BS0<br />
CIOUT<br />
CLA<br />
A3–A2<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
TBI<br />
D31–D0<br />
C1 C2 C3 C4 C5<br />
PRE<br />
DRIVE<br />
Figure 7-22. Line Write Bus Cycle Timing<br />
sertion and terminates the line write bus cycle, TIP remains asserted if the processor is<br />
ready to begin another bus cycle. Otherwise, the processor negates TIP during the next<br />
clock. The processor also three-states the data bus during the next clock following termination<br />
of the write cycle.<br />
7.7.5 Locked Read-Modify-Write Cycles<br />
01<br />
10 11 00<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.<br />
The locked read-modify-write sequence performs a read, conditionally modifies the data in<br />
the processor, and writes the data out to memory. In the MC68060, this operation can be<br />
indivisible, providing semaphore capabilities for multiprocessor systems. During the entire<br />
7-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
read-modify-write sequence, the MC68060 asserts the LOCK signal to indicate that an indivisible<br />
operation is occurring and asserts the LOCKE signal for the last write bus cycle to<br />
indicate completion of the locked sequence. In addition to LOCK and LOCKE, the MC68060<br />
provides the BGR input to allow external arbiters to indicate to the processor whether or not<br />
to break a locked sequence. Refer to 7.11 Bus Arbitration for details on the bus arbitration<br />
protocol.<br />
The external arbiter can use the LOCK, LOCKE, and/or BGR to prevent arbitration of the<br />
bus during locked processor sequences. External bus arbitrations can use LOCKE to support<br />
bus arbitration between consecutive read-modify-write cycles. A read-modify-write<br />
operation is treated as noncachable. If the access hits in the data cache, it invalidates a<br />
matching valid entry and pushes a matching dirty entry. The read-modify-write transfer<br />
begins after the line push (if required) is complete; however, LOCK may assert during the<br />
line push bus cycle.<br />
The TAS, CAS, and MOVEC of BUSCR instructions are the only MC68060 instructions that<br />
utilize read-modify-write transfers. Some page descriptor updates during translation table<br />
searches also use read-modify-write transfers. Refer to Section 4 Memory Management<br />
Unit for information about table searches.<br />
The read-modify-write transfer for the CAS instruction in the MC68060 is similar to that of<br />
the MC68040. If an operand does not match one of these instructions, the MC68060 executes<br />
a single write transfer to terminate the locked sequence with LOCKE asserted. For the<br />
CAS instruction, the value read from memory is written back. Figure 7-23 illustrates a functional<br />
timing diagram for a TAS instruction read-modify-write bus transfer.<br />
Clock 1 (C1)<br />
The read cycle starts in C1. During C1, the processor places valid values on the address<br />
bus and transfer attributes. LOCK is asserted to identify a locked read-modify-write bus<br />
cycle. For user and supervisor mode accesses, which the corresponding memory unit<br />
translates, the UPAx signals are driven with the values from the matching U1 and U0 bits.<br />
The TTx and TMx signals identify the specific access type. R/W is driven high for a read<br />
cycle. CIOUT is asserted if the access is identified as noncachable. The processor asserts<br />
TS during C1 to indicate the beginning of a bus cycle. If not already asserted from a previous<br />
bus cycle, the TIP signal is also asserted at this time to indicate that a bus cycle is<br />
active. Refer to Section 4 Memory Management Unit for information on the MC68060<br />
and MC68LC060 memory units and Appendix B MC68EC060 for information on the<br />
MC68EC060 memory unit.<br />
Clock 2 (C2)<br />
During C2, the processor negates TS. The selected device uses R/W, SIZ1, SIZ0, A1, and<br />
A0 or BSx, to place its information on the data bus. With the exception of R/W, these signals<br />
also select any or all of the data bus bytes (D24–D31, D16–D23, D15–D8, and D7–<br />
D0).<br />
Concurrently, the selected device asserts TA. At the end of the C2, assuming that the acknowledge<br />
termination ignore state capability is disabled, the processor samples the level<br />
of TA and registers the current value on the data bus. If TA is asserted, the read transfer<br />
terminates and the registered data is passed to the appropriate memory unit. If TA is not<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-29
Bus Operation<br />
BCLK<br />
A31–A2<br />
A1–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
R/W<br />
SIZ1–SIZ0<br />
BS3–BS0<br />
CIOUT<br />
LOCK<br />
LOCKE<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
D31–D0<br />
C1 C2 CI C3 C4<br />
LONG<br />
LOCKED TRANSFER<br />
PRE<br />
DRIVE<br />
NOTE: It is assumed that the acknowledge termination ignore state capability is disabled.<br />
Figure 7-23. Locked Bus Cycle for TAS Instruction Timing<br />
recognized asserted, the processor ignores the data and appends a wait state instead of<br />
terminating the transfer. The processor continues to sample TA on successive rising edges<br />
of BCLK until TA is recognized as asserted. The registered data is then passed to the<br />
appropriate memory unit. If more than one read cycle is required to read in the operand(s),<br />
C1 and C2 are repeated accordingly.<br />
7-30 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
When the processor recognizes TA at the end of the last read transfer for the locked bus<br />
cycle, it negates TIP during the first half of the next clock.<br />
Clock Idle (CI)<br />
The processor does not assert any new control signals during the idle clock states, but it<br />
may begin the modify portion of the sequence at this time. The R/W signal remains in the<br />
read mode until C3 to prevent bus conflicts with the preceding read portion of the cycle<br />
and the data bus is not driven until C4.<br />
Clock 3 (C3)<br />
During C3, the processor places valid values on the address bus and transfer attributes<br />
and drives R/W low for a write cycle. The processor asserts TS to indicate the beginning<br />
of a bus cycle. The TIP signal is also asserted at this time to indicate that a bus cycle is<br />
active. LOCKE is asserted during C3 for the last write bus cycle of the locked sequence.<br />
If multiple write transfers are required for misaligned operands or multiple operands,<br />
LOCKE is asserted only for the final write transfer.<br />
The processor pre-conditions the data bus during C3 to improve AC timing. The process<br />
of pre-conditioning involves reinforcing the logic level that is already at the data pin. If the<br />
voltage level is originally zero volts, nothing is done; if the voltage level is 3.3 V, that voltage<br />
level is reinforced; however, if the voltage level is originally 5 V, the processor drives<br />
that data pin from 5 V down to 3.3 V. Note that no active logic change is done at this time.<br />
The actual logic level change is done in C4. This pre-conditioning affects operation primarily<br />
when using the processor in a 5-V system.<br />
Clock 4 (C4)<br />
During C4, the processor negates TS and drives the appropriate bytes of the data bus with<br />
the data to be written. All other bytes are driven with undefined values. The selected device<br />
uses R/W, SIZ1, SIZ0, A1, and A0 or BSx, to register the information on the data bus.<br />
Any or all of the data bus bytes (D31–D24, D23–D16, D15–D8, and D7–D0) are selected<br />
by SIZ1, SIZ0, A1, and A0 or BSx. Concurrently, the selected device asserts TA. Assuming<br />
that the acknowledge termination ignore state capability is disabled, the processor<br />
samples the level of TA; if TA is asserted, the bus cycle terminates. If TA is not recognized<br />
asserted at the end of C4, the processor appends a wait state instead of terminating the<br />
transfer. The processor continues to sample the TA signal on successive rising edges of<br />
BCLK until it is recognized asserted.<br />
When the processor recognizes TA at the rising edge of BCLK, the bus cycle is terminated,<br />
but TIP remains asserted if the processor is ready to begin another bus cycle. Otherwise,<br />
the processor negates TIP during the next clock. The processor also three-states<br />
the data bus during the next clock following termination of the write cycle. When the last<br />
write transfer is terminated, LOCKE is negated. The processor also negates LOCK if the<br />
next bus cycle is not a read-modify-write operation.<br />
7.7.6 Emulating CAS2 and CAS Misaligned<br />
The CAS2 and CAS (with misaligned operands) are not supported in hardware by the<br />
MC68060. If these instructions are encountered, an unimplemented integer exception is<br />
taken. Once the opcode for a CAS2 or CAS is decoded, the MOVEC instruction to the<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-31
Bus Operation<br />
BUSCR is used to control the LOCK and LOCKE outputs. Refer to 7.4 Bus Control Register<br />
for the format of the BUSCR. Emulation of these instructions is done as part of the<br />
MC68060 software package (<strong>M68060</strong>SP). Refer to Appendix C MC68060 Software Package<br />
for more information.<br />
7.7.7 Using CLA to Increment A3 and A2<br />
The MC68060 provides the capability to cycle long-word address bits A3, A2 based on the<br />
CLA signal, which should assist in supporting high-speed DRAM systems. CLA may also be<br />
used to support bursting for slaves which do not burst.<br />
The processor begins sampling CLA immediately following the BCLK rising edge that<br />
causes TS to assert. The initial address of the line transfer is that of the first requested or<br />
needed long word and the attributes are those of the line transfer. After each BCLK rising<br />
edge when CLA is asserted, the long-word address (A3, A2) increments in circular wraparound<br />
fashion. If CLA is negated, A3, A2 does not change, but remains fixed, as on the<br />
MC68040 processor. Since CLA is not an acknowledge termination signal, it is not affected<br />
by the acknowledge termination ignore state capability, if that mode is enabled. Also note<br />
that the A3, A2 increments in a circular wrap around fashion for as many times as CLA is<br />
asserted about a rising BCLK edge.<br />
Figure 7-24 shows how CLA may be used for a high-speed DRAM design. In this figure, the<br />
DRAM design requires a means of cycling A3, A2 before TA is asserted to the processor.<br />
CLA provides a method of avoiding a delay which would otherwise be incurred with the use<br />
of an external medium-scale integration (MSI) counter. W0 to W3 represent A3, A2 incrementing.<br />
C0 to C3 represent the column address sequencing caused by the change of A3,<br />
A2. The timing diagram represents a 5:3:3:3 design, which is feasible with a full-speed 50-<br />
MHz clock and 65-ns page-mode DRAMs.<br />
7.8 ACKNOWLEDGE CYCLES<br />
Bus transfers with transfer type signals TT1 and TT0 = $3 are classified as acknowledge bus<br />
cycles. The following paragraphs describe interrupt acknowledge, breakpoint acknowledge,<br />
and LPSTOP broadcast bus cycles that use this encoding.<br />
7.8.1 Interrupt Acknowledge Cycles<br />
When a peripheral device requires the services of the MC68060 or is ready to send information<br />
that the processor requires, it can signal the processor to take an interrupt exception.<br />
The interrupt exception transfers control to a routine that responds appropriately. The<br />
peripheral device uses the interrupt priority level signals (IPLx) to signal an interrupt condition<br />
to the processor and to specify the priority level for the condition. Refer to Section 8<br />
Exception Processing for a discussion on the IPLx levels and IPEND.<br />
The status register (SR) of the MC68060 contains an interrupt priority mask (I2–I0 bits). The<br />
value in the interrupt mask is the highest priority level that the processor ignores. When an<br />
interrupt request has a priority higher than the value in the mask, the processor makes the<br />
request a pending interrupt. IPLx must maintain the interrupt request level until the<br />
MC68060 acknowledges the interrupt to guarantee that the interrupt is recognized. The<br />
MC68060 continuously samples IPLx on consecutive rising edges of CLK to synchronize<br />
7-32 <strong>M68060</strong> USER’S MANUAL MOTOROLA
CLK<br />
TS<br />
TA<br />
CLA<br />
A3–A2<br />
DATA<br />
(WRITE CYCLE)<br />
DATA<br />
(READ CYCLE)<br />
RAS<br />
CAS<br />
DRAM ADDRESS<br />
ROW C0 C1 C2 C3 C0<br />
Figure 7-24. Using CLA in a High-Speed DRAM Design<br />
Bus Operation<br />
and debounce these signals. An interrupt request that is held constant for two consecutive<br />
CLK periods is considered a valid input. Although the protocol requires that the request<br />
remain until the processor runs an interrupt acknowledge cycle for that interrupt value, an<br />
interrupt request that is held for as short a period as two CLK cycles can be potentially recognized.<br />
Figure 7-25 is a flowchart of the procedure for a pending interrupt condition.<br />
OTHERWISE<br />
W0 W1 W2 W3 W0<br />
RESET<br />
SAMPLE AND SYNCHRONIZE<br />
IPL2–IPL0<br />
ASSERT IPEND<br />
INTERRUPT LEVEL ><br />
I2–I0,<br />
OR TRANSITION ON LEVEL 7<br />
Figure 7-25. Interrupt Pending Procedure<br />
The MC68060 asserts IPEND when an interrupt request is pending. Figure 7-26 illustrates<br />
the assertion of IPEND relative to the assertion of an interrupt level on the IPLx signals.<br />
IPEND signals external devices that an interrupt exception will be taken at an upcoming<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-33
Bus Operation<br />
instruction boundary (following any higher priority exception). The IPEND signal negates<br />
after the interrupt acknowledge bus cycle.<br />
CLK<br />
IPL2–IPL0<br />
IPEND<br />
IPLx RECOGNIZED<br />
IPLx SYNCHRONIZED<br />
COMPARE REQUEST WITH MASK IN SR<br />
ASSERT IPEND<br />
Figure 7-26. Assertion of IPEND<br />
IPEND is intended to provide status information, and must not be used to replace the interrupt<br />
acknowledge cycle. As such, normal applications do not rely on IPEND to disable interrupts.<br />
Applications that use IPEND as a replacement for the interrupt acknowledge cycle are<br />
neither recommended nor supported.<br />
The MC68060 takes an interrupt exception for a pending interrupt within one instruction<br />
boundary after processing any other pending exception with a higher priority. Thus, the<br />
MC68060 executes at least one instruction in an interrupt exception handler before recognizing<br />
another interrupt request. The following paragraphs describe the various kinds of<br />
interrupt acknowledge bus cycles that can be executed as part of interrupt exception processing.<br />
Table 7-4 provides a summary of the possible interrupt acknowledge terminations<br />
and the exception processing results. Note that TRA must always be negated for proper<br />
operation in the MC68040 acknowledge termination mode.<br />
Table 7-4. Interrupt Acknowledge Termination Summary<br />
Acknowledge<br />
Termination<br />
Mode<br />
TA TEA TRA AVEC Termination Condition<br />
Either High High High Don’t Care Insert Wait States<br />
MC68040<br />
Native-MC68060<br />
High<br />
Don’t Care<br />
Low<br />
Low<br />
High<br />
Don’t Care<br />
Don’t Care<br />
Take Spurious Interrupt Exception<br />
Don’t Care<br />
Either Low High High High<br />
Register Vector Number on D7–D0 and Take Interrupt<br />
Exception<br />
Either Low High High Low Take Autovectored Interrupt Exception<br />
MC68040<br />
Native-MC68060<br />
Low<br />
Don’t Care<br />
Low<br />
High<br />
High<br />
Low<br />
Don’t Care<br />
Retry Interrupt Acknowledge Cycle<br />
Don’t Care<br />
MC68040 Don’t Care Don’t Care Low Don’t Care Illegal Combination, Unsupported<br />
7-34 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
7.8.1.1 INTERRUPT ACKNOWLEDGE CYCLE (TERMINATED NORMALLY). When the<br />
MC68060 processes an interrupt exception, it performs an interrupt acknowledge bus cycle<br />
to obtain the vector number that contains the starting location of the interrupt exception handler.<br />
Some interrupting devices have programmable vector registers that contain the interrupt<br />
vectors for the exception handlers they use. Other interrupting conditions or devices<br />
cannot supply a vector number and use the autovector bus cycle described in 7.8.1.2<br />
Autovector Interrupt Acknowledge Cycle.<br />
The interrupt acknowledge bus cycle is a read transfer. It differs from a normal read cycle in<br />
the following respects:<br />
• TT1 and TT0 = $3 to indicate an acknowledged bus cycle<br />
• Address signals A31–A0 are set to all ones ($FFFFFFFF)<br />
• TM2–TM0 are set to the interrupt request level (the inverted values of IPLx).<br />
The responding device places the vector number on the lower byte of the data bus during<br />
the interrupt acknowledge bus cycle, and the cycle is terminated normally with TA. Figure 7-<br />
27 and Figure 7-28 illustrate a flowchart and functional timing diagram for an interrupt<br />
acknowledge cycle terminated with TA.<br />
Note that the acknowledge termination ignore state capability is applicable to the interrupt<br />
acknowledge cycle. If enabled, TA and other acknowledge termination signals are ignored<br />
for a user-programmed number of BCLK cycles.<br />
7.8.1.2 AUTOVECTOR INTERRUPT ACKNOWLEDGE CYCLE. When the interrupting<br />
device cannot supply a vector number, it requests an automatically generated vector<br />
(autovector). Instead of placing a vector number on the data bus and asserting TA, the<br />
device asserts the autovector (AVEC) signal with TA to terminate the cycle. AVEC is only<br />
sampled with TA asserted. AVEC can be grounded if all interrupt requests are autovectored.<br />
The vector number supplied in an autovector operation is derived from the interrupt priority<br />
level of the current interrupt. When the AVEC signal is asserted with TA during an interrupt<br />
acknowledge bus cycle, the MC68060 ignores the state of the data bus and internally generates<br />
the vector number, which is the sum of the interrupt priority level plus 24 ($18). There<br />
are seven distinct autovectors that can be used, corresponding to the seven levels of interrupts<br />
available with IPLx signals. Figure 7-29 illustrates a functional timing diagram for an<br />
autovector operation.<br />
Note that the acknowledge termination ignore state capability is applicable to the interrupt<br />
acknowledge cycle. If enabled, AVEC and other acknowledge termination signals are<br />
ignored for a user-programmed number of BCLK cycles.<br />
7.8.1.3 SPURIOUS INTERRUPT ACKNOWLEDGE CYCLE. When a device does not<br />
respond to an interrupt acknowledge bus cycle, spurious with TA, or AVEC and TA, the<br />
external logic typically returns the transfer error acknowledge signal (TEA). In this case, the<br />
MC68060 automatically generates the spurious interrupt vector number 24 ($18) instead of<br />
the interrupt vector number. If operating in the MC68040 acknowledge termination mode,<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-35
Bus Operation<br />
1) IPEND RECOGNIZED. WAIT FOR INSTRUC-<br />
TION BOUNDARY OR LOCK NEGATED<br />
2) SET R/W TO READ<br />
3) DRIVE ADDRESS ON A31–A0 TO $FFFFFFFF<br />
4) DRIVE UPA1–UPA0 = 0<br />
5) DRIVE TT1–TT0 = 3<br />
6) DRIVE TM2–TM0 = INTERRUPT LEVEL<br />
7) DRIVE TLN1–TLN0 = 0<br />
8) ASSERT BS3<br />
9) NEGATIVE CIOUT, LOCK, LOCKE, BS2–BS0<br />
10) DRIVE SIZ1–SIZ0 TO BYTE<br />
11) ASSERT TS FOR ONE BCLK<br />
12) ASSERT TIP<br />
13) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER READ PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) IF NORMAL TERMINATION (TA ONLY) WITH<br />
AVEC ASSERTED, USE VECTORS 25 TO 31,<br />
DEPANDING ON INTERRUPT LEVEL<br />
2) IF NORMAL TERMINATION (TA ONLY) WITH<br />
AVEC NEGATED, USE VECTOR GIVEN IN<br />
D7–D0<br />
3) IF BUS ERROR TERMINATION, USE VEC-<br />
TOR 24<br />
4) IF RETRY TERMINATION, RETRY IACK<br />
CYCLE<br />
1) NEGATE TIP OR START NEXT CYCLE<br />
Figure 7-27. Interrupt Acknowledge Cycle Flowchart<br />
and if TA and TEA are both asserted, the processor retries the cycle. If operating in native-<br />
MC68060 acknowledge termination mode, a retry is indicated by the assertion of TRA.<br />
Note that the acknowledge termination ignore state capability is applicable to the interrupt<br />
acknowledge cycle. If enabled, TA, TEA, TRA, and other acknowledge termination signals<br />
are ignored for a user-programmed number of BCLK cycles.<br />
7.8.2 Breakpoint Acknowledge Cycle<br />
1) ASSERT IPL2–IPL0 SUCH THAT INTERRUPT<br />
LEVEL GREATER THAN MASK LEVEL IN SR<br />
1) DECODE ADDRESS AND ATTRIBUTES<br />
2) EITHER PLACE VECTOR ON D7–D0 OR<br />
ASSERT AVEC<br />
3) ASSERT TA, TEA, OR TRA FOR ONE BCLK<br />
1) THREE-STATE D31–D0<br />
2) NEGATE AVEC IF NECESSARY<br />
The execution of a BKPT instruction generates the breakpoint acknowledge cycle. An<br />
acknowledged access is a read bus cycle and is indicated with TT1, TT0 = $3, address A31–<br />
A0 = $00000000, and TM2–TM0 = $0. When the external device terminates the cycle with<br />
either TA or TEA, the processor takes an illegal instruction exception. A retry termination<br />
simply retries the breakpoint acknowledge cycle. Figure 7-30 and Figure 7-31 illustrate a<br />
flowchart and functional timing diagram for a breakpoint acknowledge bus cycle.<br />
7-36 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TT1–TT0<br />
UPA1–UPA0<br />
SIZ1–SIZ0<br />
R/W<br />
TM2–TM0<br />
BS2–BS0<br />
BS3<br />
CIOUT<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
AVEC<br />
D31–D8<br />
D7–D0<br />
C1 C2<br />
BYTE<br />
INTERRUPT LEVEL<br />
INTERRUPT<br />
ACKNOWLEDGE<br />
VECTOR #<br />
C1 C2<br />
WRITE STACK<br />
Figure 7-28. Interrupt Acknowledge Bus Cycle Timing<br />
Bus Operation<br />
Note that the acknowledge termination ignore state capability is applicable to the breakpoint<br />
acknowledge cycle. If enabled, TA, TEA, and TRA are ignored for a user-programmed number<br />
of BCLK cycles.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-37
Bus Operation<br />
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TT1–TT0<br />
UPA1–UPA0<br />
SIZ1–SIZ0<br />
R/W<br />
TM2–TM0<br />
BS2–BS0<br />
BS3<br />
CIOUT<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
AVEC<br />
D31–D0<br />
C1 C2<br />
BYTE<br />
INTERRUPT LEVEL<br />
INTERRUPT<br />
ACKNOWLEDGE<br />
AUTOVECTORED<br />
C1 C2<br />
WRITE STACK<br />
Figure 7-29. Autovector Interrupt Acknowledge Bus Cycle Timing<br />
7.8.2.1 LPSTOP BROADCAST CYCLE. The execution of an LPSTOP instruction generates<br />
the LPSTOP broadcast cycle. This access is a write bus cycle and is indicated with<br />
TT1, TT0 = $3, A31–A0 = $FFFFFFFE, and TM2–TM0 = $0. When an external device terminates<br />
the cycle with either TA or TEA, the processor enters the low-power stop mode. A<br />
7-38 <strong>M68060</strong> USER’S MANUAL MOTOROLA
PROCESSOR SYSTEM<br />
1) SET R/W TO READ<br />
3) DRIVE ADDRESS ON A31–A0 TO $00000000<br />
4) DRIVE UPA1–UPA0 = 0<br />
5) DRIVE TT1–TT0 = 3<br />
6) DRIVE TM2–TM0 = 0<br />
7) DRIVE TLN1–TLN0 = 0<br />
8) ASSERT BS0<br />
9) NEGATIVE CIOUT, LOCK, LOCKE, BS3–BS1<br />
10) DRIVE SIZ1–SIZ0 TO BYTE<br />
11) ASSERT TS FOR ONE BCLK<br />
12) ASSERT TIP<br />
13) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED. ELSE,<br />
ASSERT SAS AFTER READ PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) IF NORMAL OR BUS ERROR TERMINATION<br />
TAKE EXCEPTION USING VECTOR 4<br />
(ILLEGAL INSTRUCTION EXCEPTION<br />
VECTOR) AFTER COMPLETION OF BUS<br />
CYCLE<br />
2) IF RETRY TERMINATION, RETRY BREAK-<br />
POINT ACKNOWLEDGE CYCLE<br />
1) NEGATE TIP OR START NEXT CYCLE<br />
2) INITIATE EXCEPTION PROCESSING<br />
1) DECODE ADDRESS AND ATTRIBUTES<br />
2) ASSERT TA, TEA, OR TRA FOR ONE BCLK<br />
Figure 7-30. Breakpoint Interrupt Acknowledge Cycle Flowchart<br />
Bus Operation<br />
retry termination simply retries the LPSTOP broadcast cycle. The lower data bits D15–D0<br />
are driven with the LPSTOP immediate word value and the upper data bits D31–D16 are<br />
driven high. After a number of CLK cycles, PSTx change to $16. The timing of when the<br />
PSTx signals are updated relative to the LPSTOP broadcast cycle is undefined.<br />
Once the LPSTOP broadcast cycle is finished, no bus arbitration activity is performed by the<br />
MC68060. Furthermore, it is imperative that no alternate master bus activity be done from<br />
the time the LPSTOP broadcast cycle is finished to when the LPSTOP encoding is indicated<br />
by PSTx. For systems that require the MC68060 to be three-stated when in the LPSTOP<br />
mode, the bus must be arbitrated away during the LPSTOP broadcast cycle. This is easily<br />
achieved by having the BG input negated at the same time as TA or TEA. For additional<br />
power savings, CLK may be stopped in the low state while in the LPSTOP mode. Systems<br />
must ensure that CLK only be stopped when the PSTx signals indicate $16.<br />
Figure 7-32 illustrates a flowchart of the LPSTOP broadcast cycle. Figure 7-33 and Figure<br />
7-34 illustrate functional timing diagrams for an LPSTOP broadcast cycle as a function of<br />
BG.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-39
Bus Operation<br />
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TT1–TT0<br />
UPA1–UPA0<br />
SIZ1–SIZ0<br />
R/W<br />
TM2–TM0<br />
BS3–BS1<br />
BS0<br />
CIOUT<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
D31–D0<br />
C1 C2<br />
BYTE<br />
BREAKPOINT<br />
ACKNOWLEDGE<br />
C1 C2<br />
WRITE STACK<br />
Figure 7-31. Breakpoint Interrupt Acknowledge Bus Cycle Timing<br />
To exit the LPSTOP mode, the processor CLK must be restarted for at least eight CLK and<br />
two BCLK periods prior to asserting either the RSTI or generating an interrupt. It is imperative<br />
before asserting RSTI or generating the interrupt no alternate master activity be done<br />
until the processor begins exception processing for either the reset or interrupt. Additionally,<br />
the following control signals must be pulled-up or negated during this time: BB, TRA, TA,<br />
TEA, CLA, BGR, BG, SNOOP, AVEC, MDIS, CDIS, TCI, and TBI. The processor uses the<br />
PSTx encoding of $18 to indicate exception processing.<br />
7-40 <strong>M68060</strong> USER’S MANUAL MOTOROLA
PROCESSOR SYSTEM<br />
1) SET R/W TO WRITE<br />
2) DRIVE ADDRESS ON A31–A0 TO $FFFFFFFF<br />
3) DRIVE UPA1–UPA0 = 0<br />
4) DRIVE TT1–TT0 = 3<br />
5) DRIVE TM2–TM0 = 0<br />
6) DRIVE TLN1–TLN0 = 0<br />
7) ASSERT BS3–BS2<br />
8) NEGATE CIOUT, LOCK, LOCKE, BS1–BS0<br />
9) DRIVE SIZ1–SIZ0 TO BYTE<br />
10) ASSERT TS FOR ONE BCLK<br />
11) ASSERT TIP<br />
12) DRIVE D15–D0 TO IMMEDIATE VALUE<br />
13) ASSERT SAS IMMEDIATELY IF<br />
ACKNOWLEDGE TERMINATION IGNORE<br />
STATE CAPABILITY DISABLED; ELSE,<br />
ASSERT SAS AFTER WRITE PRIMARY<br />
IGNORE STATE COUNTER HAS EXPIRED<br />
1) IF NORMAL OR BUS ERROR TERMINATION<br />
ENTER LPSTOP MODE AFTER COMPLETION<br />
OF BUS CYCLE<br />
2) IF RETRY TERMINATION, RETRY LPSTOP<br />
BROADCAST CYCLE<br />
1) NEGATE TIP<br />
2) THREE-STATE ENTIRE BUS IF BG NEGATED<br />
AT BUS CYCLE TERMINATION; ELSE, DRIVE<br />
BUS SIGNALS HIGH<br />
1) PERFORM INTERNAL CLEANUP<br />
2) ENTER LPSTOP MODE<br />
3) DRIVE PST4–PST0 = $16<br />
1) DECODE ADDRESS AND ATTRIBUTES<br />
2) ASSERT TA, TEA, OR TRA FOR ONE BCLK<br />
3) DRIVE BG<br />
4) TEMPORARILY CEASE ALL ALTERNATE<br />
MASTER ACTIVITY<br />
1) CONTINUE ALTERNATE MASTER ACTIVITY<br />
AS NECESSARY WHEN PST4–PST0 = $16<br />
2) STOP CLK AT LOW STATE IF NEEDED<br />
3) BUS ARBITRATION MUST RECOGNIZE<br />
THAT PROCESSOR DOES NOT PERFORM<br />
TS-BTT TRACKING WHILE IN LPSTOP MODE<br />
Figure 7-32. LPSTOP Broadcast Cycle Flowchart<br />
Bus Operation<br />
In normal applications, the requirement to keep the above-mentioned control signals<br />
negated while exiting the LPSTOP condition should be easy to meet, since most of these<br />
signals should already have pullup resistors and keeping alternate master activity from<br />
occurring would allow the pullup resistors to keep these control signals negated. However,<br />
strict compliance for the BGR and AVEC signals is not necessary because these signals are<br />
significant only during locked sequences (BGR) and interrupt acknowledge cycles (AVEC),<br />
neither of which is pending when exiting the LPSTOP condition.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-41
Bus Operation<br />
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TT1–TT0<br />
SIZ1–SIZ0<br />
R/W<br />
TM2–TM0<br />
BS1–BS0<br />
BS3–BS2<br />
CIOUT<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
D15–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
PST4–PST0<br />
C1 C2<br />
$FFFFFFFE<br />
PRE<br />
DRIVE<br />
WORD<br />
LPSTOP<br />
BROADCAST<br />
NO ALTERNATE MASTER ACTIVITY ALLOWED<br />
CLK MAY BE<br />
STOPPED LOW<br />
Figure 7-33. LPSTOP Broadcast Bus Cycle Timing, BG Negated<br />
7-42 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
$16
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TT1–TT0<br />
SIZ1–SIZ0<br />
R/W<br />
TM2–TM0<br />
BS1–BS0<br />
BS3–BS2<br />
CIOUT<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
D15–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
PST4–PST0<br />
C1 C2<br />
$FFFFFFFE<br />
PRE<br />
DRIVE<br />
WORD<br />
LPSTOP<br />
BROADCAST<br />
NO ALTERNATE MASTER ACTIVITY ALLOWED<br />
Figure 7-34. LPSTOP Broadcast Bus Cycle Timing, BG Asserted<br />
Bus Operation<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-43<br />
$16<br />
CLK MAY BE<br />
STOPPED LOW
Bus Operation<br />
Figure 7-35 illustrates a flowchart for exiting the LPSTOP mode, and Figure 7-36 illustrates<br />
the bus activity when exiting the LPSTOP mode, assuming that an interrupt is used to<br />
awaken the processor and that the bus is initially three-stated.<br />
1) PERFORM INTERNAL WAKE-UP<br />
2) BEGIN EXCEPTION PROCESSING<br />
3) DRIVE PST4–PST0 = $18 (EXCEPTION<br />
PROCESSING)<br />
RESET<br />
PROCESSOR SYSTEM<br />
INTERRUPT<br />
1) PERFORM INTERRUPT<br />
ACKNOWLEDGE CYCLE TO<br />
GET VECTOR NUMBER<br />
2) PLACE STACK FRAME ON<br />
SYSTEM STACK<br />
1) FETCH INITIAL SYSTEM STACK<br />
POINTER FROM VECTOR<br />
TABLE<br />
1) FETCH PROGRAM COUNTER FROM<br />
VECTOR TABLE<br />
2) PREFETCH INSTRUCTIONS OF APPRO-<br />
PRIATE EXCEPTION HANDLER<br />
3) EXECUTE FIRST INSTRUCTION OF APPRO-<br />
PRIATE EXCEPTION HANDLER<br />
1) BEGIN TO OSCILLATE CLK FOR AT LEAST<br />
8 CLKS PLUS 2 BCLKS<br />
2) TEMPORARILY CEASE ALL ALTERNATE<br />
MASTER ACTIVITY<br />
3) NEGATE BB, TRA, TEA, TA, CLA, BGR, BG,<br />
SNOOP, AVEC, MDIS, CDIS, TCI, AND TBI.<br />
4) ASSERT RSTI OR ASSERT IPL2–IPL0 TO<br />
GREATER THAN INTERRUPT MASK LEVEL<br />
1) ASSERT BG AFTER PST4–PST0 = $18<br />
2) CONTINUE ALTERNATE MASTER<br />
ACTIVITY AS NECESSARY<br />
1) RESPOND TO INTERRUPT ACKNOWLEDGE<br />
BUS CYCLE AS APPROPRIATE<br />
2) PERFORM NORMAL READ/WRITE TO<br />
MEMORY AS REQUESTED BY PROCESSOR<br />
Figure 7-35. Exiting LPSTOP Mode Flowchart<br />
Note that the acknowledge termination ignore state capability is applicable to the LPSTOP<br />
broadcast cycle. If enabled, TA, TEA, and TRA are ignored for a user-programmed number<br />
of BCLK cycles.<br />
7-44 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
TS<br />
TIP<br />
SAS<br />
TA, TEA, TRA,<br />
TCI, TBI, AVEC<br />
SNOOP, BGR,<br />
MDIS, CDIS, CLA<br />
D31–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
PST4–PST0<br />
IPL2–IPL0<br />
CLK READY<br />
FOR MORE<br />
THAN 8 CLKS<br />
AND 2 BCLKS<br />
$16 $18<br />
NO ALTERNATE MASTER ACTIVITY ALLOWED<br />
EXCEPTION<br />
PROCESSING<br />
Figure 7-36. Exiting LPSTOP Mode Timing Diagram<br />
Bus Operation<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-45
Bus Operation<br />
7.9 BUS EXCEPTION CONTROL CYCLES<br />
The MC68060 bus architecture requires assertion of TA from an external device to signal<br />
that a bus cycle is complete. TA is not asserted in the following cases:<br />
• The external device does not respond.<br />
• No interrupt vector is provided.<br />
• Various other application-dependent errors occur.<br />
External circuitry can provide TEA when no device responds by asserting TA within an<br />
appropriate period of time after the processor begins the bus cycle. This allows the cycle to<br />
terminate and the processor to enter exception processing for the error condition. A retry<br />
may be indicated by asserting TEA in combination with TA in the MC68040 acknowledge<br />
termination mode or by asserting TRA if in the native-MC68060 acknowledge termination<br />
mode.<br />
To properly control termination of a bus cycle for a bus error or retry condition, TA and TEA<br />
must be asserted and negated about the same rising edge of BCLK when using the<br />
MC68040 acknowledge termination mode. Table 7-5 lists the control signal combinations<br />
and the resulting bus cycle terminations. Bus error and retry terminations during burst cycles<br />
operate as described in 7.7.2 Line Read Transfer and 7.7.4 Line Write Cycles<br />
7.9.1 Bus Errors<br />
Table 7-5. Termination Result Summary<br />
Acknowledge<br />
Termination<br />
Mode<br />
TA TEA TRA Result<br />
MC68040<br />
Native-MC68060<br />
High<br />
Don’t Care<br />
Low<br />
Low<br />
High<br />
Don’t Care<br />
Bus Error—Terminate and Take Bus Error Exception,<br />
Possibly Deferred<br />
MC68040 1 Native-MC68060<br />
Low Low High<br />
Retry Operation—Terminate and Retry<br />
2 Don’t Care High Low<br />
Either Low High High Normal Cycle Terminate and Continue<br />
Either High High High Insert Wait States<br />
MC68040<br />
NOTES:<br />
Don’t Care Don’t Care Low Illegal operation, Not Supported<br />
1. A retry termination in MC68040-mode is valid only for the first long word of a line transfer and is considered a<br />
bus error termination otherwise. Note that for burst-inhibited line transfers, the resulting long-word bus cycles<br />
are considered part of the original line transfer and would therefore cause a bus error termination as well.<br />
2. A retry termination in native-MC68060-mode is valid only for the first long word of a line transfer it is ignored<br />
otherwise. Note that for burst-inhibited line transfers, the resulting long-word bus cycles are considered part of<br />
the original line transfer and would therefore ignore the retry termination as well.<br />
The system hardware can use the TEA signal to abort the current bus cycle when a fault is<br />
detected. A bus error is recognized during a bus cycle when TA is negated and TEA is<br />
asserted (MC68040 acknowledge termination mode) or during a bus cycle when TEA is<br />
asserted (native-MC68060 acknowledge termination mode). Also, for the MC68040<br />
acknowledge termination mode, a retry termination during the 2nd, 3rd, or 4th long word of<br />
a line transfer is interpreted as a bus error termination. This rule applies also for the second,<br />
third, and fourth long-word transfer on a line transfer that was burst inhibited.<br />
7-46 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
When the processor recognizes a bus error condition for an access, the access is terminated<br />
immediately. A line access that has TEA asserted for one of the four long-word transfers<br />
aborts without completing the remaining transfers, regardless of whether the line<br />
transfer uses a burst or burst-inhibited access.<br />
When a bus cycle is terminated with a bus error, the MC68060 can enter access error<br />
exception processing immediately following the bus cycle, or it can defer processing the<br />
exception. The instruction prefetch mechanism requests instruction words from the instruction<br />
memory unit before it is ready to execute them. If a bus error occurs on an instruction<br />
fetch, the processor does not take the exception until it attempts to use the instruction.<br />
Should an intervening instruction cause a branch or should a task switch occur, the access<br />
error exception for the unused access does not occur. Similarly, if a bus error is detected on<br />
the second, third, or fourth long-word transfer for a line read access, an access error exception<br />
is taken only if the execution unit is specifically requesting that long word. The line is not<br />
placed in the cache, and the processor repeats the line access when another access references<br />
the line. If a misaligned operand spans two long words in a line, a bus error on either<br />
the first or second transfer for the line causes exception processing to begin immediately. A<br />
bus error termination for any write access or read access that reference data specifically<br />
requested by the execution unit causes the processor to begin exception processing immediately.<br />
Refer to Section 8 Exception Processing for details of access error exception processing.<br />
When a bus error terminates an access, the contents of the corresponding cache can be<br />
affected in different ways, depending on the type of access. For a cache line read to replace<br />
a valid instruction or data cache line, the cache line is untouched if the replacement line read<br />
terminates with a bus error. If a dirty data cache line is being replaced, the dirty line is placed<br />
in the push buffer and is eventually written out to memory. This is done whether or not a bus<br />
error occurs during the replacement line read. If any cache push results in a bus error termination,<br />
the cache push data is lost.<br />
Write accesses to memory pages specified as cachable writethrough by the data memory<br />
unit update the corresponding cache line before accessing memory. If a bus error occurs<br />
during a memory access, the cache line remains valid with the new data. For noncachable<br />
precise memory pages, the cache line is not updated if the write cycle terminates with a bus<br />
error. Figure 7-37 illustrates a functional timing diagram of a bus error on a word write<br />
access causing an access error exception. Figure 7-38 illustrates a functional timing diagram<br />
of a bus error on a line read access that does not cause an access error exception.<br />
In general, write cycles that result in bus error termination must be avoided. The MC68060<br />
has write and push buffers to decouple the processor from the system. Before the processor<br />
writes into the write and push buffers, access errors that result from address translation<br />
cache (ATC) faults should have been reported via an access error exception and eventually<br />
fixed by the access error handler. Since the instruction that reports the bus error on the write<br />
cycle usually is not the instruction that causes the write, it is not possible to recover that write<br />
cycle via an instruction restart. Although the fault address indicates the logical address of<br />
the write cycle that incurred the bus error, the write data information is not available in the<br />
access error stack. As such, this access error case is nonrecoverable unless the system is<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-47
Bus Operation<br />
BCLK<br />
A31–A0<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
SIZ1<br />
SIZ0<br />
R/W<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
TEA<br />
D31–D0<br />
Figure 7-37. Word Write Access Bus Cycle Terminated with TEA Timing<br />
implemented with an external device that latches the write data when a bus error terminates<br />
a write cycle.<br />
7.9.2 Retry Operation<br />
C1 C2<br />
PRE<br />
DRIVE<br />
WRITE CYCLE<br />
WORD<br />
C1 C2<br />
WRITE STACK<br />
When an external device asserts both the TA and TEA signals during a bus cycle in the<br />
MC68040 acknowledge termination mode or if an external device asserts TRA with TEA<br />
negated during a bus cycle in the native-MC68060 acknowledge termination mode, the processor<br />
enters the retry bus operation sequence. The processor terminates the bus cycle and<br />
immediately retries the bus cycle using the same access information (address and transfer<br />
attributes). However, if the bus cycle was a cache push operation and the bus is arbitrated<br />
away from the MC68060 before the retry operation with a snoop access during the arbitration<br />
which invalidates the cache push, the processor does not initiate a retry operation. Figure<br />
7-39 illustrates a functional timing diagram for a retry of a read bus transfer.<br />
PRE<br />
DRIVE<br />
7-48 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
A31–A4<br />
A1–A0<br />
A3–A2<br />
CLA<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
SIZ1–SIZ0<br />
R/W<br />
TS<br />
TIP<br />
SAS<br />
TA<br />
TEA<br />
TBI<br />
D31–D0<br />
C1 C2 C3 C4<br />
01<br />
10 11<br />
TEA ENDS BURST—<br />
NO EXCEPTION<br />
TAKEN<br />
Figure 7-38. Line Read Access Bus Cycle Terminated with TEA Timing<br />
Bus Operation<br />
The processor retries any read or write bus cycles of a read-modify-write sequence separately;<br />
LOCK remains asserted during the entire retry sequence. If the last bus cycle of a<br />
locked access is retried, LOCKE remains asserted through the retry of the write bus cycle.<br />
When in the MC68040 acknowledge termination mode, a retry termination on the initial longword<br />
transfer of a line access causes the processor to retry the bus cycle as illustrated in<br />
Figure 7-40. However, the processor interprets a retry bus operation signaled during the<br />
second, third, or fourth long-word transfer of a line burst bus cycle as a bus error and causes<br />
the processor to abort the line transfer. However, when in the native-MC68060 acknowledge<br />
termination mode, a retry termination signaled during the second, third, or fourth long-word<br />
transfers of a line burst bus cycle are ignored.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-49
Bus Operation<br />
BCLK<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
MC68040<br />
ACKNOWLEDGE<br />
TERMINATION<br />
MODE<br />
NATIVE-MC68060<br />
ACKNOWLEDGE<br />
TERMINATION<br />
MODE<br />
A31–A0<br />
R/W<br />
SIZ1–SIZ0<br />
TS<br />
TIP<br />
D31–D0<br />
SAS<br />
TRA<br />
TA<br />
TEA<br />
TRA<br />
TA<br />
TEA<br />
C1<br />
CW<br />
READ CYCLE<br />
RETRY SIGNALED<br />
Figure 7-39. Retry Read Bus Cycle Timing<br />
The MC68060 considers the resulting second, third, and fourth long-word bus cycles of a<br />
burst-inhibited line transfer as part of the original line transfer cycle. Therefore, the MC68060<br />
interprets a retry termination during these bus cycles as though they were part of the original<br />
line transfer, and depending on the acknowledge termination mode, a retry termination is<br />
either interpreted as a bus error (MC68040 mode) or ignored (native-MC68060 mode).<br />
Negating the bus grant (BG) signal on the MC68060 while indicating a retry termination provides<br />
a relinquish and retry operation for any bus cycle that can be retried (see Figure 7-44).<br />
If retrying a bus cycle that is part of a locked sequence of bus cycles, a relinquish and retry<br />
of the bus requires BGR be asserted along with BG negated to cause the processor to abort<br />
any following locked bus cycles that are a part of the locked sequence.<br />
7-50 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
C2<br />
LONG<br />
C1 C2<br />
RETRY<br />
CYCLE
BCLK<br />
MISCELLANEOUS<br />
ATTRIBUTES<br />
MC68040<br />
ACKNOWLEDGE<br />
TERMINATION<br />
MODE<br />
NATIVE-MC68060<br />
ACKNOWLEDGE<br />
TERMINATION<br />
MODE<br />
A31–A0<br />
SIZ1–SIZ0<br />
R/W<br />
TS<br />
TIP<br />
D31–D0<br />
SAS<br />
TRA<br />
TA<br />
TEA<br />
TRA<br />
TA<br />
TEA<br />
7.9.3 Double Bus Fault<br />
C1 C2<br />
LINE<br />
RETRY<br />
SIGNALED<br />
C1<br />
C2 C3<br />
RETRY CYCLE<br />
C4 C5<br />
Figure 7-40. Line Write Retry Bus Cycle Timing<br />
Bus Operation<br />
A double bus fault occurs when an access or address error occurs during the exception processing<br />
sequence, e.g., the processor attempts to stack several words containing information<br />
about the state of the machine while processing an access error exception. If a bus error<br />
occurs during the stacking operation, the second error is considered a double bus fault and<br />
the processor is halted.<br />
The MC68060 indicates a double bus fault condition by continuously driving PSTx with an<br />
encoded value of $1C until the processor is reset. Only an external reset operation can<br />
restart a halted processor. The halted processor releases the external bus by negating BR<br />
and forcing all outputs to a high-impedance state.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-51
Bus Operation<br />
A second access or address error that occurs during execution of an exception handler or<br />
later, does not cause a double bus fault. A bus cycle that is retried does not constitute a bus<br />
error or contribute to a double bus fault. The processor continues to retry the same bus cycle<br />
as long as external hardware requests it.<br />
7.10 BUS SYNCHRONIZATION<br />
The MC68060 integer unit generates access requests to the instruction and data memory<br />
units to support integer and floating-point operations. Both the fetch and write-back<br />
stages of the integer unit pipeline perform accesses to the data memory unit. All read and<br />
write accesses are performed in strict program order. Compared with the MC68040, the<br />
MC68060 is always “serialized’. This feature makes it possible for automatic bus synchronization<br />
without requiring NOPs between instructions to guarantee serialization of reads and<br />
writes to I/O devices.<br />
The instruction restart model used for exception processing in the MC68060 may require<br />
special care when used with certain peripherals. After the operand fetch for an instruction,<br />
an exception that causes the instruction to be aborted can occur, resulting in another access<br />
for the operand after the instruction restarts. For example, an exception could occur after a<br />
read access of an I/O device’s status register. The exception causes the instruction to be<br />
aborted and the register to be read again. If the first read accesses clears the status bits,<br />
the status information is lost, and the instruction obtains incorrect data.<br />
7.11 BUS ARBITRATION<br />
The bus design of the MC68060 provides for one bus master at a time, either the MC68060<br />
or an external device. More than one device having the capability to control the bus can be<br />
attached to the bus. An external arbiter prioritizes requests and determines which device is<br />
granted access to the bus. Bus arbitration is the protocol by which the processor or an external<br />
device becomes the bus master. When the MC68060 is the bus master, it uses the bus<br />
to read instructions and transfer data not contained in its internal caches to and from memory.<br />
When an alternate bus master owns the bus, the MC68060 can be made to monitor the<br />
alternate bus master’s transfer and maintain cache coherency. This capability is discussed<br />
in more detail in 7.12 Bus Snooping Operation.<br />
Like the MC68040, the MC68060 implements an arbitration method in which an external<br />
arbiter controls bus arbitration and the processor acts as a slave device requesting ownership<br />
of the bus from the arbiter. Since the user defines the functionality of the external arbiter,<br />
it can be configured to support any desired priority scheme. For systems in which the<br />
processor is the only possible bus master, the bus can be continuously granted to the processor,<br />
and no arbiter is needed. Systems that include several devices that can become bus<br />
masters require an arbiter to assign priorities to these devices so, when two or more devices<br />
simultaneously attempt to become the bus master, the one having the highest priority<br />
becomes the bus master first. The MC68060 bus interface controller generates bus<br />
requests to the external arbiter in response to internal requests from the instruction and data<br />
memory units.<br />
The MC68060 supports two bus arbitration protocols. These arbitration protocols are mutually<br />
exclusive and must not be mixed in a system. An MC68040-style arbitration protocol is<br />
7-52 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
provided for compatibility with existing MC68040-based ASICs and logic. This arbitration<br />
protocol uses the BR, BG, and BB signals. Bus tenure terminated (BTT) must be ignored by<br />
the external arbiter and pulled high using a separate pullup resistor on the MC68060 pin<br />
when using this arbitration protocol.<br />
In addition to the MC68040-arbitration protocol, a high speed MC68060-arbitration protocol<br />
is introduced to provide arbitration activity at higher frequencies. This arbitration protocol<br />
uses the BR, BG, BTT, and BGR signals. BB must be ignored by the external arbiter and<br />
pulled high using a separate pullup resistor on the MC68060 when using this arbitration protocol.<br />
In either arbitration protocol, the bus arbitration unit in the MC68060 operates synchronously<br />
and transitions between states in which CLK is enabled via CLKEN asserted (on the rising<br />
edge of BCLK). Either arbitration protocol allows arbitration to overlap with bus activity, but<br />
the MC68040-arbitration protocol should not be used at full bus speed. With either arbitration<br />
protocol, each master which can initiate bus cycles must have their TS signals connected<br />
together so that the MC68060 can maintain proper internal state. Note also, when<br />
using the MC68040-arbitration protocol, any alternate master which takes over bus ownership<br />
and initiates bus cycles with the assertion of TS must also assert BB for the time of its<br />
bus tenure.<br />
7.11.1 MC68040-Arbitration Protocol (BB Protocol)<br />
When using the MC68040-arbitration protocol, BTT must be pulled high through a resistor.<br />
Since BTT is also an output, a separate pullup resistor must be used exclusively for BTT.<br />
The MC68060 requests the bus from the external bus arbiter by asserting BR whenever an<br />
internal bus request is pending. The processor continues to assert BR for as long as it<br />
requires the bus. The processor negates BR at any time without regard to the status of BG<br />
and BB. If the bus is granted to the processor when an internal bus request is generated,<br />
BR is asserted simultaneously with transfer start (TS), allowing the access to begin immediately.<br />
The processor always drives BR, and BR cannot be wire-ORed with other devices.<br />
The external arbiter asserts BG to indicate to the processor that it has been granted the bus.<br />
If BG is negated while a bus cycle is in progress, the processor relinquishes the bus at the<br />
completion of the bus cycle, except on locked sequences in which BGR is negated. To guarantee<br />
that the bus is relinquished, BG must be negated prior to the rising edge of the BCLK<br />
in which the last TA, TEA, or TRA is asserted. Note that the bus controller considers the four<br />
long-word bus transfers of a burst-inhibited line transfer to be a single bus cycle and does<br />
not relinquish the bus until completion of the fourth transfer.<br />
Unlike the MC68040 in which the read and write portions of a locked sequence is divisible,<br />
the MC68060 provides a choice via the BGR input. If BGR is asserted when BG is negated<br />
in the middle of a locked sequence, the MC68060 operates like the MC68040 and relinquishes<br />
the bus after the current bus cycle is completed. Otherwise, if BGR is negated when<br />
BG is negated, the MC68060 ignores the negated BG, retains bus ownership, and completes<br />
all bus cycles of the locked sequence before giving up the bus. Systems may use the<br />
BGR input to assign severity of the BG negation. For instance, if bus arbitration is used to<br />
allow for DRAM refresh, it is okay to ignore locked sequences and force the MC68060 to<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-53
Bus Operation<br />
relinquish the bus. But, if the alternate master is another MC68060, it may not be advisable<br />
to allow locked sequences to be broken. Figure 7-46 illustrates BGR functionality on locked<br />
sequences.<br />
When the bus has been granted to the processor in response to the assertion of BR, one of<br />
two situations can occur. In the first situation, the processor monitors BB and TS to determine<br />
when the bus cycle of the alternate bus master is complete and to guarantee that<br />
another master has not already started another bus tenure. After the alternate bus master<br />
negates and three-states BB, the processor asserts BB to indicate explicit bus ownership<br />
and begins the bus cycle by asserting TS. The processor continues to assert BB until the<br />
external arbiter negates BG, after which BB is driven negated at the completion of the bus<br />
cycle, then forced to a high-impedance state. As long as BG is asserted, BB remains<br />
asserted to indicate the bus is owned, and the processor continuously drives the address<br />
bus, attributes, and control signals. The processor negates BR when there are no pending<br />
internal requests to allow the external arbiter to grant the bus to an alternate bus master if<br />
necessary.<br />
In the second situation, the processor samples BB until the alternate master negates BB.<br />
Then the processor takes implicit ownership of the bus. Implicit ownership of the bus occurs<br />
when the processor is granted the bus, but there are no pending bus cycles. The MC68060<br />
does not drive the bus and BB if the bus is implicitly owned. This is different from the<br />
MC68040 which drives the address, attributes, and control signals during implicit ownership<br />
of the bus. If an internal access request is generated, the processor assumes explicit ownership<br />
of the bus and immediately begins an access, simultaneously asserting BB, BR, TIP,<br />
and TS. If the external arbiter keeps BG asserted to the processor, the processor keeps BB<br />
asserted and either executes active bus cycles or drives the address and attributes with<br />
undefined values in-between active bus cycles.<br />
BR can be used by the external arbiter as an indication that the processor needs the bus.<br />
However, there is no guarantee that when the bus is granted to the processor, that a bus<br />
cycle will be performed. At best, BR must be used as status output that the processor needs<br />
the bus, but not as an indication that the processor is in a certain bus arbitration state. Figure<br />
7-41 provides a high-level arbitration diagram that can be used by external arbiters to predict<br />
how the MC68060 operates as a function of external signals, and internal signals. For<br />
instance, note that the relationship between the internal BR and the external BR is best<br />
described as a synchronous delay off BCLK.<br />
Figure 7-41 is a bus arbitration state diagram for the MC68040 bus arbitration protocol.<br />
Table 7-6 lists conditions that cause a change to and from the various states. Table 7-7 lists<br />
a summary of the bus conditions and states.<br />
7-54 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Present<br />
State<br />
Reset<br />
Explicit<br />
Own<br />
End<br />
Tenure<br />
AM<br />
Implicit<br />
AM<br />
Explicit<br />
Implicit<br />
Own<br />
Table 7-6. MC68040-Arbitration Protocol Transition Conditions<br />
Condition RSTI BG<br />
TS<br />
sampled<br />
as an<br />
input<br />
TSI<br />
SNOOP<br />
BB<br />
sampled<br />
as an<br />
input<br />
(BBI)<br />
Internal<br />
Bus<br />
Request<br />
(IBR)<br />
Transfer in<br />
Progress?<br />
End of<br />
Cycle?<br />
Bus Operation<br />
Next State<br />
A1 A — — — — — — — Reset<br />
A2 A A — — — — — — Implicit Own<br />
A3 N N — — — — — — AM Implicit<br />
B1 N N — — — — N — End Tenure<br />
B2 N N — — — — A N Explicit Own<br />
B3 N N — — — — A A End Tenure<br />
B4 N A — — — — — — Explicit Own<br />
C1 N N N — N — — — AM Implicit<br />
C2 N A — — — N — — Implicit Own<br />
C3 N A — — — A — — Explicit Own<br />
C4 N N A — — — — — Violation<br />
C5 N N — — A — — — Violation<br />
D1 N — A A — — — — Snoop<br />
D2 N — A N — — — — AM Explicit<br />
D3 N N N — — — — — AM Implicit<br />
D4 N A N — N N — — Implicit Own<br />
D5 N A N — N A — — Explicit Own<br />
D6 N A N — A — — — AM Explicit<br />
E1 N — A A — — — — Snoop<br />
E2 N — A N — — — — AM Explicit<br />
E3 N — N — A — — — AM Explicit<br />
E4 N A N — N N — — Implicit Own<br />
E5 N A N — N A — — Explicit Own<br />
E6 N N N — N — — — AM Implicit<br />
F1 N N N — — — — — AM Implicit<br />
F2 N A — — — N — — Implicit Own<br />
F3 N A — — — A — — Explicit Own<br />
F4 N N A — — — — — Violation<br />
Snoop G1 — — — — — — — — AM Explicit<br />
Any A — — — — — — — Reset<br />
NOTES:<br />
1) “N” means negated; “A” means asserted.<br />
2) End of Cycle: Whatever terminates a bus transaction whether it is normal, bus error, or retried. Note that ong-word<br />
bus cycles that result from a burst-inhibited line transfer are considered part of that original line transfer.<br />
3) Conditions C4, C5, and F4 indicate that an alternate master has taken ownership without sampling BB as negated.<br />
4) IBR refers to an internal bus request. The output signal BR is a registered version of IBR.<br />
5) BBI refers to BB when sampled as an input.<br />
6) SNOOP denotes the condition in which SNOOP is sampled asserted and TT1 = 0.<br />
7) In this state diagram, BGR is assumed always asserted, hence, bus cycles within a locked sequence are treated no<br />
differently from nonlocked bus cycles, except that the processor takes an extra BCLK period in the end tenure state<br />
to allow for LOCK and LOCKE to negate. If BGR is negated and a locked sequence is in progress, the processor<br />
does not relinquish the bus if BG is negated until the end of the last bus cycle in the locked sequence.<br />
8) The processor does not require a valid acknowledge termination for snooped accesses. The only restriction is that<br />
a snoop cycle be performed at no more than a maximum rate of once every two BCLK cycles. This state diagram<br />
properly emulates this behavior.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-55
Bus Operation<br />
Table 7-7. MC68040-Arbitration Protocol State Description<br />
BBO Bus Status Own State<br />
Not Driven Not Driven No Reset<br />
Not Driven Not Driven No Alternate Master Implicit Own<br />
Not Driven Not Driven No Alternate Master Explicit Own<br />
Not Driven Not Driven Yes Implicit Ownership<br />
Asserted Driven Yes Explicit Ownership<br />
Negated<br />
for One CLK, then<br />
Three-Stated<br />
Stops Being<br />
Driven at End<br />
of State<br />
Yes End Tenure<br />
Not Driven<br />
NOTE:<br />
Not Driven No<br />
Alternate Master Own<br />
and Snooped<br />
BBO represents the component of BB when driven by the MC68060. BBO is either driven<br />
asserted or three-stated; however, BBO is driven negated for one CLK (as opposed to<br />
BCLK) period before three-stating.<br />
The MC68060 can be in any one of seven bus arbitration states during bus operation: reset,<br />
AM-implicit own, AM-explicit own, snoop, implicit ownership, explicit ownership, and the end<br />
tenure states.<br />
The reset state is entered whenever RSTI is asserted in any bus arbitration state, except the<br />
explicit ownership state. For that state, the end tenure state is entered prior to entering the<br />
reset state.This is done to ensure other bus masters are capable of taking the bus away from<br />
the processor when it is reset. When RSTI is negated, the processor proceeds to the implicit<br />
ownership state or alternate master implicit ownership state, depending on BG. If an alternate<br />
master asserts TS or has asserted TS in the past, the processor waits for BTT to assert<br />
(or alternatively, for BB to go from being asserted to being negated) before taking the bus,<br />
even though BG may be asserted to the processor.<br />
The AM-implicit own state denotes the MC68060 does not have ownership (BG negated) of<br />
the bus and is not in the process of snooping an access, and the alternate has not begun its<br />
tenure by asserting TS (alternate master TS or SNOOP negated). In the AM-implicit own<br />
state, the MC68060 does not drive the bus. The processor enters the AM-explicit own state<br />
when TS is asserted by the alternate master. Once in the AM-explicit own state, the processor<br />
waits for the alternate master to transition and negate BB (or alternatively assert BTT)<br />
before recognizing that a change of tenure has occurred. If BG is negated when BB is<br />
negated (or alternatively BTT asserted), the processor assumes that another master has<br />
taken implicit ownership of the bus. Otherwise, if BG is asserted when BB is negated (or BTT<br />
asserted), the processor assumes implicit ownership of the bus.<br />
If an alternate master loses bus ownership when it is in its implicit ownership state, the processor<br />
checks TS. If TS is sampled asserted, the processor interprets this as the alternate<br />
master transitioning to its explicit ownership state, and it does not take over bus ownership.<br />
This operation is different from that of the MC68040, in that external arbiters are required to<br />
check for this boundary condition. However, in order for the processor to properly detect this<br />
boundary condition, it is imperative that the TS of all alternate bus masters be tied together<br />
with the processor’s TS signal<br />
7-56 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BBI<br />
BBO THREE-STATE<br />
BBO<br />
IBR<br />
E3<br />
BCLK<br />
D<br />
E2<br />
E4<br />
G1<br />
Q<br />
AM<br />
EXPLICIT<br />
F2<br />
SNOOP<br />
E1<br />
IMPLICIT<br />
OWN<br />
BB<br />
BR<br />
E6<br />
E5<br />
D6<br />
D2<br />
F1<br />
F3<br />
IBR<br />
BR<br />
BBI<br />
BBO<br />
BB<br />
BCLK<br />
D1<br />
D4<br />
AM<br />
IMPLICIT<br />
Figure 7-41. MC68040-Arbitration Protocol State Diagram<br />
Bus Operation<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-57<br />
D3<br />
D5<br />
EXPLICIT<br />
OWN<br />
= INTERNAL BUS REQUEST SIGNAL<br />
= EXTERNAL BUS REQUEST PIN<br />
= INTERNAL BB SAMPLED AS INPUT<br />
= BB DRIVEN INTERNALLY BY MC68060<br />
= EXTERNAL BB PIN<br />
= VIRTUAL BUS CLOCK DERIVED FROM CLK AND CLKEN<br />
A3<br />
A2<br />
C2<br />
C1<br />
END<br />
TENURE<br />
C3<br />
RESET<br />
B3<br />
B4<br />
A1<br />
B1<br />
B2
Bus Operation<br />
The snoop state is similar to the AM-explicit own state in that the MC68060 does not have<br />
ownership of the bus. The snoop state differs from the AM-explicit own state in that the<br />
MC68060 is in the process of performing an internal snoop operation because the processor<br />
has detected that TS and SNOOP are asserted and TT1 = 0. The snoop state always returns<br />
to the AM-explicit own state.<br />
The implicit ownership state indicates that the MC68060 owns the bus because BG is<br />
asserted to it. The processor, however, is not ready to begin a bus cycle, and it keeps BB<br />
negated and the bus three-stated until an internal bus request occurs.<br />
The MC68060 explicitly owns the bus when the bus is granted to it (BG asserted) and at<br />
least one bus cycle has initiated. The processor asserts BB during this state to indicate the<br />
processor has explicit ownership of the bus. Until BG is negated, the processor retains<br />
explicit ownership of the bus whether or not active bus cycles are being executed. When the<br />
processor is ready to relinquish the bus, it goes through the end tenure state to indicate to<br />
all alternate masters that it is relinquishing the bus. During the end tenure state, BB goes<br />
from being actively asserted to being actively negated for one CLK cycle and then threestated.<br />
While in this state, RSTI is asserted and the processor proceeds to the end tenure<br />
state to inform other bus masters it is relinquishing the bus.<br />
7.11.2 MC68060-Arbitration Protocol (BTT Protocol)<br />
The MC68060-arbitration protocol is different from the MC68040-arbitration protocol in that<br />
BTT is used instead of BB. BTT indicates that the MC68060 has completed a bus tenure<br />
and the bus can now be used by another master. When using the MC68060-arbitration protocol,<br />
BB must be pulled high via a separate pullup resistor since the processor drives BB<br />
during bus tenure times. This pullup resistor must be used solely for BB.<br />
Arbitration within the MC68060 bus interface controller is based on current bus ownership<br />
and the concept that a bus cycle is an atomic entity which cannot be split, though it may be<br />
prematurely terminated. If the bus is currently owned by the processor, it can be owned by<br />
another master only after the completion of the final bus cycle when the processor has<br />
asserted BTT.<br />
If the bus is not currently owned by the processor, it asserts its BR signal as soon as it needs<br />
the bus. Bus mastership is assumed as soon as the assertion of BG is received from the bus<br />
arbiter and the one BCLK period assertion of the bused BTT is detected (or alternately, the<br />
transition and negation of BB is detected at a rising BCLK edge), indicating the previous<br />
master has terminated its tenure and relinquished the bus. If the MC68060 still has a need<br />
to use the bus when BG is received, it assumes bus mastership, asserts TS, and starts a<br />
bus cycle. Note the MC68060 negates its BR signal if, due to internal state, it no longer<br />
needs to use the bus at that moment in time. It negates its BR signal at the same time it<br />
asserts the TS signal if the bus is only needed for one bus cycle.<br />
BTT is connected to all masters in a system to give notice of the termination of bus tenure<br />
by the MC68060 processor. BTT is asserted by the MC68060 after it has lost right of ownership<br />
to the bus by the negation of BG and is ready to end usage of the bus. After the final<br />
termination acknowledgment of the final bus cycle when the MC68060 has lost bus ownership,<br />
the processor asserts BTT for a one BCLK period, negates BTT for a one BCLK period,<br />
7-58 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
and then three-states BTT. If the external bus arbiter has granted the bus to an alternate<br />
master by the assertion of BG to that master, that master, using this protocol, can start a bus<br />
cycle on the rising BCLK edge in which it detects the assertion of BTT. The previous master<br />
can be driving BTT negated at the same time the current master is starting a bus cycle<br />
because the current master will still have its BTT signal three-stated. Since the alternate<br />
master does not drive BTT in this protocol until it has finished its tenure, there is no conflict<br />
with tying all master’s BTT signals together. This is different than the MC68040-arbitration<br />
protocol which used BB to continuously indicate to other bus masters the bus was being<br />
used by the MC68040.<br />
When a processor using the MC68040-arbitration protocol is finished using the bus, BB has<br />
to be driven negated for a short period of time and then three-stated. The use of the BTT<br />
protocol works much better than the BB protocol in a high-speed bus environment because<br />
the kind of drive (asserted, negated, or three-stated) of BTT can be synchronous with the<br />
clock. Arbiters do not need to be changed going from a MC68040 system to a MC68060 system,<br />
since arbiters do not need to sample the BB signal in a MC68040 system or BTT in a<br />
MC6060 system, but need only use BR, BG, and perhaps LOCK to determine bus ownership<br />
rights. Masters need only sample BB or BTT and TS and BG to determine the proper<br />
times to take over ownership of the bus. In cases where the MC68060 has implicit bus ownership<br />
after it has finished all needed bus cycles, BTT remains three-stated until BG is<br />
negated and the MC68060 is forced off the bus. For this case, in the next BCLK period after<br />
the MC68060 detects the negation of BG, it asserts BTT for one BCLK period, negates BTT<br />
for one BCLK period, and then three-states BTT. In implicit bus ownership cases where the<br />
MC68060 is given the bus but never actually uses it by asserting TS, the MC68060 does not<br />
assert BTT when BG is negated.<br />
In systems that use the BTT protocol, the assertions of TS and BTT must be tracked by masters,<br />
to determine the proper times at which the bus may be taken over. Assertions of BTT<br />
prior to, during, and after the negation of BG may also need to be logged by a master in<br />
cases where the BG is not parked with a master and no master has used the bus for some<br />
time. In such cases the master is required to have kept state information that indicated a previous<br />
master had earlier finished using the bus, implying it is safe to immediately take control<br />
of the bus. The MC68060 processor internally maintains this information.<br />
After external reset, initiated with the negation of RSTI, and with BG asserted, the MC68060<br />
does not wait for the assertion of BTT by another master to take over mastership of the bus<br />
and start bus activity, provided there has been no assertion of TS by another master in the<br />
interim of time between the negation of RSTI and the clock cycle when the MC68060 is<br />
ready to start a bus cycle. If another master starts bus activity (TS asserted) in this interim<br />
of time, even though the MC68060 may have received a bus grant indication (BG asserted),<br />
the MC68060 waits for BTT to be asserted by the other master before it takes over bus mastership.<br />
When BG is negated by the arbiter, the MC68060 relinquishes the bus as soon as the current<br />
bus cycle is complete unless a locked sequence of bus cycles is in progress with BGR<br />
negated. In this case, the MC68060 completes the sequence of atomic locked bus cycles,<br />
drives LOCK and LOCKE negated for one BCLK period during the clock when the address<br />
and other bus cycle attributes are idled, and in the next BCLK period, three-states LOCK<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-59
Bus Operation<br />
and LOCKE and then relinquishes the bus by asserting BTT. BGR is a qualifier for BG which<br />
indicates to the MC68060 the degree of necessity for relinquishing bus ownership when BG<br />
is negated. BGR primarily affects how the MC68060 behaves during atomic locked<br />
sequences when BG is negated.<br />
The MC68060 arbitration protocol allows bus ownership to be removed from the MC68060<br />
and granted to another bus master with the negation of BG, even if the processor is indicating<br />
a locked sequence is in progress. A LOCK signal is provided by the MC68060 to indicate<br />
the processor intends the current set of bus cycles to be locked together, but this can either<br />
be enforced or overridden by the system bus arbiter’s control of the BGR signal. The assertion<br />
of BGR with the negation of BG by an external bus arbiter forces the processor to relinquish<br />
the bus as soon as the current bus cycle is finished even if the processor is running a<br />
locked sequence of atomic bus cycles. If both BGR and BG are negated when the MC68060<br />
is running a sequence of locked bus cycles, the MC68060 finishes the entire set of atomic<br />
locked bus cycles and then relinquishes the bus at the completion of that unit of atomic<br />
locked bus cycles and no disruption of the atomic sequence occurs. Note the MC68060 may<br />
be running a set of back-to-back atomic locked sequences, the abutment of which an external<br />
bus arbiter can not detect to determine a safe time to negate BG. With BGR negated the<br />
MC68060 finishes the last bus cycle of the current set of atomic locked bus cycles and then<br />
relinquishes the bus, thus preventing the interruption of that unit of atomic locked sequence<br />
of bus cycles. Figure 7-46 illustrates BGR functionality during locked sequences.<br />
As an alternative to the BGR protocol, the MC68060 retains the LOCKE signal from the<br />
MC68040 bus. The MC68040 uses a LOCKE signal during the last bus cycle of a locked<br />
sequence of bus cycles to allow an external arbiter to detect the boundary between back-toback<br />
locked sequences on the bus. An external arbiter in a MC68040 system can use the<br />
LOCKE status signal to determine safe times to remove BG without breaking a locked<br />
sequence and allow arbitration to be overlapped with the last transfer in a locked sequence.<br />
However, a retry acknowledge termination during the last bus cycle of a locked sequence<br />
with LOCKE asserted and BG negated requires asynchronous logic in the external bus arbiter<br />
to re-assert BG before the bus cycle finishes to prevent the splitting or interruption of the<br />
locked sequence. Use of the BGR protocol prevents this problem by allowing the MC68060<br />
determine the proper time to relinquish bus ownership and simplifies the external bus arbiter<br />
design.<br />
For locked sequences of bus cycles, the MC68060 asserts LOCK with the TS of the first bus<br />
cycle and negates LOCK following the final termination acknowledgment of the last transfer<br />
of the last bus cycle during the execution of the TAS and CAS instructions, on updates of<br />
history information in table searches, and after the execution of MOVEC instructions that set<br />
and later reset the LOCK bit in the BUSCR. Depending on how the arbiter is designed with<br />
respect to LOCK and BGR, this can have the effect of preventing overlapped bus arbitration<br />
during locked sequences. By keeping LOCK asserted throughout the duration of a locked<br />
sequence, the last bus cycle of the sequence can be retried and still maintain the lock status.<br />
7-60 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
The MC68060 processor, like the MC68040, will continue to drive external address and<br />
attribute lines, but unlike the MC68040, it may drive undefined values on the address and<br />
attribute lines during times when the bus is still owned but idle after a previous usage. Also,<br />
unlike the MC68040, in cases of implicit bus ownership, when the MC68060 has been<br />
granted the bus but has not yet run a cycle, the processor does not drive the address and<br />
attributes lines and they remain three-stated until a bus cycle is actually initiated.<br />
Figure 7-42 shows the behavior of the MC68060 given inputs defined in Table 7-8. The<br />
states are defined in Table 7-9. The arbitration state diagram for the MC68060-arbitration<br />
protocol is similar to the MC68040-arbitration protocol with the exception that BB is no<br />
longer used as an input. As with the MC68040-arbitration protocol, the end tenure state is<br />
used to inform other bus masters the processor is relinquishing the bus.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-61
Bus Operation<br />
Present<br />
State<br />
Reset<br />
Explicit<br />
Own<br />
End<br />
Tenure<br />
AM<br />
Implicit<br />
AM<br />
Explicit<br />
Implicit<br />
Own<br />
Table 7-8. MC68060-Arbitration Protocol State Transition Conditions<br />
Condition RSTI BG<br />
TS sampled<br />
as an input<br />
(TSI))<br />
SNOOP<br />
BTT sampled<br />
as an input<br />
(BTTI)<br />
Internal<br />
Bus Request<br />
(IBR)<br />
Transfer<br />
in<br />
Progress?<br />
End of<br />
Cycle?<br />
Next State<br />
A1 A — — — — — — — Reset<br />
A2 N A — — — — — — Implicit Own<br />
A3 N N — — — — — — AM Implicit<br />
B1 N N — — — — N — End Tenure<br />
B2 N N — — — — A N Explicit Own<br />
B3 N N — — — — A A End Tenure<br />
B4 N A — — — — — — Explicit Own<br />
C1 N N N — — — — — AM Implicit<br />
C2 N A — — — N — — Implicit Own<br />
C3 N A — — — A — — Explicit Own<br />
C4 N N A — — — — — Violation<br />
D1 N — A A — — — — Snoop<br />
D2 N — A N — — — — AM Explicit<br />
D3 N N N — — — — — AM Implicit<br />
D4 N A N — — N — — Implicit Own<br />
D5 N A N — — A — — Explicit Own<br />
E1 N — A A — — — — Snoop<br />
E2 N — A N — — — — AM Explicit<br />
E3 N — N — N — — — AM Explicit<br />
E4 N A N — A N — — Implicit Own<br />
E5 N A N — A A — — Explicit Own<br />
E6 N N N — A — — — AM Implicit<br />
F1 N N N — — — — — AM Implicit<br />
F2 N A — — — N — — Implicit Own<br />
F3 N A — — — A — — Explicit Own<br />
F4 N N A — — — — — Violation<br />
Snoop G1 N — — — — — — — AM Explicit<br />
Any — A — — — — — — — Reset<br />
NOTES:<br />
1) “N” means negated; “A” means asserted.<br />
2) End of cycle: Whatever terminates a bus transaction whether it is normal, bus error, or retried. Note that long-word<br />
bus cycles that result from a burst inhibited line transfer are considered part of that original line transfer.<br />
3) Conditions C4 and F4 indicate that an alternate master has taken bus ownership without waiting for the current master<br />
to assert BTT.<br />
4) IBR refers to an internal bus request. The output signal BR is a registered version of IBR.<br />
5) BTTI refers to BTT when sampled as an input.<br />
6) SNOOP denotes the condition in which SNOOP is sampled asserted, and TT1 = 0.<br />
7) In this state diagram, BGR is assumed always asserted; hence, bus cycles within a locked sequence are treated no<br />
differently from nonlocked bus cycles, except that the processor takes an extra BCLK period in the end tenure state<br />
to allow for LOCK and LOCKE to negate. If BGR is negated and a locked sequence is in progress, the processor does<br />
not relinquish the bus if BG is negated until the end of the last bus cycle in the locked sequence.<br />
8) The processor does not require a valid acknowledge termination for snooped accesses. The only restriction is that a<br />
snoop cycle be performed at no more than a maximum rate of once every two BCLK cycles. This state diagram properly<br />
emulates this behavior.<br />
7-62 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Table 7-9. MC68060-Arbitration Protocol State Description<br />
BTTO Bus Status Own State<br />
Not Driven Not Driven No Reset<br />
Not Driven Not Driven No Alternated Master Implicit Own<br />
Not Driven Not Driven No Alternate Master Explicit Own<br />
Not Driven Not Driven Yes Implicit Ownership<br />
Not Driven Driven Yes Explicit Ownership<br />
Asserted for One<br />
BCLK, Negated for<br />
One BCLK then<br />
Three-Stated<br />
Stops Being<br />
Driven at End<br />
of State<br />
Yes End Tenure<br />
Not Driven Not Driven No Alternate Master Own and Snooped<br />
NOTE: BTTO represents the component of BTT as driven by the MC68060. BTT is normally<br />
three-stated but driven for one BCLK when asserted and one BCLK when negated.<br />
Bus Operation<br />
The MC68060 can be in any one of seven bus arbitration states during bus operation: reset,<br />
AM-implicit own, AM-explicit own, snoop, implicit ownership, explicit ownership, and the end<br />
tenure state.<br />
The reset state is entered whenever RSTI is asserted in any bus arbitration state, except the<br />
explicit ownership state. For that state, the end tenure state is entered prior to entering the<br />
reset state.This is done to ensure other bus masters are capable of taking the bus away from<br />
the processor when it is reset. When RSTI is negated, the processor proceeds to the implicit<br />
ownership state or alternate master implicit ownership state, depending on BG. If an alternate<br />
master asserts TS or has asserted TS in the past, the processor waits for BTT to assert<br />
(or alternatively for BB to go from being asserted to being negated) before taking the bus,<br />
even though BG may be asserted to the processor.<br />
The AM-implicit own state denotes the MC68060 does not have ownership (BG negated) of<br />
the bus and is not in the process of snooping an access, and the alternate has not begun its<br />
tenure by asserting TS (alternate master TS or SNOOP negated). In the AM-implicit own<br />
state, the MC68060 does not drive the bus. The processor enters the AM-explicit own state<br />
when TS is asserted by the alternate master. Once in the AM-explicit own state, the processor<br />
waits for the alternate master to assert BTT before recognizing that a change of tenure<br />
has occurred. If BG is negated when BTT is asserted, the processor assumes that another<br />
master has taken implicit ownership of the bus. Otherwise, if BG is asserted when BTT is<br />
asserted, the processor assumes implicit ownership of the bus.<br />
If an alternate master loses bus ownership when it is in implicit ownership state, the processor<br />
checks TS. If TS is sampled asserted, the processor interprets this as the alternate master<br />
transitioning to its explicit ownership state, and it does not take bus ownership. This<br />
operation is different from that of the MC68040 in that external arbiters are required to check<br />
for this boundary condition. However, in order for the processor to properly detect this<br />
boundary condition, it is imperative that the TS of all alternate bus masters be tied together<br />
with the processor’s TS signal.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-63
Bus Operation<br />
E3<br />
BTTI<br />
E2<br />
E4<br />
G1<br />
SNOOP<br />
AM<br />
EXPLICIT<br />
F2<br />
BTTO THREE-STATE<br />
BTTO<br />
IBR<br />
BCLK<br />
D<br />
Q<br />
E1<br />
IMPLICIT<br />
OWN<br />
BTT<br />
BR<br />
E6<br />
E5<br />
D2<br />
F1<br />
F3<br />
D1<br />
D4<br />
IBR<br />
BR<br />
BTTI<br />
BTTO<br />
BTT<br />
BCLK<br />
AM<br />
IMPLICIT<br />
Figure 7-42. MC68060-Arbitration Protocol State Diagram<br />
7-64 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
D3<br />
D5<br />
A3<br />
A2<br />
C2<br />
EXPLICIT<br />
OWN<br />
C1<br />
END<br />
TENURE<br />
C3<br />
RESET<br />
= INTERNAL BUS REQUEST SIGNAL<br />
= EXTERNAL BUS REQUEST PIN<br />
= INTERNAL BTT SAMPLED AS INPUT<br />
= BTT DRIVEN INTERNALLY BY MC68060<br />
= EXTERNAL BTT PIN<br />
= VIRTUAL BUS CLOCK DERIVED FROM CLK AND CLKEN<br />
B3<br />
B4<br />
A1<br />
B1<br />
B2
Bus Operation<br />
The snoop state is similar to the AM-explicit own state in that the MC68060 does not have<br />
ownership of the bus. The snoop state differs from the AM-explicit own state in that the<br />
MC68060 is in the process of performing an internal snoop operation because the processor<br />
has detected that TS and SNOOP are asserted and TT1 = 0. The snoop state always returns<br />
to the AM-explicit own state. The implicit ownership state indicates that the MC68060 owns<br />
the bus because BG is asserted to it. The processor, however, is not ready to begin a bus<br />
cycle, and keeps BB negated and the bus three-stated until an internal bus request occurs.<br />
The MC68060 explicitly owns the bus when the bus is granted to it (BG asserted) and it has<br />
initiated at least one bus cycle. Until BG is negated, the processor retains explicit ownership<br />
of the bus whether or not active bus cycles are being executed. When the processor is ready<br />
to relinquish the bus, it goes through the end tenure state to indicate to all alternate masters<br />
that it is relinquishing the bus. During the end tenure state, BTT is asserted for one BCLK<br />
and is actively negated for the next BCLK prior to three-stating. While in this state, if RSTI<br />
is asserted, the processor proceeds to the end tenure state to inform other bus masters it is<br />
relinquishing the bus.<br />
All alternate masters that reside in a system and use the MC68060-arbitration protocol must<br />
provide the same functionality as the MC68060 for proper system operation.<br />
7.11.3 External Arbiter Considerations<br />
The bus arbitration state diagrams for the MC68040-arbitration protocol and MC68060-arbitration<br />
protocol may be used to approximate the high level behavior of the processor. In<br />
either case, it is assumed that all TS signals in a system are tied together, all BB signals in<br />
a system are tied together and to a pullup resistor (MC68040-arbitration protocol), or all BTT<br />
signals in a system are tied together and to a pullup resistor (MC68060-arbitration protocol).<br />
Furthermore, unused BB or BTT pins must have separate pullup resistors.<br />
If an alternate master loses bus ownership when it is in its implicit ownership state, the processor<br />
checks TS. If TS is sampled asserted, the processor interprets this as the alternate<br />
master transitioning to its explicit ownership state, and it does not take over bus ownership.<br />
This operation is different from that of the MC68040, in that external arbiters are required to<br />
check for this boundary condition. However, in order for the processor to properly detect this<br />
boundary condition, it is imperative that the TS of all alternate bus masters be tied together<br />
with the processor’s TS signal.<br />
When using the MC68040-arbitration protocol, as with the TS signal, the BB of all alternate<br />
bus masters must be tied together to the processor’s BB signal. Also, when an alternate<br />
master becomes bus master, it must assert BB if it initiates a bus cycle with the TS asserted.<br />
The external arbiter design needs to include the function of BR. For example, in certain<br />
cases associated with conditional branches, the MC68060 can assert BR to request the bus<br />
from an alternate bus master, then negate BR without using the bus, regardless of whether<br />
or not the external arbiter eventually asserts BG. This situation happens when the MC68060<br />
attempts to prefetch an instruction for a conditional branch. To achieve maximum performance,<br />
the processor may prefetch the instructions of the forward path for a conditional<br />
branch. If the branch prediction is incorrect and if the conditional branch results in a branchnot-taken,<br />
the previously issued branch-taken prefetch is then terminated since the prefetch<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-65
Bus Operation<br />
is no longer needed. In an attempt to save time, the MC68060 negates BR. If BG takes too<br />
long to assert, the MC68060 enters a disregard request condition.<br />
The BR signal can be reasserted immediately for a different pending bus request, or it can<br />
stay negated indefinitely. If an external bus arbiter is designed to wait for the MC68060 to<br />
perform an active bus cycle before proceeding, then the system experiences an extended<br />
period of time in which bus arbitration is dead-locked. It must be understood that BR is a<br />
status signal which may or may not have any relationship to BB, BTT, or BG.<br />
When using the MC68060-arbitration protocol it is possible to determine bus tenure boundaries<br />
by observing TS and BTT. An active bus tenure begins when a bus master asserts its<br />
TS for the first time. Once the bus tenure has started, the active bus master must end its<br />
tenure by asserting BTT (or a low-to-high transition of BB). If a bus master is granted the<br />
bus, but does not start an active bus tenure by asserting TS, no BTT assertion (or a low-tohigh<br />
transition of BB) is needed since no bus tenure was started. When reset is applied to<br />
the entire system, TS to all bus masters must be negated via a pullup resistor. In addition,<br />
the bus arbiter must grant the bus to a single bus master. Once the first bus master recognizes<br />
that TS is negated and that it has been granted the bus, it asserts its TS to establish<br />
its bus tenure and to inform other bus masters that its bus tenure has begun (this assumes<br />
that the TS signals of all bus masters in the system are tied together). All other bus masters<br />
will therefore detect an asserted TS (TS is asserted by the first bus master) immediately<br />
after reset. These bus masters must then wait for BTT to assert (or a low-to-high transition<br />
of BB) before beginning their bus tenure when granted the bus.<br />
Figure 7-43 illustrates an example of the processor requesting the bus from the external bus<br />
arbiter. During C1, the MC68060 asserts BR to request the bus from the arbiter, which<br />
negates the alternate bus master’s BG signal and grants the bus to the processor by asserting<br />
BG during C2. During C2, the alternate bus master completes its current access and<br />
relinquishes the bus in C3 by three-stating all bus signals and negating BB and/or asserting<br />
BTT. Typically, the BB and BTT signals require a pullup resistor to maintain a logic-one level<br />
between bus master tenures. The alternate bus master should negate these signals before<br />
three-stating to minimize rise time of the signals and ensure that the processor recognizes<br />
the correct level on the next BCLK rising edge. At the end of C3, the processor has already<br />
received bus grant and the alternate master has relinquished the bus. Hence, the processor<br />
assumes ownership of the bus and immediately begins a bus cycle during C4. During C6,<br />
the processor begins the second bus cycle for the misaligned operand and negates BR<br />
since no other accesses are pending. During C7, the external bus arbiter grants the bus<br />
back to the alternate bus master that is waiting for the processor to relinquish the bus. The<br />
processor negates BB, asserts BTT, and three-states bus signals during C8. Finally, the<br />
alternate bus master has the bus grant. The processor has relinquished the bus at the end<br />
of C8 and is able to resume bus activity during C9. Note that BTT is asserted only for one<br />
BCLK period and is negated for one BCLK period during C10. BTT is then three-stated in<br />
C10.<br />
Further note that BB is only negated for one CLK (as opposed to BCLK) period before being<br />
three-stated, and the MC68040-arbitration protocol should not be used for full bus speed<br />
operation.<br />
7-66 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BUS<br />
ARBITRATION<br />
STATE<br />
BCLK<br />
A31–A0<br />
TRANSFER<br />
ATTRIBUTES<br />
TS<br />
TA<br />
D31–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
AM_BR*<br />
AM_BG*<br />
AM-EX AM-EX AM-EX EX-OWN EX-OWN EX-OWN EX-OWN END-TEN AM-IMP AM-EX<br />
C1 C2 C3 C4 C5 C6 C7 C8 C9<br />
ALTERNATE<br />
MASTER<br />
*AM indicates the alternate bus master.<br />
PROCESSOR<br />
Figure 7-43. Processor Bus Request Timing<br />
Bus Operation<br />
Figure 7-44 illustrates a functional timing diagram for an arbitration of a relinquish and retry<br />
operation (MC68040 acknowledge termination mode). In Figure 7-44, the processor read<br />
access that begins in C1 is terminated at the end of C2 with a retry request and BG negated,<br />
forcing the processor to relinquish the bus and allow the alternate master to access the bus.<br />
Note that the processor re-asserts BR during C3 since the original access is pending again.<br />
After alternate bus master ownership, the bus is granted to the processor to allow it to retry<br />
the access beginning in C7.<br />
Figure 7-45 is a functional timing diagram for implicit ownership of the bus.<br />
ALTERNATE<br />
MASTER<br />
Figure 7-46 illustrates the effect of BGR on bus arbitration activity during locked sequences.<br />
When BGR is asserted while BG is negated, locked sequences can be broken. Otherwise,<br />
the entire locked sequence of bus cycles are completed by the processor before relinquishing<br />
the bus.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-67<br />
C10
Bus Operation<br />
BUS<br />
ARBITRATION<br />
STATE<br />
BCLK<br />
A31–A0<br />
TRANSFER<br />
ATTRIBUTES<br />
R/W<br />
TS<br />
TA<br />
TEA<br />
D31–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
AM_BR*<br />
AM_BG*<br />
EX-OWN EX-OWN END-TEN AM-IMP AM-EX AM-EX EX-OWN EX-OWN<br />
PROCESSOR<br />
Figure 7-44. Arbitration During Relinquish and Retry Timing<br />
7.12 BUS SNOOPING OPERATION<br />
C1 C2 C3 C4 C5 C6 C7 C8<br />
ALTERNATE<br />
MASTER<br />
*AM indicates the alternate bus master.<br />
NOTE: The MC68040 acknowledge termination mode is assumed.<br />
PROCESSOR<br />
The MC68060 has the capability of monitoring bus transfers by other bus masters. The process<br />
of bus monitoring is called snooping and is controlled by the SNOOP signal.<br />
Snooping can occur when the bus is granted to another bus master, and the MC68060 sees<br />
a TS assertion by the alternate master. If SNOOP is asserted, the processor registers the<br />
value of the A31–A0 and TT1 signals on the rising edge of BCLK in which TS is asserted.<br />
7-68 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BUS<br />
ARBITRATION<br />
STATE<br />
BCLK<br />
A31–A0<br />
TRANSFER<br />
ATTRIBUTES<br />
TS<br />
TA<br />
D31–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
AM_BR*<br />
AM_BG*<br />
AM-EX AM-EX AM-EX IM-OWN IM-OWN EX-OWN EX-OWN EX-OWN EX-OWN<br />
C1 C2 C3 C4 C5 C6 C7 C8 C9<br />
BUS<br />
BUS OWNED<br />
IMPLICITLY<br />
ALTERNATE<br />
AND ACTIVE<br />
OWNED<br />
MASTER PROCESSOR<br />
*AM indicates the alternate bus master.<br />
BUS OWNED<br />
AND IDLE<br />
Figure 7-45. Implicit Bus Ownership Arbitration Timing<br />
Bus Operation<br />
In addition, the snoop address on A31–A0 is again registered on the next CLK (not BCLK)<br />
rising edge. For proper operation, the snoop addresses registered on these two separate<br />
occasions must be consistent. Only normal and MOVE16 bus transfers can be snooped.<br />
The MC68060 then examines the address of the transfer and invalidates the line in its<br />
caches in which the address matches. This process is done quietly without external indication<br />
that a cache entry has been invalidated. Note that when snooping is enabled and an<br />
entry matches in the MC68060 caches, the entry is invalidated regardless of the state of the<br />
R/W signal, transfer size, or whether or not the line has clean or dirty data. If SNOOP is<br />
negated, no snooping is done, and no lines in the caches are invalidated.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-69
Bus Operation<br />
BCLK<br />
TS<br />
TIP<br />
R/W<br />
LOCK<br />
LOCKE<br />
ADDRESS<br />
ATTRIBUTES<br />
PRE<br />
DRIVE<br />
PRE<br />
DRIVE<br />
D31–D0<br />
SAS<br />
Figure 7-46. Effect of BGR on Locked Sequences<br />
The MC68060 does not require snooped bus cycles to be terminated with a legal transfer<br />
termination (TA, TEA, or TRA). The only requirement is that TS be asserted no more frequently<br />
than once every other BCLK edge. Figure 7-47 shows a snooped bus cycle.<br />
7-70 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
TA<br />
BR<br />
BG<br />
BGR<br />
BTT<br />
BB<br />
AM_BG<br />
ALTERNATE<br />
MASTER<br />
PROCESSOR<br />
ALTERNATE<br />
MASTER<br />
PROCESSOR
BUS<br />
ARBITRATION<br />
STATE<br />
BCLK<br />
SNOOP<br />
A31–A0<br />
TRANSFER<br />
ATTRIBUTES<br />
TT1<br />
7.13 RESET OPERATION<br />
TS<br />
TA<br />
D31–D0<br />
BR<br />
BG<br />
BB<br />
BTT<br />
AM_BR*<br />
AM_BG*<br />
END-TEN AM-IMP SNOOP AM-EXP AM-EXP AM-EXP<br />
*AM indicates the alternate bus master.<br />
C1 C2 C3 C4 C5 C6<br />
ALTERNATE<br />
MASTER<br />
Figure 7-47. Snooped Bus Cycle<br />
PROCESSOR<br />
Bus Operation<br />
An external device asserts the reset input signal (RSTI) to reset the processor. When power<br />
is applied to the system, external circuitry should assert RSTI for a minimum of ten BCLK<br />
cycles after V CC is within tolerance. Figure 7-48 is a functional timing diagram of the poweron<br />
reset operation, illustrating the relationships among V CC , RSTI, mode selects, and bus<br />
signals. CLK is required to be stable by the time V CC reaches the minimum operating specification.<br />
CLK should start oscillating as V CC is ramped up in order to clear out contention<br />
internal to the part caused by the random manner in which internal flip-flops power-up. RSTI<br />
is internally synchronized for two BCLKs before being used and must meet the specified<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-71
Bus Operation<br />
setup and hold times to BCLK (specifications #51 and #52 in Section 12 Electrical and<br />
Thermal Characteristics) only if recognition by a specific BCLK rising edge is required and<br />
for configuration settings to be registered on the rising BCLK edge shown in Figure 7-48.<br />
BCLK<br />
+3.3 V<br />
VCC 0 V<br />
RSTI<br />
D15-D0,<br />
IPL2–IPL0<br />
BUS<br />
SIGNALS<br />
TS<br />
TIP<br />
BR<br />
BG<br />
BB<br />
BTT<br />
t > 10<br />
BCLK CYCLES<br />
27<br />
CLK CYCLES<br />
NOTE: For the processor to begin bus cycles after reset, BG must be asserted, TS must be negated or pulled up. If bus arbitration activity<br />
is started by an alternate master (TS asserted), BTT must be asserted (or BB transition from asserted to negated) eventually to indicate<br />
an end to the alternate master's tenure.<br />
Figure 7-48. Initial Power-On Reset Timing<br />
TS must be pulled up or negated during reset. Once RSTI negates, the processor is internally<br />
held in reset for another 27 CLK cycles. During the reset period, all signals that can be,<br />
are three-stated, and the remaining signals are driven to their inactive state. Once RSTI<br />
negates, all bus signals continue to remain in a high-impedance state until the processor is<br />
granted the bus. If BG is negated to the processor, the bus is three-stated, and no bus cycle<br />
activity is present until BG is asserted. Afterwards, the first bus cycle for reset exception processing<br />
begins. In Figure 7-48 the processor assumes implicit bus ownership on reset<br />
before the first bus cycle begins. The levels on IPLx and D15–D0 are used to selectively<br />
enable the special modes of operation when RSTI is negated. These signals are registered<br />
into the processor on the last rising edge of BCLK in which RSTI is sampled low. These signals<br />
should be driven to their normal levels before the end of the 27-CLK internal reset<br />
period.<br />
7-72 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
For processor resets after the initial power-on reset, RSTI should be asserted for at least ten<br />
BCLK periods. Figure 7-49 illustrates timings associated with a reset when the processor is<br />
executing bus cycles. BB and TIP are negated before transitioning to a three-state level.<br />
BCLK<br />
RSTI<br />
D15-D0,<br />
IPL2–IPL0<br />
BUS<br />
SIGNALS<br />
TS<br />
TIP<br />
BR<br />
BG<br />
BB<br />
BTT<br />
t > 10<br />
BCLK CYCLES<br />
Figure 7-49. Normal Reset Timing<br />
27<br />
CLK CYCLES<br />
NOTE: For the processor to reset begin bus cycles after reset, BG must be asserted, TS must be negated or pulled up. BTT must be asserted (or BTT transition<br />
from asserted to negated) eventually to indicate an end to the alternate master's tenure.<br />
Resetting the processor causes any bus cycle in progress to terminate as if TEA had been<br />
asserted. In addition, the processor initializes registers appropriately for a reset exception.<br />
Section 8 Exception Processing describes reset exception processing. When a RESET<br />
bus operation instruction is executed, the processor drives the reset out (RSTO) signal for<br />
512 CLK cycles. In this case, the processor can be used to reset external devices in a system,<br />
and the internal registers of the processor are unaffected. The external devices connected<br />
to the RSTO signal are reset at the completion of the RESET instruction. An RSTI<br />
signal that is asserted to the processor during execution of a RESET instruction immediately<br />
resets the processor and causes the RSTO signal to negate. RSTO can be logically ANDed<br />
with the external signal driving RSTI to derive a system reset signal that is asserted for both<br />
an external processor reset and execution of a RESET instruction.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-73
Bus Operation<br />
7.14 SPECIAL MODES OF OPERATION<br />
The MC68060 supports the following three operation modes, which are selectively enabled<br />
during processor reset and remain in effect until the next processor reset. Refer to 7.13<br />
Reset Operation for reset timing information. Table 7-10 summarizes the three special<br />
modes and associates them with the appropriate IPLx signal.<br />
Signal<br />
IPL2<br />
IPL1<br />
IPL0<br />
Table 7-10. Special Mode vs. IPLx Signals<br />
Value During<br />
Reset Time<br />
Action<br />
Asserted Extra Data Write Hold Mode Enabled<br />
Negated Extra Data Write Hold Mode Disabled<br />
Asserted Native-MC68060 Acknowledge Termination Protocol<br />
Negated MC68040 Acknowledge Termination Protocol<br />
Asserted Acknowledge Termination Ignore State Capability Enabled<br />
Negated Acknowledge Termination Ignore State Capability Disabled<br />
7.14.1 Acknowledge Termination Ignore State Capability<br />
The MC68060 provides acknowledge termination ignore state capability to make high-frequency<br />
system design easier. This feature defines BCLK edges during which the acknowledge<br />
termination signals (TA, TEA, and TRA) are ignored. This feature is enabled if IPL0 is<br />
asserted during reset.<br />
During reset, 16 bits of information (from D15–D0) are registered into the MC68060. These<br />
16 bits define four values of four bits each. Two of the four values are used for read bus<br />
cycles; the other two values are used for write bus cycles. For the read bus cycle, the first<br />
value is the primary ignore state count value. The primary ignore state count value is used<br />
during the first long-word transfer of a line transfer cycle, or the only data transfer for byte,<br />
word, or long-word bus cycles. The second value is the secondary ignore state count value.<br />
The secondary ignore state count value is used during the next three long words for line<br />
transfer cycles, after the first long word has been transferred. Similarly, the two values of the<br />
write bus cycle are defined as a primary ignore state count value and a secondary ignore<br />
state count value, respectively. Figure 7-50 shows the assignment of the four data nibbles<br />
at reset.<br />
15 12 11 8 7 4 3<br />
0<br />
READ PRIMARY<br />
IGNORE STATE COUNT<br />
READ SECONDARY<br />
IGNORE STATE COUNT<br />
WRITE PRIMARY<br />
IGNORE STATE COUNT<br />
Figure 7-50. Data Bus Usage During Reset<br />
WRITE SECONDARY<br />
IGNORE STATE COUNT<br />
At the beginning of a bus cycle, the appropriate primary ignore state count value is loaded<br />
into an internal counter. The counter decrements every BCLK rising edge. As long as the<br />
counter has a non-zero count value, the MC68060 ignores the acknowledge termination signals.<br />
Once the counter reaches zero, the MC68060 asserts SAS for one BCLK period and<br />
begins to sample the acknowledge termination signals and acts accordingly. For byte, word,<br />
or long-word transfers, the bus cycle ends when a valid termination is detected. For line<br />
transfer cycles after the first long-word transfer, the secondary ignore state count value is<br />
7-74 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Bus Operation<br />
loaded into the internal counter and the counter decrements every rising BCLK edge. As<br />
long as the counter has a non-zero count value, the MC68060 ignores the acknowledge termination<br />
signals. Once the counter reaches zero, the MC68060 asserts SAS for one BCLK<br />
period and begins to sample the acknowledge termination signals and acts accordingly. This<br />
process repeats for the rest of the line transfer cycle.<br />
To aid in system debug for system designs that continuously assert TA, a status signal,<br />
SAS, is provided to indicate which rising BCLK edge the MC68060 begins to sample<br />
acknowledge termination signals. SAS is negated on the next rising BCLK edge if the bus<br />
cycle ends or if the next ignore state count value is non-zero. Aside from being a status signal,<br />
SAS may be used in conjunction with some decode address bits to generate the CLA<br />
signal or TA signal shown in Figure 7-24.<br />
Figure 7-51 shows an example of how the MC68060 behaves when the acknowledge termination<br />
ignore state mode is enabled. In this example, the read primary ignore state count<br />
value and the read secondary ignore state count value are initialized to a value of one during<br />
reset. On the first long-word access, TA is asserted immediately, but data is not registered<br />
until the rising edge of C4. On the next long-word access, the secondary count value takes<br />
effect. In a similar manner, TA is ignored until the rising edge of C6. On the last long-word<br />
access of the line, the secondary ignore state count expires before TA is asserted. Therefore,<br />
more wait states are added until TA is asserted and recognized on the rising edge of<br />
C12.<br />
BCLK<br />
TS<br />
ADDRESS AND<br />
ATTRIBUTES<br />
R/W<br />
TA<br />
SAS<br />
D31–D0<br />
IGNORED IGNORED IGNORED IGNORED<br />
C1 C2 C3 C4 C5 C6 C7 C8<br />
READ PRIMARY IGNORE STATE COUNT = 1<br />
READ SECONDARY IGNORE STATE COUNT = 1<br />
C9 C10 C11 C12<br />
Figure 7-51. Acknowledge Termination Ignore State Example<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-75
Bus Operation<br />
The ignore state settings can be used to make the system design of the acknowledge termination<br />
logic simpler than in existing MC68040 systems that required these signals to be<br />
valid (either asserted or negated) about every rising BCLK edge. Thus, using the acknowledge<br />
termination ignore state capability allows the use of slower ASICs and PALs to be used<br />
for generating the acknowledge termination signals without the requirement that these signals<br />
be at a valid logic level about every rising BCLK edge.<br />
7.14.2 Acknowledge Termination Protocol<br />
The MC68060 provides system designers a choice of using either the MC68040 acknowledge<br />
termination protocol or the native-MC68060 acknowledge termination protocol. The<br />
native-MC68060 acknowledge termination protocol is chosen if IPL1 is asserted during<br />
reset.<br />
The MC68040 acknowledge termination protocol is provided for MC68040 compatibility. In<br />
this protocol, a retry is indicated by having both TA and TEA asserted simultaneously. In this<br />
mode, the TRA signal must be pulled up at all times. Refer to Table 7-4 and Table 7-5 for<br />
details on acknowledge termination signal encoding.<br />
The native-MC68060 acknowledge termination protocol is provided to aid in high-frequency<br />
designs. The signal TRA is used to indicate a retry operation, as opposed to using a combination<br />
of TA and TEA to indicate a retry. Refer to Table 7-4 and Table 7-5 for details on the<br />
native-MC68060 acknowledge termination signal encoding.<br />
7.14.3 Extra Data Write Hold Time Mode<br />
In this mode, the MC68060 holds the contents of the data bus valid during a write bus cycle<br />
for an extra BCLK period after a valid TA is sampled. This mode is enabled if IPL2 is<br />
asserted during reset. When this mode is enabled, a zero wait state burst bus cycle is not<br />
possible and systems must be designed to insert wait states on burst accesses. Figure 7-<br />
52 shows an example of a line transfer cycle with this mode enabled. Read cycles are unaffected<br />
by this mode.<br />
7-76 <strong>M68060</strong> USER’S MANUAL MOTOROLA
BCLK<br />
TS<br />
ADDRESS AND<br />
ATTRIBUTES<br />
R/W<br />
TA<br />
D31–D0<br />
Figure 7-52. Extra Data Write Hold Example<br />
Bus Operation<br />
C1 C2 C3 C4 C5 C6 C7 C8 C9 C10 C11 C12<br />
PRE<br />
DRIVE<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 7-77
SECTION 8<br />
EXCEPTION PROCESSING<br />
Exception processing is the activity performed by the processor in preparing to execute a<br />
special routine for any condition that causes an exception. Exception processing does not<br />
include execution of the routine itself. This section describes the processing for each type<br />
of integer unit exception, exception priorities, the return from an exception, and bus fault<br />
recovery. This section also describes the formats of the exception stack frames. For details<br />
on floating-point exceptions refer to Section 6 Floating-Point Unit.<br />
8.1 EXCEPTION PROCESSING OVERVIEW<br />
Exception processing is the transition from the normal processing of a program to the processing<br />
required for any special internal or external condition that preempts normal processing.<br />
External conditions that cause exceptions are interrupts from external devices, bus<br />
errors, and resets. Internal conditions that cause exceptions are instructions, address<br />
errors, and tracing. For example, the TRAP, TRAPcc, CHK, RTE, DIV, and FDIV instructions<br />
can generate exceptions as part of their normal execution. In addition, illegal instructions,<br />
unimplemented integer instructions, unimplemented effective addresses, unimplemented<br />
floating-point instructions and data types, and privilege violations cause exceptions. Exception<br />
processing uses an exception vector table and an exception stack frame. The following<br />
paragraphs describe the vector table and a generalized exception stack frame.<br />
The MC68060 uses a restart exception processing model. Exceptions are recognized at the<br />
execution stage of the operand execution pipeline (OEP) and force later instructions that<br />
have not yet reached that stage to be aborted.<br />
Instructions that cannot be interrupted, such as those that generate locked bus transfers or<br />
access noncachable precise pages, are allowed to complete before exception processing<br />
begins, unless an access error prevents this instruction from completing.<br />
Exception processing occurs in four functional steps. However, all individual bus cycles<br />
associated with exception processing (vector acquisition, stacking, etc.) are not guaranteed<br />
to occur in the order in which they are described in this section. Figure 8-1 illustrates a general<br />
flowchart for the steps taken by the processor during exception processing.<br />
During the first step, the processor makes an internal copy of the status register (SR). Then<br />
the processor changes to the supervisor mode by setting the S-bit and inhibits tracing of the<br />
exception handler by clearing the T-bit in the SR. For the reset and interrupt exceptions, the<br />
processor also updates the interrupt priority mask in the SR.<br />
During the second step, the processor determines the vector number for the exception. For<br />
interrupts, the processor performs an interrupt acknowledge bus cycle to obtain the vector<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
8-1
Exception Processing<br />
number. For all other exceptions, internal logic provides the vector number. This vector number<br />
is used in the last step to calculate the address of the exception vector. Throughout this<br />
section, vector numbers are given in decimal notation.<br />
8-2<br />
S ➧ 1<br />
T ➧<br />
0<br />
VECTOR = 2<br />
BUS ERROR OR<br />
ADDRESS ERROR<br />
IF NOT PROCESSING AN<br />
ACCESS ERROR EXCEPTION<br />
ENTRY<br />
SAVE INTERNAL<br />
COPY OF SR<br />
S ➧ 1<br />
T ➧ 0<br />
(SEE NOTE)<br />
DETERMINE VECTOR<br />
NUMBER<br />
SAVE CONTENTS<br />
TO STACK FRAME<br />
(SEE NOTE)<br />
OTHERWISE<br />
CALCULATE<br />
ADDRESS OF FIRST<br />
INSTRUCTION OF<br />
EXCEPTION HANDLER<br />
FETCH FIRST<br />
INSTRUCTION OF<br />
EXCEPTION HANDLER<br />
OTHERWISE<br />
BEGIN EXECUTION<br />
OF EXCEPTION<br />
HANDLER<br />
EXIT<br />
BUS ERROR<br />
Figure 8-1. General Exception Processing Flowchart<br />
<strong>M68060</strong> USER’S MANUAL<br />
(DOUBLE BUS FAULT)<br />
BUS ERROR OR<br />
ADDRESS ERROR<br />
IF PROCESSING AN<br />
ACCESS ERROR EXCEPTION<br />
NOTE: THESE BLOCKS VARY FOR RESET AND INTERRUPT EXCEPTIONS.<br />
(DOUBLE BUS FAULT)<br />
HALTED STATE<br />
PST4–PST0 = $1C<br />
EXIT<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
The third step is to save the current processor contents for all exceptions other than reset.<br />
The processor creates one of four exception stack frame formats on the supervisor stack<br />
and fills it with information appropriate for the type of exception. Other information can also<br />
be stacked, depending on which exception is being processed and the state of the processor<br />
prior to the exception. Figure 8-2 illustrates the general form of the exception stack frame.<br />
SP<br />
15 12 11 0<br />
STATUS REGISTER<br />
PROGRAM COUNTER<br />
FORMAT VECTOR OFFSET<br />
ADDITIONAL PROCESSOR STATE INFORMATION<br />
(2 OR 4 WORDS, IF NEEDED)<br />
Figure 8-2. General Form of Exception Stack Frame<br />
The last step involves the determination of the address of the first instruction of the exception<br />
handler and then passing control to the handler. The processor multiplies the vector<br />
number by four to determine the exception vector offset. It adds the offset to the value stored<br />
in the vector base register (VBR) to obtain the memory address of the exception vector.<br />
Next, the processor loads the program counter (PC) (and the supervisor stack pointer (SSP)<br />
for the reset exception) from the exception vector table entry with the address of the first<br />
instruction of the exception handler. The processor then fetches this instruction and initiates<br />
exception handling. At the conclusion of exception handling, the processor resumes normal<br />
processing at the address in the PC.<br />
The MC68060 is unique from earlier members of the family in that if an interrupt is pending<br />
during exception processing, the exception processing for that interrupt is deferred until the<br />
first instruction of the exception handler of the current exception is executed. This allows any<br />
exception handler to mask interrupts by ensuring that the first instruction of the exception<br />
handler is an SR write that raises the interrupt level.<br />
Normally, the end of an exception handler contains an RTE instruction. When the processor<br />
executes the RTE instruction, it examines the stack frame on top of the supervisor stack to<br />
determine if it is a valid frame. If the processor determines that it is a valid frame, the SR and<br />
PC fields are loaded from the exception frame and control is passed to the specified instruction<br />
address.<br />
All exception vectors are located in the supervisor address space and are accessed using<br />
data references. Only the initial reset vector is fixed in the processor’s memory map; once<br />
initialization is complete, there are no fixed assignments. Since the VBR provides the base<br />
address of the exception vector table, the exception vector table can be located anywhere<br />
in memory; it can even be dynamically relocated for each task that an operating system executes.<br />
8-3
Exception Processing<br />
The MC68060 supports a 1024-byte vector table containing 256 exception vectors (see<br />
Table 8-1). Motorola defines the first 64 vectors and reserves the other 192 vectors for userdefined<br />
interrupt vectors. External devices can use vectors reserved for internal purposes<br />
at the discretion of the system designer. External devices can also supply vector numbers<br />
for some exceptions. External devices that cannot supply vector numbers use the autovector<br />
capability, which allows the MC68060 to automatically generate a vector number.<br />
8.2 INTEGER UNIT EXCEPTIONS<br />
The following paragraphs describe the external interrupt exceptions and the different types<br />
of exceptions generated internally by the MC68060 integer unit. The following exceptions<br />
are discussed:<br />
• Access Error<br />
• Address Error<br />
8-4<br />
Table 8-1. Exception Vector Assignments<br />
Vector<br />
Number(s)<br />
Vector<br />
Offset (Hex)<br />
Stack Frame<br />
Format<br />
Stacked<br />
Program<br />
Counter*<br />
Assignment<br />
0<br />
1<br />
2<br />
3<br />
000<br />
004<br />
008<br />
00C<br />
—<br />
—<br />
42<br />
—<br />
—<br />
—<br />
fault<br />
Reset Initial SSP<br />
Reset Initial PC<br />
Access Fault<br />
Address Error<br />
4<br />
5<br />
6<br />
7<br />
010<br />
014<br />
018<br />
01C<br />
0<br />
2<br />
2<br />
2<br />
fault<br />
next<br />
next<br />
next<br />
Illegal Instruction<br />
Integer Divide-by-Zero<br />
CHK, CHK2 Instructions<br />
TRAPcc, TRAPV Instructions<br />
8<br />
9<br />
10<br />
11<br />
11<br />
11<br />
020<br />
024<br />
028<br />
02C<br />
02C<br />
02C<br />
0<br />
2<br />
0<br />
0<br />
2<br />
4<br />
fault<br />
next<br />
fault<br />
fault<br />
next<br />
next<br />
Privilege Violation<br />
Trace<br />
Line 1010 Emulator (Unimplemented A-Line Opcode)<br />
Line 1111 Emulator (Unimplemented F-Line Opcode)<br />
Floating-Point Unimplemented Instruction<br />
Floating-Point Disabled<br />
12<br />
13<br />
14<br />
15<br />
030<br />
034<br />
038<br />
03C<br />
0<br />
0<br />
0<br />
next<br />
—<br />
fault<br />
next<br />
Emulator Interrupt<br />
Defined for MC68020 and MC68030, not used by MC68060<br />
Format Error<br />
Uninitialized Interrupt<br />
16–23 040–05C — — (Unassigned, Reserved)<br />
24<br />
25<br />
26<br />
27<br />
060<br />
064<br />
068<br />
06C<br />
0<br />
0<br />
0<br />
0<br />
next<br />
next<br />
next<br />
next<br />
Spurious Interrupt<br />
Level 1 Interrupt Autovector<br />
Level 2 Interrupt Autovector<br />
Level 3 Interrupt Autovector<br />
28<br />
29<br />
30<br />
31<br />
070<br />
074<br />
078<br />
07C<br />
0<br />
0<br />
0<br />
0<br />
next<br />
next<br />
next<br />
next<br />
Level 4 Interrupt Autovector<br />
Level 5 Interrupt Autovector<br />
Level 6 Interrupt Autovector<br />
Level 7 Interrupt Autovector<br />
32–47 080–0BC 0 next TRAP #0–15 Instruction Vectors<br />
48–55 0C0–0DC — — †<br />
Floating-Point Exceptions<br />
56<br />
57<br />
58<br />
59<br />
0E0<br />
0E4<br />
0E8<br />
0EC<br />
—<br />
—<br />
—<br />
—<br />
—<br />
—<br />
—<br />
—<br />
Defined for MC68030 and MC68851, not used by MC68060<br />
Defined for MC68851, not used by MC68060<br />
Defined for MC68851, not used by MC68060<br />
(Unassigned, Reserved)<br />
60<br />
61<br />
0F0<br />
0F4<br />
0<br />
0<br />
fault<br />
fault<br />
Unimplemented Effective Address<br />
Unimplemented Integer Instruction<br />
62–63 0F8–0FC — — (Unassigned, Reserved)<br />
64–255 100–3FC 0 next User Defined Vectors (192)<br />
* For the Access Fault exception, refer to 8.4.4.1 Program Counter (PC) .<br />
“fault” refers to the PC of the instruction that caused the exception.<br />
“next” refers to the PC of the next instruction that follows the instruction that caused the fault.<br />
†<br />
Refer to Section 6 Floating-Point Unit.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
• Instruction Trap<br />
• Illegal and Unimplemented Instruction Exceptions<br />
• Privilege Violation<br />
• Trace<br />
• Format Error<br />
• Breakpoint Instruction<br />
• Interrupt<br />
• Reset<br />
8.2.1 Access Error Exception<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
An access error exception occurs when a bus cycle is terminated with TEA (TA must be<br />
negated if in MC68040 acknowledge termination mode) asserted externally or an internal<br />
access error.<br />
An external access error (bus error) occurs when external logic aborts a bus cycle and<br />
asserts the TEA input signal (TA must be negated if in MC68040 acknowledge termination<br />
mode).<br />
A bus error on an operand write access always results in an access error exception, causing<br />
the processor to begin exception processing. However, the time of reporting this bus error<br />
is a function of the instruction type and/or memory mapping of the destination pages. For<br />
writes that are precise (this includes certain atomic instructions like TAS and CAS and references<br />
to pages marked noncachable precise), the occurrence of a bus error causes the<br />
pipeline to be aborted immediately and initiates exception processing. For writes that are<br />
imprecise (stored in push or store buffers or reference to pages marked noncachable imprecise),<br />
the actual bus cycle is decoupled from the instruction which generated the access. For<br />
these types of bus errors, the exception is taken, but the state of the processor may be<br />
advanced from the actual instruction which generated the write.<br />
For operand read accesses generating non-line-sized references, a bus error causes the<br />
pipeline to be immediately aborted and initiates exception processing. This is also true if a<br />
bus error occurs on the first transfer of a line-sized transfer. For a bus error that occurs on<br />
the second, third, or fourth transfers of a line access, the line is not allocated in the cache<br />
and no exception is reported. If a subsequent instruction references another operand within<br />
the given line, another system bus cycle is generated and the bus error reported at that time<br />
(i.e., as the subsequent reference receives a bus error on its initial transfer) and the exception<br />
is then taken.<br />
Bus errors that are signaled during instruction prefetches are deferred until the processor<br />
attempts to execute that instruction. At that time, the bus error is signaled and exception processing<br />
is initiated. If a bus error is encountered during an instruction prefetch cycle, but the<br />
corresponding instruction is never executed due to a change-of-flow in the instruction<br />
stream, the bus error is discarded.<br />
8-5
Exception Processing<br />
When the MC68060 detects any exception, the pipelines are aborted and exception processing<br />
is initiated. After performing the SR copy and forcing the processor into the supervisor<br />
mode, the processor then performs a pipeline synchronization to all the push and store<br />
buffers to empty before proceeding with the exception. If a buffer bus error is signaled at this<br />
time, the pipeline discards the original fault and instead reports the access error caused by<br />
the first buffer write bus error (subsequent write buffer bus errors are ignored). Once the<br />
push and store buffers are empty, the exception processing continues.<br />
Processor accesses for either data or instructions can result in internal access errors. Internal<br />
access errors must be corrected to complete execution of the current instruction. An<br />
internal access error occurs when the data or instruction memory management unit (MMU)<br />
detects that a successful address translation is not possible because the page is write protected,<br />
supervisor only, or nonresident. When the instruction or data MMU detects that a<br />
successful address translation is not possible, the instruction that initiated the unsuccessful<br />
address translation is marked with an MMU fault and is continued down the pipeline. This<br />
fault detection is independent of whether or not a table search was required. Some MMU<br />
faults such as the supervisor-protect and write-protect faults can occur on address translation<br />
cache (ATC) hits or table searches. All other MMU faults can only occur on ATC misses<br />
on the subsequent table searches. If this instruction that is marked with an MMU fault<br />
reaches the EX stage of the OEP, an access error exception is reported.<br />
As illustrated in Figure 8-1, the processor begins exception processing for an access error<br />
by making an internal copy of the current SR. The processor then enters the supervisor<br />
mode and clears the T-bit. The processor generates exception vector number 2 for the<br />
access error vector. It saves the vector offset, PC, and internal copy of the SR on the stack.<br />
In addition, the faulting logical address and the fault status long word (FSLW) is saved on<br />
the stack.<br />
A stack frame format of type 4 is generated when access error exception is reported. The<br />
stacked PC is the logical address of the instruction executing at the time the fault was<br />
detected. Note that this instruction is the instruction that initiated the bus cycle for all access<br />
error cases, except for bus errors on write buffer (push or store) bus cycles. The logical<br />
address that caused the fault is saved in the address field on the stack frame. Note that if<br />
the fault occurred on the second or later of a misaligned access, the logical address may<br />
need to be adjusted to point to the logical address that caused the access error. A fault status<br />
long word is also provided in the stack to further qualify the conditions that caused the<br />
fault.<br />
If a bus error occurs during the exception processing for an access error, address error, or<br />
reset, a double bus fault occurs, and the processor enters the halted state as indicated by<br />
the PST4–PST0 encoding $1C. In this case, the processor does not attempt to alter the current<br />
state of memory. Only an external reset can restart a processor halted by a double bus<br />
fault.<br />
The supervisor stack has special requirements to ensure that exceptions can be stacked.<br />
The stack must be resident with correct protection in the direction of growth to ensure that<br />
exception stacking never has a bus error or internal access error. Memory pages allocated<br />
to the stack that are higher in memory than the current stack pointer can be nonresident<br />
8-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
since an RTE or FRESTORE instruction can check for residency and trap before restoring<br />
the state.<br />
A special case exists for systems that allow arbitration of the processor bus during locked<br />
transfer sequences. If the arbiter can signal a bus error of a locked translation table update<br />
due to an improperly broken lock, any pages touched by exception stack operations must<br />
have the U-bit set in the corresponding page descriptor to prevent the occurrence of the<br />
locked access during translation table searches.<br />
8.2.2 Address Error Exception<br />
An address error exception occurs when the processor attempts to prefetch an instruction<br />
from an odd address. An odd address is defined as an address in which the least significant<br />
bit is set. Some of the ways an address error exception is taken is as follows: RTS, RTD,<br />
RTR, or RTE in which the PC value in the stack is odd; a branch (conditional or unconditional),<br />
jump, or subroutine call in which the branch target address is odd; and an odd vector<br />
table entry (e.g., an odd reset vector).<br />
A stack frame of type 2 is generated when this exception is reported.The stacked PC contains<br />
the address of the instruction that caused the address error. The address field in the<br />
stack contains the branch target address with A0 cleared.<br />
If an address error occurs during the exception processing for a bus error, address error, or<br />
reset, a double bus fault occurs. The processor enters the halted state as indicated by the<br />
PST4–PST0 encoding $1C. In this case, the processor does not attempt to alter the current<br />
state of memory. Only an external reset can restart a processor halted by a double bus fault.<br />
8.2.3 Instruction Trap Exception<br />
Certain instructions are used to explicitly cause trap exceptions. The TRAP #n instruction<br />
always forces an exception and is useful for implementing system calls in user programs.<br />
The TRAPcc, TRAPV, and CHK instructions force exceptions if the user program detects an<br />
error, which can be an arithmetic overflow or a subscript value that is out of bounds. The<br />
DIVS and DIVU instructions force exceptions if a division operation is attempted with a divisor<br />
of zero.<br />
As illustrated in Figure 8-1, when a trap exception occurs, the processor internally copies<br />
the SR, enters the supervisor mode, and clears the T-bit. The processor generates a vector<br />
number according to the instruction being executed. Vector 5 is for DIVx, vector 6 is for CHK,<br />
and vector 7 is for TRAPcc and TRAPV instructions. For the TRAP #n instruction, the vector<br />
number is 32 plus n. The stack frame saves the trap vector offset, the PC, and the internal<br />
copy of the SR on the supervisor stack.<br />
A stack frame of type 0 is generated when a TRAP #n exception is taken. The saved value<br />
of the PC is the logical address of the instruction following the instruction that caused the<br />
trap. Instruction execution resumes at the address in the exception vector after the required<br />
instruction is prefetched.<br />
8-7
Exception Processing<br />
For all instruction traps other than TRAP #n, a stack frame of type 2 is generated. The<br />
stacked PC contains the logical address of the next instruction to be executed. In addition<br />
to the stacked PC, a pointer to the instruction that caused the trap is saved in the address<br />
field of the stack frame. Instruction execution resumes at the address in the exception vector<br />
after the required instruction is prefetched.<br />
8.2.4 Illegal Instruction and Unimplemented Instruction Exceptions<br />
There are eight unimplemented instruction exceptions: unimplemented integer, unimplemented<br />
effective address, unimplemented A-line, unimplemented F-line, floating-point disabled,<br />
floating-point unimplemented instruction, floating-point unsupported data type, and<br />
illegal instruction.<br />
The unimplemented integer exception corresponds to vector number 61 and occurs when<br />
the processor attempts to execute an instruction that contains a quad word operand (MULx<br />
producing a 64-bit product and DIVx using a 64-bit dividend), CAS2, CHK2, CMP2, CAS<br />
with a misaligned operand, and the MOVEP instruction. A stack frame of type 0 is generated<br />
when this exception is reported. The stacked PC points to the logical address of the unimplemented<br />
integer instruction that caused the exception.<br />
The unimplemented effective address exception corresponds to vector number 60, and<br />
occurs when the processor attempts to execute any floating-point instruction that contains<br />
an extended precision immediate source operand (F, #imm,FPx), when the processor<br />
attempts to execute an FMOVEM.L #imm, instruction of more than one<br />
floating-point control register (FPCR, FPSR, FPIAR), when the processor attempts an<br />
FMOVEM.X instruction using a dynamic register list (FMOVEM.X Dn, or FMOVEM.X,<br />
,Dn). The stack frame of type 0 is generated when this exception is reported. The<br />
stacked PC points to the logical address of the instruction that caused the exception. The<br />
FPIAR is unaffected. Refer to Section 6 Floating-Point Unit for details.<br />
An unimplemented A-line exception corresponds to vector number 10 and occurs when an<br />
instruction word pattern begins (bits 15–12) with $A. The A-line opcodes are user-reserved,<br />
and Motorola will not use any A-line instructions to extend the instruction set of any of Motorola’s<br />
processors. A stack frame of format 0 is generated when this exception is reported.<br />
The stacked PC points to the logical address of the A-line instruction word.<br />
A floating-point unsupported data type exception occurs when the processor attempts to<br />
execute a bit pattern that it recognizes as an MC68881 instruction, the floating-point unit<br />
(FPU) is enabled via the processor configuration register (PCR), the floating-point instruction<br />
is implemented, but the floating-point data type is not implemented in the MC68060<br />
FPU. This exception corresponds to vector number 55. A stack frame of type 0, 2, or 3 is<br />
generated when this exception is reported. The stacked PC points to the logical address of<br />
next instruction after the floating-point instruction. Refer to Section 6 Floating-Point Unit<br />
for details.<br />
A floating-point unimplemented instruction exception occurs when the processor attempts<br />
to execute an instruction word pattern that begins with $F, the processor recognizes this bit<br />
pattern as an MC68881 instruction, the FPU is enabled via the PCR, but the floating-point<br />
instruction is not implemented in the MC68060 FPU. This exception corresponds to vector<br />
8-8<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
number 11 and shares this vector with the floating-point disabled and the unimplemented Fline<br />
exceptions. A stack frame of type 2 is generated when this exception is reported. The<br />
stacked PC points to the logical address of the next instruction after the floating-point<br />
instruction. Refer to Section 6 Floating-Point Unit for details.<br />
A floating-point disabled exception occurs when the processor attempts to execute an<br />
instruction word pattern that begins with $F, the processor recognizes this bit pattern as an<br />
MC68881 instruction, but the FPU is disabled via the PCR, or if the processor is an<br />
MC68LC060 or an MC68EC060. This exception corresponds to vector number 11 and<br />
shares this vector with the floating-point unimplemented and the F-line Unimplemented<br />
exceptions. A type 4 stack frame is generated when this exception is reported. The stacked<br />
PC points to the logical address of the next instruction. The PC of the faulted instruction field<br />
(SP+12) points to the floating-point instruction that needs to be emulated.<br />
The effective address field (SP+8) contains the effective address of the source or destination<br />
of the memory operand for the floating-point instruction. This field is valid only if the<br />
floating-point instruction references a memory operand. If the operand is in a register (either<br />
floating-point or data register), the effective address field contains $0. For the (An)+ and<br />
–(An) addressing modes, the address register is not modified by the processor, and it is the<br />
responsibility of the third party emulation software to modify the An value before returning<br />
to the user program. For the –(An) addressing mode, the value of the effective address field<br />
contains the address of the first memory operand except if the operand size is extended precision.<br />
For the extended precision case, the effective address field contains An–4 instead of<br />
An–12. This is a key difference between the MC68LC/EC060 and the MC68LC/EC040 stack<br />
frame, and third-party software emulators written for the MC68LC/EC040 must account for<br />
this difference.<br />
An unimplemented F-line exception occurs when an instruction word pattern begins (bits<br />
15–12) with $F, the MC68060 does not recognize it as a valid F-line instruction (e.g.,<br />
PTEST), and the processor does not recognize it as a floating-point MC68881 instruction.<br />
This exception corresponds to vector number 11 and shares this vector with the floatingpoint<br />
unimplemented instruction and the floating-point disabled exceptions. A stack frame<br />
of type 0 is generated by this exception. The stacked PC points to the logical address of the<br />
F-line word.<br />
If the processor encounters any other instruction word bit patterns that are not implemented<br />
by the MC68060, and is not covered by one of the other six unimplemented instruction<br />
exceptions, the illegal instruction exception is taken. The illegal instruction exception corresponds<br />
to vector number 4. An illegal instruction exception is also taken after a breakpoint<br />
acknowledge bus cycle is terminated, either by the assertion of the transfer acknowledge<br />
(TA) or the transfer error acknowledge (TEA) signal. An illegal instruction exception can also<br />
be a MOVEC instruction with an undefined register specification field in the first extension<br />
word. The M68000 instruction set defines the opcode $4AFC as an ILLEGAL instruction.<br />
This exception is also taken when that opcode is executed. A stack frame of type 0 is generated<br />
when this exception is taken. The stacked PC points to the logical address of the illegal<br />
instruction that caused the exception.<br />
8-9
Exception Processing<br />
Exception processing for illegal and unimplemented instructions is similar to that for instruction<br />
traps. When the processor has identified an illegal or unimplemented instruction, it initiates<br />
exception processing instead of attempting to execute the instruction. The processor<br />
copies the SR, enters the supervisor mode, and clears T-bit, disabling further tracing. The<br />
processor generates the vector number according to the exception type. The illegal or unimplemented<br />
instruction vector offset, current PC, and copy of the SR are saved on the supervisor<br />
stack. Instruction execution resumes at the address contained in the exception vector.<br />
8.2.5 Privilege Violation Exception<br />
To provide system security, certain instructions are privileged. An attempt to execute one of<br />
the following privileged instructions while in the user mode causes a privilege violation<br />
exception:<br />
ANDI to SR FSAVE MOVEC PLPA<br />
CINV MOVE from SR MOVES RESET<br />
CPUSH MOVE to SR ORI to SR RTE<br />
EORI to SR MOVE USP PFLUSH STOP<br />
FRESTORE LPSTOP<br />
Exception processing for privilege violations is similar to that for illegal instructions. When<br />
the processor identifies a privilege violation, it begins exception processing before executing<br />
the instruction. As illustrated in Figure 8-1, the processor copies the SR, enters the supervisor<br />
mode, and clears the T-bit. The processor generates vector number 8, saves the privilege<br />
violation vector offset, the current PC value, and the internal copy of the SR on the<br />
supervisor stack. The saved value of the PC is the logical address of the first word of the<br />
instruction that caused the privilege violation. Instruction execution resumes after the initial<br />
instruction is fetched from the address in the privilege violation exception vector.<br />
8.2.6 Trace Exception<br />
To aid in program development, the M68000 family includes an instruction-by-instruction<br />
tracing capability. In the trace mode, an instruction generates a trace exception after the<br />
instruction completes execution, allowing a debugging program to monitor execution of a<br />
program.<br />
In general terms, a trace exception is an extension to the function of any traced instruction.<br />
The execution of a traced instruction is not complete until trace exception processing is complete.<br />
If an instruction does not complete due to an access error or address error exception,<br />
trace exception processing is deferred until after execution of the suspended instruction is<br />
resumed. If an interrupt is pending at the completion of an instruction, trace exception processing<br />
occurs before interrupt exception processing starts. If an instruction forces an<br />
exception as part of its normal execution, the forced exception processing occurs before the<br />
trace exception is processed.<br />
The T-bit in the supervisor portion of the SR controls tracing. The state of the T-bit when an<br />
instruction begins execution determines whether the instruction generates a trace exception<br />
after the instruction completes.<br />
8-10<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
Note that if the processor is executing in trace mode when a group 2 or 3 exception is signaled,<br />
a trace exception will not be generated. This means that for the second example, as<br />
the TRAP exception handler completes its execution and performs its RTE, the next instruction<br />
of the program sequence will be executed before the next trace exception is performed<br />
(the MC68060 will not trace immediately after the TRAP). If tracing is required immediately<br />
following a group 2 or 3 exception, the SR contained in the exception stack frame should be<br />
checked before returning to the next instruction. If the stacked SR indicates that the processor<br />
was executing in trace mode, the trace handler should be executed to account for the<br />
instruction that initiated the exception. Refer to 8.2 Integer Unit Exceptions for a list of<br />
group 2 or 3 exceptions.<br />
Trace exception processing starts at the end of normal processing for the traced instruction<br />
and before the start of the next instruction. As illustrated in Figure 8-1, the processor makes<br />
an internal copy of the SR and enters the supervisor mode. It also clears the T-bit of the SR,<br />
disabling further tracing. The processor supplies vector number 9 for the trace exception and<br />
saves the trace exception vector offset, PC value, and the internal copy of the SR on the<br />
supervisor stack. A stack frame of type 2 is generated when this exception is taken. The<br />
stacked value of the PC is the logical address of the next instruction to be executed. In addition,<br />
the address field of the stack contains the logical address of the instruction that caused<br />
the trace exception. Instruction execution resumes after the initial instruction is fetched from<br />
the address in the privilege violation exception vector.<br />
When the STOP or LPSTOP instruction is traced, the processor never enters the stopped<br />
condition. A STOP or LPSTOP instruction that begins execution with the T-bit set forces a<br />
trace exception after it loads the SR. Upon return from the trace exception handler, execution<br />
continues with the instruction following the STOP or LPSTOP instruction, and the processor<br />
never enters the stopped condition.<br />
8.2.7 Format Error Exception<br />
Just as the processor verifies that the bit pattern contained in the operation word represents<br />
a valid instruction, it also performs certain checks of data values for control operations. The<br />
RTE and FRESTORE instruction check the validity of the stack format code. The RTE<br />
instruction checks if the format field indicates a type supported by the processor (formats 0,<br />
2, 3 or 4). Likewise, for FPU state frames, the FRESTORE instruction checks if the upper 8<br />
bits of the status field contained in the floating-point state frame is valid ($00, $60, or $E0).<br />
If any of these checks determine that the format of the data is improper, the instruction generates<br />
a format error exception. This exception saves a stack frame of type 0, generates<br />
exception vector number 14, and continues execution at the address in the format exception<br />
vector. The stacked PC value is the logical address of the instruction that detected the format<br />
error.<br />
8.2.8 Breakpoint Instruction Exception<br />
To provide increased debug capabilities in conjunction with a hardware emulator, the<br />
MC68060 provides a series of breakpoint instructions ($4848–$484F) which generate a<br />
special external bus cycle when executed.<br />
8-11
Exception Processing<br />
When the MC68060 executes one of the breakpoint instructions, it performs a breakpoint<br />
acknowledge cycle (read cycle) with an acknowledge transfer type (TT=$3) and transfer<br />
modifier value of $0. Refer to Section 7 Bus Operation for a description of the breakpoint<br />
acknowledge cycle. After external hardware terminates the bus cycle with either TA or TEA,<br />
the processor performs illegal instruction exception processing. Refer to 8.2.4 Illegal<br />
Instruction and Unimplemented Instruction Exceptions for details on illegal instruction<br />
exception processing.<br />
8.2.9 Interrupt Exception<br />
When a peripheral device requires the services of the MC68060 or is ready to send information<br />
that the processor requires, it can signal the processor to take an interrupt exception<br />
using the IPLx signals. The three signals encode a value of 0–7 (IPL0 is the least significant<br />
bit). High levels on all three signals correspond to no interrupt requested (level 0). Values<br />
1–7 specify one of seven levels of interrupts, with level 7 having the highest priority. Table<br />
8-2 lists the interrupt levels, the states of IPLx that define each level, and the SR interrupt<br />
mask value that allows an interrupt at each level.<br />
8-12<br />
Table 8-2. Interrupt Levels and Mask Values<br />
Requested<br />
Control Line Status Interrupt Mask Level Required<br />
Interrupt Level IPL2 IPL1 IPL0<br />
for Recognition<br />
0 Negated Negated Negated No Interrupt Requested<br />
1 Negated Negated Asserted 0<br />
2 Negated Asserted Negated 0–1<br />
3 Negated Asserted Asserted 0–2<br />
4 Asserted Negated Negated 0–3<br />
5 Asserted Negated Asserted 0–4<br />
6 Asserted Asserted Negated 0–5<br />
7 Asserted Asserted Asserted 0–7<br />
When an interrupt request has a priority higher than the value in the interrupt priority mask<br />
of the SR (bits 10–8), the processor makes the request a pending interrupt. Priority level 7,<br />
the nonmaskable interrupt, is a special case. Level 7 interrupts cannot be masked by the<br />
interrupt priority mask, and they are transition sensitive. The processor recognizes an<br />
interrupt request each time the external interrupt request level changes from some lower<br />
level to level 7, regardless of the value in the mask. Figure 8-3 shows two examples of<br />
interrupt recognitions, one for level 6 and one for level 7. When the MC68060 processes a<br />
level 6 interrupt, the SR mask is automatically updated with a value of 6 before entering the<br />
handler routine so that subsequent level 6 interrupts and lower level interrupts are masked.<br />
Provided no instruction that lowers the mask value is executed, the external request can be<br />
lowered to level 3 and then raised back to level 6 and a second level 6 interrupt is not<br />
processed. However, if the MC68060 is handling a level 7 interrupt (SR mask set to level 7)<br />
and the external request is lowered to level 3 and than raised back to level 7, a second level<br />
7 interrupt is processed. The second level 7 interrupt is processed because the level 7<br />
interrupt is transition sensitive. A level comparison also generates a level 7 interrupt if the<br />
request level and mask level are at 7 and the priority mask is then set to a lower level (as<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
with the MOVE to SR or RTE instruction). The level 6 interrupt request and mask level<br />
example in Figure 8-3 is the same as for all interrupt levels except 7.<br />
LEVEL 6 EXAMPLE<br />
LEVEL 7 EXAMPLE<br />
EXTERNAL<br />
IPL2–IPL0<br />
100 ($3) 101 ($5)<br />
INTERRUPT PRIORITY<br />
MASK (I2–I0) ACTION<br />
IF 001 ($6) AND 101 ($5) THEN LEVEL 6 INTERRUPT<br />
IF 100 ($3) AND STILL 110 ($6) THEN NO ACTION<br />
IF 001 ($6) AND STILL 110 ($6) THEN NO ACTION<br />
Figure 8-3. Interrupt Recognition Examples<br />
(INITIAL CONDITIONS)<br />
(LEVEL COMPARISON)<br />
IF STILL 001 ($6) AND RTE SO THAT 101 ($5) THEN LEVEL 6 INTERRUPT (LEVEL COMPARISON)<br />
100 ($3) 101 ($5)<br />
IF 000 ($7) AND 101 ($5) THEN LEVEL 7 INTERRUPT<br />
IF 000 ($7) AND 111 ($7) THEN NO ACTION<br />
IF 100 ($3) AND STILL 111 ($7) THEN NO ACTION<br />
(INITIAL CONDITIONS)<br />
(TRANSITION)<br />
IF 000 ($7) AND STILL 111 ($7) THEN LEVEL 7 INTERRUPT (TRANSITION)<br />
IF STILL 000 ($7) AND RTE SO THAT 101 ($5) THEN LEVEL 7 INTERRUPT (LEVEL COMPARISON)<br />
Note that a mask value of 6 and a mask value of 7 both inhibit request levels of 1–6 from<br />
being recognized. In addition, neither masks an interrupt request level of 7. The only difference<br />
between mask values of 6 and 7 occurs when the interrupt request level is 7 and the<br />
mask value is 7. If the mask value is lowered to 6, a second level 7 interrupt is recognized.<br />
External circuitry can chain or otherwise merge signals from devices at each level, allowing<br />
an unlimited number of devices to interrupt the processor. When several devices are connected<br />
to the same interrupt level, each device should hold its interrupt priority level constant<br />
until its corresponding interrupt acknowledge bus cycle ensures that all requests are processed.<br />
Refer to Section 7 Bus Operation for details on the interrupt acknowledge cycle.<br />
Figure 8-4 illustrates a flowchart for interrupt exception processing. When processing an<br />
interrupt exception, the processor first makes an internal copy of the SR, sets the mode to<br />
supervisor, suppresses tracing, and sets the processor interrupt mask level to the level of<br />
the interrupt being serviced. The processor attempts to obtain a vector number from the<br />
8-13
Exception Processing<br />
interrupting device using an interrupt acknowledge bus cycle with the interrupt level number<br />
output on the transfer modifier signals. For a device that cannot supply an interrupt vector,<br />
the autovector signal (AVEC) must be asserted. In this case, the MC68060 uses an internally<br />
generated autovector, which is one of vector numbers 25–31, that corresponds to the<br />
interrupt level number (see Table 8-1). If external logic indicates a bus error during the interrupt<br />
acknowledge cycle, the interrupt is considered spurious, and the processor generates<br />
the spurious interrupt vector number, 24.<br />
Once the vector number is obtained, the processor creates a stack frame of type 0. In this<br />
stack frame, the processor saves the exception vector offset, PC value, and the internal<br />
copy of the SR on the supervisor stack. The saved value of the PC is the logical address of<br />
the next instruction had the interrupt not occurred.<br />
Unlike previous processors of the M68000 family, the MC68060 defers interrupt sampling<br />
from the beginning of exception processing of any exception, up to and until the first instruction<br />
of the exception handler. This allows the first instruction of any exception handler to<br />
raise the interrupt mask level and therefore execute the exception handler without interrupts<br />
(except level 7 interrupts).<br />
Most M68000 family peripherals use programmable interrupt vector numbers as part of the<br />
interrupt acknowledge operation for the system. If this vector number is not initialized after<br />
reset and the peripheral must acknowledge an interrupt request, the peripheral usually<br />
returns the vector number for the uninitialized interrupt vector, 15.<br />
8.2.10 Reset Exception<br />
Asserting the reset in (RSTI) input signal causes a reset exception. The reset exception has<br />
the highest priority of any exception; it provides for system initialization and recovery from<br />
catastrophic failure. Reset also aborts any processing in progress when RSTI is recognized;<br />
processing cannot be recovered. Figure 8-5 is a flowchart of the reset exception processing.<br />
The reset exception places the processor the supervisor mode by setting the S-bit and disables<br />
tracing by clearing the T-bit in the SR. This exception also sets the processor’s interrupt<br />
priority mask in the SR to the highest level, level 7. Next the VBR is initialized to zero<br />
($00000000), and all bits in the cache control register (CACR) for the on-chip caches are<br />
cleared. The reset exception also clears the translation control register (TCR). It clears the<br />
enable bit in each of the four transparent translation registers (TTRs). It also clears the bus<br />
control register (BUSCR), and the PCR. The reset also affects the FPU. A quiet not-a-number<br />
(NAN) is loaded into each of the seven floating-point registers, and the floating-point<br />
control register (FPCR), floating-point status register (FPSR), and floating-point instruction<br />
address register (FPIAR) are cleared. If the processor is granted the bus, and the processor<br />
does not detect TS asserted (possibly by an alternate master), the processor then performs<br />
two long-word read bus cycles. The first long word, at address 0, is loaded into the SP, and<br />
the second long word, at address 4, is loaded into the PC. Reset exception processing concludes<br />
with the transfer of control to the memory location defined by the PC.<br />
After the initial instruction is fetched, program execution begins at the address in the PC.<br />
The reset exception does not flush the ATCs or invalidate entries in the instruction or data<br />
caches; it does not save the value of either the PC or the SR. If an access error or address<br />
8-14<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
ENTRY<br />
SAVE INTERNAL<br />
COPY OF SR<br />
S<br />
T<br />
I2–I0<br />
=<br />
=<br />
=<br />
FETCH VECTOR<br />
FROM INTERRUPTING<br />
DEVICE<br />
IF NO VECTOR #<br />
AUTOVECTOR #25–#31<br />
1<br />
0<br />
LEVEL OF<br />
INTERRUPT<br />
VECTOR OFFSET,<br />
PC, AND SR ➧<br />
STACK FRAME<br />
CALCULATE ADDRESS<br />
OF FIRST INSTRUCTION<br />
OF HANDLER<br />
FETCH FIRST<br />
INSTRUCTION<br />
OF HANDLER<br />
OTHERWISE<br />
BEGIN INSTRUCTION<br />
EXECUTION<br />
EXIT<br />
BUS ERROR<br />
SPURIOUS INTERRUPT<br />
VECTOR #24<br />
BUS ERROR<br />
BUS ERROR OR<br />
ADDRESS ERROR<br />
Figure 8-4. Interrupt Exception Processing Flowchart<br />
<strong>M68060</strong> USER’S MANUAL<br />
PROCESS<br />
ACCESS ERROR<br />
Exception Processing<br />
error occurs during the exception processing sequence for a reset, a double bus fault is generated.<br />
The processor halts and signals the double bus fault status on the processor status<br />
outputs ([PST4–PST0] = $1C). Execution of the reset instruction does not cause a reset<br />
exception, nor does it affect any internal registers except the PC. The execution of this<br />
EXIT<br />
8-15
Exception Processing<br />
instruction causes the MC68060 to assert the RSTO signal, allowing other devices within<br />
the system to be reset.<br />
8-16<br />
ENTRY<br />
S-BIT OF SR<br />
T-BIT OF SR<br />
I2–I0 BITS OF SR<br />
VBR<br />
CACR<br />
DTTn[E-BIT]<br />
ITTn[E-BIT]<br />
TCR<br />
BUSCR<br />
PCR<br />
FP DATA REGS.<br />
FP CONTROL REGS.<br />
FETCH VECTOR #0<br />
OTHERWISE<br />
VECTOR #0 ➧ SP<br />
FETCH VECTOR #1<br />
OTHERWISE<br />
VECTOR #1 ➧<br />
PC<br />
FETCH FIRST<br />
INSTRUCTION<br />
EXIT<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
=<br />
OTHERWISE<br />
BEGIN INSTRUCTION<br />
EXECUTION<br />
1<br />
0<br />
$7<br />
$0<br />
$0<br />
0<br />
0<br />
$0<br />
$0<br />
$0<br />
NAN<br />
$0<br />
BUS ERROR<br />
BUS ERROR<br />
BUS ERROR OR<br />
ADDRESS ERROR<br />
(DOUBLE BUS FAULT)<br />
(DOUBLE BUS FAULT)<br />
(DOUBLE BUS FAULT)<br />
Figure 8-5. Reset Exception Processing Flowchart<br />
<strong>M68060</strong> USER’S MANUAL<br />
HALTED STATE<br />
(PST4–PST0 = $1C)<br />
EXIT<br />
MOTOROLA
8.3 EXCEPTION PRIORITIES<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
Exceptions can be divided into the five basic groups identified in Table 8-3. These groups<br />
are defined by specific characteristics and the order in which they are handled. Table 8-3<br />
represents the priority used for simultaneous faults, as viewed by the MC68060 hardware.<br />
In Table 8-3, 0.0 represents the highest priority, while 4.1 is the lowest. Note that there are<br />
shared priorities for exceptions within Group 3, since these types are mutually exclusive.<br />
Table 8-3. Exception Priority Groups<br />
Group.Priority Exception and Relative Priority Characteristics<br />
0.0 Reset<br />
The processor aborts all processing (instruction<br />
or exception) and does not save old context.<br />
1.0<br />
1.1<br />
1.2<br />
2.0<br />
2.1<br />
2.2<br />
2.3<br />
2.4<br />
2.5<br />
2.6<br />
Address Error<br />
Instruction Access Error<br />
Data Access Error<br />
A-Line Unimplemented<br />
F-Line Unimplemented<br />
Illegal Instruction<br />
Privilege Violation<br />
Unimplemented EA<br />
Unimplemented Integer<br />
Floating-Point Unimplemented Instruction,<br />
Floating-Point Unsupported Data Type<br />
The processor suspends processing and saves<br />
the processor context.<br />
Exception processing begins before the<br />
instruction is executed.<br />
Exception processing begins after the initial<br />
memory operand address is calculated, but<br />
before instruction is executed.<br />
3.0<br />
3.1<br />
3.2<br />
3.3<br />
3.4<br />
3.5<br />
3.6<br />
Floating-Point BSUN<br />
* , CHK, CHK2, Divide-by-<br />
Zero, TRAPV, TRAPcc, TRAP #n, RTE Format<br />
Error<br />
Floating-Point SNAN*<br />
Floating-Point OPERR*<br />
Floating-Point OVFL*<br />
Floating-Point UNFL*<br />
Floating-Point DZ*<br />
Floating-Point INEX*<br />
Exception processing is part of instruction<br />
execution and begins after instruction<br />
execution.<br />
4.0 Trace<br />
Exception processing begins when the current<br />
4.1 Interrupt<br />
instruction is completed.<br />
*<br />
Refer to Section 6 Floating-Point Unit (MC68060 Only) for details concerning floating-point instructions. For<br />
the case of an emulated FTRAPcc instruction and a floating-point BSUN exception, the BSUN is considered<br />
higher priority.<br />
Within an MC68060 system, more than one exception can occur at the same time. The reset<br />
exception is unique; central processing unit (CPU) reset overrides and clears all other<br />
exceptions which may have occurred at the same time. All other exceptions are handled<br />
according to the priority relationship defined in Table 8-3.<br />
The method used to process exceptions in the MC68060 is similar to that found on the<br />
MC68040 due to the restart exception model. In general, when multiple exceptions are<br />
pending, the exception with the highest priority is processed first, and the remaining exceptions<br />
are regenerated when the original faulting instruction is restarted.<br />
To clarify the exception priority within group 1, it is important to note that instruction fetch<br />
pipeline (IFP) access errors are not recognized until the faulted portion of the instruction is<br />
actually used (or attempted to be used). As an example, consider a “move.l (An), xxx.l”<br />
instruction. If the source operand defined at the address contained in An is faulted, the operand<br />
access error will occur. If the extension words defining the destination address are also<br />
faulted, the IFP access error would be processed after the source operand fault. Thus, in<br />
8-17
Exception Processing<br />
this example, the instruction has two faults (instruction access error and operand access<br />
error), but the faults are not simultaneous and appear as an operand access error on the<br />
source address and an instruction access error on the destination address to the processor.<br />
Another item to note is that for instructions with indirect addresses, the processing of the<br />
indirection is always completed prior to the instruction entering normal OEP sequence control.<br />
To illustrate the handling of multiple exceptions, consider first a pending interrupt being<br />
posted while a program is executing in trace mode (i.e., bit 15 of the SR is set).<br />
Since the processor always samples for pending interrupts and traces at the conclusion of<br />
instruction execution, both the trace and the interrupt appear simultaneous to the processor.<br />
Since the trace has higher priority than the interrupt (4.0 versus 4.1), trace exception processing<br />
begins. After the first instruction of the trace exception handler has been executed,<br />
the processor again samples for pending interrupts. Providing the previous interrupt is still<br />
pending, the processor now begins interrupt exception processing. As the interrupt handler<br />
completes execution, control returns to the trace handler. As the trace handler completes,<br />
control returns to the original program.<br />
As a second example of the handling of multiple exceptions, consider the prior scenario (a<br />
pending interrupt being posted while a program is executing in trace mode) at the same time<br />
a TRAP instruction enters the OEP.<br />
As described before, since the processor always samples for pending interrupts and traces<br />
at the conclusion of instruction execution, both the trace and the interrupt appear simultaneous<br />
to the processor. Since the trace has higher priority than the interrupt, trace exception<br />
processing begins. After the first instruction of the trace exception handler has been executed,<br />
the processor again samples for pending interrupts. Providing the previous interrupt<br />
is still pending, the processor begins interrupt exception processing. As the interrupt handler<br />
completes execution, control returns to the trace handler. As the trace handler completes,<br />
control returns to the original program, where the TRAP instruction is executed, causing that<br />
exception to occur.<br />
Note that if the processor is executing in trace mode when a group 2 or 3 exception is signaled,<br />
a trace exception will not be generated. This means that for the second example, as<br />
the TRAP exception handler completes its execution and performs its RTE, the next instruction<br />
of the program sequence will be executed before the next trace exception is performed<br />
(the MC68060 will not trace immediately after the TRAP). If tracing is required immediately<br />
following a group 2 or 3 exception, the SR contained in the exception stack frame should be<br />
checked before returning to the next instruction. If the stacked SR indicates that the processor<br />
was executing in trace mode, the trace handler should be executed to account for the<br />
instruction that initiated the exception.<br />
Considering the previous example, the TRAP handler should check the stacked SR, and<br />
since the processor was executing in trace mode, pass control to the trace handler. If this<br />
check is not made, the next trace exception will not occur until the instruction after the TRAP<br />
has completed execution.<br />
8-18<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
8.4 RETURN FROM EXCEPTIONS<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Exception Processing<br />
Once the processor has completed processing of all exceptions, it must restore the machine<br />
context at the time of the initial exception before returning control to the original process.<br />
Since the MC68060 is a complete restart machine, when the processor executes an RTE<br />
instruction, only three fields are referenced. The stack format is accessed (SP+6) and the<br />
frame type is first verified. If the format indicates an invalid type, a format error exception is<br />
signaled. Otherwise, the processor accesses the SR (SP) and PC (SP+2) fields from the top<br />
of the supervisor stack. If the PC value defines an odd address (least significant address bit<br />
is set), then an address error exception is signaled. Note that for the format error or the<br />
address error, the new stack frame will contain the SR value at the time the RTE’s execution<br />
began, i.e., the SR has not been corrupted by the execution of the RTE. For either fault, the<br />
PC is the logical address of the RTE instruction.<br />
Given a valid stack format and a nonfaulting PC, the SR and PC are loaded with the stack<br />
operands, the SSP adjusted by the appropriate value determined by the format field, and<br />
control passed to the location defined by the new PC.<br />
When the processor writes or reads a stack frame, it uses long-word operand transfers<br />
wherever possible. Using a long-word-aligned SP enhances exception processing performance.<br />
The processor does not necessarily read or write the stack frame data in sequential<br />
order. The following paragraphs discuss in detail each stack frame format.<br />
Note that unlike any of the previous M68000 processors, the MC68060 RTE instruction<br />
treats the access error frame no differently from other frames.<br />
8.4.1 Four-Word Stack Frame (Format $0)<br />
If a four-word stack frame is on the stack and an RTE instruction is encountered, the processor<br />
updates the SR and PC with the data read from the stack, increments the stack<br />
pointer by eight, and resumes normal instruction execution<br />
SP<br />
+$02<br />
+$06<br />
15<br />
Stack Frames Exception Types Stacked PC Points To<br />
STATUS REGISTER<br />
PROGRAM COUNTER<br />
0 0 0 0 VECTOR OFFSET<br />
FOUR-WORD STACK FRAME–FORMAT $0<br />
0<br />
• Interrupt<br />
• Format Error<br />
• TRAP #N<br />
• Illegal Instruction<br />
• A-Line Instruction<br />
• F-Line Instruction<br />
• Privilege Violation<br />
• Floating-Point Pre-Instruction<br />
• Unimplemented Integer<br />
• Unimplemented Effective Address<br />
• Next Instruction<br />
• RTE or FRESTORE Instruction<br />
• Next Instruction<br />
• Illegal Instruction<br />
• A-Line Instruction<br />
• F-Line Instruction<br />
• First Word of Instruction<br />
Causing Privilege Violation<br />
• Floating-Point Instruction<br />
• Unimplemented Integer Instruction<br />
• Instruction That Used the Unimplemented<br />
Effective Address<br />
8-19
Exception Processing<br />
8.4.2 Six-Word Stack Frame (Format $2)<br />
If a six-word stack frame is on the stack and an RTE instruction is encountered, the processor<br />
restores the SR and PC values from the stack, increments the SSP by $C, and resumes<br />
normal instruction execution.<br />
8.4.3 Floating-Point Post-Instruction Stack Frame (Format $3)<br />
In this case, the processor restores the SR and PC values from the stack and increments<br />
the supervisor stack pointer by $C. If another floating-point post-instruction exception is<br />
pending, exception processing begins immediately for the new exception; otherwise, the<br />
processor resumes normal instruction execution.<br />
8-20<br />
SP<br />
+$02<br />
+$06<br />
+$08<br />
SP<br />
+$02<br />
+$06<br />
+$08<br />
15<br />
Stack Frames Exception Types<br />
STATUS REGISTER<br />
PROGRAM COUNTER<br />
0 0 1 0 VECTOR OFFSET<br />
ADDRESS<br />
SIX-WORD STACK FRAME–FORMAT $2<br />
0<br />
• CHK, CHK2 (Emulated),<br />
TRAPcc, FTRAPcc(Emulated),<br />
TRAPV, Trace, or Zero Divide<br />
• Unimplemented Floating-<br />
Point Instruction<br />
• Address Error<br />
<strong>M68060</strong> USER’S MANUAL<br />
Stacked PC Points To;<br />
Address Field Has<br />
• Next Instruction; Address field<br />
has the address of the instruction<br />
that caused the exception.<br />
• Next Instruction; Address field<br />
has the calculated for<br />
the floating-point instruction.<br />
• Instruction that caused the address<br />
error; Address field has<br />
the branch target address with<br />
A0=0.<br />
Stack Frames Exception Types<br />
Stacked PC Points To;<br />
Effective Address Field<br />
15<br />
STATUS REGISTER<br />
PROGRAM COUNTER<br />
0 • Floating-Point Post-Instruction • Next Instruction; Effective<br />
Address field is the calculated<br />
effective address for the floating-point<br />
instruction.<br />
0 0 1 1 VECTOR OFFSET<br />
EFFECTIVE ADDRESS<br />
FLOATING-POINT POST-INSTRUCTION<br />
STACK FRAME–FORMAT $3<br />
MOTOROLA
8.4.4 Eight-Word Stack Frame (Format $4)<br />
Exception Processing<br />
An eight-word stack frame is created for data and instruction access errors. It is also used<br />
for the floating-point disabled exception. Refer to 8.2.4 Illegal Instruction and Unimplemented<br />
Instruction Exceptions for details on the use of this frame for the floating-point disabled<br />
exception. The following paragraphs describe in detail the format for this frame as<br />
used by for the access error and how the processor uses it when returning from exception<br />
processing.<br />
SP<br />
+$02<br />
+$06<br />
+$08<br />
+$0C<br />
15<br />
Stack Frames Exception Types Stacked PC Points To<br />
STATUS REGISTER<br />
PROGRAM COUNTER<br />
0 1 0 0 VECTOR OFFSET<br />
FAULT ADDRESS or<br />
EFFECTIVE ADDRESS*<br />
FAULT STATUS LONGWORD (FSLW) or<br />
PC OF FAULTED INSTRUCTION*<br />
EIGHT-WORD STACK FRAME–FORMAT $4<br />
* Defined for the Floating-Point Disabled Exception<br />
0<br />
• Data or Instruction Access<br />
Fault (ATC Fault or Bus Error)<br />
• Floating-Point Disabled Exception<br />
• See 8.4.4.1 Program<br />
Counter (PC), 8.4.4.2 Fault<br />
Address, and 8.4.4.3 Fault<br />
Status Long Word (FSLW)<br />
for additional information.<br />
• Next instruction; Effective<br />
Address Field has calculated<br />
of memory operand (if<br />
any); PC of Faulted Instruction<br />
points to the F-line instruction<br />
word of the floatingpoint<br />
instruction.<br />
8.4.4.1 Program Counter (PC). On read access faults, the PC points to the instruction that<br />
caused the access error. This instruction is restarted when an RTE is executed, hence, the<br />
read cycle is re-executed. On read access errors on the second or later of misaligned reads,<br />
the read cycles that are successful prior to the access error are re-executed since the processor<br />
uses a restart model for recovery from exceptions.<br />
Programs that rely on a read bus error to test for the existence of I/O or peripheral devices<br />
must increment the value of the PC prior to the execution of the RTE instruction. Incrementing<br />
the PC involves the calculation of the instruction length, which is dependent on the<br />
addressing mode used. To avoid having to calculate the instruction length, it is possible to<br />
use a NOP-TEST_WRITE-NOP instead of a TEST_READ of the I/O or peripheral device.<br />
The initial NOP causes all prior write cycles to complete. The TEST_WRITE causes the<br />
access error, and if the write cycle is to imprecise operand space, the stacked PC of the<br />
access error stack contains the address of the second NOP. When the RTE is executed,<br />
instruction execution resumes at the second NOP. The limitation of this method is that it<br />
works only if the I/O device is mapped to imprecise operand space. If the write is to a precise<br />
operand space, the processor does not increment the PC, and the stacked PC contains the<br />
instruction address of the TEST_WRITE.<br />
On write access errors, the PC points to the instruction that causes the access error except<br />
for bus error (TEA) on writes that involve the push and store buffers. Refer to 8.4.4.3 Fault<br />
Status Long Word (FSLW) for specific information on these write cases. For these write<br />
cases, the PC does not point to the instruction that caused the access error. Hence the write<br />
cycle that incurred the bus error is lost. In general, bus errors on writes must be avoided.<br />
The processor provides little support for recovery on bus errored write cycles to imprecise<br />
operand spaces. For precise spaces, both the faulting PC and logical operand address are<br />
directly provided in the exception frame.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 8-21
Exception Processing<br />
I/O devices or peripherals that use multiple pages (paged MMU) to define the cache mode<br />
and that cannot tolerate duplicate reads must not allow code that causes misaligned reads<br />
that cross page boundaries. In this case, either use the TTRs or the default TTR to define<br />
the I/O or peripheral cache mode. I/O devices or peripherals must not be accessed using<br />
instructions which perform both read and write cycles (e.g., a memory-to-memory move)<br />
unless the devices accessed are capable of handling rerun cycles caused by a processor<br />
with a restart recovery model.<br />
8.4.4.2 Fault Address. The fault address field contains the logical address of the access<br />
that incurred the access error. The SIZE, TT, TM, R- and W-bits of the FSLW qualify the fault<br />
address. For MMU-related exceptions (e.g., missing page faults, write protect, supervisor<br />
protect), the fault address is the logical address calculated by the integer unit. For misaligned<br />
operand access faults, the fault address points to the initial logical address calculated<br />
by the integer unit regardless of which bus cycle actually faulted. For instruction<br />
extension word faults, this field points to the logical address of the instruction opword and<br />
not the extension word.<br />
8.4.4.3 Fault Status Long Word (FSLW) . The FSLW information indicates whether an<br />
access to the instruction stream or the data stream (or both) caused the fault and contains<br />
status information for the faulted access. Figure 8-6 illustrates the FSLW format.<br />
31 28 27 26 25 24 23 22 21 20 19 18 16<br />
RESERVED MA RESERVED LK RW SIZE TT<br />
TM<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
IO PBE SBE PTA PTB IL PF SP WP TWE RE WE TTR BPE RESERVED<br />
SEE<br />
Figure 8-6. Fault Status Long-Word Format<br />
Bits 31–28, 26, and 1—Reserved by Motorola.<br />
IO, MA—Instruction or Operand, Misaligned Access<br />
IO,MA<br />
0, 0 = Fault occurred on the first access of a misaligned transfer, or to the<br />
only access of an aligned transfer.<br />
0, 1 = Fault occurred on the second or later access of a misaligned<br />
transfer.<br />
1, 0 = Fault occurred on an instruction opword fetch.<br />
1, 1 = Fault occurred on a fetch of an extension word.<br />
LK—Locked Transfer<br />
0 =Fault did not occur on a locked transfer.<br />
1 =Fault occurred on a locked transfer initiated by the processor (e.g., TAS, CAS, table<br />
searches. Also set on locked transfers within the boundaries defined by the<br />
MOVEC of BUSCR (LOCK bit) instruction.<br />
8-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Exception Processing<br />
RW—Read and Write<br />
00 = Undefined, reserved<br />
01 = Write<br />
10 = Read<br />
11 = Read-Modify-Write<br />
A read-modify-write indicates that the referenced address is capable of being read and<br />
written. For example, for an ADD D0, instruction, the memory operand is read, modified,<br />
and then written by this instruction. A read-modify-write does not imply a “locked”<br />
sequence.<br />
SIZE—Transfer Size<br />
00 = Byte<br />
01 = Word<br />
10 = Long<br />
11 = Double Precision or MOVE16<br />
The SIZE field corresponds to the original access size. If a data cache line read results<br />
from a read miss and the line read encounters a bus error, the SIZE field in the resulting<br />
stack frame indicates the size of the original read generated by the execution unit.<br />
TT—Transfer Type<br />
This field defines the TT1–TT0 signal encoding for the faulted access.<br />
TM—Transfer Modifier<br />
This field defines the TM2–TM0 signal encoding for the faulted access.<br />
PBE—Push Buffer Bus Error<br />
0 = Fault not caused by a bus error (TEA asserted) during a push buffer write.<br />
1 = Fault caused by a bus error (TEA asserted) during a push buffer write.<br />
SBE—Store Buffer Bus Error<br />
0 =Fault not caused by a bus error (TEA asserted) during a store buffer write.<br />
1 =Fault caused by a bus error (TEA asserted) during a store buffer write.<br />
PTA—Pointer A Fault<br />
0 =Fault not due to an invalid root level descriptor.<br />
1 =Fault due to an invalid root level descriptor.<br />
PTB—Pointer B Fault<br />
0 =Fault not due to an invalid pointer level descriptor.<br />
1 =Fault due to an invalid pointer level descriptor.<br />
IL—Indirect Level Fault<br />
0 =Fault not due to encountering a second indirect page descriptor.<br />
1 =Fault due to encountering a second indirect page descriptor.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 8-23
Exception Processing<br />
PF—Page Fault<br />
0 =Fault not due to an invalid page descriptor.<br />
1 =Fault due to an invalid page descriptor.<br />
SP—Supervisor Protect<br />
0 =Fault not due to user process accessing a page that is supervisor protected.<br />
1 =Fault due to user process accessing a page that is supervisor protected.<br />
WP—Write Protect<br />
0 =Fault not due to a write access on a write-protected page.<br />
1 =Fault due to a write access on a write-protected page.<br />
TWE—Bus Error (TEA asserted) on Table Search<br />
0 =Fault is not caused by a bus error during any MMU table search read or write.<br />
1 =Fault is caused by a bus error during any MMU table search read or write.<br />
RE—Bus Error (TEA asserted) on Read<br />
0 =Fault is not caused by a bus error on a read cycle.<br />
1 =Fault is caused by a bus error on a read cycle.<br />
WE—Bus Error (TEA asserted) on Write<br />
0 =Fault is not caused by a bus error on a write cycle.<br />
1 =Fault is caused by a bus error on a write cycle.<br />
TTR—TTR Hit<br />
0 =Fault is detected on an access that is mapped by the a paged MMU translation or a<br />
default TTR translation.<br />
1 =Fault is detected on an access that is mapped by one of the four TTRs.<br />
BPE—Branch Prediction Error<br />
0 =Fault is not caused by a branch prediction error.<br />
1 =Fault is caused by a branch prediction error.<br />
Refer to 8.4.7 Branch Prediction Error for details on this error type.<br />
SEE—Software Emulation Error<br />
0 =Fault is not caused by a software emulation error.<br />
1 =Fault is caused by a software emulation error.<br />
The processor does not set the SEE bit. This bit is used by the <strong>M68060</strong>SP to indicate a<br />
software emulation error case. Refer to Appendix C MC68060 Software Package for<br />
details on how this bit is set.<br />
8-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
8.4.5 Recovering from an Access Error<br />
Exception Processing<br />
The access error exception handler can identify the cause of the fault by examining the<br />
FSLW. Unlike earlier processors, the MC68060 provides all the information needed to identify<br />
the fault by examining the FSLW. Note that this section does not discuss the use of the<br />
SEE (software emulation error) bit nor does it provide the procedure needed to support the<br />
<strong>M68060</strong>SP misaligned CAS and CAS2 emulation code. Refer to Appendix C MC68060<br />
Software Package for details of how access error recovery is affected by the <strong>M68060</strong>SP.<br />
The first step to recovering from an access error is for the exception handler to determine<br />
whether or not a branch prediction error has occurred. See 8.4.7 Branch Prediction Error<br />
for details on how a branch prediction error occurs. If the BPE bit in the FSLW is set, flush<br />
the branch cache and continue with normal access error handling. If no other faults are indicated,<br />
then execute an RTE and continue normal operations.<br />
The second step for the handler is to determine whether or not the access error is recoverable.<br />
In general, bus errors (TEA Asserted) on write cycles must be avoided. Refer to 8.4.6<br />
Bus Errors and Pending Memory Writes for further details of bus errors and pending<br />
memory writes. In summary, check for any of the following nonrecoverable write cases:<br />
• PBE = 1 (push buffer bus error)<br />
• SBE = 1 (store buffer bus error)<br />
• RW = 11, IO = 0, MA=1 (bus error on misaligned read-modify-write)<br />
• RW = 01, for a MOVE , in which the destination operand writes over the<br />
source operand.<br />
For these nonrecoverable write cases, the write reference has been lost and it is up to the<br />
system software designer to determine the next course of action. Probably the most prudent<br />
course of action is to discontinue the user program and enter a known supervisor state.<br />
The third step is to handle the transparent translation access error cases. This is indicated<br />
by TTR=1. All of these cases are recoverable as long as step two from above has been taken<br />
out. At this point, the access error may be caused by the following errors, which are mutually<br />
exclusive.<br />
• SP = 1 (supervisor protection violation detected by one of the four TTRs)<br />
• WP = 1 (write protection violation detected by one of the four TTRs)<br />
• RE = 1 (bus error on read)<br />
• WE = 1 (bus error on write)<br />
For the SP = 1 or WP = 1 cases, it is possible to modify the transparent translation descriptor<br />
to allow the access to occur once the instruction is restarted.<br />
For the RE = 1 or WE = 1 cases, unless the cause of the bus error is removed, when the<br />
instruction is restarted, the access error handler is re-entered, possibly resulting in an infinite<br />
loop.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 8-25
Exception Processing<br />
The fourth step is to handle the paged memory management invalid descriptor cases. This<br />
step is unnecessary if using an MC68EC060 or if the paged MMU is disabled. An invalid descriptor<br />
is indicated by TTR = 0, and any one of the following bits are set: PTA, PTB, IL, PF,<br />
and TWE. These bits indicate the cause of the access error and are mutually exclusive:<br />
• TWE = 1 (bus error detected during MMU table search reads or writes)<br />
• PTA = 1 (invalid root level descriptor)<br />
• PTB = 1 (invalid pointer-level descriptor)<br />
• IL = 1 (a second indirect level descriptor is encountered)<br />
• PF = 1 (invalid page descriptor)<br />
Of the above cases, the TWE bit case must be handled with special care. Since no information<br />
is given as to when the bus error is encountered, it is possible to encounter the bus error<br />
again in the process of locating the fault.<br />
The paged memory management architecture allows for only one level of indirection. A page<br />
descriptor of type indirect must point to a page descriptor of type resident. If that second<br />
page descriptor is of type invalid, an exception is taken such that PF = 1. If that second page<br />
descriptor is of type indirect, a second level of indirection is attempted, and an exception is<br />
taken such that IL = 1. If IL = 1, the handler must supply a page descriptor of type resident.<br />
The PTA, PTB, PF cases require that the exception handler allocate physical memory for<br />
the appropriate page and update the appropriate descriptor. When the instruction is<br />
restarted, the table search either encounters the next table search fault or executes successfully.<br />
It is important to note that the MC68060 performs table searches in hardware and does not<br />
use the fetch table and page descriptors from the cache. The descriptor tables must be<br />
placed in noncachable memory so that when the exception handler touches these descriptors,<br />
that the physical image in memory is updated properly.<br />
Also note that since table searches that result in invalid descriptors (TWE, PTA, PTB, IL, PF)<br />
do not update the ATC, the ATC need not be flushed by the exception handler.<br />
The fifth step is to handle the paged memory management protection violation and bus error<br />
cases. This step is unnecessary if using an MC68EC060 or if the paged MMU is disabled.<br />
At this point, the table search has resulted in a valid page descriptor, and that the ATC has<br />
been updated. As long as fourth step above is handled, following causes are possible and<br />
are mutually exclusive:<br />
• SP = 1 (supervisor protection violation detected by paged MMU)<br />
• WP = 1 (write protection violation detected by paged MMU)<br />
• RE = 1 (bus error on read)<br />
• WE = 1 (bus error on write)<br />
For the protection violation cases (SP and WP), if the access is to be allowed, the page<br />
descriptor must be updated, and the corresponding ATC entry must be flushed. When the<br />
8-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Exception Processing<br />
instruction is restarted, another table search is performed, and the instruction is executed<br />
successfully. If the access is not allowed, it is up to the system software designer to determine<br />
appropriate action.<br />
For the physical bus error cases, as long as it is not one of the non-recoverable write cases,<br />
the exception handler must fix the page descriptor to point to a different physical memory,<br />
so that when the restart of the instruction occurs, that bus error does not recur.<br />
It is important to note that the MC68060 performs table searches in hardware, and does not<br />
use the fetch table and page descriptors from the cache. The descriptor tables must be<br />
placed in non-cachable memory so that when the exception handler touches these descriptors,<br />
that the physical image in memory is updated properly.<br />
The sixth step is to handle the default TTR cases. The default TTR is indicated if none of<br />
these bits are set: TTR, PTA, PTB, IL and PF. At this point, only the following cases are possible:<br />
• WP = 1 (write protection violation detected by default TTR)<br />
• RE = 1 (bus error on read)<br />
• WE = 1 (bus error on write)<br />
These cases may be handled similarly to step three. If the exception handler has gotten to<br />
this point, but none of the WP, RE and WE bits are set, and if the BPE bit is set and has<br />
been handled by the first step, then execute an RTE.<br />
8.4.6 Bus Errors and Pending Memory Writes<br />
The MC68060 processor contains two different write buffers for pending memory write operations:<br />
the store buffer and the push buffer. The store buffer is used to optimize performance<br />
by deferring bus write operations in write through and imprecise cache modes, and the push<br />
buffer holds displaced copyback mode cache lines and line write data for the MOVE16<br />
instruction.<br />
The push buffer holds a displaced cache line destined for memory until the cache-miss bus<br />
read access that caused the push completes. Imprecise cache modes (cachable writethrough<br />
and copyback, and cache inhibited, imprecise) use the write buffers of the MC68060<br />
to optimize system performance. Cache inhibited precise mode provides a precise exception<br />
model for MC68060 operation, not utilizing the write buffers (store or push).<br />
When the MC68060 detects an exception condition, all instruction execution is aborted and<br />
the exception processing state is entered. Upon entering this state, the pipeline stalls until<br />
both the store and push buffers are empty before beginning exception processing. If a TEA<br />
signal termination occurs during a memory write cycle while emptying the store buffer, ‘a bus<br />
error TEA on store buffer’ is recorded and the buffer sequences through all the remaining,<br />
pending writes. However, if a TEA signal termination occurs during a memory write cycle<br />
while emptying the push buffer, ‘a bus error TEA on push buffer’ is recorded and the memory<br />
write operation is aborted immediately.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 8-27
Exception Processing<br />
Once the write buffers (push and store) are all empty, the pipeline re-evaluates the pending<br />
exception types. If no TEA fault occurred during the emptying of the buffers, the processor<br />
continues with the original exception. If a TEA fault did occur as the buffers were emptied,<br />
the original exception is discarded and an operand data access error exception is taken. The<br />
exception stack for the access error includes indicator bits in the FSLW signalling the occurrence<br />
of the push buffer TEA or store buffer TEA. Note that both errors may be present<br />
within a single access error exception. The exception stack frame will record the PC value<br />
at the time the exception was detected, but this value has no relationship to the instruction<br />
that caused the push or store buffer entries to originally be made. The stacked virtual<br />
address is meaningless for these two fault types.<br />
There are other non-recoverable write cases which are unrelated to the push and store<br />
buffer cases. The execution of a misaligned read-modify-write instruction which partially<br />
completes the writes before faulting is inherently non-recoverable on a restart machine.<br />
Consider the ADD D0, instruction. In this instruction, the processor fetches the<br />
memory operand, adds the contents of D0 internally, and writes the result out to memory. If<br />
the memory operand is misaligned and a bus error occurs on the second or later access,<br />
the first part of the memory operand would have been overwritten. If the instruction enters<br />
the access error exception handler, it cannot be restarted because original memory value<br />
has been corrupted. This read-modify-write instruction and others like it can be detected in<br />
the access error handler because the access error frame has separate read and write bits<br />
(RW field). If both bits are set, the instruction is a read-modify-write instruction similar to the<br />
ADD instruction case as discussed.<br />
Another non-recoverable write case is similar to the ADD case above, but is more difficult to<br />
detect. A MOVE , instruction in which the source operand and destination<br />
operand overlap may have the same problems as discussed in the ADD instruction if the<br />
destination operand is part of the source operand and a misaligned write occurs, which<br />
result in an access error on the second or later misaligned case. The MOVE ,<br />
instruction is not normally considered a read-modify-write type of instruction, and is<br />
not detected simply by looking at the RW bits in the FSLW.<br />
An MC68060 system design could implement address/data capture logic to provide additional<br />
information for these bus error scenarios.<br />
8-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
8.4.7 Branch Prediction Error<br />
Exception Processing<br />
A branch prediction error occurs when a taken branch instruction is executed creating a<br />
branch cache entry and then this same code is re-executed with the former branch instruction<br />
now appearing as an extension word for another opcode.In this type of sequence where<br />
the interpretation of the code stream is dynamically changed, a branch prediction error may<br />
occur.<br />
In the past, Motorola had suggested using a TRAPF (word or long) instruction to remove a<br />
branch in the following construct:<br />
bra label2<br />
label1: <br />
label2: <br />
where a TRAPF (word or long) can be substituted for the branch instruction and the subsequent<br />
instruction, instruction effectively appears as the extension word of the TRAPF.<br />
The BPE bit of the FSLW can be asserted if the instruction is a taken branch instruction,<br />
but the likelihood of this usage is expected to be very low. The replacement of branch<br />
instructions using this TRAPF construct is still recommended for cases where is not<br />
a branch instruction. It is the responsibility of the access error handler to test the BPE bit,<br />
and if asserted, clear the branch cache. Refer to 8.4.5 Recovering from an Access Error<br />
for details on how to recover from this error.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 8-29
SECTION 9<br />
IEEE 1149.1 TEST (JTAG) AND<br />
DEBUG PIPE CONTROL MODES<br />
This section describes the IEEE 1149.1 test access port (normal Joint Test Action Group<br />
(JTAG)) mode and the debug pipe control mode, which are available on the MC68060.<br />
9.1 IEEE 1149.1 TEST ACCESS PORT (NORMAL JTAG) MODE<br />
The MC68060 includes dedicated user-accessible test logic that is fully compliant with the<br />
IEEE standard 1149.1-1993 Standard Test Access Port and Boundary Scan Architecture<br />
except in the case where the JTAG architecture and the LPSTOP function interact. This<br />
case is not formally addressed by the standard, but the MC68060 solution is transparent to<br />
the functionality defined by the standard, has the effect of meeting full compatibility to IEEE<br />
1149.1, and has been approved by the IEEE 1149.1 Working Group Committee.<br />
The following description is to be used in conjunction with the supporting IEEE document<br />
listed previously. This section includes the description of those chip-specific items that the<br />
IEEE standard defines as required as well as those items that are specific to the MC68060<br />
implementation.<br />
The MC68060 JTAG test architecture implementation supports circuit board test strategies<br />
that are based on the IEEE standard. This architecture provides access to all of the data and<br />
control pins of the chip from the board-edge connector through the standard four pin test<br />
access port (TAP) plus the additional optional active low TRST reset pin (see Section 2 Signal<br />
Description for a description of TRST). The test logic itself uses a static design and is<br />
entirely independent of the system logic, except where the JTAG mode is subordinate to<br />
another complimentary test mode (see 9.2 Debug Pipe Control Mode).<br />
When placed in the<br />
subordinate mode, the JTAG test logic is placed in reset and the TAP pins are used for alternate<br />
purposes in accordance with the rules and restrictions set forth for the use of a JTAG<br />
compliance enable pin.<br />
The MC68060 JTAG implementation provides the capabilities to:<br />
1. Perform boundary scan operations to test circuit board electrical continuity,<br />
2. Bypass the MC68060 by reducing the shift register path to a single cell,<br />
3. Sample the MC68060 system pins during operation and transparently shift out the<br />
result,<br />
4. Set the MC68060 output drive pins to fixed logic values while reducing the shift register<br />
path to a single cell, and<br />
5. Protect the MC68060 system output and input pins from backdriving and random<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-1
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-2<br />
toggling (such as during in-circuit testing) by placing all system signal pins to a high<br />
impedance state.<br />
9.1.1 Overview<br />
NOTE<br />
The IEEE standard 1149.1 test logic cannot be considered completely<br />
benign to those planning not to use this capability. Certain<br />
precautions must be observed to ensure that this logic does<br />
not interfere with system operation and allows full use of the<br />
LPSTOP function. Refer to 9.1.5 Disabling the IEEE 1149.1<br />
Standard Operation<br />
Figure 9-1 illustrates the block diagram of the MC68060 implementation of the 1149.1 standard.The<br />
test logic includes several test data registers, an instruction register, instruction<br />
register control decode, and a 16-state dedicated TAP controller. The sixteen controller<br />
states are defined in detail in the in the IEEE 1149.1 standard, but eight are listed in Table<br />
9-1 and included for illustration purposes:<br />
Table 9-1. JTAG States<br />
State Name State Summary<br />
Test-Logic-Reset Places test logic in default defined reset state<br />
Run-Test-Idle<br />
Allows test control logic to remain idle while test operations<br />
occur<br />
Capture-IR Loads default IDCODE instruction into the instruction register<br />
Shift-IR<br />
Allows serial data to move from TDI to TDO through the instruction<br />
register<br />
Update-IR<br />
Applies and activates instruction contained in the instruction<br />
shift register<br />
Capture-DR Loads parallel sampled data into the selected test data register<br />
Shift-DR<br />
Allows serial data to move from TDI to TDO through the selected<br />
test data register<br />
Update-DR Applies test data contained in the selected test data register<br />
The TAP consists of five dedicated signal pins which are controlled by a sixth dedicated<br />
compliance enable pin.<br />
1. JTAG—An active low JTAG enable pin that maps the TAP signals to either the 1149.1<br />
logic or the emulation mode logic and meets the requirements set forth for a compliance<br />
enable pin. The TAP pins are described in the case of JTAG asserted.<br />
2. TCK—A test clock input that synchronizes test logic operations.<br />
3. TMS—A test mode select input with an internal pullup resistor that is sampled on the<br />
rising edge of TCK to sequence the TAP controller.<br />
4. TDI—A serial test data input with an internal pullup resistor that is sampled on the rising<br />
edge of TCK.<br />
5. TDO—A three-state test data output that is actively driven only in the shift-IR and shift-<br />
DR controller states and only updates on the falling edge of TCK.<br />
6. TRST—An active low asynchronous reset with an internal pullup resistor that forces<br />
the TAP controller into the test-logic-reset state.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
TDI<br />
TRST<br />
TMS<br />
TCK<br />
9.1.2 JTAG Instruction Shift Register<br />
MOTOROLA<br />
213 0<br />
1-BIT BYPASS<br />
214-BIT BOUNDARY SCAN REGISTER<br />
31 0<br />
3<br />
32-BIT IDCODE REGISTER<br />
0<br />
4-BIT INSTRUCTION SHIFT REGISTER<br />
TAP CONTROLLER<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
INSTRUCTION APPLY & DECODE REGISTER<br />
Figure 9-1. JTAG Test Logic Block Diagram<br />
The MC68060 IEEE 1149.1 implementation uses a 4-bit instruction shift register without parity.<br />
The shift register transfers its value to a parallel hold register and applies one of sixteen<br />
possible instructions, seven of which are defined as public customer-usable instructions, on<br />
the falling edge of TCK when the TAP state machine is in the update-IR state (the other nine<br />
instructions are private instructions to support manufacturing test and can cause destructive<br />
behavior if used without proper understanding). The instructions may be loaded into the shift<br />
portion of the register by placing the serial data on the TDI signal prior to each rising edge<br />
of TCK. The most significant bit of the instruction shift register is the bit closest to the TDI<br />
signal and the least significant bit is the bit closest to the TDO pin.<br />
The public customer-usable instructions that are supported are listed with their encodings in<br />
Table 9-2.<br />
<strong>M68060</strong> USER’S MANUAL<br />
0<br />
M<br />
U<br />
X<br />
TDO<br />
9-3
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Instruction Acro Class IR3–IR0 Instruction Summary<br />
EXTEST EXT Required 0000 Select boundary scan register to apply fixed values to outputs<br />
LPSAMPLE LPS Public 0001<br />
Selects the boundary scan register for data operations while<br />
input pins are isolated *<br />
MFG-TEST9 — Private 0010 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST1 — Private 0011 For Motorola Internal Manufacturing Test use only<br />
SAMPLE SMP Required 0100 Selects boundary scan register for shift, sample and preload<br />
IDCODE IDC Optional 0101 Defaults to select the ID code register<br />
CLAMP CMP Optional 0110 Selects bypass while fixing output values<br />
HIGHZ HIZ Optional 0111 Selects bypass while three-stating all chip outputs<br />
MFG-TEST2 — Private 1000 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST3 — Private 1001 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST4 — Private 1010 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST5 — Private 1011 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST6 — Private 1100 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST7 — Private 1101 For Motorola Internal Manufacturing Test use only<br />
MFG-TEST8 — Private 1110 For Motorola Internal Manufacturing Test use only<br />
BYPASS BYP Required 1111 Selects the bypass register for data operations<br />
*LPSAMPLE is not supported on version 0000. See Figure 9-2 in 9.1.3.1 Idcode Register.<br />
The EXTEST, SAMPLE/PRELOAD, and BYPASS instructions are required by IEEE 1149.1.<br />
IDCODE is an optional public instruction supported by the MC68060. CLAMP and HIGHZ<br />
are optional public instructions that are supported by the MC68060 and are described the<br />
1149.1-1993 standard. LPSAMPLE is a Motorola-defined public instruction.<br />
All encodings other than these are private instructions for Motorola internal use only.<br />
Improper or unauthorized use of these instructions could result in potential internal damage<br />
to the device and can cause external signal contention since these tests operate internal<br />
registers, data path, and memory array logic and can drive random signal values on both<br />
the input and output pins.<br />
9.1.2.1 EXTEST. The external test instruction (EXTEST) selects the 214-bit boundary scan<br />
register. The EXTEST instruction forces all output pins and bidirectional pins configured as<br />
outputs to the fixed values that are preloaded (with the PRELOAD instruction) and held in<br />
the boundary scan update registers. The EXTEST instruction can also be used to configure<br />
the direction of bidirectional pins and establish high-impedance states on some pins. The<br />
EXTEST instruction becomes active on the falling edge of TCK in the update-IR state when<br />
the data held in the instruction shift register is equivalent to $0.<br />
It is recommended that the boundary scan register bit equivalent to the RSTI pin be preloaded<br />
with the assert value for system reset prior to application of the EXTEST instruction.<br />
This will ensure that EXTEST asserts the internal reset for the MC68060 system logic to<br />
force a predictable benign internal state while forcing all system output pins to fixed values.<br />
However, if it is desired to hold the processor in the LPSTOP state when applying the<br />
EXTEST instruction, do not preload the boundary scan register bit equivalent to the RSTI<br />
pin with an assert value because this action forces the processor out of the LPSTOP state.<br />
9-4<br />
Table 9-2. JTAG Instructions<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9.1.2.2 LPSAMPLE. The LPSAMPLE instruction provides identical functionality to the<br />
SAMPLE/PRELOAD instruction described in 9.1.2.4 SAMPLE/PRELOAD with one exception:<br />
instead of sampling the system data and control signals present at the MC68060 input<br />
pins, the LPSAMPLE instruction forces the LPSTOP isolation transistors into isolation state<br />
so that it can be verified that they are present and interrupting the path from the signal pin<br />
to the internal logic.The LPSAMPLE instruction becomes active on the falling edge of TCK<br />
in the update-IR state when the data held in the instruction shift register is equivalent to a $1.<br />
9.1.2.3 Private Instructions. The set of private instructions labeled MFG-TEST1 through<br />
MFG-TEST9 are reserved by Motorola for internal manufacturing use. These instructions<br />
can change (remap) the pin I/O and pin functions as defined for system operation (some<br />
input pins may become output pins and some output pins may become input pins). Use of<br />
these instructions without proper understanding can result in potentially destructive operation<br />
of the MC68060. These instructions become active on the falling edge of TCK in the<br />
update-IR state when the data held in the instructions shift register is equivalent to values<br />
$2, $3, $8, $9, $A, $B, $C, $D, and $E.<br />
9.1.2.4 SAMPLE/PRELOAD. The SAMPLE/PRELOAD instruction provides two separate<br />
functions. First, it provides a means to obtain a sample of the system data and control signals<br />
present at the MC68060 input pins and just prior to the boundary scan cell at the output<br />
pins. This sampling occurs on the rising edge of TCK in the capture-DR state when an<br />
instruction encoding of $4 is resident in the instruction register. The user can observe this<br />
sampled data by shifting it through the boundary scan register to the output TDO by using<br />
the shift-DR state. Both the data capture and the shift operation are transparent to system<br />
operation. The user is responsible for providing some form of external synchronization to<br />
achieve meaningful results since there is no internal synchronization between TCK and the<br />
system clock, CLK.<br />
The second function of the SAMPLE/PRELOAD instruction is to initialize the boundary scan<br />
register update cells before selecting EXTEST or CLAMP. This is accomplished by ignoring<br />
the data being shifted out of the TDO pin while shifting in initialization data. The update-DR<br />
state in conjunction with the falling edge of TCK can then be used to transfer this data to the<br />
update cells. This data will be applied to the external output pins when one of the instructions<br />
listed previously is applied.<br />
9.1.2.5 IDCODE. The IDCODE instruction selects the 32-bit idcode register for connection<br />
as a shift path between the TDI pin and the TDO pin. This instruction allows the user to interrogate<br />
the MC68060 to determine its JTAG version number and other part identification<br />
data. The idcode register has been implemented in accordance with IEEE 1149.1 so that<br />
the least significant bit of the shift register stage is set to logic one on the rising edge of TCK<br />
following entry into the capture-DR state. Therefore, the first bit to be shifted out after selecting<br />
the idcode register is always a logic one (this is to differentiate a part that supports an<br />
idcode register from a part that supports only the bypass register). The remaining 31-bits are<br />
also set to fixed values (see 9.1.3.1 Idcode Register)<br />
on the rising edge of TCK following<br />
entry into the capture-DR state.<br />
The IDCODE instruction is the default value placed in the instruction register when a JTAG<br />
reset is accomplished by, either asserting TRST, or holding TMS high while clocking TCK<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-5
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
through at least five rising edges and the falling edge after the fifth rising edge. A JTAG reset<br />
will cause the TAP state machine to enter the test-logic-reset state (normal operation of the<br />
TAP state machine into the test-logic-reset state will also result in placing the default value<br />
of $5 into the instruction register). The shift register portion of the instruction register is<br />
loaded with the default value of $5 when in the Capture-IR state and a rising edge of TCK<br />
occurs.<br />
9.1.2.6 CLAMP. The CLAMP instruction selects the bypass register while simultaneously<br />
forcing all output pins and bidirectional pins configured as outputs, to the fixed values that<br />
are preloaded and held in the boundary scan update registers. This instruction enhances<br />
test efficiency by reducing the overall shift path to a single bit (the bypass register) while conducting<br />
an EXTEST type of instruction through the boundary scan register. The CLAMP<br />
instruction becomes active on the falling edge of TCK in the update-IR state when the data<br />
held in the instruction shift register is equivalent to $6.<br />
It is recommended that the boundary scan register bit equivalent to the RSTI pin be preloaded<br />
with the assert value for system reset prior to application of the CLAMP instruction.<br />
This will ensure that CLAMP asserts the internal reset for the MC68060 system logic to force<br />
a predictable benign internal state while isolating all pins from signals generated external to<br />
the part. However, if it is desired to hold the processor in the LPSTOP state when applying<br />
the CLAMP instruction, do not preload the boundary scan register bit equivalent to the RSTI<br />
pin with an assert value because this action forces the processor out of the LPSTOP state.<br />
9.1.2.7 HIGHZ. The HIGHZ instruction is an IEEE 1149.1 option that is provided as a Motorola<br />
public instruction designed to anticipate the need to backdrive the output pins and protect<br />
the input pins from random toggling during circuit board testing. The HIGHZ instruction<br />
selects the bypass register, forces all output and bidirectional pins to the high-impedance<br />
state, and isolates all input signal pins except for CLK, IPL, and RSTI. The HIGHZ instruction<br />
becomes active on the falling edge of TCK in the update-IR state when the data held in the<br />
instruction shift register is equivalent to $7.<br />
It is recommended that the boundary scan register bit equivalent to the RSTI pin be preloaded<br />
with the assert value for system reset prior to application of the HIGHZ instruction.<br />
This will ensure that HIGHZ asserts the internal reset for the MC68060 system logic to force<br />
a predictable benign internal state while isolating all pins from signals generated external to<br />
the part.<br />
9.1.2.8 BYPASS. The BYPASS instruction selects the single-bit bypass register, creating a<br />
single bit shift register path from the TDI pin to the bypass register to the TDO pin. This<br />
instruction enhances test efficiency by reducing the overall shift path when a device other<br />
than the MC68060 becomes the device under test on a board design with multiple chips on<br />
the overall IEEE-1149.1-defined boundary scan chain. The bypass register has been implemented<br />
in accordance with IEEE 1149.1 so that the shift register stage is set to logic zero<br />
on the rising edge of TCK following entry into the capture-DR state. Therefore, the first bit<br />
to be shifted out after selecting the bypass register is always a logic zero (this is to differentiate<br />
a part that supports an idcode register from a part that supports only the bypass register).<br />
9-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
The BYPASS instruction becomes active on the falling edge of TCK in the update-IR state<br />
when the data held in the instruction shift register is equivalent to $F.<br />
9.1.3 JTAG Test Data Registers<br />
The following paragraphs describe the JTAG test data registers.<br />
9.1.3.1 Idcode Register. An IEEE-1149.1-compliant JTAG identification register has been<br />
included on the MC68060. The MC68060 JTAG instruction encoded as $5 provides for reading<br />
the JTAG idcode register. The format of this register is defined in Figure 9-2.<br />
31 28 27 22 21 12 11 1 0<br />
VERSION NO. 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 1<br />
Figure 9-2. JTAG Idcode Register Format<br />
VERSION NO.—Version Number<br />
Indicates the JTAG revision of the MC68060.<br />
Bits 27–22<br />
Indicate the high performance design center.<br />
Bits 21–12<br />
Indicate the device is a Motorola MC68060.<br />
Bits 11–1<br />
Indicate the reduced JEDEC ID for Motorola. (JEDEC refers to the Joint Electron Device<br />
Engineering Council. Refer to JEDEC publication 106-A and chapter 11 of the IEEE<br />
1149.1-1993 document for further information on this field.)<br />
Bit 0<br />
Differentiates this register as JTAG idcode (as opposed to the bypass register) according<br />
to IEEE 1149.1.<br />
9.1.3.2 Boundary Scan Register. An IEEE-1149.1-compliant boundary scan register has<br />
been included on the MC68060. This 214-bit boundary scan register can be connected<br />
between TDI and TDO when the EXTEST, LPSAMPLE, or SAMPLE/PRELOAD instructions<br />
are selected. This register is used for capturing signal pin data on the input pins, forcing fixed<br />
values on the output signal pins, and selecting the direction and drive characteristics (a logic<br />
value or high impedance) of the bidirectional and three-state signal pins. Figure 9-3 through<br />
Figure 9-7 depict the various cell types.<br />
The key to using the boundary scan register is knowing the boundary scan bit order and the<br />
pins that are associated with them. Below in Table 9-3 is the bit order starting from the TDI<br />
input and going toward the TDO output.<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-7
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-8<br />
OUTPUT DATA<br />
FROM SYSTEM LOGIC<br />
1 = EXTEST<br />
0 = OTHERWISE<br />
TO<br />
SYSTEM<br />
LOGIC<br />
G1<br />
1<br />
1<br />
MUX<br />
SHIFT DR TO NEXT CELL<br />
FROM<br />
LAST<br />
CELL<br />
CLOCK DR<br />
Figure 9-3. Output Pin Cell (O.Pin)<br />
TO NEXT CELL<br />
C1<br />
1D<br />
G1<br />
1<br />
1<br />
MUX<br />
CLOCK DR<br />
MUX<br />
Figure 9-4. Observe-Only Input Pin Cell (I.Obs)<br />
G1<br />
1D<br />
C1<br />
FROM<br />
LAST<br />
CELL<br />
<strong>M68060</strong> USER’S MANUAL<br />
1<br />
1<br />
UPDATE DR<br />
SHIFT DR<br />
1D<br />
C1<br />
INPUT<br />
PIN<br />
TO OUTPUT<br />
BUFFER<br />
MOTOROLA
MOTOROLA<br />
FROM<br />
INPUT PIN<br />
FROM<br />
LAST<br />
CELL<br />
OUTPUT CONTROL<br />
FROM SYSTEM LOGIC<br />
SHIFT DR<br />
G1<br />
1<br />
1<br />
1 = EXTEST<br />
0 = OTHERWISE<br />
G1<br />
1<br />
1<br />
CLOCK DR<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Figure 9-5. Input Pin Cell (I.Pin)<br />
MUX<br />
FROM<br />
LAST<br />
CELL<br />
1D<br />
C1<br />
TO<br />
NEXT<br />
CELL<br />
UPDATE DR<br />
Figure 9-6. Output Control Cell (IO.Ctl)<br />
1D<br />
CLOCK DR<br />
C1<br />
<strong>M68060</strong> USER’S MANUAL<br />
MODE<br />
G1<br />
SHIFT DR TO NEXT CELL<br />
G1<br />
1<br />
1<br />
MUX<br />
1D<br />
C1<br />
UPDATE DR<br />
1<br />
1<br />
1D<br />
C1<br />
TO<br />
SYSTEM<br />
LOGIC<br />
TO OUTPUT<br />
BUFFER<br />
(1 = DRIVE)<br />
9-9
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-10<br />
OUTPUT<br />
ENABLE<br />
OUTPUT<br />
DATA<br />
INPUT<br />
DATA<br />
TO NEXT CELL<br />
I/O.CTL<br />
O.PIN<br />
I.PIN<br />
FROM<br />
LAST CELL<br />
TO NEXT<br />
PIN PAIR<br />
Figure 9-7. General Arrangement of Bidirectional Pin Cells<br />
Table 9-3. Boundary Scan Bit Definitions<br />
Bit Cell Type Pin/Cell Name Pin Type<br />
0 O.Pin A31 I/O<br />
1 I.Pin A31 I/O<br />
2 O.Pin A30 I/O<br />
3 I.Pin A30 I/O<br />
4 IO.Ctl A31–A28 ena —<br />
5 O.Pin A29 I/O<br />
6 I.Pin A29 I/O<br />
7 O.Pin A28 I/O<br />
8 I.Pin A28 I/O<br />
9 O.Pin A27 I/O<br />
10 I.Pin A27 I/O<br />
11 O.Pin A26 I/O<br />
12 I.Pin A26 I/O<br />
13 IO.Ctl A27–A24 ena —<br />
14 O.Pin A25 I/O<br />
15 I.Pin A25 I/O<br />
16 O.Pin A24 I/O<br />
17 I.Pin A24 I/O<br />
18 O.Pin A23 I/O<br />
19 I.Pin A23 I/O<br />
20 O.Pin A22 I/O<br />
21 I.Pin A22 I/O<br />
22 IO.Ctl A23–A20 ena —<br />
23 O.Pin A21 I/O<br />
24 I.Pin A21 I/O<br />
25 O.Pin A20 I/O<br />
26 I.Pin A20 I/O<br />
27 O.Pin A19 I/O<br />
28 I.Pin A19 I/O<br />
29 O.Pin A18 I/O<br />
30 I.Pin A18 I/O<br />
31 IO.Ctl A19–A16 ena —<br />
EN<br />
<strong>M68060</strong> USER’S MANUAL<br />
I/O<br />
PIN<br />
MOTOROLA
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Table 9-3. Boundary Scan Bit Definitions (Continued)<br />
Bit Cell Type Pin/Cell Name Pin Type<br />
32 O.Pin A17 I/O<br />
33 I.Pin A17 I/O<br />
34 O.Pin A16 I/O<br />
35 I.Pin A16 I/O<br />
36 O.Pin A15 I/O<br />
37 I.Pin A15 I/O<br />
38 O.Pin A14 I/O<br />
39 I.Pin A14 I/O<br />
40 IO.Ctl A15–A12 ena —<br />
41 O.Pin A13 I/O<br />
42 I.Pin A13 I/O<br />
43 O.Pin A12 I/O<br />
44 I.Pin A12 I/O<br />
45 O.Pin A11 I/O<br />
46 I.Pin A11 I/O<br />
47 O.Pin A10 I/O<br />
48 I.Pin A10 I/O<br />
49 IO.Ctl A11–A10,TT1–TT0 ena —<br />
50 O.Pin TT1 I/O<br />
51 I.Pin TT1 I/O<br />
52 O.Pin TT0 Output<br />
53 I.Obs MTM1 I<br />
54 O.Pin UPA1 Output<br />
55 O.Pin UPA0 Output<br />
56 IO.Ctl UPA1–UPA0,XCIOUTena —<br />
57 O.Pin XCIOUT Output<br />
58 O.Pin XIPEND Output<br />
59 O.Pin XRSTO Output<br />
60 IO.Ctl XIPEND, XRSTO ena —<br />
61 O.Pin XBS0 Output<br />
62 O.Pin XBS1 Output<br />
63 IO.Ctl XBS3–XBS0 ena —<br />
64 O.Pin XBS2 Output<br />
65 O.Pin XBS3 Output<br />
66 I.Pin XMDIS Input<br />
67 I.Pin XCDIS Input<br />
68 I.Pin XRSTI Input<br />
69 I.Pin XIPL2 Input<br />
70 I.Pin XIPL1 Input<br />
71 I.Pin XIPL0 Input<br />
72 I.Pin XCLKEN Input<br />
73 I.Obs CLK Input<br />
74 I.Obs MTM2 Input<br />
75 I.Pin XTCI Input<br />
76 I.Pin XAVEC Input<br />
77 I.Pin XTBI Input<br />
78 I.Pin XBGR Input<br />
79 I.Pin XBG Input<br />
80 I.Pin XTRA Input<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-11
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-12<br />
Table 9-3. Boundary Scan Bit Definitions (Continued)<br />
Bit Cell Type Pin/Cell Name Pin Type<br />
81 I.Pin XTEA Input<br />
82 I.Pin XTA Input<br />
83 O.Pin PST0 Output<br />
84 O.Pin PST1 Output<br />
85 O.Pin PST2 Output<br />
86 IO.Ctl PST4–PST0, XBR ena —<br />
87 O.Pin PST3 Output<br />
88 O.Pin PST4 Output<br />
89 O.Pin XSAS Output<br />
90 IO.Ctl XSAS ena —<br />
91 O.Pin XBTT I/O<br />
92 IO.Ctl XBTT ena —<br />
93 I.Pin XBTT I/O<br />
94 O.Pin XTS I/O<br />
95 I.Pin XTS ena —<br />
96 I.Pin XTS I/O<br />
97 O.Pin XTIP Output<br />
98 IO.Ctl XTIP ena —<br />
99 I.Pin XSNOOP Input<br />
100 O.Pin XBB I/O<br />
101 IO.Ctl XBB ena —<br />
102 I.Pin XBB I/O<br />
103 O.Pin XBR Output<br />
104 IO.Ctl XLOCK, XLOCKE ena —<br />
105 O.Pin XLOCK Output<br />
106 O.Pin XLOCKE Output<br />
107 O.Pin TLN0 Output<br />
108 O.Pin SIZ0 Output<br />
109 IO.Ctl TLN0,SIZ1–SIZ0,XR_W ena —<br />
110 O.Pin SIZ1 Output<br />
111 O.Pin XR_W Output<br />
112 O.Pin TLN1 Output<br />
113 O.Pin TM0 Output<br />
114 IO.Ctl TLN1,TM2–TM0 ena —<br />
115 O.Pin TM1 Output<br />
116 O.Pin TM2 Output<br />
117 O.Pin A0 I/O<br />
118 I.Pin A0 I/O<br />
119 O.Pin A1 I/O<br />
120 I.Pin A1 I/O<br />
121 IO.Ctl A1–A0 ena —<br />
122 I.Pin XCLA —<br />
123 O.Pin A2 I/O<br />
124 I.Pin A2 I/O<br />
125 O.Pin A3 I/O<br />
126 I.Pin A3 I/O<br />
127 IO.Ctl A3–A2 ena —<br />
128 O.Pin A4 I/O<br />
129 I.Pin A4 I/O<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Table 9-3. Boundary Scan Bit Definitions (Continued)<br />
Bit Cell Type Pin/Cell Name Pin Type<br />
130 O.Pin A5 I/O<br />
131 I.Pin A5 I/O<br />
132 IO.Ctl A5–A4 ena —<br />
133 O.Pin A6 I/O<br />
134 I.Pin A6 I/O<br />
135 O.Pin A7 I/O<br />
136 I.Pin A7 I/O<br />
137 IO.Ctl A9–A6 ena —<br />
138 O.Pin A8 I/O<br />
139 I.Pin A8 I/O<br />
140 O.Pin A9 I/O<br />
141 I.Pin A9 I/O<br />
142 O.Pin D31 I/O<br />
143 I.Pin D31 I/O<br />
144 O.Pin D30 I/O<br />
145 I.Pin D30 I/O<br />
146 IO.Ctl D31–D28 ena —<br />
147 O.Pin D29 I/O<br />
148 I.Pin D29 I/O<br />
149 O.Pin D28 I/O<br />
150 I.Pin D28 I/O<br />
151 O.Pin D27 I/O<br />
152 I.Pin D27 I/O<br />
153 O.Pin D26 I/O<br />
154 I.Pin D26 I/O<br />
155 IO.Ctl D27–D24 ena —<br />
156 O.Pin D25 I/O<br />
157 I.Pin D25 I/O<br />
158 O.Pin D24 I/O<br />
159 I.Pin D24 I/O<br />
160 O.Pin D23 I/O<br />
161 I.Pin D23 I/O<br />
162 O.Pin D22 I/O<br />
163 I.Pin D22 I/O<br />
164 IO.Ctl D23–D20 ena —<br />
165 O.Pin D21 I/O<br />
166 I.Pin D21 I/O<br />
167 O.Pin D20 I/O<br />
168 I.Pin D20 I/O<br />
169 O.Pin D19 I/O<br />
170 I.Pin D19 I/O<br />
171 O.Pin D18 I/O<br />
172 I.Pin D18 I/O<br />
173 IO.Ctl D19–D16 ena —<br />
174 O.Pin D17 I/O<br />
175 I.Pin D17 I/O<br />
176 O.Pin D16 I/O<br />
177 I.Pin D16 I/O<br />
178 O.Pin D15 I/O<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-13
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-14<br />
Table 9-3. Boundary Scan Bit Definitions (Continued)<br />
Bit Cell Type Pin/Cell Name Pin Type<br />
179 I.Pin D15 I/O<br />
180 O.Pin D14 I/O<br />
181 I.Pin D14 I/O<br />
182 IO.Ctl D15–D12 ena —<br />
183 O.Pin D13 I/O<br />
184 I.Pin D13 I/O<br />
185 O.Pin D12 I/O<br />
186 I.Pin D12 I/O<br />
187 O.Pin D11 I/O<br />
188 I.Pin D11 I/O<br />
189 O.Pin D10 I/O<br />
190 I.Pin D10 I/O<br />
191 IO.Ctl D11–D8 ena —<br />
192 O.Pin D9 I/O<br />
193 I.Pin D9 I/O<br />
194 O.Pin D8 I/O<br />
195 I.Pin D8 I/O<br />
196 O.Pin D7 I/O<br />
197 I.Pin D7 I/O<br />
198 O.Pin D6 I/O<br />
199 I.Pin D6 I/O<br />
200 IO.Ctl D7–D4 ena —<br />
201 O.Pin D5 I/O<br />
202 I.Pin D5 I/O<br />
203 O.Pin D4 I/O<br />
204 I.Pin D4 I/O<br />
205 O.Pin D3 I/O<br />
206 I.Pin D3 I/O<br />
207 O.Pin D2 I/O<br />
208 I.Pin D2 I/O<br />
209 IO.Ctl D3–D0 ena —<br />
210 O.Pin D1 I/O<br />
211 I.Pin D1 I/O<br />
212 O.Pin D0 I/O<br />
213 I.Pin D0 I/O<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9.1.3.3 BYPASS REGISTER. An IEEE-1149.1-compliant bypass register has been<br />
included on the MC68060. This register is a single bit in depth when connected between TDI<br />
and TDO. The register element is in the shift path which operates during rising edges of TCK<br />
while the TAP state machine is in the shift-DR state or captures a default state of logic 0<br />
during the rising edge of TCK while the TAP state machine is in the capture-DR state.<br />
9.1.4 Restrictions<br />
SHIFT DR<br />
0<br />
FROM TDI<br />
CLOCK DR<br />
1 MUX<br />
Figure 9-8. JTAG Bypass Register<br />
The test logic is implemented using static logic design, and TCK can be stopped in either a<br />
high or low state without loss of data. The system logic, however, operates on a different<br />
system clock which is not synchronized to TCK internally. Any mixed operation requiring the<br />
use of 1149.1 test logic in conjunction with system functional logic that uses both clocks,<br />
must have coordination and synchronization of these clocks done externally to the<br />
MC68060.<br />
The MC68060 also includes an internal instruction known as LPSTOP which can place the<br />
output pins in a high-impedance state, isolate the input pins from their internal signals, and<br />
stop the internal clock. Special care must be taken to ensure that the JTAG logic does not<br />
consume excess power during this mode if it is to be left inactive (see 9.1.5 Disabling the<br />
IEEE 1149.1 Standard Operation).<br />
9.1.5 Disabling the IEEE 1149.1 Standard Operation<br />
G1<br />
1<br />
There are two methods by which the device can be used without the IEEE 1149.1 test logic<br />
being active: 1) non-use of the JTAG test logic by either non-termination (disconnection) or<br />
intentional fixing of TAP logic values, and 2) intentional disabling of the JTAG test logic by<br />
assertion of the JTAG signal.<br />
There are several considerations that must be addressed if the IEEE 1149.1 logic is not<br />
going to be used once the MC68060 is assembled onto a board. The prime consideration is<br />
to ensure that the IEEE 1149.1 test logic remains transparent and benign to the system logic<br />
during functional operation. This requires the minimum of either connecting the TRST pin to<br />
logic 0, or connecting the TCK clock pin to a clock source that will supply five rising edges<br />
and the falling edge after the fifth rising edge, to ensure that the part enters the test-logicreset<br />
state. The recommended solution is to connect TRST to logic 0 since logic was<br />
included to ensure that unterminated or fixed-value terminated pins consume the least<br />
power during the LPSTOP functional state. Another consideration is that the TCK pin does<br />
not have a pullup as is required on the TMS, TDI, and TRST pins; therefore, it should not be<br />
left unterminated to preclude mid-level input values.<br />
1D<br />
C1<br />
<strong>M68060</strong> USER’S MANUAL<br />
TO TDO<br />
9-15
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
A second method of using the MC68060 without the IEEE 1149.1 logic being active is to<br />
select the alternate complementary test debug emulation mode by placing a logic 1 on the<br />
defined compliance enable pin, JTAG. When the JTAG is asserted, then the IEEE 1149.1<br />
test controller is placed in the test-logic-reset state by applying a logic 0 on the internal TRST<br />
signal to the controller, and the TAP pins are remapped to their equivalent debug emulation<br />
mode pins.<br />
9-16<br />
NOTE<br />
The MC68060 supports the low-power stop mode which can isolate<br />
the input and output signal pins from their internal connections<br />
and allows the internal system clock to be stopped. In<br />
accordance with IEEE1149.1, the JTAG logic can become the<br />
chip master during this functional mode and can conduct test<br />
operations. During this type of testing, the MC68060 will consume<br />
power at a level higher than that specified for functional<br />
LPSTOP mode. If the JTAG mode is left active, but is not being<br />
actively used to conduct test operations, the MC68060 will consume<br />
power at a level below the rated LPSTOP maximum but<br />
not at the lowest possible level. In order to consume the least<br />
possible power, the JTAG logic must be specifically disabled by<br />
placing a logic 0 on the TRST pin and a logic 1 on the TMS pin,<br />
as shown in Figure 9-9.<br />
TDI<br />
TMS<br />
TD0 NO CONNECTION<br />
TRST<br />
TCK<br />
JTAG<br />
Vcc<br />
Figure 9-9. Circuit Disabling IEEE Standard 1149.1<br />
1K<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
9.1.6 Motorola MC68060 BSDL Description<br />
-- Version 1.0 02-18-94<br />
-- Revision List: None<br />
-- Package Type: 18 x 18 PGA<br />
entity MC68060 is<br />
generic(PHYSICAL_PIN_MAP:string := "PGA_18x18");<br />
port (<br />
TDI: in bit;<br />
TDO: out bit;<br />
TMS: in bit;<br />
TCK: in bit;<br />
TRST: in bit;<br />
D: inout bit_vector(0 to 31);<br />
A: inout bit_vector(0 to 31);<br />
CLA: in bit;<br />
TM: out bit_vector(0 to 2);<br />
TLN: out bit_vector(0 to 1);<br />
R_W: out bit;<br />
SIZ: out bit_vector(0 to 1);<br />
LOCKE: out bit;<br />
LOCK: out bit;<br />
BR: out bit;<br />
BB: inout bit;<br />
SNOOP: in bit;<br />
TIP: out bit;<br />
TS: inout bit;<br />
BTT: inout bit;<br />
SAS: out bit;<br />
PST: out bit_vector(0 to 4);<br />
TA: in bit;<br />
TEA: in bit;<br />
TRA: in bit;<br />
BG: in bit;<br />
BGR: in bit;<br />
TBI: in bit;<br />
AVEC: in bit;<br />
TCI: in bit;<br />
CLK: in bit;<br />
CLKEN: in bit;<br />
IPL: in bit_vector(0 to 2);<br />
RSTI: in bit;<br />
CDIS: in bit;<br />
MDIS: in bit;<br />
BS: out bit_vector(0 to 3);<br />
RSTO: out bit;<br />
IPEND: out bit;<br />
CIOUT: out bit;<br />
UPA: out bit_vector(0 to 1);<br />
TT1: inout bit;<br />
TT0: out bit;<br />
JTAGENB: in bit_vector(0 to 2);<br />
THERM1: linkage bit;<br />
THERM0: linkage bit;<br />
EVDD: linkage bit_vector(1 to 25);<br />
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-17
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
9-18<br />
EVSS: linkage bit_vector(1 to 25);<br />
IVDD: linkage bit_vector(1 to 16);<br />
IVSS: linkage bit_vector(1 to 16)<br />
);<br />
use STD_1149_1_1994.all;<br />
attribute COMPONENT_CONFORMANCE of MC68060: entity is "STD_1149_1_1993" ;<br />
attribute PIN_MAP of MC68060 : entity is PHYSICAL_PIN_MAP;<br />
-- PGA_18x18 Pin Map<br />
--<br />
-- No-connects: D4, D5, D6, D7, D9, D11, D13, D14, K4, M4, N4, Q16, R7,<br />
-- R10, S12, T9, T12<br />
-constant<br />
PGA_18x18 : PIN_MAP_STRING :=<br />
"TDI: S3, " &<br />
"TDO: T2, " &<br />
"TMS: S5, " &<br />
"TCK: S4, " &<br />
"TRST: T3, " &<br />
-- 0 1 2 3 4 5 6 7 8 9 10 11<br />
"D: ( C3, B3, C4, A2, A3, A4, A5, A6, B7, A7, A8, A9, " &<br />
-- 12 13 14 15 16 17 18 19 20 21 22 23<br />
" A10, A11, A12, A13, B11, A14, B12, A15, A16, A17, B16, C15, " &<br />
-- 24 25 26 27 28 29 30 31<br />
" A18, C16, B18, D16, C18, E16, E17, D18 ), " &<br />
-- 0 1 2 3 4 5 6 7 8 9 10 11<br />
"A: ( L18, K18, J17, J18, H18, G18, G16, F18, E18, F16, P1, N3, " &<br />
-- 12 13 14 15 16 17 18 19 20 21 22 23<br />
" N1, M1, L1, K1, K2, J1, H1, J2, G1, F1, E1, G3, " &<br />
-- 24 25 26 27 28 29 30 31<br />
" D1, F3, E2, C1, E3, B1, D3, A1 ), " &<br />
"CLA: K15, " &<br />
"TM: ( N18, M18, K17 ), " &<br />
"TLN: ( Q18, P18 ), " &<br />
"R_W: N16, " &<br />
"SIZ: ( P17, P16 ), " &<br />
"LOCKE: R18, " &<br />
"LOCK: S18, " &<br />
"BR: T18, " &<br />
"BB: T17, " &<br />
"SNOOP: P15, " &<br />
"TIP: R15, " &<br />
"TS: R16, " &<br />
"BTT: Q15, " &<br />
"SAS: Q14, " &<br />
"PST: ( T15, S14, R14, T16, Q13 ), " &<br />
"TA: T14, " &<br />
"TEA: S13, " &<br />
"TRA: Q12, " &<br />
"BG: T13, " &<br />
"BGR: Q11, " &<br />
"TBI: S11, " &<br />
"AVEC: T11, " &<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
"TCI: T10, " &<br />
"JTAGENB: ( T4, F15, S10 ), " &<br />
"CLK: R9, " &<br />
"CLKEN: Q8, " &<br />
"IPL: ( T8, T7, T6 ), " &<br />
"RSTI: S7, " &<br />
"CDIS: T5, " &<br />
"MDIS: S6, " &<br />
"BS: ( Q4, Q5, Q6, Q7 ), " &<br />
"RSTO: R3, " &<br />
"IPEND: S1, " &<br />
"CIOUT: R1, " &<br />
"UPA: ( Q3, Q1 ), " &<br />
"TT1: P2, " &<br />
"TT0: P3, " &<br />
"THERM1: M15, " &<br />
"THERM0: L15, " &<br />
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
"EVDD: ( B5, B9, B14, C2, C17, D8, D10, D12, D15, E4, G2, " &<br />
" G4, G15, G17, J4, J15, L4, M2, M17, N15, P4, Q10, " &<br />
" R2, R17, S16 ), " &<br />
"EVSS: ( B2, B4, B6, B8, B10, B13, B15, B17, D2, D17, F2, " &<br />
" F4, F17, H2, H17, L2, L17, N2, N17, Q2, Q9, Q17, " &<br />
" S2, S15, S17 ), " &<br />
"IVDD: ( C5, C8, C10, C12, C14, E15, H3, H16, J3, J16, L16, " &<br />
" M3, R5, R8, R12, S8 ), " &<br />
"IVSS: ( C6, C7, C9, C11, C13, H4, H15, K3, K16, L3, M16, " &<br />
" R4, R6, R11, R13, S9 ) ";<br />
-- Other Pin Maps here<br />
attribute TAP_SCAN_IN of TDI:signal is true;<br />
attribute TAP_SCAN_OUT of TDO:signal is true;<br />
attribute TAP_SCAN_MODE of TMS:signal is true;<br />
attribute TAP_SCAN_CLOCK of TCK:signal is (33.0e6, BOTH);<br />
attribute TAP_SCAN_RESET of TRST:signal is true;<br />
attribute COMPLIANCE_ENABLE of JTAGENB(0): signal is true;<br />
attribute COMPLIANCE_ENABLE of JTAGENB(1): signal is true;<br />
attribute COMPLIANCE_ENABLE of JTAGENB(2): signal is true;<br />
attribute COMPLIANCE_PATTERNS of MC68060: entity is<br />
"(JTAGENB(0), JTAGENB(1), JTAGENB(2)) (000)";<br />
attribute INSTRUCTION_LENGTH of MC68060:entity is 4;<br />
attribute INSTRUCTION_OPCODE of MC68060:entity is<br />
"EXTEST (0000)," &<br />
"LPSAMPLE (0001)," &<br />
"SAMPLE (0100)," &<br />
"IDCODE (0101)," &<br />
"CLAMP (0110)," &<br />
"HIGHZ (0111)," &<br />
"PRIVATE (0010, 0011, 1000,1001,1010,1011,1100,1101,1110)," &<br />
"BYPASS (1111)";<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-19
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
attribute INSTRUCTION_CAPTURE of MC68060: entity is "0101";<br />
attribute INSTRUCTION_PRIVATE of MC68060:entity is "PRIVATE";<br />
attribute REGISTER_ACCESS of MC68060:entity is<br />
"BOUNDARY (LPSAMPLE)";<br />
attribute IDCODE_REGISTER of MC68060: entity is<br />
"0001" & -- version<br />
"000001" & -- design center<br />
"0000110000" & -- sequence number<br />
"00000001110" & -- Motorola<br />
"1"; -- required by 1149.1<br />
attribute BOUNDARY_CELLS of MC68060:entity is<br />
"BC_1, BC_2, BC_4";<br />
attribute BOUNDARY_LENGTH of MC68060:entity is 214;<br />
attribute BOUNDARY_REGISTER of MC68060:entity is<br />
--num cell port function safe ccell dsval rslt<br />
"0 (BC_1, D(0), input, X), " &<br />
"1 (BC_2, D(0), output3, X, 4, 0, Z), " &<br />
"2 (BC_1, D(1), input, X), " &<br />
"3 (BC_2, D(1), output3, X, 4, 0, Z), " &<br />
"4 (BC_2, *, control, 0), " & -- d[3:0]<br />
"5 (BC_1, D(2), input, X), " &<br />
"6 (BC_2, D(2), output3, X, 4, 0, Z), " &<br />
"7 (BC_1, D(3), input, X), " &<br />
"8 (BC_2, D(3), output3, X, 4, 0, Z), " &<br />
"9 (BC_1, D(4), input, X), " &<br />
"10 (BC_2, D(4), output3, X, 13, 0, Z), " &<br />
"11 (BC_1, D(5), input, X), " &<br />
"12 (BC_2, D(5), output3, X, 13, 0, Z), " &<br />
"13 (BC_2, *, control, 0), " & -- d[7:4]<br />
"14 (BC_1, D(6), input, X), " &<br />
"15 (BC_2, D(6), output3, X, 13, 0, Z), " &<br />
"16 (BC_1, D(7), input, X), " &<br />
"17 (BC_2, D(7), output3, X, 13, 0, Z), " &<br />
"18 (BC_1, D(8), input, X), " &<br />
"19 (BC_2, D(8), output3, X, 22, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"20 (BC_1, D(9), input, X), " &<br />
"21 (BC_2, D(9), output3, X, 22, 0, Z), " &<br />
"22 (BC_2, *, control, 0), " & -- d[11:8]<br />
"23 (BC_1, D(10), input, X), " &<br />
"24 (BC_2, D(10), output3, X, 22, 0, Z), " &<br />
"25 (BC_1, D(11), input, X), " &<br />
"26 (BC_2, D(11), output3, X, 22, 0, Z), " &<br />
"27 (BC_1, D(12), input, X), " &<br />
"28 (BC_2, D(12), output3, X, 31, 0, Z), " &<br />
"29 (BC_1, D(13), input, X), " &<br />
"30 (BC_2, D(13), output3, X, 31, 0, Z), " &<br />
"31 (BC_2, *, control, 0), " & -- d[15:12]<br />
"32 (BC_1, D(14), input, X), " &<br />
"33 (BC_2, D(14), output3, X, 31, 0, Z), " &<br />
9-20<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
"34 (BC_1, D(15), input, X), " &<br />
"35 (BC_2, D(15), output3, X, 31, 0, Z), " &<br />
"36 (BC_1, D(16), input, X), " &<br />
"37 (BC_2, D(16), output3, X, 40, 0, Z), " &<br />
"38 (BC_1, D(17), input, X), " &<br />
"39 (BC_2, D(17), output3, X, 40, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"40 (BC_2, *, control, 0), " & -- d[19:16]<br />
"41 (BC_1, D(18), input, X), " &<br />
"42 (BC_2, D(18), output3, X, 40, 0, Z), " &<br />
"43 (BC_1, D(19), input, X), " &<br />
"44 (BC_2, D(19), output3, X, 40, 0, Z), " &<br />
"45 (BC_1, D(20), input, X), " &<br />
"46 (BC_2, D(20), output3, X, 49, 0, Z), " &<br />
"47 (BC_1, D(21), input, X), " &<br />
"48 (BC_2, D(21), output3, X, 49, 0, Z), " &<br />
"49 (BC_2, *, control, 0), " & -- d[23:20]<br />
"50 (BC_1, D(22), input, X), " &<br />
"51 (BC_2, D(22), output3, X, 49, 0, Z), " &<br />
"52 (BC_1, D(23), input, X), " &<br />
"53 (BC_2, D(23), output3, X, 49, 0, Z), " &<br />
"54 (BC_1, D(24), input, X), " &<br />
"55 (BC_2, D(24), output3, X, 58, 0, Z), " &<br />
"56 (BC_1, D(25), input, X), " &<br />
"57 (BC_2, D(25), output3, X, 58, 0, Z), " &<br />
"58 (BC_2, *, control, 0), " & -- d[27:24]<br />
"59 (BC_1, D(26), input, X), " &<br />
--num cell port function safe ccell dsval rslt<br />
"60 (BC_2, D(26), output3, X, 58, 0, Z), " &<br />
"61 (BC_1, D(27), input, X), " &<br />
"62 (BC_2, D(27), output3, X, 58, 0, Z), " &<br />
"63 (BC_1, D(28), input, X), " &<br />
"64 (BC_2, D(28), output3, X, 67, 0, Z), " &<br />
"65 (BC_1, D(29), input, X), " &<br />
"66 (BC_2, D(29), output3, X, 67, 0, Z), " &<br />
"67 (BC_2, *, control, 0), " & -- d[31:28]<br />
"68 (BC_1, D(30), input, X), " &<br />
"69 (BC_2, D(30), output3, X, 67, 0, Z), " &<br />
"70 (BC_1, D(31), input, X), " &<br />
"71 (BC_2, D(31), output3, X, 67, 0, Z), " &<br />
"72 (BC_1, A(9), input, X), " &<br />
"73 (BC_2, A(9), output3, X, 76, 0, Z), " &<br />
"74 (BC_1, A(8), input, X), " &<br />
"75 (BC_2, A(8), output3, X, 76, 0, Z), " &<br />
"76 (BC_2, *, control, 0), " & -- a[9:6]<br />
"77 (BC_1, A(7), input, X), " &<br />
"78 (BC_2, A(7), output3, X, 76, 0, Z), " &<br />
"79 (BC_1, A(6), input, X), " &<br />
--num cell port function safe ccell dsval rslt<br />
"80 (BC_2, A(6), output3, X, 76, 0, Z), " &<br />
"81 (BC_2, *, control, 0), " & -- a[5:4]<br />
"82 (BC_1, A(5), input, X), " &<br />
"83 (BC_2, A(5), output3, X, 81, 0, Z), " &<br />
"84 (BC_1, A(4), input, X), " &<br />
"85 (BC_2, A(4), output3, X, 81, 0, Z), " &<br />
MOTOROLA<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
<strong>M68060</strong> USER’S MANUAL<br />
9-21
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
"86 (BC_2, *, control, 0), " & -- a[3:2]<br />
"87 (BC_1, A(3), input, X), " &<br />
"88 (BC_2, A(3), output3, X, 86, 0, Z), " &<br />
"89 (BC_1, A(2), input, X), " &<br />
"90 (BC_2, A(2), output3, X, 86, 0, Z), " &<br />
"91 (BC_1, CLA, input, X), " &<br />
"92 (BC_2, *, control, 0), " & -- a[1:0]<br />
"93 (BC_1, A(1), input, X), " &<br />
"94 (BC_2, A(1), output3, X, 92, 0, Z), " &<br />
"95 (BC_1, A(0), input, X), " &<br />
"96 (BC_2, A(0), output3, X, 92, 0, Z), " &<br />
"97 (BC_2, TM(2), output3, X, 99, 0, Z), " &<br />
"98 (BC_2, TM(1), output3, X, 99, 0, Z), " &<br />
"99 (BC_2, *, control, 0), " & -- tln(1),tm[2:0]<br />
--num cell port function safe ccell dsval rslt<br />
"100 (BC_2, TM(0), output3, X, 99, 0, Z), " &<br />
"101 (BC_2, TLN(1), output3, X, 99, 0, Z), " &<br />
"102 (BC_2, R_W, output3, X, 104, 0, Z), " &<br />
"103 (BC_2, SIZ(1), output3, X, 104, 0, Z), " &<br />
"104 (BC_2, *, control, 0), " & -- tln(0),siz[1:0]<br />
"105 (BC_2, SIZ(0), output3, X, 104, 0, Z), " &<br />
"106 (BC_2, TLN(0), output3, X, 104, 0, Z), " &<br />
"107 (BC_2, LOCKE, output3, X, 109, 0, Z), " &<br />
"108 (BC_2, LOCK, output3, X, 109, 0, Z), " &<br />
"109 (BC_2, *, control, 0), " & -- lock,locke<br />
"110 (BC_2, BR, output3, X, 127, 0, Z), " &<br />
"111 (BC_1, BB, input, X), " &<br />
"112 (BC_2, *, control, 0), " & -- bb<br />
"113 (BC_2, BB, output3, X, 112, 0, Z), " &<br />
"114 (BC_1, SNOOP, input, X), " &<br />
"115 (BC_2, *, control, 0), " & -- tip<br />
"116 (BC_2, TIP, output3, X, 115, 0, Z), " &<br />
"117 (BC_1, TS, input, X), " &<br />
"118 (BC_2, *, control, 0), " & -- ts<br />
"119 (BC_2, TS, output3, X, 118, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"120 (BC_1, BTT, input, X), " &<br />
"121 (BC_2, *, control, 0), " & -- btt<br />
"122 (BC_2, BTT, output3, X, 121, 0, Z), " &<br />
"123 (BC_2, *, control, 0), " & -- sas<br />
"124 (BC_2, SAS, output3, X, 123, 0, Z), " &<br />
"125 (BC_2, PST(4), output3, X, 127, 0, Z), " &<br />
"126 (BC_2, PST(3), output3, X, 127, 0, Z), " &<br />
"127 (BC_2, *, control, 0), " & -- pst[4:0],br<br />
"128 (BC_2, PST(2), output3, X, 127, 0, Z), " &<br />
"129 (BC_2, PST(1), output3, X, 127, 0, Z), " &<br />
"130 (BC_2, PST(0), output3, X, 127, 0, Z), " &<br />
"131 (BC_1, TA, input, X), " &<br />
"132 (BC_1, TEA, input, X), " &<br />
"133 (BC_1, TRA, input, X), " &<br />
"134 (BC_1, BG, input, X), " &<br />
"135 (BC_1, BGR, input, X), " &<br />
"136 (BC_1, TBI, input, X), " &<br />
"137 (BC_1, AVEC, input, X), " &<br />
"138 (BC_1, TCI, input, X), " &<br />
9-22<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
"139 (BC_2, *, internal, X), " &<br />
--num cell port function safe ccell dsval rslt<br />
"140 (BC_4, CLK, input, X), " &<br />
"141 (BC_1, CLKEN, input, X), " &<br />
"142 (BC_1, IPL(0), input, X), " &<br />
"143 (BC_1, IPL(1), input, X), " &<br />
"144 (BC_1, IPL(2), input, X), " &<br />
"145 (BC_1, RSTI, input, X), " &<br />
"146 (BC_1, CDIS, input, X), " &<br />
"147 (BC_1, MDIS, input, X), " &<br />
"148 (BC_2, BS(3), output3, X, 150, 0, Z), " &<br />
"149 (BC_2, BS(2), output3, X, 150, 0, Z), " &<br />
"150 (BC_2, *, control, 0), " & -- bs[3:0]<br />
"151 (BC_2, BS(1), output3, X, 150, 0, Z), " &<br />
"152 (BC_2, BS(0), output3, X, 150, 0, Z), " &<br />
"153 (BC_2, *, control, 0), " & -- ipend,rsto<br />
"154 (BC_2, RSTO, output3, X, 153, 0, Z), " &<br />
"155 (BC_2, IPEND, output3, X, 153, 0, Z), " &<br />
"156 (BC_2, CIOUT, output3, X, 157, 0, Z), " &<br />
"157 (BC_2, *, control, 0), " & -- upa[1:0],ciout<br />
"158 (BC_2, UPA(0), output3, X, 157, 0, Z), " &<br />
"159 (BC_2, UPA(1), output3, X, 157, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"160 (BC_2, *, internal, X), " &<br />
"161 (BC_2, TT0, output3, X, 164, 0, Z), " &<br />
"162 (BC_1, TT1, input, X), " &<br />
"163 (BC_2, TT1, output3, X, 164, 0, Z), " &<br />
"164 (BC_2, *, control, 0), " & -- a[11:10],TT[1:0]<br />
"165 (BC_1, A(10), input, X), " &<br />
"166 (BC_2, A(10), output3, X, 164, 0, Z), " &<br />
"167 (BC_1, A(11), input, X), " &<br />
"168 (BC_2, A(11), output3, X, 164, 0, Z), " &<br />
"169 (BC_1, A(12), input, X), " &<br />
"170 (BC_2, A(12), output3, X, 173, 0, Z), " &<br />
"171 (BC_1, A(13), input, X), " &<br />
"172 (BC_2, A(13), output3, X, 173, 0, Z), " &<br />
"173 (BC_2, *, control, 0), " & -- a[15:12]<br />
"174 (BC_1, A(14), input, X), " &<br />
"175 (BC_2, A(14), output3, X, 173, 0, Z), " &<br />
"176 (BC_1, A(15), input, X), " &<br />
"177 (BC_2, A(15), output3, X, 173, 0, Z), " &<br />
"178 (BC_1, A(16), input, X), " &<br />
"179 (BC_2, A(16), output3, X, 182, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"180 (BC_1, A(17), input, X), " &<br />
"181 (BC_2, A(17), output3, X, 182, 0, Z), " &<br />
"182 (BC_2, *, control, 0), " & -- a[19:16]<br />
"183 (BC_1, A(18), input, X), " &<br />
"184 (BC_2, A(18), output3, X, 182, 0, Z), " &<br />
"185 (BC_1, A(19), input, X), " &<br />
"186 (BC_2, A(19), output3, X, 182, 0, Z), " &<br />
"187 (BC_1, A(20), input, X), " &<br />
"188 (BC_2, A(20), output3, X, 191, 0, Z), " &<br />
"189 (BC_1, A(21), input, X), " &<br />
"190 (BC_2, A(21), output3, X, 191, 0, Z), " &<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-23
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
"191 (BC_2, *, control, 0), " &<br />
"192 (BC_1, A(22), input, X), " & -- a[23:20]<br />
"193 (BC_2, A(22), output3, X, 191, 0, Z), " &<br />
"194 (BC_1, A(23), input, X), " &<br />
"195 (BC_2, A(23), output3, X, 191, 0, Z), " &<br />
"196 (BC_1, A(24), input, X), " &<br />
"197 (BC_2, A(24), output3, X, 200, 0, Z), " &<br />
"198 (BC_1, A(25), input, X), " &<br />
"199 (BC_2, A(25), output3, X, 200, 0, Z), " &<br />
--num cell port function safe ccell dsval rslt<br />
"200 (BC_2, *, control, 0), " & -- a[27:24]<br />
"201 (BC_1, A(26), input, X), " &<br />
"202 (BC_2, A(26), output3, X, 200, 0, Z), " &<br />
"203 (BC_1, A(27), input, X), " &<br />
"204 (BC_2, A(27), output3, X, 200, 0, Z), " &<br />
"205 (BC_1, A(28), input, X), " &<br />
"206 (BC_2, A(28), output3, X, 209, 0, Z), " &<br />
"207 (BC_1, A(29), input, X), " &<br />
"208 (BC_2, A(29), output3, X, 209, 0, Z), " &<br />
"209 (BC_2, *, control, 0), " & -- a[31:28]<br />
"210 (BC_1, A(30), input, X), " &<br />
"211 (BC_2, A(30), output3, X, 209, 0, Z), " &<br />
"212 (BC_1, A(31), input, X), " &<br />
"213 (BC_2, A(31), output3, X, 209, 0, Z) ";<br />
end MC68060;<br />
9.2 DEBUG PIPE CONTROL MODE<br />
A debug pipe control mode is implemented on the MC68060 to allow special chip functions<br />
to be accomplished. These functions are useful during system level hardware development<br />
and operating system debug. Access to the debug pipe control mode is achieved by negating<br />
the JTAG signal. When in the debug pipe control mode, the regular JTAG interface is<br />
used by the debug pipe control mode, and is therefore not available.<br />
The debug pipe control mode uses the resulting serial interface to load commands that allow<br />
various operations on the processor to occur. Some of the operations are: halt the central<br />
processing unit (CPU), restart the CPU, insert select commands into the primary pipeline,<br />
disable select processor configurations, force all outputs to high-impedance state, release<br />
all outputs from high-impedance state, and generate an emulator interrupt.<br />
The advantage of using the debug pipe control mode is that the processor is allowed to operate<br />
normally and at its normal frequency. The only difference is that the processor no longer<br />
has the regular JTAG interface. This should not be a problem since the regular JTAG interface<br />
is not used during normal processor operations.<br />
9-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
9.2.1 Debug Command Interface<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Figure 9-10 illustrates the debug command interface and Table 9-4 outlines the pins needed<br />
by the debug command interface. The debug command interface consists of a five-bit shift<br />
register and a five-bit parallel register, with each register operating independently. To activate<br />
the debug command interface, JTAG must be driven negated. This allows the debug<br />
command interface to take over the regular JTAG interface and remap JTAG pin functions.<br />
The resulting interface is fully synchronous to the CLK input.<br />
D31–D0<br />
A31–A0<br />
CLK<br />
JTAG<br />
TRST (PDISABLE)<br />
TDI (PTDI)<br />
TCK (PSHIFT)<br />
TDO (PTDO)<br />
TMS (PAPPLY)<br />
TO ALL<br />
FLIP-FLOPS<br />
CONTROLLER<br />
S<br />
E<br />
R<br />
I<br />
A<br />
L<br />
MC68060 CHIP BOUNDARY<br />
5-BIT<br />
COMMAND<br />
WORD<br />
Figure 9-10. Debug Command Interface Schematic<br />
Table 9-4. Debug Command Interface Pins<br />
Pin Name Alias Description<br />
TCK PSHIFT Serial Shift Enable<br />
TMS PAPPLY Command Apply Enable<br />
TDI PTDI Serial Command Data In<br />
TRST PDISABLE Debug Command Disable<br />
TDO PTDO Serial Command Data Out<br />
JTAG JTAG JTAG or Debug Select<br />
CLK CLK Clock<br />
The commands enter the debug command interface through the PTDI serial input signal into<br />
the five-bit shift register. The shift register is controlled by the PSHIFT input. The PSHIFT<br />
signal determines which rising CLK edge contains valid data on the PTDI input. When<br />
asserted the PSHIFT input causes data from the PTDI input to be latched and causes internal<br />
data bits already in the shift register to be passed on to the next shift register bit. Serial<br />
data eventually shifts out through the PTDO output. PTDO can be used as a status output<br />
and can be used to verify that the shift register is operating properly. Do not assert both PAP-<br />
PLY and PSHIFT on the same CLK edge as this is interpreted as a “no operation”.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-25<br />
P<br />
A<br />
R<br />
A<br />
L<br />
L<br />
E<br />
L<br />
COMMAND<br />
VALID<br />
BIT 4<br />
BIT 0<br />
OEP<br />
CONTROL LOGIC
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Operating independently of the 5-bit shift register, the 6-bit parallel register is the command<br />
register used by the operand execution pipeline (OEP) control logic to control processor<br />
operations. The sixth bit of the parallel register is connected to the PDISABLE input and<br />
bypasses the 5-bit shift register. PDISABLE should normally be driven negated at all times<br />
to indicate that the command register is active. The other five bits of the parallel register are<br />
each connected to a corresponding bit in the shift register. The PAPPLY input controls the<br />
parallel register. When PAPPLY is asserted, the PDISABLE and shift register data are<br />
latched into the parallel register, and the command is then transmitted to the OEP control<br />
logic. Do not assert both PAPPLY and PSHIFT on the same rising CLK edge as this is interpreted<br />
as a “no operation”. Do not assert PAPPLY more frequently than once every other<br />
rising CLK edge. Although most commands are five bits in length, it is not necessary to shift<br />
in all five bits for the “generate an emulator interrupt” command. For that command, only<br />
three bits need to be shifted in. Figure 9-11 shows a sample interface timing diagram.<br />
CLK<br />
JTAG<br />
PDISABLE<br />
PTDI<br />
PSHIFT<br />
PAPPLY<br />
0 1 2 3 4<br />
SERIAL REGISTER 4 0 1 2 3 4<br />
SERIAL REGISTER 3<br />
SERIAL REGISTER 2<br />
SERIAL REGISTER 1<br />
SERIAL REGISTER 0<br />
PARALLEL REGISTER<br />
COMMAND VALID<br />
0 1 2 3<br />
0 1 2<br />
0 1<br />
Figure 9-11. Interface Timing<br />
9-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
0<br />
4<br />
3<br />
2<br />
1<br />
0
9.2.2 Debug Pipe Control Mode Commands<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
The following capabilities are provided by the debug pipe control mode:<br />
• Halt and restart processor execution<br />
• Forcing the processor into an emulator mode<br />
• From a halted processor state, the following additional capabilities are provided:<br />
—Setting and resetting a non-pipelined execution mode in the processor<br />
—Override disable processor configuration features (instruction cache, data cache,<br />
address translation caches (ATCs), write buffer, branch cache, floating-point unit<br />
(FPU), superscalar dispatch)<br />
—Forcing insertion of cache and ATC control operations into the processor pipeline for<br />
execution (CINV all for instruction cache and data cache, CPUSH all for instruction<br />
cache and data cache, and PFLUSH all for ATCs)<br />
—Forcing all processor outputs into and out of a high-impedance state and disable all<br />
inputs<br />
—Setting and resetting modes that convert trace exceptions and breakpoint instructions<br />
into emulator mode entry<br />
Table 9-5 provides a brief summary of the command functions that are made available<br />
through the debug pipe control mode. Most of the commands can only be issued only when<br />
the processor is halted.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-27
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Table 9-5. Command Summary<br />
Command Command Operation<br />
$00 No operation<br />
Restart the processor<br />
This command restarts the processor after it had been halted by the execution of a HALT instruction<br />
$01<br />
(opcode = $4AC8), or receipt of the $02 (Halt the processor) command.This command must be issued<br />
only when the processor is halted.<br />
Halt the processor<br />
This command forces the processor to gracefully halt. The processor samples for halts once per instruc-<br />
$02<br />
tion and if this command is present, the processor halts execution. The halted state is reflected in the<br />
PST encoding (PST = 11100).<br />
Enable the PULSE instruction to toggle non-pipelined mode<br />
This command enables the PULSE instruction (opcode = $4acc) to toggle the processor between the<br />
non-pipelined mode (allowing single-pipe dispatches) and normal pipeline mode. The PULSE instruction<br />
$03<br />
must be followed by a NOP to ensure proper operation. Refer to command $07 for details of non-pipelined<br />
mode, single-pipe dispatch operation. The $04 command negates the effect of this command. This<br />
command must be issued only when the processor is halted.<br />
Reset all non-pipelined modes<br />
This command forces the processor to normal pipeline operation and negates the effect of the $03, $06,<br />
$04<br />
and $07 commands. The $04 command negates the effect of this command. This command must be issued<br />
only when the processor is halted.<br />
$05 Reserved<br />
Enable non-pipelined mode (allowing superscalar dispatches)<br />
This command forces the processor into a non-pipelined mode of operation, while allowing superscalar<br />
dispatches (if PCR0 = 1). After an instruction pair is dispatched into the primary and secondary OEPs,<br />
execution of the subsequent instructions is delayed until the original instruction(s) complete execution<br />
$06<br />
and the pipeline is synchronized. The synchronization requires the processor to be in a quiescent state<br />
with all pending memory cycles complete. This implies all write buffers (push and store) are empty. The<br />
$04 command negates the effect of this command. This command must be issued only when the processor<br />
is halted.<br />
Enable non-pipelined mode (allowing single-pipe dispatches)<br />
This command forces the processor into a non-pipelined mode of operation, while allowing instruction<br />
dispatches into the primary OEP only. After an instruction has been dispatched into the primary OEP,<br />
execution of the subsequent instructions is delayed until the original instruction complete execution and<br />
$07<br />
the pipeline is synchronized. The synchronization requires the processor to be in a quiescent state with<br />
all pending memory cycles complete. This implies all write buffers (push and store) are empty. The $04<br />
command negates the effect of this command. This command must be issued only when the processor<br />
is halted.<br />
Perform CINVA IC operation<br />
$08 This command causes a CINVAIC instruction to be inserted into the primary OEP. This command must<br />
be received while the processor is halted.<br />
Perform CINVA DC operation<br />
$09 This command causes a CINVA DC instruction to be inserted into the primary OEP. This command must<br />
be received while the processor is halted.<br />
Perform CPUSHA IC,DC operation<br />
$0A This command causes a CPUSHA IC,DC instruction to be inserted into the primary OEP. This command<br />
must be issued only when the processor is halted.<br />
Perform CPUSHA DC operation<br />
$0B This command causes a CPUSHA DC instruction to be inserted into the primary OEP. This command<br />
must be issued only when the processor is halted.<br />
Perform PFLUSHA operation<br />
$0C This command causes a PFLUSHA instruction to be inserted into the primary OEP. This command must<br />
be received while the processor is halted.<br />
9-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
Table 9-5. Command Summary (Continued)<br />
Command Command Operation<br />
Force all the processor outputs to high-impedance state<br />
This command causes the processor to three-state all output pins and ignore all input pins. This com-<br />
$0D mand does not apply to the debug command interface pins. This forces the processor into a state where<br />
an emulator can generate system bus cycles by driving the appropriate pins. This command must be issued<br />
only when the processor is halted.<br />
Release all the processor outputs from high-impedance state<br />
$0E This command causes the processor to re-enable all output pins and begin sampling all the input pins.<br />
This command must be issued only when the processor is halted.<br />
Negate the effects of the Disable commands<br />
$0F<br />
This command causes the processor to disable the effects of the commands from $10 to $17.<br />
Disable instruction cache<br />
$10 This command forces the processor to run with the instruction cache disabled. The $0F command negates<br />
the effect of this command. This command must be issued only when the processor is halted.<br />
Disable data cache<br />
$11 This command forces the processor to run with the data cache disabled. The $0F command negates the<br />
effect of this command. This command must be issued only when the processor is halted.<br />
Disable instruction ATC<br />
$12 This command forces the processor to run with the instruction ATC disabled. The $0F command negates<br />
the effect of this command. This command must be issued only when the processor is halted.<br />
Disable data ATC<br />
$13 This command forces the processor to run with the data ATC disabled. The $0F command negates the<br />
effect of this command. This command must be issued only when the processor is halted.<br />
Disable write buffer<br />
This command forces the processor to run with the store buffers disabled. This command operation is<br />
$14<br />
equivalent to that provided by the cache control register (CACR) bit 29. The $0F command negates the<br />
effect of this command. This command must be issued only when the processor is halted.<br />
Disable branch cache<br />
$15 This command forces the processor to run with the branch cache disabled. The $0F command negates<br />
the effect of this command. This command must be issued only when the processor is halted.<br />
Disable FPU<br />
$16 This command forces the FPU-disabled operation. The $0F command negates the effect of this command.<br />
This command must be issued only when the processor is halted.<br />
Disable secondary OEP<br />
$17 This command disables superscalar operation. The $0F command negates the effect of this command.<br />
This command must be issued only when the processor is halted.<br />
trace -> normal trace; bkpt -> normal breakpoint<br />
$18 Both the trace and breakpoint exceptions operate normally. This command must be issued only when<br />
the processor is halted.<br />
trace -> normal trace; bkpt -> bkpt with emulator mode entry<br />
The trace exception operates normally. A breakpoint exception operates using vector offset $30, in ad-<br />
$19<br />
dition, the processor enters the emulator mode. This command must be issued only when the processor<br />
is halted.<br />
trace -> normal trace with emulator mode entry; bkpt -> normal breakpoint<br />
$1A The breakpoint exception operates normally. A trace exception operates normally; in addition, the processor<br />
enters the emulator mode. This command must be issued only when the processor is halted.<br />
trace -> normal trace with emulator mode entry; bkpt -> bkpt with emulator mode entry<br />
The trace exception operates normally. The breakpoint exception operates using vector offset $30. In<br />
$1B<br />
addition, when either of these exceptions are taken, the processor enters the emulator mode. This command<br />
must be issued only when the processor is halted.<br />
Generate an emulator interrupt<br />
$1C–$1F<br />
Take an emulator interrupt exception.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-29
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
There are two ways to halt the processor. The first method uses the debug pipe control<br />
mode command “halt the processor”. This command causes the processor to gracefully halt<br />
instruction execution. When this command is received, the processor posts a pending halt<br />
condition an then waits for an interruptible point to be reached. Once the interruptible point<br />
is encountered, the processor halts instruction execution and signals the status with the<br />
PSTx signals.<br />
The second method uses the HALT instruction. The HALT instruction is a 16-bit privileged<br />
instruction ($4AC8 encoding) and is new with the MC68060 instruction set. When the processor<br />
executes this instruction, the pipeline is synchronized and then the processor enters<br />
the halted state. Once halted, the processor drives a unique PSTx output encoding.<br />
The halt state is different than the stopped state since no interrupts are processed while in<br />
this mode. To enable the processor to exit the halted state and resume normal instruction<br />
execution, the “restart the processor” command is issued through the debug pipe control<br />
mode. When this command is received, the processor continues normal instruction execution<br />
by forcing an instruction fetch to the next sequential instruction address contained in the<br />
program counter (PC). Using this approach, any commands that may have been executed<br />
while halted (like patching memory and clearing the instruction cache) will be correctly handled<br />
by the processor when restarting. For instance, if the HALT instruction was used to<br />
place the processor into the halted state, instruction execution resumes at the instruction following<br />
the HALT instruction.<br />
The commands $06 and $07 can be used to force nonpipelined operation. When operating<br />
in nonpipelined execution mode, the processor’s OEP performs a single dispatch (of an<br />
instruction or instruction pair) and immediately enters a pipeline hold state that prevents subsequent<br />
dispatches. After the instruction/instruction pair has completed execution of all OEP<br />
pipeline stages, the hold state is reset to release another single dispatch. To allow toggling<br />
between normal operation and the nonpipelined, single-pipe operation, a new MC68060<br />
instruction, the PULSE instruction, can be used by issuing command $03.<br />
The PULSE instruction is a 16-bit user mode instruction that uses the $4ACC opcode. The<br />
PULSE instruction has been added to the instruction set primarily to provide a unique encoding<br />
of the PSTx outputs for external triggering purposes. Additionally, with command $03, it<br />
is used to allow the capability to toggle in and out of nonpipelined operation mode. When<br />
the PULSE instruction is executed in user mode, the PSTx encoding $04 will exist for one<br />
CLK period. When the PULSE instruction is executed in supervisor mode, the PSTx encoding<br />
of $14 will exist for one CLK period.<br />
When using the PULSE instruction to toggle in and out of nonpipelined mode, A NOP<br />
instruction must follow the PULSE instruction to ensure proper operation. All nonpipelined<br />
modes of operation are disabled through the “reset all nonpipelined modes” command $04.<br />
Commands $08 to $0C are used to insert instructions into the primary OEP. These instructions<br />
are executed immediately. Accordingly, any number of commands can be shifted into<br />
the processor while halted. The execution time of the instruction is equal to the normal execution<br />
time of the instruction plus three CLK periods, where the first cycle corresponds to<br />
the cycle when “command valid” is asserted. It is the responsibility of the external logic<br />
9-30 <strong>M68060</strong> USER’S MANUAL MOTOROLA
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
inserting the commands to guarantee that there is sufficient time between commands to<br />
allow for proper operation.<br />
Commands $0D three-states all outputs and causes all inputs to be ignored. Command $0E<br />
allows outputs to be driven and inputs to be sampled.<br />
Commands $10–$17 force specific processor features to be disabled. Command $0F<br />
negates the effects of all the commands between $10 and $17. These commands override<br />
the configuration as defined by the CACR, PCR, or TCR. Note that these instructions affecting<br />
processor configuration do not affect the operation of the MOVEC instructions which<br />
affect the CACR, PCR, or TCR. The MOVEC instruction to these registers operates normally,<br />
but the enabling of a specific feature is overridden if the corresponding debug function<br />
has been executed. Any MOVEC reading contents of the CACR, PCR, or TCR will return<br />
the value contained in the register and is independent of any debug commands which may<br />
have been executed.<br />
Commands $18–$1B configure whether or not the trace and breakpoint exceptions force a<br />
processor entry into emulator mode.<br />
Commands $1C–$1F generate an emulator interrupt exception.<br />
9.2.3 Emulator Mode<br />
The MC68060 implements a mode of operation that provides an outside control function<br />
(i.e., emulator) controllability and visibility mechanisms to direct MC68060 processor operations.<br />
When the processor is in the emulator mode, the branch cache is not used. Instructions executed<br />
when the MC68060 is in emulator mode generate address space and bus transfer<br />
cycle attributes as an alternate logical function code space access with no address translation:<br />
• No address translation<br />
• No cache access<br />
• TT1, TT0 = 2 {Alternate Logical Function Code Access}<br />
• TM2–TT0 = 5 (operand references) or 6 (instruction references) {Logical Function Code<br />
5 or 6}.<br />
Entry into emulator mode can be accomplished via one of four methods:<br />
1. A “generate emulator interrupt” command can be initiated through the debug pipe control<br />
mode. If this command is received by the MC68060, the processor waits for an<br />
interruptible point in the instruction stream, and then generates an emulator interrupt<br />
exception. A four-word exception stack frame (in alternate address space) is created,<br />
with the PC value equal to the next PC and the exception type/vector offset equal to<br />
$30. The vector pointed to by VBR + $30 defines the exception handler entry point,<br />
within the alternate address space (TT = 2, TM = 6).<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-31
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
2. After RSTI is negated, the processor counts 16 CLKs before actually beginning the<br />
reset exception processing. The “generate emulator interrupt” command must be<br />
received through the debug pipe control mode within that 16-CLK window. The reset<br />
exception is processed normally, but the fetch of the initial stack pointer and initial PC<br />
is mapped to the alternate address space. Instruction execution begins in emulator<br />
mode. The reset exception vector pointed to by VBR + $04 defines the entry point<br />
within the alternate address space.<br />
3. If a breakpoint entry into emulator mode is enabled via the debug pipe control mode,<br />
the execution of a BKPT instruction generates an entry into emulator mode. For this<br />
case, the processor creates a four-word stack frame (in alternate address space) with<br />
the PC equal to the PC of the BKPT instruction and the vector offset equal to $30. VBR<br />
+ $30 defines the entry point within the alternate address space.<br />
4. If a trace entry into emulator mode is enabled via the debug pipe control mode, all<br />
trace exceptions cause an entry into the emulator mode. For this case, the processor<br />
creates the normal six-word trace exception stack frame (in alternate address space),<br />
with PC equal to the next PC, address equal to the last PC, and vector offset equal to<br />
$24. The trace exception vector pointed to by VBR + $24 defines the entry point within<br />
the alternate address space.<br />
Exit from emulator mode is performed via the execution of an RTE instruction. Note that an<br />
RTE executed from emulator mode assumes that the stack is in the alternate address<br />
space. Other properties of the processor while executing in the emulator mode are as follows:<br />
• MOVES instructions operate normally, using standard address translation/cache access<br />
for these instructions. The MDIS and CDIS input pins can be used to disable address<br />
translation and/or cache access on these instructions.<br />
• TAS, CAS, and MOVE16 instructions must not be executed in emulator mode—results<br />
of these instructions executed in emulator mode are unpredictable (undefined).<br />
• All interrupts are ignored while the MC68060 is in emulator mode.<br />
If memory does not respond to the alternate function code space, it is the responsibility of<br />
the emulator to capture and save the stack frame information for its own use. The emulator<br />
is also responsible for supplying the saved stack frame information in response to the reads<br />
initiated by an RTE instruction (word read for SR, long-word read for PC, word read for format/vector).<br />
A unique PSTx encoding of $08 is used to identify emulator mode exception<br />
processing.<br />
The emulator interrupt exception is treated like other interrupts by the MC68060 processor<br />
and is sampled for at the completion of execution of an instruction. Once an interruptible<br />
point is encountered and the exception initiated, the processor pushes a normal exception<br />
stack frame (storing SR, PC, and format/vector and decrementing the supervisor stack<br />
pointer) by performing two long word writes. This is performed with emulator mode addressing—alternate<br />
function code space.<br />
The emulator interrupt exception priority falls below trace and above regular interrupts in the<br />
MC68060 exception priority list. Its exception vector number is 12 (vector offset = $30), its<br />
stack frame is four-word (format =0), and it stores the PC of the next instruction (like other<br />
9-32 <strong>M68060</strong> USER’S MANUAL MOTOROLA
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
interrupts). The 32-bit instruction address of the first instruction of the emulator interrupt<br />
exception handler is derived as with other exceptions—the memory contents of address<br />
VBR + exception offset ($30).<br />
The emulator mode entry from the breakpoint exception shares the same vector table entry<br />
(VBR + $30) as the emulator interrupt exception. However, the emulator mode entry from<br />
the breakpoint exception requires that the exception handler increment the stacked PC by<br />
two to point to the instruction following the breakpoint instruction. On the other hand, the<br />
emulator interrupt stack’s PC already points to the next instruction.<br />
9.3 SWITCHING BETWEEN JTAG AND DEBUG PIPE CONTROL<br />
MODES OF OPERATION<br />
Since JTAG and the debug pipe control modes share the same set of pins, only one mode<br />
can be used at a time. Normally, the JTAG mode is used only during product testing, and<br />
the debug pipe control mode is used by the end user in conjunction with an in-circuit emulator.<br />
For this use, the board manufacturer normally designs in whatever JTAG functionality<br />
is required without regard to whether the board will eventually be used in the debug pipe<br />
control mode or not. The responsibility of allowing the processor to operate under the debug<br />
pipe control mode lies with the emulator vendor. The emulator vendor needs to ensure that<br />
the socket built to carry the processor has the target system’s JTAG pins isolated from the<br />
processor to allow full control of these pins. Hence, under normal circumstances, dynamic<br />
switching between JTAG and debug pipe control modes is unnecessary.<br />
However, for systems that need to switch between these modes can do so by following<br />
some guidelines. These guidelines are illustrated in Figure 9-12 and Figure 9-13. These figures<br />
illustrate how to transition between the JTAG mode and the debug pipe control mode.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-33
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
CLK<br />
TCK<br />
JTAG<br />
TRST<br />
TMS<br />
TDI<br />
STATE<br />
1<br />
JTAG MODE<br />
2 3 4 5 6 7 8 9 10 11 12 13 14<br />
2 3 4<br />
SeIR TLR<br />
TLR<br />
TLR DISABLED<br />
DEBUG MODE<br />
NOTES:<br />
1. Clock is shown at 2x TCK here for illustration. Any relationship may exist but 3 full rising edges of CLK should occur after JTAG<br />
goes high and before PSHIFT or PDISABLE change.<br />
2. When JTAG goes high, the MC68060 goes from "functional with JTAG" to "functional with DEBUG". When going to DEBUG<br />
modes the JTAG package pins remap to:<br />
TRST → PDISABLE<br />
TDI → PTDI<br />
TMS → PAPPLY<br />
TCK → PSHIFT<br />
JTAG MUST BE IN TLR<br />
ALL "P" signals internally negated when JTAG = low.<br />
3. Hold TRST = H across boundary to prevent PAPPLY.<br />
4. Hold TMS = H across boundary to keep JTAG in TLR.<br />
5. After the boundary, PAPPLY must be negated before PDISABLE negates.<br />
Figure 9-12. Transition from JTAG to Debug Mode Timing Diagram<br />
9-34 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
SHIFT<br />
SHIFT<br />
APPLY<br />
CLK<br />
PSHIFT<br />
JTAG<br />
PDISABLE<br />
PAPPLY<br />
PTDI<br />
ACTION
CLK<br />
PSHIFT<br />
JTAG<br />
PDISABLE<br />
PAPPLY<br />
PTDI<br />
ACTION<br />
1<br />
IEEE 1149.1 Test (JTAG) and Debug Pipe Control Modes<br />
DEBUG MODE<br />
JTAG MODE<br />
2 3 4 5 6 7 8 9 10 11 12 13 14 15<br />
SHIFT APPLY NO ACTION<br />
TLR<br />
TLR TLR<br />
RTI SeDR STATE<br />
TRANSITION FROM DEBUG TO JTAG MODE<br />
NOTES:<br />
1. Clock is shown at 2x TCK here for illustration.<br />
2. Hold PSHIFT = L and PAPPLY = L across boundary to prevent debug command.<br />
3. Hold TRST = L across boundary to asynchronously set to TLR state.<br />
4. Establish TDI = H and TMS = H before starting TCK.<br />
5. Negate TRST after starting TCK.<br />
Figure 9-13. Transition from Debug to JTAG Mode Timing Diagram<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 9-35<br />
CLK<br />
TCK<br />
JTAG<br />
TRST<br />
TMS<br />
TDI
SECTION 10<br />
INSTRUCTION EXECUTION TIMING<br />
This section details the MC68060 instruction execution times in terms of processor clock<br />
cycles and the superscalar architecture. The number of operand cycles for each instruction<br />
is also included, enclosed in parentheses following the number of clock cycles. Timing<br />
entries are presented as:<br />
C(r/w)<br />
where:<br />
C = The number of processor clock cycles, including all applicable operand fetches and<br />
stores, plus all internal CPU cycles required to complete the instruction execution.<br />
r/w = The number of operand reads (r) and writes (w). A read-modify-write cycle is<br />
denoted as (1/1).<br />
10.1 SUPERSCALAR OPERAND EXECUTION PIPELINES<br />
The superscalar architecture of the MC68060 processor consists of three structures within<br />
the operand execution pipeline (OEP). The components include a primary OEP (pOEP), a<br />
secondary OEP (sOEP) plus a monolithic register file containing the general-purpose registers,<br />
Dn and An. As instructions are gated out of the instruction fetch pipeline’s instruction<br />
buffer, consecutive operation words (if available) are loaded into the pOEP and sOEP. A<br />
superscalar instruction dispatch algorithm must then determine if the instruction-pair may<br />
continue its OEP execution simultaneously.<br />
Each OEP consists of two compute engines: an adder structure for calculating operand virtual<br />
addresses (the address generation unit (AGU)) and an integer execute engine for performing<br />
instruction operations (the integer execute engine (IEE)).<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
10-1
Instruction Execution Timing<br />
Each compute engine has resources associated with its respective function. A generalized<br />
model of the resources required for instruction execution can be stated as:<br />
Instruction Resources = f(Base, Index, A, B, Address_result, Execute_result)<br />
where:<br />
Base = Base address register for the AGU<br />
Index = Index register for the AGU<br />
A = Source operand required by the “A” side of the arithmetic/logic unit<br />
within the integer execute engine<br />
B = Source operand required by the “B” side of the arithmetic/logic unit<br />
within the integer execute engine<br />
Address_result = Result operand produced by the address generation unit<br />
Execute_result = Result operand produced by the integer execute engine<br />
In the MC68060 design, the dispatch algorithm is implemented by assigning a 5-bit “name”<br />
to each resource. The name is then used to identify the exact resource required for each<br />
instruction’s execution. The resource name may identify one of the sixteen general-purpose<br />
machine registers (Rn) or a non-register resource (e.g., memory operand, immediate operand,<br />
etc.).<br />
The dispatch algorithm operates within the first stage of the operand execution pipeline. The<br />
results of the resource examination must be completed within this first stage to transition the<br />
appropriate instruction(s) into the subsequent stages of the OEPs. In particular, the dispatch<br />
algorithm determines if resource conflicts exist between the pOEP and sOEP.<br />
By definition of the MC68060 architecture, there are no conflicts possible on non-register<br />
resources. This means the dispatch algorithm must detect any register resource conflicts<br />
between the pOEP and sOEP. The sOEP resource requirements are validated through a<br />
series of six tests. If all the tests are successful, the sOEP instruction is dispatched simultaneously<br />
with the pOEP instruction into the second stage of the pipeline. If any test fails, the<br />
dispatching of the sOEP instruction is inhibited.<br />
10.1.1 Dispatch Test 1: sOEP Opword and Required<br />
Extension Words Are Valid<br />
Whenever instructions are loaded into the OEP, the instruction buffer attempts to load a 16bit<br />
operation word and 32-bits of extension words into both the pOEP and sOEP. This test<br />
validates that the operation word and any extension words required by the sOEP instruction<br />
are present. If the required opword and extensions are valid, the subsequent tests may be<br />
performed. In the event that any of the required instruction words are not valid, the instruction<br />
in the pOEP is dispatched immediately rather than delay execution waiting for instruction<br />
words for the sOEP.<br />
10.1.2 Dispatch Test 2: Instruction Classification<br />
The instruction set of the M68000 family can be broadly separated into two groups: standard<br />
and non-standard instructions. Standard instructions represent the majority of the instruction<br />
set and the basic control structure for the OEP supports these operations without any<br />
instruction-specific control states. Conversely, the non-standard instructions represent more<br />
complex operations and require additional hardware to control their execution within the<br />
10-2<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
OEP. In many cases, a non-standard instruction requires multiple cycles to execute and the<br />
operation is decomposed into a series of “standard” cycles.<br />
The MC68060 definition of a standard instruction is:<br />
• The instruction requires a maximum of one set of extension words.<br />
• The instruction makes a maximum of one memory access.<br />
• The resources required by the instruction are completely specified by the operation<br />
word.<br />
The standard instruction group is subdivided into two classes:<br />
pOEP | sOEP This class identifies those standard instructions which may be executed<br />
in either the primary or secondary OEP. This group represents all<br />
standard single-cycle instructions.<br />
pOEP-only This class of standard instructions may be executed in the primary OEP<br />
only. This class includes all multi-cycle standard instructions.<br />
The non-standard instruction group is subdivided into three classes:<br />
pOEP-until-last Many of the non-standard instructions represent a combination of<br />
multiple “standard” operations. As an example, consider the<br />
memory-to-memory MOVE instruction. This instruction is decomposed<br />
into two standard operations: first, a standard read cycle followed by a<br />
standard write cycle. This class allows a standard single-cycle<br />
instruction to be dispatched from the sOEP during the last cycle of its<br />
pOEP execution.<br />
pOEP-only This class of non-standard instructions may only be executed in the<br />
primary OEP.<br />
pOEP-but- This class of non-standard instructions requires that the<br />
allows-sOEP operation be performed in the primary OEP, but allows standard<br />
instructions of the pOEP | sOEP class to be dispatched to the<br />
secondary OEP.<br />
Given these instruction classifications, consider Table 10-1 which defines Test 2 of the<br />
superscalar dispatch algorithm of the OEP:<br />
10-3
Instruction Execution Timing<br />
10-4<br />
Table 10-1. Superscalar OEP Dispatch Test Algorithm<br />
Contents of pOEP Contents of sOEP Dispatch Algorithm<br />
pOEP | sOEP pOEP | sOEP Test 2 is successful<br />
pOEP | sOEP pOEP-only Test 2 fails<br />
pOEP | sOEP pOEP-until-last Test 2 fails<br />
pOEP | sOEP pOEP-but-allows-sOEP Test 2 fails<br />
— — —<br />
pOEP-only pOEP | sOEP Test 2 fails<br />
pOEP-only pOEP-only Test 2 fails<br />
pOEP-only pOEP-until-last Test 2 fails<br />
pOEP-only pOEP-but-allows-sOEP Test 2 fails<br />
— — —<br />
pOEP-until-last pOEP | sOEP Test 2 is successful<br />
pOEP-until-last pOEP-only Test 2 fails<br />
pOEP-until-last pOEP-until-last Test 2 fails<br />
pOEP-until-last pOEP-but-allows-sOEP Test 2 fails<br />
— — —<br />
pOEP-but allows-sOEP pOEP | sOEP Test 2 is successful<br />
pOEP-but allows-sOEP pOEP-only Test 2 fails<br />
pOEP-but allows-sOEP pOEP-until-last Test 2 fails<br />
pOEP-but allows-sOEP pOEP-but-allows-sOEP Test 2 fails<br />
Table 10-2, Table 10-3, and Table 10-4 define the classification for the entire instruction set.<br />
The notation “–(Ax)+” indicates = {(Ax), (Ax)+, –(Ax)}.<br />
Table 10-2. MC68060 Superscalar Classification<br />
of M680x0 Integer Instructions<br />
Mnemonic Instruction Superscalar Classification<br />
ABCD Add Decimal with Extend pOEP-only<br />
ADD Add pOEP | sOEP<br />
ADDA Add Address pOEP | sOEP<br />
ADDI,Dx Add Immediate pOEP | sOEP<br />
ADDI,–(Ax)+ “ pOEP | sOEP<br />
Remaining ADDI “ pOEP-until-last<br />
ADDQ Add Quick pOEP | sOEP<br />
ADDX Add Extended pOEP-only<br />
AND AND Logical pOEP | sOEP<br />
ANDI,Dx AND Immediate pOEP | sOEP<br />
ANDI,–(Ax)+ “ pOEP | sOEP<br />
Remaining ANDI “ pOEP-until-last<br />
ANDI to CCR AND Immediate to Condition Codes pOEP-only<br />
ASL Arithmetic Shift Left pOEP | sOEP<br />
ASR Arithmetic Shift Right pOEP | sOEP<br />
Bcc Branch Conditionally pOEP-only1<br />
BCHG Dy, Test a Bit and Change pOEP-only<br />
BCHG #, “ pOEP-until-last<br />
BCLR Dy, Test a Bit and Clear pOEP-only<br />
BCLR #, “ pOEP-until-last<br />
BFCHG Test Bit Field and Change pOEP-only<br />
BFCLR Test Bit Field and Clear pOEP-only<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
Table 10-2. MC68060 Superscalar Classification<br />
of M680x0 Integer Instructions (Continued)<br />
BFEXTS Extract Bit Field Signed pOEP-only<br />
BFEXTU Extract Bit Field Unsigned pOEP-only<br />
BFFFO Find First One in Bit Field pOEP-only<br />
BFINS Insert Bit Field pOEP-only<br />
BFSET Set Bit Field pOEP-only<br />
BFTST Test Bit Field pOEP-only<br />
BKPT Breakpoint pOEP-only<br />
BRA Branch Always pOEP-only<br />
BSET Dy, Test a Bit and Set pOEP-only<br />
BSET #, “ pOEP-until-last<br />
BSR Branch to Subroutine pOEP-only<br />
BTST Dy, Test a Bit pOEP-only<br />
BTST #, “ pOEP-until-last<br />
CAS Compare and Swap with Operand pOEP-only<br />
CHK Check Register Against Bounds pOEP-only<br />
CLR Clear an Operand pOEP | sOEP<br />
CMP Compare pOEP | sOEP<br />
CMPA Compare Address pOEP | sOEP<br />
CMPI,Dx Compare Immediate pOEP | sOEP<br />
CMPI,–(Ax)+ “ pOEP | sOEP<br />
Remaining CMPI “ pOEP-until-last<br />
CMPM Compare Memory pOEP-until-last<br />
DBcc Test Condition, Decrement and Branch pOEP-only<br />
DIVS.L Signed Divide Long pOEP-only<br />
DIVS.W Signed Divide Word pOEP-only<br />
DIVU.L Unsigned Long Divide pOEP-only<br />
DIVU.W Unsigned Divide Word pOEP-only<br />
EOR Exclusive OR Logical pOEP | sOEP<br />
EORI,Dx Exclusive OR Immediate pOEP | sOEP<br />
EORI,–(Ax)+ “ pOEP | sOEP<br />
Remaining EORI “ pOEP-until-last<br />
EORI to CCR Exclusive OR Immediate to Condition Codes pOEP-only<br />
EXG Exchange Registers pOEP-only<br />
EXT Sign Extend pOEP | sOEP<br />
EXTB.L Sign Extend Byte to Long pOEP | sOEP<br />
ILLEGAL Take Illegal Instruction Trap pOEP | sOEP<br />
JMP Jump pOEP-only<br />
JSR Jump to Subroutine pOEP-only<br />
LEA Load Effective Address pOEP | sOEP<br />
LINK Link and Allocate pOEP-until-last<br />
LSL Logical Shift Left pOEP | sOEP<br />
LSR Logical Shift Right pOEP | sOEP<br />
MOVE,Rx Move Data from Source to Destination pOEP | sOEP<br />
MOVE Ry, “ pOEP | sOEP<br />
MOVE y,x “ pOEP-until-last<br />
MOVE #,x “ pOEP-until-last<br />
MOVEA Move Address pOEP | sOEP<br />
MOVE from CCR Move from Condition Codes pOEP-only<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
Mnemonic Instruction Superscalar Classification<br />
10-5
Instruction Execution Timing<br />
10-6<br />
Table 10-2. MC68060 Superscalar Classification<br />
of M680x0 Integer Instructions (Continued)<br />
Mnemonic Instruction Superscalar Classification<br />
MOVE to CCR Move to Condition Codes pOEP | sOEP<br />
MOVE16 Move 16 Byte Block pOEP-only<br />
MOVEM Move Multiple Registers pOEP-only<br />
MOVEQ Move Quick pOEP | sOEP<br />
MULS.L Signed Multiply Long pOEP-only<br />
MULS.W Signed Multiply Word pOEP-only<br />
MULU.L Unsigned Multiply Long pOEP-only<br />
MULU.W Unsigned Multiply Word pOEP-only<br />
NBCD Negate Decimal with Extend pOEP-only<br />
NEG Negate pOEP | sOEP<br />
NEGX Negate with Extend pOEP-only<br />
NOP No Operation pOEP-only<br />
NOT Logical Complement pOEP | sOEP<br />
OR Inclusive OR Logical pOEP | sOEP<br />
ORI,Dx Inclusive OR Immediate pOEP | sOEP<br />
ORI,–(Ax)+ “ pOEP | sOEP<br />
Remaining ORI “ pOEP-until-last<br />
ORI to CCR Inclusive OR Immediate to Condition Codes pOEP-only<br />
PACK Pack BCD Digit pOEP-only<br />
PEA Push Effective Address pOEP-only<br />
ROL Rotate without Extend Left pOEP | sOEP<br />
ROR Rotate without Extend Right pOEP | sOEP<br />
ROXL Rotate with Extend Left pOEP-only<br />
ROXR Rotate with Extend Right pOEP-only<br />
RTD Return and Deallocate Parameters pOEP-only<br />
RTR Return and Restore Condition Codes pOEP-only<br />
RTS Return from Subroutine pOEP-only<br />
SBCD Subtract Decimal with Extend pOEP-only<br />
Scc Set According to Condition pOEP-but-allows-sOEP<br />
SUB Subtract pOEP | sOEP<br />
SUBA Subtract Address pOEP | sOEP<br />
SUBI,Dx Subtract Immediate pOEP | sOEP<br />
SUBI,–(Ax)+ “ pOEP | sOEP<br />
Remaining SUBI “ pOEP-until-last<br />
SUBQ Subtract Quick pOEP | sOEP<br />
SUBX Subtract with Extend pOEP-only<br />
SWAP Swap Register Halves pOEP-only<br />
TAS Test and Set an Operand pOEP-only<br />
TRAP Trap pOEP | sOEP<br />
TRAPF Trap on False pOEP | sOEP<br />
remaining TRAPcc Trap on Condition pOEP-only<br />
TRAPV Trap on Overflow pOEP-only<br />
TST Test an Operand pOEP | sOEP<br />
UNLK Unlink pOEP-only<br />
UNPK Unpack BCD Digit pOEP-only<br />
1<br />
A Bcc instruction is pOEP-but-allows-sOEP if it is not predicted from the branch cache and the direction of the<br />
branch is forward or if the Bcc is predicted as a “not-taken” branch.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
Table 10-3. Superscalar Classification of M680x0 Privileged Instructions<br />
Mnemonic Instruction Superscalar Classification<br />
ANDI to SR AND Immediate to Status Register pOEP-only<br />
CINV Invalidate Cache Lines pOEP-only<br />
CPUSH Push and Invalidate Cache Lines pOEP-only<br />
EORI to SR Exclusive OR Immediate to Status Register pOEP-only<br />
MOVE from SR Move from Status Register pOEP-only<br />
MOVE to SR Move to Status Register pOEP-only<br />
MOVE USP Move User Stack Pointer pOEP-only<br />
MOVEC Move Control Register pOEP-only<br />
MOVES Move Address Space pOEP-only<br />
ORI to SR Inclusive OR Immediate to Status Register pOEP-only<br />
PFLUSH Flush ATC Entries pOEP-only<br />
PLPA Load Physical Address pOEP-only<br />
RESET Reset External Devices pOEP-only<br />
RTE Return from Exception pOEP-only<br />
STOP Load Status Register and Stop pOEP-only<br />
Table 10-4. Superscalar Classification of M680x0 Floating-Point Instructions<br />
Mnemonic Instruction Superscalar Classification<br />
FABS, FDABS, FSABS Absolute Value pOEP-but-allows-sOEP1<br />
FADD, FDADD, FSADD Add pOEP-but-allows-sOEP1<br />
FBcc Branch Conditionally pOEP-only<br />
FCMP Compare pOEP-but-allows-sOEP1<br />
FDIV, FDDIV, FSDIV,<br />
FSGLDIV<br />
Divide 1<br />
pOEP-but-allows-sOEP<br />
FINT, FINTRZ Integer Part, Round-to-Zero pOEP-but-allows-sOEP1<br />
FMOVE, FDMOVE, FSMOVE Move Floating-Point Data Register pOEP-but-allows-sOEP1<br />
FMOVE Move System Control Register pOEP-only<br />
FMOVEM Move Multiple Data Registers pOEP-only<br />
FMUL, FDMUL, FSMUL,<br />
FSGLMUL<br />
Multiply pOEP-but-allows-sOEP1<br />
FNEG, FDNEG, FSNEG Negate pOEP-but-allows-sOEP<br />
1<br />
FNOP No Operation pOEP-only<br />
FSQRT Square Root pOEP-but-allows-sOEP1<br />
FSUB, FDSUB, FSSUB Subtract pOEP-but-allows-sOEP1<br />
FTST Test Operand pOEP-but-allows-sOEP1<br />
1<br />
These floating-point instructions are pOEP-but-allows-sOEP except for the following:<br />
FDm,FPn<br />
F&imm,FPn<br />
F.x,FPn<br />
which are classified as pOEP-only<br />
The MC68060 superscalar architecture allows pairs of single-cycle standard operations to<br />
be simultaneously dispatched in the operand execution pipelines. Additionally, the design<br />
also permits a single-cycle standard instruction plus a conditional branch (Bcc) predicted<br />
by the branch cache to be dispatched in the OEP. Bcc instructions predicted as not taken<br />
allow another instruction to be executed in the sOEP. This also is true for forward Bcc<br />
instructions that are not predicted.<br />
10-7
Instruction Execution Timing<br />
Additionally, the use of instruction folding techniques allow one or two instructions to be<br />
simultaneously executed with a predicted taken Bcc (also for BRA and JMP instructions).<br />
The floating-point pre-exception model of the MC68060 supports execution overlap<br />
between multi-cycle floating-point instructions and the integer execute engines. Once a<br />
multi-cycle floating-point instruction has started its execution, the primary and secondary<br />
OEPs may continue to dispatch and complete integer instructions in parallel with the<br />
floating-point instructions. The OEPs will stall only if another floating-point instruction is<br />
encountered before the first floating-point instruction has completed its execution. The<br />
floating-point instructions that permit this execution overlap are classified as pOEP-butallows-sOEP<br />
in Table 10-4.<br />
10.1.3 Dispatch Test 3: Allowable Effective Addressing Mode in the sOEP<br />
To minimize the hardware structures required for the address generation unit within the secondary<br />
OEP, certain addressing modes are not allowed. The addressing modes not supported<br />
by the sOEP include: the address register indirect with index plus base displacement<br />
{(bd, An, Xi∗SF)}<br />
and all PC-relative modes {(d16, PC), (d8, PC, Xi∗SF),<br />
(bd, PC, Xi∗SF)}.<br />
10.1.4 Dispatch Test 4: Allowable Operand Data Memory Reference<br />
The MC68060 processor design features a shared operand data cache pipeline capable of<br />
supporting a single operand reference per machine cycle. This test validates that only a single<br />
operand data memory reference is present between the instruction-pair in the pOEP and<br />
sOEP.<br />
10.1.5 Dispatch Test 5: No Register Conflicts on sOEP.AGU Resources<br />
This test validates that the register resources of the sOEP.AGU (Base, Index) do not conflict<br />
with the results being generated by the instruction in the pOEP. The most significant bit of<br />
the resource name is asserted to indicate a register resource. Thus, this test can be stated<br />
as:<br />
test5 = 1 /* set test5 as okay<br />
if (sOEP.Base > 15)/* indicates a valid register<br />
/* if the sOEP.Base equals the pOEP’s Address_ or Execute_result, a conflict exists<br />
if ((sOEP.Base = pOEP.Address_result) || (sOEP.Base = pOEP.Execute_result))<br />
test5 = 0/* test5 has register conflict; test fails<br />
10-8<br />
if (sOEP.Index > 15)/* indicates a valid register<br />
/* if the sOEP.Index equals the pOEP’s Address_ or Execute_result, a conflict exists<br />
if ((sOEP.Index = pOEP.Address_result) || (sOEP.Index = pOEP.Execute_result))<br />
test5 = 0/* test5 has register conflict; test fails<br />
As examples of failing sequences, consider the following instruction pairs:<br />
add.l #,a0Execute_result = a0<br />
mov.l (a0),d0Base = a0<br />
add.l d1,d0 Execute_result = d0<br />
lea (a1,d0.l),a0Index = d0<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
If the first instruction of each pair is contained in the pOEP and the second in the sOEP, test<br />
5 fails for both pairs. For the first example, the base resource required by the sOEP conflicts<br />
with the execute result generated by the pOEP instruction. In the second example, the index<br />
resource required by the sOEP conflicts with the execute result from the pOEP instruction.<br />
10.1.6 Dispatch Test 6: No Register Conflicts on sOEP.IEE Resources<br />
This test validates that the register resources of the sOEP.IEE (A, B) do not conflict with the<br />
execute result being generated by the instruction in the pOEP. Recall the most significant<br />
bit of the resource name is asserted to indicate a register resource. Thus, this test can be<br />
stated as:<br />
test6 = 1 /* set test6 as okay<br />
if (sOEP.A > 15) /* indicates a valid register<br />
/* if the sOEP.A equals the pOEP’s Execute_result, a conflict exists<br />
if ((sOEP.A = pOEP.Execute_result))<br />
test6 = 0/* test6 has register conflict<br />
if (sOEP.B > 15) /* indicates a valid register<br />
/* if the sOEP.B equals the pOEP’s Execute_result, a conflict exists<br />
if ((sOEP.B = pOEP.Execute_result))<br />
test6 = 0/* test6 has register conflict<br />
There are two very important exceptions to this rule involving the MOVE instruction:<br />
1. If the primary OEP instruction is a simple “move long to register” (MOVE.L,Rx) and<br />
the destination register Rx is required as either the sOEP.A or sOEP.B input, the<br />
MC68060 bypasses the data as required and the test succeeds.<br />
2. In the following sequence of instructions:<br />
.l,Dx<br />
mov.l Dx,<br />
the result of the pOEP instruction is needed as an input to the sOEP.IEE and the sOEP<br />
instruction is a move instruction. The destination operand for the memory write is sourced<br />
directly from the pOEP execute result and the test succeeds.<br />
Consider the following examples:<br />
asl.l &k,d0 Execute_result = d0<br />
add.l d0,d1 A = d0<br />
add.l ,d1 Execute_result = d1<br />
sub.l d0,d1 B = d1<br />
mov.l ,d0 Execute_result = d0<br />
add.l d0,d1 A = d0<br />
For all the examples, let the first instruction be loaded into the primary OEP and the second<br />
loaded into the secondary OEP.<br />
In the first and second examples, the result of the pOEP instruction is required as an input<br />
to the sOEP.IEE. Since the pOEP instruction is not a simple MOVE operation, the test fails<br />
in each case.<br />
In the third example, the result of the pOEP operation is needed as an input to the<br />
sOEP.IEE, but since the pOEP is executing the register-load MOVE instruction, the desti-<br />
10-9
Instruction Execution Timing<br />
nation operand can be routed to the sOEP before the actual “execution” of the pOEP instruction.<br />
The test succeeds in this example.<br />
10.2 TIMING ASSUMPTIONS<br />
For the timing data presented, the following assumptions are made:<br />
1. The data presents the execution times for individual instructions and makes no assumptions<br />
concerning the ability of the MC68060 to dispatch multiple instructions in a<br />
given machine cycle. For sequences where instruction-pairs are dispatched, the execution<br />
time of the two instructions is defined by the execution time of the instruction in<br />
the pOEP.<br />
2. The OEP is loaded with the opword and all required extension words at the beginning<br />
of each instruction execution. This implies that the OEP spends no time waiting for the<br />
instruction fetch pipeline (IFP) to supply opwords and/or extensions.<br />
3. The OEP does not experience any sequence-related pipeline stalls. The most common<br />
example of this type of stall is a “change/use” register stall. This type of stall results<br />
from a register being modified by an instruction and a subsequent instruction<br />
generating an address using the previously modified register. The second instruction<br />
must stall in the OEP until the register is actually updated by the previous instruction.<br />
For example:<br />
10-10<br />
muls.l #,d0<br />
mov.l (a0,d0.l*4),d1<br />
In this sequence, the second instruction is held for 2 clock cycles stalling for the first<br />
instruction to complete the update of the d0 register. If consecutive instructions load<br />
a register and then use that register as the base for an address calculation (An), a 2clock-cycle<br />
wait may be incurred. This represents the maximum change/use penalty<br />
for a base register. The maximum change/use penalty for an index register (Xi) is 3<br />
clock cycles (for Xi.l*2, Xi.l*8, and Xi.w). The change/use penalty for an index register<br />
if Xi.l*1 or Xi.l*4 is 2 clock cycles.<br />
Certain instructions have been optimized to ensure no change/use stall occurs on<br />
subsequent instructions. The destination register of the following instructions is available<br />
for subsequent instructions:<br />
lea<br />
mov.l&imm,Rn<br />
movq<br />
clr.lDn,<br />
any op(An)+<br />
any op–(An)<br />
as a base register for address calculation with no stall, or as an index register for<br />
address calculation with no stall, if Xi.l*{1,4}. If the index register used is Xi.l*2, Xi.l*8,<br />
or Xi.w, then the previously described 3 cycle stall occurs.<br />
The MC68060 provides another change/use optimization for a commonly encountered<br />
construct—when an address register is loaded from memory and then used in an operand<br />
address calculation, the OEP experiences a one cycle stall.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
mov.l,An<br />
<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
4. The OEP is able to complete all memory accesses without any stall conditions due to<br />
ATC or cache misses and/or operand data cache bank busy. This means all operand<br />
data memory references produce address translation cache hits, are mapped to cachable<br />
pages, and produce hits in the operand data cache. Additionally, branch instructions<br />
are assumed to produce an instruction cache hit for the target address instruction<br />
fetch.<br />
The occurrence of any cache miss will add a specific number of cycles to the base execution<br />
time of an instruction (see 10.3 Cache and atc Performance Degradation<br />
Times and 10.4 Effective Address Calculation Times).<br />
For instructions which generate external bus cycles as part of their execution (e.g.,<br />
MOVE16, CPUSH), a 2-1-1-1 memory system is assumed.<br />
5. All data accesses are assumed to be aligned on the same byte boundary as the operand<br />
size:<br />
•16-bit operands aligned on 0-modulo-2 addresses<br />
•32-bit operands aligned on 0-modulo-4 addresses<br />
•64-bit operands aligned on 0-modulo-8 addresses<br />
•96-bit operands aligned on 0-modulo-4 addresses<br />
If the operand alignment fails these suggested guidelines, the reference is termed a<br />
misaligned access. The processor is required to make multiple accesses to obtain any<br />
misaligned operand. For copyback or writethrough pages, one processor clock cycle<br />
must be added to the instruction execution time for a misaligned read reference. Two<br />
clock cycles must be added for a misaligned write or read-modify-write.<br />
6. Certain instructions perform a pipeline synchronization prior to their actual execution.<br />
For these opcodes, the instruction enters the pOEP and then waits until the following<br />
conditions are met:<br />
•The instruction cache is in a quiescent state with all outstanding cache misses<br />
completed.<br />
•The data cache is in a quiescent state with all outstanding cache misses completed.<br />
•The push and write buffers are empty.<br />
•The execution of all previous instructions has completed.<br />
Once all these conditions are satisfied, the instruction begins its actual execution.<br />
For the instruction timings listed in the timing data, the following assumptions are made<br />
for these pipeline synchronization instructions:<br />
•The instruction cache is not processing any cache misses.<br />
•The data cache is not processing any cache misses.<br />
•The push and write buffers are empty.<br />
•The OEP has dispatched an instruction or instruction-pair on the previous cycle.<br />
10-11
Instruction Execution Timing<br />
10-12<br />
The following instructions perform this pipeline synchronization:<br />
andi_to_sr<br />
bkpt<br />
cas<br />
cinv<br />
cpush<br />
eori_to_sr<br />
halt<br />
lpstop<br />
move_to_sr<br />
movec<br />
nop<br />
ori_to_sr<br />
pflush<br />
plpa<br />
reset<br />
rte<br />
stop<br />
tas<br />
7. Certain instructions have a variable execution time based on input operands, cache<br />
state, etc. For these instructions, the execution time listed represents the maximum<br />
value. These times are listed as:
10.3.2 Data ATC Miss<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Instruction Execution Timing<br />
Assumptions:<br />
• A single, “C-index” level, normal table search (the only U-bit or M-bit update possible is<br />
for the page descriptor itself).<br />
• Given a memory response time of “w-x-y-z” to the bus interface of the MC68060.<br />
Data ATC Miss = 8+3*w(3/0), if U-bit and M-bit of descriptor are in the proper state.<br />
Data ATC Miss = 14+4*w(3/1), if M-bit only, or U-bit and M-bit of descriptor must be set by<br />
the MC68060.<br />
Data ATC Miss = 16+5*w(4/1), if U-bit only of descriptor must be set by the MC68060.<br />
10.3.3 Instruction Cache Miss<br />
Assumptions:<br />
• The following degradation time assumes the MC68060 instruction buffer is empty and<br />
the instruction cache miss memory access time is fully exposed. This is an estimated<br />
degradation using a conservative assumption.<br />
Note that the MC68060 instruction fetch pipeline prefetches continually, loading instructions<br />
into the instruction buffer, which decouples the instruction fetch pipeline from the<br />
operand execution pipeline. As a result, instruction cache miss memory access times<br />
for most operations will be partially or completely hidden by the instruction buffer, contributing<br />
minimal degradation to actual execution time.<br />
• The following degradation estimate assumes an instruction fetch flow of sequential operations,<br />
the cache miss line is entered sequentially and contains no branches/jumps.<br />
• Given a memory response time of “w-x-y-z” to the bus interface of the MC68060.<br />
Instruction Cache Miss (Line Fill) = w+x+y+z<br />
10.3.4 Data Cache Miss<br />
Assumptions:<br />
• Given a memory response time of “w-x-y-z” to the bus interface of the MC68060.<br />
If copyback mode:<br />
Data Cache Miss (Line Fill) = 2+w {+, if during x+y+z a memory data operand reference is<br />
made by a subsequent instruction, an operand execution pipeline stall will take place until<br />
the entire line is written into the data cache during x+y+z}<br />
If noncachable mode (operand read):<br />
Data Cache Miss = 2+w<br />
If noncacheable mode (operand write) and precise mode or write buffer disabled:<br />
Data Cache Miss = 3+w<br />
10-13
Instruction Execution Timing<br />
10.4 EFFECTIVE ADDRESS CALCULATION TIMES<br />
Table 10-5 shows the number of clock cycles required to compute an instruction’s effective<br />
address. The MC68060 address generation hardware supports the calculation of most<br />
effective addresses within the structure of the operand execution pipeline with no additional<br />
cycles required. The number of operand read and write cycles is shown in parentheses (r/w).<br />
The following rules apply to any effective address calculation:<br />
• The size of the index register (Xi) and the scale factor (SF) do not affect the calculation<br />
time for the indexed addressing modes.<br />
• The size of the absolute address (short, long) does not affect its calculation time. In subsequent<br />
tables, the nomenclature “(xxx).WL” is used to denote either the absolute short<br />
{(xxx).W} or absolute long {(xxx).L} addressing modes.<br />
In general, the use of a memory indirect effective address adds three cycles to the instruction<br />
execution times (one cycle to process full format effective address and two cycles to<br />
fetch the memory indirect pointer). For instructions which calculate both a source and destination<br />
address (e.g., memory-to-memory moves), two effective address calculations are<br />
performed, one for the source and another for the destination.<br />
10.5 MOVE INSTRUCTION EXECUTION TIMES<br />
Table 10-6 and Table 10-7 show the number of clock cycles for execution of the MOVE<br />
instruction. The number of operand read and write cycles is shown in parentheses (r/<br />
w).Note, if memory indirect addressing is used for a MOVE instruction, add 2(1/0) cycles for<br />
10-14<br />
Table 10-5. Effective Address Calculation Times<br />
Addressing Mode<br />
Calculation<br />
Time<br />
Dn Data Register Direct 0(0/0)<br />
An Address Register Direct 0(0/0)<br />
(An) Address Register Indirect 0(0/0)<br />
(An)+ Address Register Indirect with Postincrement 0(0/0)<br />
–(An) Address Register Indirect with Predecrement 0(0/0)<br />
(d16,An) Address Register Indirect with Displacement 0(0/0)<br />
(d8,An,Xi∗SF)<br />
Address Register Indirect with Index and Byte Displacement 0(0/0)<br />
(bd,An,Xi∗SF)<br />
Address Register Indirect with Index and Base (16-, 32-bit) Displacement 1(0/0)<br />
([bd,An,Xn],od<br />
)<br />
Memory Indirect Preindexed Mode 3(1/0)<br />
([bd,An],Xn,od<br />
)<br />
Memory Indirect Postindexed Mode 3(1/0)<br />
(xxx).W Absolute Short 0(0/0)<br />
(xxx).L Absolute Long 0(0/0)<br />
(d16,PC) Program Counter with Displacement 0(0/0)<br />
(d8,PC,Xi∗SF)<br />
Program Counter with Index and Byte Displacement 0(0/0)<br />
(bd,PC,Xi∗SF) Program Counter with Index and Base (16-, 32-bit) Displacement 1(0/0)<br />
# Immediate 0(0/0)<br />
([bd,PC,Xn],o<br />
d)<br />
Program Counter Memory Indirect Preindexed Mode 3(1/0)<br />
([bd,PC],Xn,o<br />
d)<br />
Program Counter Memory Indirect Postindexed Mode 3(1/0)<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
Instruction Execution Timing<br />
each memory indirect address to the numbers in Table 10-6 and Table 10-7.The execution<br />
times for the MOVE16 instruction are shown in Table 10-8.<br />
Table 10-6. Move Byte and Word Execution Times<br />
Source<br />
Dn An (An) (An)+ –(An)<br />
Destination<br />
(d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF) (xxx).WL<br />
Dn 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
An 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
(An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(An)+ 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
–(An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d16,An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d8,An,Xi∗SF) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(bd,An,Xi∗SF) 2(1/0) 2(1/0) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 4(1/1) 3(1/1)<br />
(xxx).W 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(xxx).L 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d16,PC) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d8,PC,Xi∗SF) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(bd,PC,Xi∗SF) 2(1/0) 2(1/0) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 4(1/1) 3(1/1)<br />
# 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 2(0/1) 3(0/1) 2(0/1)<br />
Table 10-7. Move Long Execution Times<br />
Source<br />
Dn An (An) (An)+ –(An)<br />
Destination<br />
(d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF) (xxx).WL<br />
Dn 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
An 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
(An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(An)+ 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
–(An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d16,An) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d8,An,Xi∗SF) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(bd,An,Xi∗SF) 2(1/0) 2(1/0) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 4(1/1) 3(1/1)<br />
(xxx).W 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(xxx).L 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d16,PC) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(d8,PC,Xi∗SF) 1(1/0) 1(1/0) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
(bd,PC,Xi∗SF) 2(1/0) 2(1/0) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 3(1/1) 4(1/1) 3(1/1)<br />
# 1(0/0) 1(0/0) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 2(0/1) 3(0/1) 2(0/1)<br />
Table 10-8. MOVE16 Execution Times<br />
Source<br />
(Ax)<br />
Destination<br />
(Ax)+ (xxx).L<br />
(Ay) — — 18(1/1) 1<br />
(Ay)+ — 18(1/1) 1 18(1/1) 1<br />
(xxx).L 18(1/1) 1<br />
18(1/1) 1 —<br />
1 These execution times assume cache misses for both read and write MOVE16<br />
accesses. Execution times are 11(1/1) if the read access hits in the operand data<br />
cache. Note, for this instruction the operand read/write refers to a line-sized transfer.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 10-15
Instruction Execution Timing<br />
10.6 STANDARD INSTRUCTION EXECUTION TIMES<br />
Table 10-9 shows the number of clock cycles required for execution of the standard instructions,<br />
including completion of the operation and storing of the result. The number of operand<br />
read and write cycles is shown in parentheses (r/w). In this table, denotes any effective<br />
address and denotes a memory operand. For all instructions in Table 10-9, the clock<br />
cycles and r/w cycles for the effective address calculation (Table 10-5) must be added to the<br />
values listed.<br />
Table 10-9. Standard Instruction Execution Time<br />
Instruction Size op ,An<br />
1<br />
For entries in this column, add one cycle if the is (Ay)+, –(Ay) and Ay = An<br />
2<br />
Word divides have conditional exit points.<br />
3<br />
Add one cycle to the effective address calculation time for all addressing modes except Rn, (An), (An)+, –(An),<br />
(d16,An), and (d16,PC)<br />
1<br />
op ,Dn op Dn,<br />
ADD Byte, Word 1(1/0) 1(1/0) 1(1/1)<br />
“ Long 1(1/0) 1(1/0) 1(1/1)<br />
AND Byte, Word —— 1(1/0) 1(1/1)<br />
“ Long — 1(1/0) 1(1/1)<br />
CMP Byte, Word 1(1/0) 1(1/0) —<br />
“ Long 1(1/0) 1(1/0) —<br />
DIVS Word —
10.7 IMMEDIATE INSTRUCTION EXECUTION TIMES<br />
Instruction Execution Timing<br />
Table 10-10 shows the number of clock cycles required for execution of the immediate<br />
instructions, including completion of the operation and storing of the result. The number of<br />
operand read and write cycles is shown in parentheses (r/w).<br />
Table 10-10. Immediate Instruction Execution Times<br />
Destination<br />
Instruction Size<br />
Dn An (An)<br />
(An)<br />
+<br />
–(An) (d16,An) (d8,An,Xi*SF) (bd,An,Xi*SF)<br />
1 Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
1 (xxx).WL<br />
ADDI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
ADDQ Byte, Word<br />
1(0/<br />
0)<br />
1(0/<br />
0)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/1) 1(1/1) 2(1/1) 1(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
1(0/<br />
0)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/1) 1(1/1) 2(1/1) 1(1/1)<br />
ANDI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
CMPI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
0)<br />
1(1/<br />
0)<br />
1(1/<br />
0)<br />
2(1/0) 2(1/0) 3(1/0) 2(1/0)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
0)<br />
1(1/<br />
0)<br />
1(1/<br />
0)<br />
2(1/0) 2(1/0) 3(1/0) 2(1/0)<br />
EORI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
MOVEQ Long<br />
1(0/<br />
0)<br />
— — — — — — — —<br />
ORI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
SUBI Byte, Word<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
—<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
SUBQ Byte, Word<br />
1(0/<br />
0)<br />
1(0/<br />
0)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/1) 1(1/1) 2(1/1) 1(1/1)<br />
“ Long<br />
1(0/<br />
0)<br />
1(0/<br />
0)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/<br />
1)<br />
1(1/1) 1(1/1) 2(1/1) 1(1/1)<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 10-17
Instruction Execution Timing<br />
10.8 SINGLE-OPERAND INSTRUCTION EXECUTION TIMES<br />
Table 10-11 shows the number of clock cycles required for execution of the single-operand<br />
instructions. The number of operand reads and write cycles is shown in parentheses (r/w).<br />
Where indicated, the number of clock cycles and r/w cycles must be added to those required<br />
for effective address calculation.<br />
Table 10-11. Single-Operand Instruction Execution Times<br />
Instruction Size Register Memory<br />
CAS Byte, Word1 — 19(1/1)<br />
“ Long1 — 19(1/1)<br />
NBCD Byte 1(0/0) 1(1/1) 2<br />
NEG Byte, Word 1(0/0) 1(1/1) 2<br />
“ Long 1(0/0) 1(1/1) 2<br />
NEGX Byte, Word 1(0/0) 1(1/1) 2<br />
“ Long 1(0/0) 1(1/1) 2<br />
NOT Byte, Word 1(0/0) 1(1/1) 2<br />
“ Long 1(0/0) 1(1/1) 2<br />
Scc Byte -> False 1(0/0) 1(1/1) 2<br />
“ Byte -> True 1(0/0) 1(1/1) 2<br />
TAS Byte 1(0/0) 17(1/1) 2<br />
TST Byte, Word 1(0/0) 1(1/0) 2<br />
“ Long 1(0/0) 1(1/0) 2<br />
1 Add (1 + effective address calculation time) cycles for all addressing modes<br />
except Rn, (An), (An)+, –(An), and (d16,An).<br />
2 Add the effective address calculation time to these instructions.<br />
Execution times for the CLR instruction are given in Table 10-12. The number of operand<br />
reads and writes is shown in parentheses (r/w).<br />
Table 10-12. Clear (CLR) Execution Times<br />
Size Dn<br />
A<br />
n<br />
(An) (An)+ –(An) (d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF)<br />
1 Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
1 (xxx).WL<br />
Byte, Word 1(0/0) — 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
Long 1(0/0) — 1(0/1) 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 1(0/1)<br />
10-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
10.9 SHIFT/ROTATE EXECUTION TIMES<br />
Instruction Execution Timing<br />
Table 10-13 indicates the number of clock cycles required for execution of the shift and<br />
rotate instructions. The number of operand read and write cycles is shown in parentheses<br />
(r/w). Where indicated, the number of clock cycles and r/w cycles must be added to those<br />
required for effective address calculation.<br />
Table 10-13. Shift/Rotate Execution Times<br />
Instruction Size Register Memory<br />
1<br />
For entries in this column, add the effective address calculation time. These operations<br />
are word-size only.<br />
1<br />
ASL, ASR Byte, Word 1(0/0) 1(1/1)<br />
“ Long 1(0/0) —<br />
LSL, LSR Byte, Word 1(0/0) 1(1/1)<br />
“ Long 1(0/0) —<br />
ROL, ROR Byte, Word 1(0/0) 1(1/1)<br />
“ Long 1(0/0) —<br />
ROXL, ROXR Byte, Word 1(0/0) 1(1/1)<br />
“ Long 1(0/0) —<br />
10.10 BIT MANIPULATION AND BIT FIELD EXECUTION TIMES<br />
Table 10-14 and Table 10-15 indicate the number of clock cycles required for execution of<br />
the bit manipulation instructions. The execution times for the bit field instructions is shown<br />
in Table 10-16. The number of operand read and write cycles is shown in parentheses (r/w).<br />
Where indicated, the number of clock cycles and r/w cycles must be added to those required<br />
for effective address calculation.<br />
Table 10-14. Bit Manipulation (Dynamic Bit Count)<br />
Execution Times<br />
Instruction Size Register Memory<br />
1 For entries in this column, add the effective address calculation<br />
time.<br />
1<br />
BCHG Byte — 1(1/1)<br />
“ Long 1(0/0) —<br />
BCLR Byte — 1(1/1)<br />
“ Long 1(0/0) —<br />
BSET Byte — 1(1/1)<br />
“ Long 1(0/0) —<br />
BTST Byte — 1(1/0)<br />
“ Long 1(0/0) —<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 10-19
Instruction Execution Timing<br />
Table 10-15. Bit Manipulation (Static Bit Count) Execution Times<br />
Destination<br />
Instruction Size<br />
Dn<br />
A<br />
n<br />
(An) (An)+ –(An) (d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF) 1<br />
(xxx).WL<br />
BCHG Byte — — 1(1/1) 1(1/1) 1(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long 1(0/0) — — — — — — — —<br />
BCLR Byte — — 1(1/1) 1(1/1) 1(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ 1(0/0) — — — — — — — —<br />
BSET Byte — — 1(1/1) 1(1/1) 1(1/1) 2(1/1) 2(1/1) 3(1/1) 2(1/1)<br />
“ Long 1(0/0) — — — — — — — —<br />
BTST Byte — — 1(1/0) 1(1/0) 1(1/0) 2(1/0) 2(1/0) 3(1/0) 2(1/0)<br />
“ Long 1(0/0) — — — — — — — —<br />
1 Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
Table 10-16. Bit Field Execution Times 1<br />
Instruction<br />
Dn An (An) (An)+ –(An)<br />
Destination<br />
(d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF)<br />
1 The type of offset and width (static, dynamic) does not affect the execution time.<br />
2 Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
2<br />
(xxx).WL<br />
BFCHG (< 5 Bytes) 8(0/0) — 8(2/1) — — 8(2/1) 9(2/1) 10(2/1) 9(2/1)<br />
BFCHG(= 5 Bytes) 12(0/0) — 12(4/2) — — 12(4/2) 13(4/2) 14(4/2) 13(4/2)<br />
BFCLR (< 5 Bytes) 8(0/0) — 8(2/1) — — 8(2/1) 9(2/1) 10(2/1) 9(2/1)<br />
BFCLR(= 5 Bytes) 12(0/0) — 12(4/2) — — 12(4/2) 13(4/2) 14(4/2) 13(4/2)<br />
BFEXTS(< 5 Bytes) 6(0/0) — 6(1/0) — — 6(1/0) 7(1/0) 8(1/0) 7(1/0)<br />
BFEXTS(= 5 Bytes) 8(0/0) — 8(2/0) — — 8(2/0) 9(2/0) 10(2/0) 9(2/0)<br />
BFEXTU(< 5 Bytes) 6(0/0) — 6(1/0) — — 6(1/0) 7(1/0) 8(1/0) 7(1/0)<br />
BFEXTU(= 5 Bytes) 8(0/0) — 8(2/0) — — 8(2/0) 9(2/0) 10(2/0) 9(2/0)<br />
BFFFO(< 5 Bytes) 9(0/0) — 9(1/0) — — 9(1/0) 10(1/0) 11(1/0) 10(1/0)<br />
BFFFO(= 5 Bytes) 11(0/0) — 11(2/0) — — 11(2/0) 12(2/0) 13(2/0) 12(2/0)<br />
BFINS (< 5 Bytes) 6(0/0) — 6(1/1) — — 6(1/1) 7(1/1) 8(1/1) 7(1/1)<br />
BFINS(= 5 Bytes) 6(0/0) — 6(2/2) — — 6(2/2) 7(2/2) 8(2/2) 7(2/2)<br />
BFSET(< 5 Bytes) 8(0/0) — 8(2/1) — — 8(2/1) 9(2/1) 10(2/1) 9(2/1)<br />
BFSET(= 5 Bytes) 12(0/0) — 12(4/2) — — 12(4/2) 13(4/2) 14(4/2) 13(4/2)<br />
BFTST (< 5 Bytes) 6(0/0) — 6(1/0) — — 6(1/0) 7(1/0) 8(1/0) 7(1/0)<br />
BFTST(= 5 Bytes) 8(0/0) — 8(2/0) — — 8(2/0) 9(2/0) 10(2/0) 9(2/0)<br />
10-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
10.11 BRANCH INSTRUCTION EXECUTION TIMES<br />
Instruction Execution Timing<br />
Table 10-17, Table 10-18, and Table 10-19 indicate the number of clock cycles required for<br />
execution of the branch, jump, and return instructions. The number of operand read and<br />
write cycles is shown in parentheses (r/w). Where indicated, the number of clock cycles and<br />
r/w cycles must be added to those required for effective address calculation.<br />
Instruction<br />
Not<br />
Predicted,<br />
Forward,<br />
Taken<br />
Table 10-17. Branch Execution Times<br />
Not<br />
Predicted,<br />
Forward,<br />
Not Taken<br />
Not<br />
Predicted,<br />
Backward,<br />
Taken<br />
Not<br />
Predicted,<br />
Backward,<br />
Not Taken<br />
Predicted<br />
Correctly as<br />
Taken<br />
Predicted<br />
Correctly as<br />
Not Taken<br />
Predicted<br />
Incorrectly<br />
Bcc 7(0/0) 1(0/0) 3(0/0) 7(0/0) 0(0/0) 1(0/0) 7(0/0)<br />
BRA 3(0/0) — 3(0/0) — 0(0/0) — —<br />
BSR 3(0/1) — 3(0/1) — 1(0/1) — —<br />
DBcc 3(0/0) 8(0/0) 3(0/0) 8(0/0) 2(0/0) 2(0/0) 8(0/0)<br />
DBRA 3(0/0) 7(0/0) 3(0/0) 7(0/0) 1(0/0) 1(0/0) 7(0/0)<br />
FBcc 8(0/0) 2(0/0) 8(0/0) 2(0/0) 2(0/0) 2(0/0) 8(0/0)<br />
Table 10-18. JMP, JSR Execution Times 1<br />
Instruction<br />
Not<br />
Predicted,<br />
Forward,<br />
Taken<br />
Not<br />
Predicted,<br />
Forward,<br />
Not Taken<br />
Not<br />
Predicted,<br />
Backward,<br />
Taken<br />
Not<br />
Predicted,<br />
Backward,<br />
Not Taken<br />
Predicted<br />
Correctly as<br />
Taken<br />
Predicted<br />
Correctly as<br />
Not Taken<br />
Predicted<br />
Incorrectly<br />
JMP (d16,PC) 3(0/0) — 3(0/0) —— 0(0/0) — —<br />
JMP xxx.WL 3(0/0) — 3(0/0) — 0(0/0) — —<br />
Remaining JMP 5(0/0) — 5(0/0) — 5(0/0) — —<br />
JSR (d16,PC) 3(0/1) — 3(0/1) — 1(0/1) — —<br />
JSR xxx.WL 3(0/1) — 3(0/1) — 1(0/1) — —<br />
Remaining JSR 5(0/1) — 5(0/1) — 5(0/1) — —<br />
1 Add the effective address calculation time for each entry.<br />
Table 10-19. Return Instruction Execution Times<br />
Instruction Execution Time<br />
RTD 7(1/0)<br />
RTE 17(3/0)<br />
RTR 8(2/0)<br />
RTS 7(1/0)<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 10-21
Instruction Execution Timing<br />
10.12 LEA, PEA, AND MOVEM EXECUTION TIMES<br />
Table 10-20 indicates the number of clock cycles required for execution of the LEA, PEA,<br />
and MOVEM instructions. The number of operand read and write cycles is shown in parentheses<br />
(r/w).<br />
Table 10-20. LEA, PEA, and MOVEM Instruction Execution Times<br />
Instruction (An)<br />
(An)<br />
+<br />
–<br />
(An)<br />
(d16,An)<br />
(d8,An,<br />
Xi∗SF)<br />
(bd,An,<br />
Xi∗SF) 1 (xxx).WL (d16,PC)<br />
(d8,PC,<br />
Xi∗SF)<br />
(bd,PC,<br />
Xi∗SF) 1<br />
LEA 1(0/0) - - 1(0/0) 1(0/0) 2(0/0) 1(0/0) 1(0/0) 1(0/0) 2(0/0)<br />
PEA 1(0/1) - - 2(0/1) 2(0/1) 3(0/1) 1(0/1) 1(0/1) 2(0/1) 2(0/1)<br />
MOVEM Mem->Reg<br />
n 2 (n/<br />
0)<br />
n(n/<br />
0)<br />
- n(n/0) 1+n(n/0) 2+n(n/0) 1+n(n/0) n(n/0) 1+n(n/0) 2+n(n/0)<br />
MOVEM Reg->Mem n(0/n) —<br />
1<br />
Add 2(1/0) cycles to the (bd,{An,PC},Xi*SF) time for a memory indirect address.<br />
2<br />
“n” is the number of registers being moved.<br />
n(0/<br />
n)<br />
n(0/n) 1+n(0/n) 2+n(0/n) 1+n(0/n) — — —<br />
10.13 MULTIPRECISION INSTRUCTION EXECUTION TIMES<br />
Table 10-21 indicates the number of clock cycles for execution of the multiprecision instructions.<br />
The number of clock cycles includes the time to fetch both operands, perform the<br />
operations, and store the results. The number of read and write cycles is shown in parentheses<br />
(r/w).<br />
Table 10-21. Multiprecision Instruction Execution Times<br />
Instruction Size op Dy,Dx<br />
op<br />
y,x<br />
1<br />
Where y,x is (Ay)+,(Ax)+ for CMPM and –(Ay),–(Ax) for all<br />
other instructions.<br />
1<br />
ADDX Byte, Word 1(0/0) 2(2/1)<br />
“ Long 1(0/0) 2(2/1)<br />
CMPM Byte, Word — 2(2/0)<br />
“ Long — 2(2/0)<br />
SUBX Byte, Word 1(0/0) 2(2/1)<br />
“ Long 1(0/0) 2(2/1)<br />
ABCD Byte 1(0/0) 2(2/1)<br />
SBCD Byte 1(0/0) 2(2/1)<br />
10.14 STATUS REGISTER, MOVES, AND MISCELLANEOUS<br />
INSTRUCTION EXECUTION TIMES<br />
Table 10-22, Table 10-23, and Table 10-24 indicate the number of clock cycles required for<br />
execution of the status register, MOVES, and miscellaneous instructions. The number of<br />
operand read and write cycles is shown in parentheses (r/w). Where indicated, the number<br />
of clock cycles and r/w cycles must be added to those required for effective address calculation.<br />
10-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
1 For these instructions, add the effective address calculation time.<br />
1 Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
Instruction Execution Timing<br />
Table 10-22. Status Register (SR) Instruction Execution Times<br />
Instruction Execution Time<br />
ANDI to SR 12(0/0)<br />
EORI to SR 12(0/0)<br />
MOVE from SR 1(0/1) 1<br />
MOVE to SR 12(1/0) 1<br />
ORI to SR 5(0/0)<br />
Table 10-23. MOVES Execution Times<br />
MOVES Function<br />
Size (An) (An)+ –(An)<br />
Destination<br />
(d16,An) (d8,An,Xi∗SF) (bd,An,Xi∗SF) 1<br />
(xxx).WL<br />
Source -> Rn Byte, Word 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0)<br />
“ Long 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0)<br />
Rn -> Dest Byte, Word 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 3(0/1) 2(0/1)<br />
“ Long 1(0/1) 1(0/1) 1(0/1) 1(0/1) 2(0/1) 3(0/1) 2(0/1)<br />
Table 10-24. Miscellaneous Instruction Execution Times<br />
Instruction Size Register Memory Reg -> Dest Source -> Reg<br />
ANDI to CCR Byte 1(0/0) — — —<br />
CHK Word 2(0/0) 2(1/0) 1 — —<br />
“ Long 2(0/0) 2(1/0) 1 — —<br />
CINVA — —
Instruction Execution Timing<br />
Instruction Size Register Memory Reg -> Dest Source -> Reg<br />
PLPA (ATC hit) — 15(0/0) — — —<br />
PLPA (ATC miss) — 28(0/0) — — —<br />
PFLUSH — 18(0/0) — — —<br />
PFLUSHN — 18(0/0) — — —<br />
PFLUSHAN — 33(0/0) — — —<br />
PFLUSHA — 33(0/0) — — —<br />
RESET — 520(0/0) — — —<br />
STOP Word 8(0/0) — — —<br />
SWAP Word 1(0/0) — — —<br />
TRAPF — 1(0/0) — — —<br />
TRAPcc — 1(0/0) — — —<br />
TRAPV — 1(0/0) — — —<br />
UNLK — 1(1/0) — — —<br />
UNPK — 2(0/0) 2(1/1) — —<br />
1 For these entries, add the effective address calculation time.<br />
2<br />
For the CPUSH instruction, the operand write figure refers to line-sized transfers.<br />
10.15 FPU INSTRUCTION EXECUTION TIMES<br />
Table 10-25 shows the number of clock cycles required for execution of the floating-point<br />
instructions, including completion of the operation and storing of the result. The number of<br />
operand read and write cycles is shown in parentheses (r/w).<br />
Instruction<br />
Table 10-24. Miscellaneous Instruction Execution Times (Continued)<br />
Table 10-25. Floating-Point Instruction Execution Times<br />
FPn Dn (An) (An)+ –(An)<br />
Effective Address, <br />
(d16,An)<br />
(d16,PC)<br />
(d8,An,Xi∗SF)<br />
(d8,PC,Xi∗SF)<br />
(bd,An,XI∗SF)<br />
(bd,PC,XI∗SF)<br />
(xxx).WL #<br />
FABS 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FDABS 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FSABS 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FADD 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FDADD 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FSADD 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FCMP 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FDIV 37(0/0) 39(0/0) 37(1/0) 37(1/0) 37(1/0) 37(1/0) 38(1/0) 39(1/0) 38(1/0) 38(0/0)<br />
FDDIV 37(0/0) 39(0/0) 37(1/0) 37(1/0) 37(1/0) 37(1/0) 38(1/0) 39(1/0) 38(1/0) 38(0/0)<br />
FSDIV 37(0/0) 39(0/0) 37(1/0) 37(1/0) 37(1/0) 37(1/0) 38(1/0) 39(1/0) 38(1/0) 38(0/0)<br />
FMOVE<br />
,FPx<br />
1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 1(0/0)<br />
FDMOVE<br />
,FPx<br />
1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 1(0/0)<br />
FSMOVE<br />
,FPx<br />
1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 1(0/0)<br />
FMOVE<br />
FPy,<br />
— 3(0/0) 1(0/1) 1(0/1) 1(0/1) 1(1/0) 2(0/1) 3(0/1) 2(0/1) —<br />
FMOVE<br />
,FPCR<br />
— 8(0/0) 6(1/0) 6(1/0) 6(1/0) 6(1/0) 7(1/0) 8(1/0) 7(1/0) 7(0/0)<br />
FMOVE<br />
FPCR,<br />
— 4(0/0) 2(0/1) 2(0/1) 2(0/1) 2(1/0) 3(0/1) 4(0/1) 3(0/1) —<br />
FINT 3(0/0) 4(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 5(1/0) 3(1/0) 3(0/0)<br />
FINTRZ 3(0/0) 4(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 5(1/0) 3(1/0) 3(0/0)<br />
10-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Instruction<br />
Instruction Execution Timing<br />
FSGLDIV 37(0/0) 39(0/0) 37(1/0) 37(1/0) 37(1/0) 37(1/0) 38(1/0) 39(1/0) 38(1/0) 38(0/0)<br />
FSGLMUL 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FMOVEM<br />
,FPx *<br />
FMOVEM<br />
FPy, *<br />
Table 10-25. Floating-Point Instruction Execution Times (Continued)<br />
FPn Dn (An) (An)+ –(An)<br />
— —<br />
— —<br />
1+3n<br />
(3n/0)<br />
1+3n<br />
(0/3n)<br />
1+3n<br />
(3n/0)<br />
—<br />
— 1+3n(3n/0) 2+3n(3n/0) 3+3n(3n/0)<br />
1+3n<br />
(0/3n)<br />
Effective Address, <br />
(d16,An)<br />
(d16,PC)<br />
(d8,An,Xi∗SF)<br />
(d8,PC,Xi∗SF)<br />
(bd,An,XI∗SF)<br />
(bd,PC,XI∗SF)<br />
1+3n(0/3n) 2+3n(0/3n) 3+3n(0/3n)<br />
(xxx).WL #<br />
2+3n(3n/<br />
0)<br />
2+3n(0/<br />
3n)<br />
FMUL 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FDMUL 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FSMUL 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 4(0/0)<br />
FNEG 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FDNEG 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FSNEG 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 2(0/0)<br />
FSUB 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 3(0/0)<br />
FDSUB 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 3(0/0)<br />
FSSUB 3(0/0) 5(0/0) 3(1/0) 3(1/0) 3(1/0) 3(1/0) 4(1/0) 5(1/0) 4(1/0) 3(0/0)<br />
FTST 1(0/0) 3(0/0) 1(1/0) 1(1/0) 1(1/0) 1(1/0) 2(1/0) 3(1/0) 2(1/0) 1(0/0)<br />
FSQRT 68(0/0) 70(0/0) 68(1/0) 68(1/0) 68(1/0) 68(1/0) 69(1/0) 70(1/0) 69(1/0) 69(0/0)<br />
FSSQRT 68(0/0) 70(0/0) 68(1/0) 68(1/0) 68(1/0) 68(1/0) 69(1/0) 70(1/0) 69(1/0) 69(0/0)<br />
FDSQRT 68(0/0) 70(0/0) 68(1/0) 68(1/0) 68(1/0) 68(1/0) 69(1/0) 70(1/0) 69(1/0) 69(0/0)<br />
FSAVE — — 3(0/3) — — — — — — —<br />
FRE-<br />
STORE<br />
— — 6(3/0) — — — — — — —<br />
FMOVEM<br />
,FPxR<br />
— — 7(n/0) — — — — — — —<br />
FMOVEM<br />
FPxR,<br />
— — 5(0/n) — — — — — — —<br />
NOTES:<br />
“n” is the number of registers being moved.<br />
For all FPU operations, if the external operand format is byte, word, or long, add three cycles to the execution time.<br />
*For all FPU operations except FMOVEM, if the external operand format is extended precision, add two cycles to the<br />
execution time.<br />
Add 2(1/0) cycles to the (bd,An,Xi*SF) time for a memory indirect address.<br />
Add 1(0/0) cycle if the specifies a double precision immediate operand.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 10-25<br />
—<br />
—
Instruction Execution Timing<br />
10.16 EXCEPTION PROCESSING TIMES<br />
Table 10-26 indicates the number of clock cycles required for exception processing. The<br />
number of clock cycles includes the time spent in the OEP by the instruction causing the<br />
exception, the stacking of the exception frame, the vector fetch, and the fetch of the first<br />
instruction of the exception handler routine. The number of operand read and write cycles<br />
is shown in parentheses (r/w).<br />
Table 10-26. Exception Processing Times<br />
Exception Execution Time<br />
CPU Reset 45(2/0)<br />
1 Indicates the time from when RSTI is negated until the first<br />
instruction enters the OEP.<br />
2 For these entries, add the effective address calculation time.<br />
3 Assumes either autovector or external vector supplied with zero<br />
wait states.<br />
4 For these entries, add the instruction execution time minus 1 if a<br />
post-exception fault occurs.<br />
1<br />
Bus Error 19(1/4)<br />
Address Error 19(1/3)<br />
Illegal Instruction 19(1/2)<br />
Integer Divide By Zero 20(1/3) 2<br />
CHK Instruction 20(1/3) 2<br />
TRAPV, TRAPcc Instructions 19(1/3)<br />
Privilege Violation 19(1/2)<br />
Trace 19(1/3)<br />
Line A Emulator 19(1/2)<br />
Line F Emulator 19(1/2)<br />
Unimplemented EA 19(1/2)<br />
Unimplemented Integer 19(1/2)<br />
Format Error 23(1/2)<br />
Nonsupported FP 19(1/3)<br />
Interrupt3 23(1/2)<br />
TRAP Instructions 19(1/2)<br />
FP Branch on Unordered Condition 21(1/3)<br />
FP Inexact Result 19(1/3) 4<br />
FP Divide By Zero 19(1/3) 4<br />
FP Underflow 19(1/3) 4<br />
FP Operand Error 19(1/3) 4<br />
FP Overflow 19(1/3) 4<br />
FP Signaling NAN 19(1/3) 4<br />
FP Unimplemented Data Type 19(1/3)<br />
10-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
SECTION 11<br />
APPLICATIONS INFORMATION<br />
This section describes various applications topics relating to the MC68060.<br />
11.1 GUIDELINES FOR PORTING SOFTWARE TO THE MC68060<br />
The following paragraphs describe the issues involved in using the MC68060 in an existing<br />
MC68040 system from a software perspective. Although this section focuses on the<br />
MC68060, many of these items apply also to the MC68EC060 and MC68LC060.<br />
11.1.1 User Code<br />
The MC68060 is 100% user-mode compatible with the MC68040 when utilized with the<br />
MC68060 software package (<strong>M68060</strong>SP) provided by Motorola. The <strong>M68060</strong>SP is available<br />
free of charge. Appendix C MC68060 Software Package discusses the procedure for porting<br />
the <strong>M68060</strong>SP.<br />
All user-mode instructions are handled in the <strong>M68060</strong>SP, except the “TRAPF #immediate”<br />
instruction, in which the immediate value is a valid branch opcode. Use of this construct<br />
results in a branch prediction error and an access error exception is taken. This exception<br />
is indicated by the BPE bit in the fault status long word (FSLW). Although this error is recoverable<br />
in the access error handler by flushing the branch cache, performance is compromised.<br />
In addition, the CAS (misaligned operands) and CAS2 emulation may need special handling<br />
in the access error handler. Furthermore, CAS and CAS2 emulation must not be interrupted<br />
by level 7 interrupts to prevent data corruption. Refer to Appendix C MC68060 Software<br />
Package for additional information.<br />
11.1.2 Supervisor Code<br />
Unlike the MC68040, the MC68060 implements a single supervisor stack. System software<br />
that requires the use of two supervisor stacks can still do so, but with some software overhead.<br />
The MC68060 aids in distinguishing between an interrupt exception and a non-interrupt<br />
exception by implementing the M-bit in the status register (SR). The MC68060 does not<br />
internally use the M-bit, but it is provided for system software. The MC68060 clears the Mbit<br />
of the SR when an interrupt exception is taken. Otherwise, it is up to the system software<br />
to set the M-bit and to examine it as needed. Also note, when the MC68060 takes an exception,<br />
a minimum of one instruction is always processed before a pending interrupt is taken.<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
11-1
Applications Information<br />
System software can take advantage of the conditions described above to emulate an<br />
MC68040-like interrupt handler implementation. The SR stored in the interrupt exception<br />
stack frame will contain the previous value of the M-bit. Since the first instruction of the interrupt<br />
handler is always executed prior to evaluating interrupts, a MOVE 0x2700,SR instruction<br />
can be used to disable interrupts immediately and permit the interrupt handler to move<br />
the interrupt exception stack frame from the supervisor-stack-pointer (SSP)-addressed area<br />
to an interrupt-stack-pointer (ISP)-addressed area.<br />
11.1.2.1 INITIALIZATION CODE (RESET EXCEPTION HANDLER). When the processor<br />
emerges from reset, it enters the reset exception handler. Items that may be encountered in<br />
the reset exception handler are discussed in the following paragraphs.<br />
11.1.2.1.1 Processor Configuration Register (PCR) (MOVEC of PCR). Immediately<br />
after reset, the MC68060 has the superscalar dispatch disabled and the floating-point unit<br />
(FPU) enabled. The PCR may be used to set up the proper environment. The PCR is<br />
accessed via the MOVEC instruction. Since this is a new MOVEC register on the MC68060,<br />
existing MC68040 code does not reference the PCR.<br />
To properly emulate the MC68EC040 or an MC68LC040 using an MC68060, the DFP bit in<br />
the PCR must be set to disable the FPU. Disabling the FPU causes the MC68060 to create<br />
an MC68LC040- or MC68EC040-compatible stack frame when a floating-point instruction is<br />
encountered. With some modification, floating-point emulation software written for the<br />
MC68LC040 and MC68EC040 that use the stack of type 4 may then be used. However,<br />
keep in mind that there are differences in the floating-point instruction set. Also note that the<br />
stacked effective address field is different when dealing with extended precision operands<br />
using the post-increment or pre-decrement addressing modes.<br />
The ESS bit in the PCR must be set to enable superscalar dispatch. Doing so will greatly<br />
increase system performance.<br />
The PCR also provides the EDEBUG bit to enable the new MC68060 debug feature. This<br />
bit is not directly related to porting existing MC68040 software and should be disabled during<br />
normal operation.The EDEBUG bit is for use in debugging hardware and software problems<br />
with the aid of a logic analyzer. For more information, refer to Section 9 IEEE 1149.1 Test<br />
(JTAG) and Debug Pipe Control Modes.<br />
11.1.2.1.2 Default Transparent Translation Register (MOVEC of TCR). The MC68060<br />
provides a method of defining the cache mode, UPAx, and write protection if the logical<br />
address accessed is not mapped by paged memory management and TTRs. For this case,<br />
a transparent translation is done, and the cache mode, UPAx, write protection from the<br />
translation control register (TCR) (accessed via the MOVEC instruction) is used.<br />
The MC68060 default translation after reset is similar to that of the MC68040 (e.g., cache<br />
mode=cacheable write-through, UPA=00, write protection off). Since existing MC68040<br />
code probably writes zeroes to the new TCR bits, no additional work is expected for placing<br />
the MC68060 default translation to be MC68040-like.<br />
11.1.2.1.3 MC68060 Software Package (<strong>M68060</strong>SP). The <strong>M68060</strong>SP replaces the installation<br />
of the MC68040 floating-point software package (M68040FPSP). Software that was<br />
11-2<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Applications Information<br />
used to install the M68040FPSP must be removed and then replaced with software that<br />
installs the <strong>M68060</strong>SP. Be aware that the <strong>M68060</strong>SP and the M68040FPSP share many<br />
vector table entries and that the M68040FPSP does not work properly with the MC68060.<br />
The <strong>M68060</strong>SP must be installed before any of the new unimplemented instructions and<br />
unimplemented effective addresses are encountered.<br />
11.1.2.1.4 Cache Control Register (CACR) (MOVEC of CACR). As with the MC68040,<br />
the MC68060 requires that the instruction and data caches be invalidated prior to their use.<br />
In addition to this, the MC68060 requires that the branch cache be invalidated prior to its<br />
use. The branch cache is cleared via the MOVEC to CACR instruction.<br />
Care must be taken whenever the CACR is referenced in existing MC68040 code. Since the<br />
MC68040 does not implement the new CACR bits, and existing MC68040 code may reference<br />
the CACR, the new CACR bits are likely to be cleared by MC68040-code CACR writes.<br />
If this occurs, the branch cache is retained and the four-deep store buffer is disabled.<br />
Although this would not adversely affect proper operation, it significantly degrades<br />
MC68060 performance.<br />
11.1.2.1.5 Resource Checking (Access Error Handler). Many systems use the access<br />
error handler at some time after reset to check for the existence of I/O devices or memory.<br />
Existing MC68040 systems already have to deal with the restart nature of the MC68040.<br />
However, the stack frame generated by the MC68040 is significantly different from that of<br />
the MC68060. Resource checking software that relies on the stack size information must be<br />
modified appropriately.<br />
When upgrading to the MC68060 from an existing MC68030 or MC68020 system, porting<br />
resource checking software may be problematic because the continuation architecture<br />
(MC68030 and MC68020) allows an operand read bus error to be ignored and not re-run<br />
the offending instruction, but a restart machine such as the MC68060 has no provisions for<br />
doing so. A possible work-around for this is to either increment the stacked program counter<br />
(PC) prior to the RTE, or to use a NOP-RESOURCE_WRITE-NOP in place of the<br />
RESOURCE_READ, in imprecise exception mode, to poke at the possible resource area.<br />
11.1.2.2 VIRTUAL MEMORY SOFTWARE. The MC68060 fully supports virtual memory.<br />
There are some slight changes that need to be made to support the MC68060 virtual memory.<br />
The following paragraphs outline issues that need to be addressed in relation to virtual<br />
memory support.<br />
11.1.2.2.1 Translation Control Register (MOVEC of TCR) . The TCR is accessed via the<br />
MOVEC instruction, as with the MC68040. However, the TCR has newly defined bits. Since<br />
these new bits need to be cleared in normal operating mode anyway, no additional work is<br />
needed.<br />
When the MC68040 emerges from reset, the default translation is cacheable write-through,<br />
UPAx=0, and no write protect. The MC68060 provides a means for modifying these default<br />
translation parameters. There are new bits in the MC68060 TCR to define the default translation.<br />
11-3
Applications Information<br />
Existing MC68040 TCR writes probably write these new bits as zeroes, which would mean<br />
that the MC68060’s default translation is identical to that of the MC68040. If these bits in the<br />
TCR are non-zero, it is possible that somewhere in the existing MC68040 code, a TCR<br />
access would overwrite the desired bits to zero, hence returning the MC68040 default translation<br />
to be MC68040-like. If this is not desired, accesses to the TCR must be changed to<br />
set the appropriate bits.<br />
11.1.2.2.2 Descriptors in Cacheable Copyback Pages Prohibited. The MC68040<br />
allows the use of cacheable copyback pages to store page descriptors. The reason is that<br />
when a table search is initiated, the MC68040 examines the data cache for valid descriptors.<br />
Although the MC68040 does not allocate table descriptors into the cache on a miss, the system<br />
software that is used to set up the descriptors may allocate descriptors into the data<br />
cache.<br />
Since the MC68060 totally ignores the data cache when performing a table search, a<br />
descriptor that resides in a cache entry that is marked valid and dirty would cause incorrect<br />
data to be used. The system software must be modified to make the pages that contain page<br />
and table descriptors to be noncachable or cacheable writethrough to ensure coherency to<br />
avoid this situation.<br />
11.1.2.2.3 Page and Descriptor Faults (Access Error Handler). The access error handler<br />
is entered when a table search results in an invalid table descriptor, invalid page<br />
descriptor, supervisor protection violation, write protection violation, or a bus error. In an<br />
MC68040 access error handler, table-search-related causes require the use of the PTEST<br />
instruction to determine the cause of the fault.<br />
Given the many differences in the access error handling of the MC68060 and MC68040, it<br />
is recommended that the entire handler be replaced. Refer to Section 8 Exception Processing<br />
for information on recovering from an access error.<br />
Note that on unsuccessful table searches, the processor does not allocate an invalid<br />
address translation cache (ATC) entry; therefore, a PFLUSH is not necessary to remove the<br />
invalid ATC entry.<br />
When an MC68040 reports a write page fault, the stack frame contains the stacked PC of<br />
an instruction subsequent to the one that caused the write fault. On the MC68060, the<br />
stacked PC of the stack frame points to the instruction that caused the write page fault. This<br />
is a consequence of not having write-back slots on the stack frame.<br />
11.1.2.2.4 PTEST, MOVEC of MMUSR, and PLPA. The PTEST instruction is unimplemented<br />
and an illegal instruction exception is encountered when this instruction is<br />
attempted. Existing MC68040 software must remove all references to the PTEST instruction.<br />
It is likely that this instruction resides in the access error handler when recovering from<br />
a page or descriptor fault. The PTEST instruction is not emulated in the <strong>M68060</strong>SP and<br />
must therefore be avoided.<br />
The memory management unit status register (MMUSR) of the MC68040 is not implemented<br />
in the MC68060. If a MOVEC instruction is attempted to access this register, an ille-<br />
11-4<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Applications Information<br />
gal instruction exception is taken. This instruction must be removed from existing MC68040<br />
software since it is not emulated in the <strong>M68060</strong>SP.<br />
The MC68060 compensates for the lack of these instructions by providing extensive information<br />
in the FSLW in the access error stack frame. In addition, a new instruction, PLPA, is<br />
added to translate a logical to physical address by initiating a table search. This instruction<br />
may be used to provide most of the function of the PTEST instruction. As with the PTEST<br />
instruction, PLPA loads the valid page descriptor into the ATC when the table search it initiates<br />
executes successfully.<br />
If it is absolutely necessary to emulate the PTEST and the MOVEC of the MMUSR, Motorola<br />
provides assembly source code for these instructions in the bulletin board (see C.5.4<br />
AESOP Electronic Bulletin Board for bulletin board details). The source code is provided<br />
as-is and is only a rough approximation of these instructions and may need customizing. No<br />
documentation is provided other than what is available in the source code.<br />
11.1.2.3 CONTEXT SWITCH INTERRUPT HANDLERS. Context switch interrupt handlers<br />
that use the same virtual address to map into multiple physical address locations must flush<br />
the branch cache via the MOVEC to CACR instruction. The reason for this is that the branch<br />
cache is a logical cache and not a physical cache. For systems that transparently translate<br />
logical addresses to physical addresses, the branch cache need not be flushed.<br />
In multiprocessor systems, care must be taken so that saved contexts generated by an<br />
MC68040-based node not be restored into an MC68060-based node, or vice-versa. The<br />
floating-point frames are different between an MC68040 and MC68060; incorrect swapping<br />
of contexts may cause format errors to be incurred.<br />
If the context switch interrupt handler uses a nonmaskable interrupt (level 7), CAS (misaligned<br />
operands) or CAS2 instruction emulation may result in data corruption. There is no<br />
good workaround except by either avoid using the level 7 interrupt for context switching, or<br />
by using external hardware to block the interrupt lines from reporting an interrupt whenever<br />
LOCK is asserted.<br />
11.1.2.4 TRACE HANDLERS. The MC68060 does not implement “trace on change of flow”.<br />
Debug software that rely on this feature must take this into consideration. When a change<br />
of flow trace encoding is encountered, the processor does not trace.<br />
11.1.2.5 I/O DEVICE DRIVER SOFTWARE. The MC68060, like the MC68040, has a<br />
restart model, and device drivers that have been written for the MC68040 probably do not<br />
need any modification in device driver software when porting to the MC68060; however<br />
there are a few issues to consider.<br />
The cache mode (CM) encoding on the TTRs and the page descriptors is different between<br />
the MC68060 and MC68040. The MC68060 executes reads and writes in strict program<br />
order, and therefore, whenever the CM bits indicate either a noncachable precise or noncachable<br />
imprecise, the accesses are serialized. Areas that are marked cache-inhibited<br />
serialized for I/O devices should not be affected adversely by the cache mode change. Otherwise,<br />
the TTR format and the page descriptor formats have not changed for the MC68060.<br />
11-5
Applications Information<br />
I/O devices that normally incur bus errors need to be aware that the MC68060 has an imprecise<br />
exception mode that may need to be addressed.<br />
11.1.3 Precise Vs. Imprecise Exception Mode<br />
Systems that do not rely on the bus error (TEA asserted) in normal operation are not<br />
affected much by the differences between the precise and imprecise exception mode.<br />
The MC68060 provides the precise and imprecise exception modes to allow system software<br />
to assign the severity of bus errors (TEA asserted) on write cycles. In general, bus<br />
errors on writes are recoverable in the precise exception mode, but not in the imprecise<br />
exception mode. The MC68040 provides a precise exception mode, but at the expense of<br />
performance and a large access error stack frame.<br />
For systems that require precise bus error write cycles in a normal operating environment,<br />
it is possible to disable the store buffer via the MOVEC of CACR instruction. This impacts<br />
performance significantly, and must be carefully considered before doing so. Also, note that<br />
even with the store buffers disabled, a bus error caused by a push buffer write is still nonrecoverable.<br />
11.1.4 Other Considerations<br />
The following is a list of other concerns that are unlikely to affect system software, but are<br />
included for completeness.<br />
1. Some of the exception priorities for multiple exceptions on the MC68060 are different<br />
than the MC68040 (see Section 8 Exception Processing for priority groupings). This<br />
shouldn’t affect the way interrupts are handled, an interrupt is the lowest priority exception<br />
on both microprocessors.<br />
2. Unlike the MC68040, the MC68060 provides only one snoop control signal, the snoop<br />
invalidate signal (SNOOP). System software may need to CPUSH the cache before<br />
DMA activity is initiated. Alternatively, the cache mode may be changed to writethrough<br />
cacheable for all shared memory areas.<br />
11.2 USING AN MC68060 IN AN EXISTING MC68040 SYSTEM<br />
This document outlines the issues involved in using an MC68060 in an existing MC68040<br />
socket. It is assumed that for these applications, the MC68060 is made to operate in the halfspeed<br />
bus mode.<br />
11.2.1 Power Considerations<br />
The MC68060 operates at a supply voltage of 3.3 V, not 5 V. The MC68060 interfaces gluelessly<br />
to transistor-transistor logic (TTL) levels.The following paragraphs discuss the two<br />
main issues of the lower, 3.3-V supply voltage.<br />
11.2.1.1 DC TO DC VOLTAGE CONVERSION. The first issue involves the DC-to-DC voltage<br />
conversion for the MC68060 Vdd<br />
pins. The following paragraphs discuss two solutions<br />
to this problem.<br />
11-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Applications Information<br />
11.2.1.1.1 Linear Voltage Regulator Solution. This solution uses a linear voltage regulator<br />
to supply 2 A at 3.3 V. This solution is inexpensive; however, conversion efficiency of only<br />
up to 65% can be achieved. Figure 11-1 shows a solution using power BJTs. This solution<br />
would be used primarily for applications that are cost sensitive, but not power sensitive. The<br />
suggested linear solution meets the 3.3 V±<br />
5% MC68060 specifications.<br />
5 V<br />
C1<br />
R1<br />
D1<br />
T1 = TIP32<br />
T2 = 2N2222A<br />
D1 = TL431CLP<br />
D2,D3,D4 = IN4001<br />
R1 = 220 Ω<br />
R2,R3,R4 = 1K Ω<br />
R5 = 2.2K Ω<br />
C1 = 47 μF<br />
C2 = 0.01 μF<br />
C3 = 0.033 μF<br />
CL = 47 μF<br />
C2<br />
T1<br />
D2 D3 D4<br />
T2<br />
Figure 11-1. Linear Voltage Regulator Solution<br />
11.2.1.1.2 Switching Regulator Solution. This solution uses switching regulators. Linear<br />
Technologies offers two parts, the LTC1147 and LTC1148 and MAXIM offers the MAX767.<br />
The main difference among these parts is a trade-off between price, part count, and conversion<br />
efficiency.<br />
The LTC1147 solution is less expensive and has one fewer MOSFET than the LTC1148<br />
solution. The LTC1148 is less than $5 in 1000 piece quantities, and the LTC1147 is less<br />
than $4 in 1000 piece quantities. In either of these solutions there are around 15 discrete<br />
C3<br />
R4<br />
CL<br />
3.3 V<br />
2 A<br />
R2<br />
R3<br />
R5<br />
11-7
Applications Information<br />
devices that are needed externally in addition to the Linear Technologies devices. The conversion<br />
efficiency is 89% and 93% for the LTC1147 and LTC1148, respectively. Figure 11-<br />
2 and Figure 11-3 show the solutions provided by using the switching regulators. The<br />
MAX767 provides over 90% conversion efficiency at less than $4 in 1000 piece quantities.<br />
The MAX767 solution also requires discreet components off-chip. The MAX767 uses a<br />
smaller inductor than the LTC1148 solution. Figure 11-4 shows a MAXIM voltage regulator<br />
solutions. All the suggested solutions meets 3.3 V ± 5% MC68060 specifications.<br />
11-8<br />
CC<br />
RC<br />
5 V<br />
C4<br />
CT<br />
VIN<br />
SHUTDOWN<br />
I TH<br />
C T<br />
T1 = Si9430DY<br />
L1 = 50 μH Coiltronics CTX50-2-MP<br />
D1 = MBRD330<br />
D2,D3,D4 = IN4001<br />
R1 = 0.05 Ω IRC LR2512-01-R050-G<br />
RC = 1K Ω<br />
C1 = 1000 pF<br />
C2 = 100 μF, 20V<br />
C3 = 1 μF<br />
C4 = 100 nF<br />
CC = 3300 pF<br />
CT = 470 pF<br />
CL = 220 μF, 10V x2<br />
LTC1147-3.3<br />
GND<br />
C2 C3<br />
P-DRIVE<br />
SENSE +<br />
SENSE –<br />
Figure 11-2. LTC1147 Voltage Regulator Solution<br />
T1<br />
D1<br />
<strong>M68060</strong> USER’S MANUAL<br />
C1<br />
L1<br />
CL<br />
D2<br />
D3<br />
D4<br />
R1<br />
3.3 V<br />
2 A<br />
MOTOROLA
CC<br />
MOTOROLA<br />
RC<br />
5 V<br />
C4<br />
CT<br />
SHUTDOWN<br />
I TH<br />
C T<br />
T1 = Si9430DY<br />
T2 = Si9410DY<br />
L1 = 50 μH Coiltronics CTX50-2-MP<br />
D1 = MBRS140T3<br />
D2,D3,D4 = IN4001<br />
R1 = 0.05 Ω IRC LR2512-01-R050-G<br />
RC = 1K Ω<br />
C1 = 1000 pF<br />
C2 = 100 μF, 20V<br />
C3 = 1 μF<br />
C4 = 100 nF<br />
CC = 3300 pF<br />
CT = 470 pF<br />
CL = 220μF 10V X 2 AVX<br />
VIN<br />
LTC1148-3.3<br />
SGND PGND<br />
C2 C3<br />
P-DRIVE<br />
SENSE +<br />
SENSE –<br />
N-DRIVE<br />
Figure 11-3. LTC1148 Voltage Regulator Solution<br />
T1<br />
T2<br />
<strong>M68060</strong> USER’S MANUAL<br />
C1<br />
L1<br />
D1<br />
Applications Information<br />
D2<br />
D3<br />
D4<br />
R1<br />
CL<br />
3.3 V<br />
2 A<br />
11-9
Applications Information<br />
11-10<br />
C1<br />
5 V<br />
C5<br />
C4<br />
C6<br />
SS<br />
ON<br />
SYNC<br />
REF<br />
GND<br />
R2<br />
R1 = .02 ΩIRC LR2010-01-R020<br />
R2 = 10 Ω<br />
N1,N2 = Motorola MMDF3N03HD<br />
D1 = Central Semi. CMPSM-3<br />
D2 = Motorola MBRS120T3<br />
C1 = 2 x 47μF, 20V AVX TPSD476K020R<br />
C2 = 2 x 150μF Sprague<br />
595D157X0010D7T<br />
C3 = 0.1μF<br />
C4 = 4.7μF<br />
D3,D4,D5 = IN4001<br />
L1 = 5.0 μH Sumida CDR125<br />
DRG# 4722-JPS-001<br />
Vcc<br />
MAX767<br />
PGND<br />
BST<br />
DH<br />
CS<br />
LX<br />
FB<br />
DL<br />
Figure 11-4. MAX767 Voltage Regulator Solution<br />
N1<br />
N2<br />
<strong>M68060</strong> USER’S MANUAL<br />
D1<br />
L1<br />
D2<br />
C3<br />
D5<br />
D3<br />
D4<br />
R1<br />
C2<br />
3.3 V<br />
3A<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Applications Information<br />
11.2.1.2 INPUT SIGNALS DURING POWER-UP REQUIREMENT. The second issue<br />
involves the requirement that during power-up, input signals to the MC68060 not exceed Vdd<br />
by more than 4 V. This is achieved by ensuring that the 5-V supply not exceed the 3.3-V<br />
supply by more than 4 V. In any of the previously discussed DC-to-DC conversion solutions,<br />
it is possible to add three diodes in series from the 5-V supply to the 3.3-V plane. During<br />
power-up, the diodes forward bias and thus provide a current path between the 5-V source<br />
and the 3.3-V plane. This solution provides no more than (0.7 * 3) = 2.1 V drop between the<br />
5-V input and the 3.3-V plane. When the voltage regulator stabilizes, the difference of (5 –<br />
3.3) = 1.7 V is insufficient to forward bias the three diodes, hence not dissipating any energy.<br />
Both Motorola and Linear Technologies have indicated that the three diode shunt does not<br />
adversely affect operation.<br />
Figure 11-1, Figure 11-2, and Figure 11-3 include the shunt diodes as proposed to keep the<br />
5-V supply from drifting more than 2.5 V from the 3.3-V plane.<br />
11.2.2 Output Hold Time Differences<br />
On the MC68040, outputs are driven off the falling edge of PCLK. Since the MC68060 drives<br />
everything off the rising edge of CLK, a hold time differential exists and is discussed in the<br />
following paragraphs.<br />
The data write hold time specification may be met by using the extra data hold time mode<br />
to extend the hold time by a full CLK cycle in which CLKEN is asserted. However, using this<br />
mode requires that the IPLx signals be modified to invoke configuration of this mode at reset.<br />
Decreasing the address hold time affects primarily systems containing slow peripherals. An<br />
example of this problem can be shown on a system that does a read of the MC68681 duart<br />
peripheral. If the system design is implemented such that on a read of the MC68681, the<br />
address hold time relative to chip select specification is violated, it is possible to internally<br />
confuse the MC68681 and cause it to enter its test mode. The MC68681 is one of many<br />
devices that require addresses to be stable as long as its chip select is asserted. Figure 11-<br />
5 and Figure 11-6 show the differences between the hold time for the MC68060 the<br />
MC68040.<br />
PCLK<br />
BCLK<br />
TA<br />
TS<br />
A31–A0<br />
CSx<br />
Figure 11-5. MC68040 Address Hold Time<br />
11-11
Applications Information<br />
11-12<br />
CLK<br />
CLKEN<br />
1/2-SPEED BUS CLOCK<br />
TA<br />
TS<br />
A31–A0<br />
Figure 11-6. MC68060 Address Hold Time<br />
A possible solution addressing both the address and write data hold time issue for slow<br />
peripherals is to force at least one dead state between TA negation and TS assertion of the<br />
next bus cycle. This can be achieved by arbitrating the bus away from the processor on any<br />
long-word, word, or byte access. This forces the processor to release the bus, not begin a<br />
new bus cycle, three-state the address bus, and three-state the data bus on write cycles.<br />
Since the address and data buses (on writes) are three-stated and not directly driven by the<br />
MC68060, output hold time in this solution relies on the capacitive loading of the bus to<br />
achieve the extended hold time.<br />
Once the dead state has been added, the bus is returned to the processor and normal operation<br />
continues. This suggested solution does not affect line (burst) accesses, which are typically<br />
cacheable and contain no I/O devices. For this reason, performance is not<br />
compromised. In this implementation, the only signal that may be affected is BG. In this solution,<br />
BG is intercepted and combined with the dead-state inserting logic. This combined signal<br />
is then fed into the MC68060’s BG. Figure 11-7 shows the effect of BG.<br />
CLK<br />
CLKEN<br />
CS<br />
1/2-SPEED BUS CLOCK<br />
TA<br />
TS<br />
A[31:0]<br />
CSX<br />
BG<br />
Figure 11-7. MC68060 Address Hold Time Fix<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
11.2.3 Bus Arbitration<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
Applications Information<br />
The MC68060 does not drive the bus in implicit bus ownership cases where it has not yet<br />
requested the bus. Although this feature is not known to be necessary for MC68040-based<br />
designs, this is a difference. This MC68060 action does not pose any known problems to<br />
existing MC68040 designs.<br />
The BGR signal may be pulled low or grounded to cause the MC68060 to relinquish the bus<br />
on locked sequences to behave like the MC68040. To use the BB protocol, BTT should be<br />
pulled up through a resistor (approximate value of 5 KΩ)<br />
to Vdd.<br />
Since the MC68060 drives<br />
BTT low at times, no other signals should be connected to this pullup resistor.<br />
See 11.2.2 Output Hold Time Differences, as bus arbitration may be an issue for output<br />
hold time requirements.<br />
11.2.4 Snooping<br />
The MC68060 does not support snoop intervention during bus cycles as the MC68040 does.<br />
The MC68060 implements only the snoop invalidate protocol. The MC68060 only has one<br />
SNOOP signal instead of the two-bit encoding of the SCx signals on the MC68040. Also, the<br />
MC68060 does not implement the MI pin; the MI signal must be pulled up if it is used by the<br />
system.<br />
If an MC68040 system only utilizes invalidate line snoop functionality, the SCx signal control<br />
could be mapped to assert SNOOP to the MC68060. Other MC68040 snoop implementations<br />
must also implement software changes to flush cache or address map to write-through<br />
mode shared system memory areas.<br />
11.2.5 Special Modes<br />
TheMC68040 and MC68060 IPLx signals have different functionality when coming out of<br />
reset. On the MC68040, the IPLx signals select the buffer size. The MC68060 has only one<br />
buffer size, and therefore the MC68060 encodes different functionality when it samples the<br />
IPLx signals when coming out of reset.<br />
The MC68060 has new special modes that are selectable via the IPLx signals during reset.<br />
These MC68060 special modes are: acknowledge termination ignore state capability,<br />
acknowledge termination mode, and extra write hold mode. To prevent these modes from<br />
being enabled, the IPLx signals must be negated (pulled high) during reset.<br />
The MC68060 does not implement the DLE functionality of the MC68040. Applications that<br />
use the DLE mode are not upgradable without using external logic.The MC68060 does not<br />
implement the muxed bus functionality of the MC68040. Applications that use muxed bus<br />
mode are not upgradable without using external logic.<br />
11-13
Applications Information<br />
11.2.6 Clocking<br />
For systems which have PCLK-to-BCLK skew controlled by a phase-locked-loop (PLL)<br />
clock generator such as the 88915 or 88916, it is possible to connect the PCLK of the<br />
MC68040 to the MC68060 CLK input as shown in Figure 11-8. Otherwise, the MC68060<br />
CLK must be generated by an 88915 PLL as shown in Figure 11-9.<br />
EXISTING<br />
MC68040<br />
SYSTEM<br />
EXISTING<br />
MC68040<br />
SYSTEM<br />
BCLK<br />
Appropriate generation of the CLKEN signal to enable 1/2-speed operation is easily<br />
achieved by delaying the MC68040 BCLK by 5 ns before feeding it into the CLKEN input of<br />
the MC68060.<br />
Be aware that a clock skew exists between CLK and BCLK. The MC88915 can only control<br />
the skew to within 1 ns. Figure 11-10 shows the relationship between BCLK and CLKEN.<br />
11.2.7 PSTx Encoding<br />
BCLK<br />
PCLK<br />
Figure 11-8. Simple CLK Generation<br />
VIRTUAL MC68040<br />
FEEDBACK<br />
SYNC0<br />
VIRTUAL MC68040<br />
Figure 11-9. Generic CLK Generation<br />
PSTx signal encoding is different between the MC68060 and MC68040. This should not<br />
affect normal applications because PSTx signals are not used for bus control logic.<br />
11-14 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
Q0<br />
2XQ<br />
5 NS<br />
CLKEN<br />
CLK<br />
5 ns<br />
MC68060<br />
CLKEN<br />
CLK<br />
MC68060
BCLK<br />
CLK<br />
CLKEN<br />
Figure 11-10. MC68040 BCLK to CLKEN Relationship<br />
11.2.8 Miscellaneous Pullup Resistors<br />
Applications Information<br />
Pullup CLA to prevent the A3 and A2 address lines from cycling on burst accesses. Pullup<br />
TRA when MC68040 acknowledge termination mode is being used.<br />
11.3 EXAMPLE DRAM ACCESS<br />
When interfacing the MC68060 with dynamic random access memory (DRAM), it is necessary<br />
to determine how many clocks per bus cycle will be needed for a line burst transfer.<br />
The number of clocks per bus cycle is dependent upon the processor clock frequency and<br />
the DRAM access times. In this example, the DRAM RAS access time, CAS access time,<br />
RAS precharge time, and CAS precharge time are used to determine the number of clocks<br />
per bus cycle of a DRAM access. Figure 11-11 shows two successive line burst transfers.<br />
The CLA signal is used to cycle A3 and A2 a clock before the DRAM subsystem asserts TA.<br />
CLK<br />
TS<br />
TA<br />
CLA<br />
A3–A2<br />
DATA<br />
(WRITE CYCLE)<br />
DATA<br />
(READ CYCLE)<br />
RAS<br />
CAS<br />
DRAM ADDRESS<br />
W0 W1 W2 W3 W0<br />
W1<br />
W2<br />
W3<br />
ROW C0 C1 C2 C3 ROW<br />
C0 C1<br />
C2<br />
C3<br />
Figure 11-11. DRAM Timing Analysis<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 11-15
Applications Information<br />
The RAS access time determines the number of wait states needed for the first memory<br />
access. The RAS access time is the time it takes between RAS being asserted and valid<br />
data coming out of the DRAM. The total available time for the first access is the time<br />
between the TS assertion and the first TA assertion. This time is equal to the clock period<br />
multiplied by the number of primary wait states. In addition to the RAS access time, the<br />
MC68060 input setup time and the TS to RAS propagation delay must also occur between<br />
the TS and TA signals. The following equation represents the number of wait states required<br />
for the primary memory access:<br />
Wait States = (RAS propagation delay + RAS access time + Input Setup Time) / clock period<br />
The following example assumes a RAS access time of 65 ns, an input setup time of 7 ns,<br />
and a RAS propagation delay of 5 ns. The processor is running at 50 MHz, so the clock<br />
period is 20 ns. The number of wait states required is (5ns + 65ns + 7ns) / 20 ns = 3.85 wait<br />
states. Therefore 4 wait states are required.<br />
The CAS access time and the CAS precharge time determines the number of secondary<br />
wait states required. The CAS precharge time is the time that the CAS signal must remain<br />
negated between assertions. The total time available for the secondary access is the time<br />
between the first and second TA signals. This time is equal to the clock period multiplied by<br />
the number of secondary wait states. Since CAS must toggle during this time, two CAS propagation<br />
delays, the CAS precharge time, the CAS access time, and the MC68060 input<br />
setup time must occur during this time. Typically, the CAS precharge time is less than a<br />
clock period. Therefore an entire clock period is used to toggle CAS. This leaves one CAS<br />
propagation delay time, a CAS access time, and the input setup time. This time must be less<br />
than the number of wait states less one multiplied by the clock period. The following equation<br />
represents the number of wait states required for the secondary memory accesses:<br />
Wait States = [(CAS propagation delay + CAS access time + input setup time) / clock period] + 1<br />
The following example assumes a CAS access time of 20 ns, input setup time of 7 ns, and<br />
a CAS propagation delay of 5 ns. The clock period is 20 ns. The number of wait states<br />
required is [(5ns + 20ns + 7ns) / 20ns] + 1 = 2.6. Therefore three wait states are required.<br />
This first line burst transfer is a 5:3:3:3 transfer. For the primary transfer, an extra clock is<br />
added for the TS signal assertion.<br />
In this example, a second line burst transfer occurs immediately following the first transfer.<br />
If the same DRAM chips are being accessed, RAS precharge time must be considered. RAS<br />
precharge time is the time that the RAS signal must remain high between assertions. In the<br />
example, RAS precharge time is 65 ns. Two additional wait states need to be added after<br />
the second TS to assure that the RAS precharge time is satisfied. Therefore, the second line<br />
burst transfer is a 7:3:3:3 transfer.<br />
11-16 <strong>M68060</strong> USER’S MANUAL MOTOROLA
11.4 THERMAL MANAGEMENT<br />
Applications Information<br />
The maximum case temperature (Tc) in °C can be obtained from the following equation:<br />
T c = T j – P d × θ jc<br />
where:<br />
T c = Maximum Case Temperature<br />
T j = Maximum Junction Temperature<br />
P d = Maximum Power Dissipation of the Device<br />
θ jc = Thermal Resistance between the Junction of the Die and the Case<br />
In general, the ambient temperature (T a ) in °C is a function of the following equation:<br />
T a = T j – P d × θ jc – P d × θ ca<br />
The thermal resistance from case to outside ambient (θ ca ) is the only user-dependent<br />
parameter once a buffer output configuration has been determined. Reducing the case to<br />
ambient thermal resistance increases the maximum operating ambient temperature. Therefore,<br />
by utilizing methods such as heat sinks and ambient air cooling to minimize θ ca , a<br />
higher ambient operating temperature and/or a lower junction temperature can be achieved.<br />
However, an easier approach to thermal evaluation uses the following equations:<br />
T a = T j – P d × θ ja or<br />
T j = T a + P d × θ ja<br />
where:<br />
θ ja = Thermal Resistance from the Junction to the Ambient (θ jc + θ ca )<br />
The total thermal resistance for a package (θ ja ) is a combination of its two components, θ jc<br />
and θ ca . These components represent the barrier to heat flow from the semiconductor junction<br />
to the package case surface (θ jc ) and θ ca . Although θ jc is package related and the user<br />
cannot influence it, θ ca is user dependent. Good thermal management by the user, such as<br />
heat sink and airflow, can significantly reduce θ ca achieving either a lower semiconductor<br />
junction temperature or a higher ambient operating temperature. The following tables can<br />
be used to aid in deciding how much of air flow and heat sink for proper thermal management.<br />
Data for the “no heat sink” cases are derived from MC68040 PGA package characteristics.<br />
The MC68060 PGA package has similar thermal characteristics as the MC68060 PGA<br />
Package. The heat sink used for the “with heat sink” cases are based on the Thermalloy<br />
2333B heat sink. Since exact power dissipation figures for the MC68060 are unavailable at<br />
the time of printing, linear interpolation of these tables can be used to provide rough estimates.<br />
Table 11-1, Table 11-2, and Table 11-3 list the thermal data.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 11-17
Applications Information<br />
Table 11-1. With Heat Sink, No Air Flow<br />
Air Flow<br />
Velocity<br />
PD TJ θJC MAX TA – TC TC TA 0 LFM 2.8 W 110 °C 2.5 °C/W 35 °C 103 °C 68 °C<br />
0 LFM 3.1 W 110 °C 2.5 °C/W 38 °C 102 °C 64 °C<br />
0 LFM 3.5 W 110 °C 2.5 °C/W 40 °C 101 °C 61 °C<br />
0 LFM 3.8 W 110 °C 2.5 °C/W 43 °C 100 °C 57 °C<br />
0 LFM 4.2 W 110 °C 2.5 °C/W 45 °C 100 °C 54 °C<br />
0 LFM 4.5 W 110 °C 2.5 °C/W 48 °C 99 °C 51 °C<br />
0 LFM 4.9 W 110 °C 2.5 °C/W 50 °C 98 °C 48 °C<br />
0 LFM 5.2 W 110 °C 2.5 °C/W 53 °C 97 °C 44 °C<br />
Table 11-2. With Heat Sink, with Air Flow<br />
Air Flow<br />
Velocity<br />
PD TJ θJC MAX θCA θJA TC TA 200 LFM 2.8 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 103 °C 91 °C<br />
200 LFM 3.1 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 102 °C 89 °C<br />
200 LFM 3.5 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 101 °C 87 °C<br />
200 LFM 3.8 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 100 °C 84 °C<br />
200 LFM 4.2 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 100 °C 82 °C<br />
200 LFM 4.5 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 99 °C 80 °C<br />
200 LFM 4.9 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 98 °C 77 °C<br />
200 LFM 5.2 W 110 °C 2.5 °C/W 4.25 °C/W 6.75 °C/W 97 °C 75 °C<br />
400 LFM 2.8 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 103 °C 97 °C<br />
400 LFM 3.1 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 102 °C 95 °C<br />
400 LFM 3.5 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 101 °C 94 °C<br />
400 LFM 3.8 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 100 °C 92 °C<br />
400 LFM 4.2 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 100 °C 90 °C<br />
400 LFM 4.5 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 99 °C 89 °C<br />
400 LFM 4.9 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 98 °C 87 °C<br />
400 LFM 5.2 W 110 °C 2.5 °C/W 2.25 °C/W 4.75 °C/W 97 °C 85 °C<br />
600 LFM 2.8 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 103 °C 99 °C<br />
600 LFM 3.1 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 102 °C 98 °C<br />
600 LFM 3.5 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 101 °C 96 °C<br />
600 LFM 3.8 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 100 °C 95 °C<br />
600 LFM 4.2 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 100 °C 93 °C<br />
600 LFM 4.5 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 99 °C 92 °C<br />
600 LFM 4.9 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 98 °C 91 °C<br />
600 LFM 5.2 W 110 °C 2.5 °C/W 1.50 °C/W 4.00 °C/W 97 °C 89 °C<br />
11-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Table 11-3. No Heat Sink<br />
Applications Information<br />
Air Flow<br />
Velocity<br />
PD TJ θJC MAX θCA θJA TC TA 0 LFM 2.8 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 103 °C 48 °C<br />
0 LFM 3.1 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 102 °C 40 °C<br />
0 LFM 3.5 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 101 °C 32 °C<br />
0 LFM 3.8 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 100 °C 24 °C<br />
0 LFM 4.2 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 100 °C 16 °C<br />
0 LFM 4.5 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 99 °C 9 °C<br />
0 LFM 4.9 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 98 °C 1 °C<br />
0 LFM 5.2 W 110 °C 2.5 °C/W 20 °C/W 23 °C/W 97 °C -7 °C<br />
200 LFM 2.8 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 103 °C 68 °C<br />
200 LFM 3.1 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 102 °C 63 °C<br />
200 LFM 3.5 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 101 °C 58 °C<br />
200 LFM 3.8 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 100 °C 53 °C<br />
200 LFM 4.2 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 100 °C 48 °C<br />
200 LFM 4.5 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 99 °C 42 °C<br />
200 LFM 4.9 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 98 °C 37 °C<br />
200 LFM 5.2 W 110 °C 2.5 °C/W 13 °C/W 16 °C/W 97 °C 32 °C<br />
400 LFM 2.8 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 103 °C 77 °C<br />
400 LFM 3.1 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 102 °C 73 °C<br />
400 LFM 3.5 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 101 °C 68 °C<br />
400 LFM 3.8 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 100 °C 64 °C<br />
400 LFM 4.2 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 100 °C 60 °C<br />
400 LFM 4.5 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 99 °C 56 °C<br />
400 LFM 4.9 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 98 °C 52 °C<br />
400 LFM 5.2 W 110 °C 2.5 °C/W 10 °C/W 13 °C/W 97 °C 48 °C<br />
600 LFM 2.8 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 103 °C 81 °C<br />
600 LFM 3.1 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 102 °C 77 °C<br />
600 LFM 3.5 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 101 °C 74 °C<br />
600 LFM 3.8 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 100 °C 70 °C<br />
600 LFM 4.2 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 100 °C 66 °C<br />
600 LFM 4.5 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 99 °C 63 °C<br />
600 LFM 4.9 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 98 °C 59 °C<br />
600 LFM 5.2 W 110 °C 2.5 °C/W 8 °C/W 11 °C/W 97 °C 55 °C<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 11-19
Applications Information<br />
11.5 SUPPORT DEVICES<br />
Table 11-4 outlines miscellaneous devices available that can be used with the MC68060.<br />
Table 11-4. Support Devices and Products<br />
Device Description Literature<br />
MC88926 3.3 Volt Clock Driver with PLL BR1333/D<br />
MC88915/916 Clock Drivers with PLL BR1333/D<br />
MCM62940 SRAM with Burst Capability DL113<br />
MC68150 Dynamic Bus Sizing for the MC68040 MC68150/D<br />
MC68360<br />
Peripherals, DRAM controller when used in the companion<br />
mode<br />
MC68360/D<br />
Diodes/Transistors Linear Devices DL128<br />
SRAMS Static Memory DL113<br />
DRAMS Dynamic Memory DL113<br />
NM27P6841 EPROM with Burst Capability Contact National <strong>Semiconductor</strong><br />
MAX767 Switching Voltage Regulator Contact Maxim Integrated Products<br />
LTC1147/1148 Switching Voltage Regulator Contact Linear Technologies<br />
Bus Adapter MC68060 to MC68040 PGA to PGA Bus Adapter Contact Interconnect Systems Inc.<br />
11-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
SECTION 12<br />
ELECTRICAL AND THERMAL CHARACTERISTICS<br />
The following paragraphs provide information on the maximum rating and thermal characteristics<br />
for the MC68060. This section is subject to change. For the most recent specifications,<br />
refer to the web page, www.motorola.com/SPS/HPESD.<br />
12.1 MAXIMUM RATINGS<br />
Characteristic Symbol Value Unit<br />
Supply Voltage VCC<br />
Ð0.3 to 4.0 V<br />
Input Voltage Vin<br />
Maximum Operating Junction Temperature TJ<br />
Minimum Operating Ambient Temperature TA<br />
Storage Temperature Range Tstg<br />
12.2 THERMAL CHARACTERISTICS<br />
12.3 POWER DISSIPATION1,<br />
2<br />
MOTOROLA<br />
Ð0.5 to VCC+4<br />
V<br />
110<br />
° C<br />
<strong>M68060</strong> USERÕS MANUAL<br />
0<br />
Ð55 to 150<br />
° C<br />
° C<br />
Description Symbol Value Unit<br />
Thermal Resistance, Junction to CaseÑPGA<br />
Thermal Resistance, Junction to CaseÑTBGA<br />
qJC<br />
qJC<br />
2.5<br />
0.3<br />
° C/W<br />
° C/W<br />
This device contains protective circuitry<br />
against damage due to high static voltages<br />
or electrical fields; however, it is advised<br />
that normal precautions be taken to avoid<br />
application of any voltages higher that<br />
maximum-rated voltages to this highimpedance<br />
circuit. Reliability of operation<br />
is enhanced if unused inputs are tied to an<br />
appropriate logic voltage level (e.g., either<br />
GND or VCC).<br />
Conditions<br />
MC68EC060 MC68LC060 MC68060<br />
50 MHz 66 MHz 75 MHz 50 MHz 66 MHz 75 MHz 50 MHz 66 MHz<br />
Unit<br />
Vcc<br />
= 3.465 V, TA = 0°<br />
C<br />
Normal Mode<br />
3.5 4.5 Note 3 Note 3 4.5 Note 3 3.9 4.9 W<br />
Vcc<br />
= 3.465 V, TA = 0°<br />
C<br />
LPSTOP Mode, CLK Running<br />
300 300 Note 3 300 300 Note 3 300 300 mW<br />
Vcc<br />
= 3.465 V, TA = 0°<br />
C<br />
LPSTOP Mode, CLK Stopped Low<br />
NOTES:<br />
30 30 Note 3 30 30 Note 3 30 30 mW<br />
1. Power dissipation assumes no DC load.<br />
2. Power dissipation data is not applicable to the debug pipe control mode.<br />
3. Data not available at this time.<br />
12-1
Electrical and Thermal Characteristics<br />
12.4 DC ELECTRICAL SPECIFICATIONS (VCC<br />
= 3.3 V ± 5%)<br />
Characteristic Symbol Min Max Unit<br />
Input High Voltage VIH 2 5.5 V<br />
Input Low Voltage VIL GND 0.8 V<br />
Undershoot Ñ Ñ 0.8 V<br />
Overshoot<br />
Input Leakage Current<br />
Ñ Ñ 0.8 V<br />
AVEC, CLK, TT1, BG, CDIS, MDIS, IPLx, RSTI, SNOOP, CLKEN,<br />
TBI, TCI, TCK, TEA, TA, TRA, BGR, CLA, JTAG<br />
Hi-Z (Off-State) Leakage Current<br />
IIL, IIH Ð50 20 mA<br />
An, BB, CIOUT, Dn, LOCK, LOCKE, TDO,<br />
TIP, SAS, BTT, BSx, TMx, TLNx, TS, TTx, UPAx<br />
ITSI Ð50 20 mA<br />
Signal Low Input Current, VIL = 0.8 V<br />
TMS, TDI, TRST<br />
IIL Ð1.1 Ð0.18 mA<br />
Signal High Input Current, VIH = 2.0 V<br />
TMS, TDI, TRST<br />
IIH Ð0.94 Ð0.16 mA<br />
Output High Voltage, IOH = 16 mA VOH 2.4 Ñ V<br />
Output Low Voltage, IOL = 16 mA VOL Ñ 0.5 V<br />
Capacitance*, Vin = 0 V, f = 1 MHz, CLK Only Cin Ñ 20 pF<br />
Capacitance*, Vin = 0 V, f = 1 MHz, All Inputs Except CLK Cin Ñ 20 pF<br />
* Capacitance is sampled periodically and not 100% tested.<br />
12-2<br />
<strong>M68060</strong> USERÕS MANUAL<br />
MOTOROLA
12.5 CLOCK INPUT SPECIFICATIONS (VCC<br />
= 3.3 V ± 5%)<br />
Num Characteristic<br />
NOTES:<br />
1.Specification value at maximum frequency of operation.<br />
2.Minimum frequency is periodically sampled and not 100% tested.<br />
3.CLK may be stopped LOW to conserve power.<br />
MOTOROLA<br />
Frequency of Operation 02<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Electrical and Thermal Characteristics<br />
50 MHz 66 MHz 75 MHz<br />
Min Max Min Max Min Max<br />
50 02<br />
66.67 02<br />
Unit<br />
75 MHz<br />
1 CLK Cycle Time 20 Ñ 15 Ñ 13.3 Ñ nS<br />
2 CLK Rise Time Ñ 2 Ñ 2 Ñ 2 nS<br />
3 CLK Fall Time Ñ 2 Ñ 2 Ñ 2 nS<br />
4 CLK Duty Cycle Measured at 1.5 V 45 55 45 55 45 55 %<br />
4a1<br />
CLK Pulse Width High Measured at 1.5 V 9 11 6.75 8.25 6.0 7.3 nS<br />
4b1<br />
CLK Pulse Width Low Measured at 1.5 V 9 11 6.75 8.25 6.0 7.3 nS<br />
55 CLKEN Input Setup 8 Ñ 7 Ñ 5.5 Ñ nS<br />
56 CLKEN Input Hold 2 Ñ 2 Ñ 2 Ñ nS<br />
CLK<br />
BCLK<br />
CLKEN<br />
55<br />
56<br />
1<br />
4a 4b<br />
V M VL<br />
Figure 12-1. Clock Input Timing Diagram<br />
55<br />
2 3<br />
56<br />
V H<br />
12-3
Electrical and Thermal Characteristics<br />
12.6 OUTPUT AC TIMING SPECIFICATIONS (VCC<br />
= 3.3 V ± 5%)<br />
Num Characteristic<br />
114<br />
11a<br />
4<br />
NOTES:<br />
1. Output timing is measured at the pin, assuming a capacitive load of 50 pF. A maximum load of 130 pF may be used,<br />
however. Characterization indicates that at 130 pF loads, output propagation delays are modified as follows: 50 MHz,<br />
Pad at VCC,<br />
multiply prop delay by 1.4; 50 MHz, Pad at 5.5 V, multiply prop delay by 1.6; 66 MHz, Pad at VCC,<br />
multiply<br />
prop delay by 1.3; 66 MHz, pad at 5.5 V, multiply prop delay by 1.4. Exceeding the 130-pF limit on any pin may affect<br />
long-term reliability and Motorola does not guarantee proper operation.<br />
2. In a mixed supply system where the processor drives chips operating with 5-volt supply, the ÒPad Starts at 5.5 VÓ<br />
column should be used, as it is possible that a three-state pin is at 5.5 volts when the processor begins to drive it.<br />
For a non three-state pin driven by the processor or a homogeneous 3.3-volt system, the ÒPad Starts at VccÓ column<br />
must be used. This note does not apply to spec numbers 11, 11a, 40, and 40a. Refer to Note 5 for these specs.<br />
3. BCLK is not a pin signal name. It is a virtual bus clock where the BCLK rising edge coincides with that of CLK when<br />
CLKEN is asserted. The BCLK falling edge is insignificant. An output timing reference to BCLK means that the specific<br />
output transitions only on rising CLK edges when CLKEN is asserted. A timing reference to CLK means that the<br />
output may transition off the rising CLK edge, regardless of CLKEN state.<br />
4. When the processor drives these signals from a three-stated condition, use spec 11a or 40a. Use the ÒPad Starts at<br />
VCCÓ<br />
column or ÒPad Starts at 5.5 VÓ column as appropriate. Once these signals are driven, subsequent transitions<br />
are defined by spec 11 or 40. The ÒPad Starts at 5.5 VÓ column has no entry for specs 11 and 40, since the processor<br />
only drives up to the VCC<br />
level. BR is never three-stated by the processor, and therefore, spec 40a does not apply.<br />
5. ÒPad Starts at 5.5 V" does not apply since these signals are always driven.<br />
12-4<br />
BCLK to Address CIOUT, LOCK,<br />
LOCKE, R/W, SIZx, TLN, TMx,<br />
TTx, UPAx, BSx Valid (signal predriven)<br />
BCLK to Address CIOUT, LOCK,<br />
LOCKE, R/W, SIZx, TLN, TMx,<br />
TTx, UPAx, BSx Valid (signal from<br />
three-state)<br />
50 MHz 66 MHz 75 MHz<br />
Pad Pad Pad Pad<br />
Starts Starts Starts Starts<br />
2<br />
at 5.5 V at V 2<br />
CC at 5.5 V 2 at VCC<br />
2<br />
Pad Pad<br />
Starts Starts<br />
at 5.5 V 2 at V 2<br />
CC<br />
Min Max Min Max Min Max Min Max Min Max Min Max<br />
Ñ Ñ 2 12.6 Ñ Ñ 2 9.9 Ñ Ñ 1.5 8.8 nS<br />
2 15.4 2 13.5 2 11.8 2 10.4 1.5 10.5 1.5 9.2 nS<br />
12<br />
BCLK or CLK to Output Invalid<br />
(Output Hold)<br />
2 Ð 2 Ð 2 Ð 2 Ð 1.5 Ð 1.5 Ð nS<br />
13 BCLK to TS Valid 2 14.4 2 12.3 2 10.9 2 9.5 1.5 9.7 1.5 8.4 nS<br />
14 BCLK to TIP Valid 2 15.4 2 13.5 2 11.8 2 10.4 1.5 10.5 1.5 9.2 nS<br />
18 BCLK to Data Out Valid 2 13.5 2 13.5 2 10.4 2 10.4 1.5 9.2 1.5 9.2 nS<br />
19<br />
BCLK to Data Out Invalid (Output<br />
Hold)<br />
2 Ð 2 Ð 2 Ð 2 Ð 1.5 Ð 1.5 Ð nS<br />
21 BCLK to Data-Out High Impedance Ñ 12 Ñ 12 Ñ 10 Ñ 10 Ñ 8.9 Ñ 8.9 nS<br />
38<br />
BCLK to Address, CIOUT, LOCK,<br />
LOCKE, R/W, SIZx, TS, TLNx,<br />
TMx, TTx, UPAx, BSx High Impedance<br />
Ñ 12 Ñ 12 Ñ 10 Ñ 10 Ñ 8.9 Ñ 8.9 nS<br />
39 CLK to BB, TIP High Impedance Ñ 12 Ñ 12 Ñ 10 Ñ 10 Ñ 8.9 Ñ 8.9 nS<br />
404<br />
4<br />
40a<br />
BCLK to BR, BB Valid (Signal Predriven)<br />
BCLK to BB Valid (signal from<br />
three-state)<br />
Ñ Ñ 2 12.6 Ñ Ñ 2 9.9 Ñ Ñ 1.5 8.8 nS<br />
2 15.4 2 13.5 2 11.8 2 10.4 1.5 10.5 1.5 9.2 nS<br />
5<br />
50 CLK to IPEND, PSTx, RSTO Valid Ñ Ñ 2 13.5 Ñ Ñ 2 10.4 Ñ Ñ 1.5 9.2 nS<br />
57 BCLK to SAS Valid 2 15.4 2 13.5 2 11.8 2 10.4 1.5 10.5 1.5 9.2 nS<br />
58 BCLK to SAS Invalid (Output Hold) 2 Ð 2 Ð 2 Ð 2 Ð 1.5 Ð 1.5 Ð nS<br />
59 BCLK to SAS High Impedance Ñ 12 Ñ 12 Ñ 10 Ñ 10 Ñ 8.9 Ñ 8.9 nS<br />
60 BCLK to TS Invalid (Output Hold) 2 Ð 2 Ð 2 Ð 2 Ð 1.5 Ð 1.5 Ð nS<br />
61 BCLK to BTT Valid 2 15.4 2 13.5 2 11.8 2 10.4 1.5 10.5 1.5 9.2 nS<br />
62 BCLK to BTT Invalid (Output Hold) 2 Ð 2 Ð 2 Ð 2 Ð 1.5 Ð 1.5 Ð nS<br />
63 BCLK to BTT High Impedance Ñ 12 Ñ 12 Ñ 10 Ñ 10 Ñ 8.9 Ñ 8.9 nS<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Unit<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Electrical and Thermal Characteristics<br />
12.7 INPUT AC TIMING SPECIFICATIONS (VCC<br />
= 3.3 V ± 5%)<br />
Num Characteristic<br />
50 MHz<br />
Min Max<br />
66 MHz<br />
Min Max<br />
75 MHz<br />
Min. Max.<br />
Unit<br />
15 Data-In Valid to BCLK (Setup) 2 Ñ 2 Ñ 2 Ñ nS<br />
16 BCLK to Data-In Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
17<br />
BCLK to Data-In High Impedance<br />
(Read Followed by Write)<br />
Ñ 11 Ñ 9 Ñ 8 nS<br />
22a TA, Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
22b TEA Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
22c TCI Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
22d TBI Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
22e TRA Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
23<br />
BCLK to TA, TEA, TCI, TBI, TRA Invalid<br />
(Hold)<br />
2 Ñ 2 Ñ 2 Ñ nS<br />
24 AVEC Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
25 BCLK to AVEC Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
41a BB Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
41b BG Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
41c CDIS, MDIS Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
41d IPL»<br />
Valid to CLK (Setup) 2 Ñ 2 Ñ 2 Ñ nS<br />
41e BTT Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
41f BGR Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
42a BCLK to BB Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
42b BCLK to BG Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
42c BCLK to CDIS, MDIS Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
42d CLK to IPLx Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
42e BCLK to BTT Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
42f BCLK to BGR Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
44a Address Valid to BCLK (Setup) 2 Ñ 1 Ñ 2 Ñ nS<br />
44c TT1 Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
44e SNOOP Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
45a BCLK to Address Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
45c BCLK to TT1 Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
45e BCLK to SNOOP Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
46 TS Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
47 BCLK to TS Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
49<br />
BCLK to BB in High Impedance<br />
(MC68060 Assumes Bus Mastership)<br />
Ñ 3 Ñ 3 Ñ 3 nS<br />
51 RSTI Valid to BCLK 2 Ñ 2 Ñ 2 Ñ nS<br />
52 BCLK to RSTI Invalid (hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
53 Mode Select Setup to BCLK (RSTI Asserted) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
54<br />
BCLK to Mode Selects Invalid (RSTI Asserted)<br />
2 Ñ 2 Ñ 2 Ñ nS<br />
64 CLA Valid to BCLK (Setup) 10 Ñ 7 Ñ 6.2 Ñ nS<br />
65 BCLK to CLA Invalid (Hold) 2 Ñ 2 Ñ 2 Ñ nS<br />
NOTE:<br />
BCLK is not a pin signal name. It is a virtual bus clock where the BCLK rising edge coincides with that of CLK when<br />
CLKEN is asserted. The BCLK falling edge is insignificant. An input timing reference to BCLK means that the specific<br />
input transitions only on rising CLK edges when CLKEN is asserted. A timing reference to CLK means that the input<br />
may transition off the rising CLK edge, regardless of CLKEN state.<br />
12-5
Electrical and Thermal Characteristics<br />
12-6<br />
CLK<br />
BCLK<br />
CLKEN<br />
RSTI<br />
D15ÐD0 in<br />
IPL2ÐIPL0<br />
Figure 12-2. Reset Configuration Timing<br />
53<br />
54<br />
MODE SELECTS REGISTERED<br />
ON PREVIOUS BCLK EDGE<br />
<strong>M68060</strong> USERÕS MANUAL<br />
51<br />
MOTOROLA
MOTOROLA<br />
CLK<br />
BCLK<br />
CLKEN<br />
ADDRESS &<br />
ATTRIBUTES<br />
TS<br />
TIP<br />
D31ÐD0 in<br />
(READ)<br />
D31ÐD0 out<br />
(WRITE)<br />
SAS<br />
TA, TRA, TEA,<br />
TBI, TCI<br />
AVEC<br />
11<br />
13<br />
14<br />
Figure 12-3. Read/Write Timing<br />
15<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Electrical and Thermal Characteristics<br />
18 21<br />
57<br />
PRECONDITIONED DATA OR WRITE DATA FROM PREVIOUS<br />
BUS CYCLE USING EXTRA DATA WRITE HOLD MODE<br />
17<br />
NOTE: Address and attributes refer to the following signals:<br />
A31ÐA0, SIZ1, SIZ0, R/W, TT1, TT0, TM2ÐTM0, TLN1, TLN0, UPA1, UPA0, CIOUT, BS3-BS0<br />
23<br />
25<br />
60<br />
22<br />
24<br />
12<br />
12<br />
16<br />
19<br />
58<br />
12-7
Electrical and Thermal Characteristics<br />
12-8<br />
CLK<br />
BCLK<br />
CLKEN<br />
ADDRESS &<br />
ATTRIBUTES<br />
TS<br />
TIP<br />
LOCK , LOCKE<br />
BB (OUT)<br />
D31ÐD0 (OUT)<br />
(WRITE)<br />
BG<br />
12<br />
12<br />
12<br />
12 39<br />
42b<br />
12<br />
41b<br />
38<br />
12<br />
60<br />
38<br />
21<br />
19<br />
42b<br />
Figure 12-4. Bus Arbitration Timing<br />
12<br />
39<br />
(SEE NOTE 1)<br />
NOTES:<br />
1. For illustrative purposes, a bus mastership hand-over is shown after a locked bus cycle sequence<br />
which adds one extra clock period between the bus mastership hand-over that would not<br />
occur for a bus mastership hand-over after a non-locked bus cycle.<br />
2. Address and attributes refer to the following signals:<br />
A31ÐA0, SIZ1, SIZ0, R/W, TT1, TT0, TM2ÐTM0, TLN1, TLN0, UPA1, UPA0, CIOUT, BS3-BS0<br />
<strong>M68060</strong> USERÕS MANUAL<br />
11a<br />
41b<br />
13<br />
14<br />
11a<br />
38<br />
40a<br />
60<br />
MOTOROLA
MOTOROLA<br />
CLK<br />
BCLK<br />
CLKEN<br />
ADDRESS &<br />
ATTRIBUTES<br />
TS<br />
SAS<br />
LOCK , LOCKE<br />
D31ÐD0 (OUT)<br />
(WRITE)<br />
BR<br />
BG<br />
BGR<br />
BTT (OUT)<br />
58<br />
12<br />
42b<br />
41f<br />
58<br />
12<br />
40<br />
41b<br />
61<br />
38<br />
12<br />
60<br />
38<br />
21<br />
19<br />
42f<br />
Figure 12-5. Bus Arbitration Timing (Continued)<br />
42b<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Electrical and Thermal Characteristics<br />
59<br />
38<br />
(SEE NOTE 1)<br />
NOTES:<br />
1. For illustrative purposes, a bus mastership hand-over is shown after a locked bus cycle sequence<br />
which adds one extra clock period between the bus mastership hand-over that would not<br />
occur for a bus mastership hand-over after a non-locked bus cycle.<br />
2. Address and attributes refer to the following signals:<br />
A31ÐA0, SIZ1, SIZ0, R/W, TT1, TT0, TM2ÐTM0, TLN1, TLN0, UPA1, UPA0, CIOUT, BS3-BS0<br />
11a<br />
57<br />
11a<br />
41b<br />
62<br />
13<br />
12<br />
60<br />
62<br />
63<br />
12-9
Electrical and Thermal Characteristics<br />
12-10<br />
CLK<br />
BCLK<br />
CLKEN<br />
ADDRESS &<br />
ATTRIBUTES<br />
TS<br />
TIP<br />
A3ÐA2<br />
CLA<br />
11<br />
13<br />
14<br />
11<br />
64<br />
NOTE: Address and attributes refer to the following signals: A31-A0, SIZ1, SIZ0, R/W, TT1, TT0, TM2-TM0, TLN1, TLN<br />
12<br />
65<br />
60<br />
Figure 12-6. CLA Timing<br />
<strong>M68060</strong> USERÕS MANUAL<br />
11<br />
64<br />
65<br />
MOTOROLA
MOTOROLA<br />
CLK<br />
BCLK<br />
CLKEN<br />
A31ÐA0<br />
TT1 (IN)<br />
SNOOP<br />
TS (IN)<br />
44a<br />
44c<br />
44e<br />
47<br />
Figure 12-7. Snoop Timing<br />
<strong>M68060</strong> USERÕS MANUAL<br />
Electrical and Thermal Characteristics<br />
46<br />
45c<br />
45e<br />
45a<br />
12-11
Electrical and Thermal Characteristics<br />
12-12<br />
CLK<br />
CLKEN<br />
BCLK<br />
RSTI<br />
CDIS, MDIS<br />
BB (IN)<br />
BTT (IN)<br />
CLK<br />
IPEND<br />
RSTO<br />
PST4ÐPST0<br />
IPL2ÐIPL0<br />
41c<br />
41a<br />
41e<br />
41d<br />
50<br />
50<br />
50<br />
Figure 12-8. Other Signals Timing<br />
<strong>M68060</strong> USERÕS MANUAL<br />
51<br />
42c<br />
42a<br />
42e<br />
42d<br />
52<br />
49<br />
12<br />
12<br />
12<br />
MOTOROLA
Ordering Information and Mechanical Data<br />
SECTION 13<br />
ORDERING INFORMATION AND MECHANICAL DATA<br />
This section contains the ordering information, pin assignments, and package dimensions<br />
of the MC68060, MC68LC060, and MC68EC060.<br />
13.1 ORDERING INFORMATION<br />
The following table provides ordering information pertaining to the MC68060, MC68LC060,<br />
and MC68EC060 package types, frequencies, temperatures, and Motorola order numbers.<br />
Package Type Frequency<br />
13.2 PIN ASSIGNMENTS<br />
Maximum Junction<br />
Temperature<br />
Minimum Ambient<br />
Temperature<br />
Order Number<br />
PGA—RC Suffix 50 MHz 110°<br />
C 0°<br />
C MC68060RC50<br />
PGA—RC Suffix 66 MHz 110°<br />
C 0°<br />
C MC68060RC66<br />
PGA—RC Suffix 50 MHz 110°<br />
C 0°<br />
C MC68LC060RC50<br />
PGA—RC Suffix 66 MHz 110°<br />
C 0°<br />
C MC68LC060RC66<br />
PGA—RC Suffix 75 MHz 110°<br />
C 0°<br />
C MC68LC060RC75<br />
PGA—RC Suffix 50 MHz 110°<br />
C 0°<br />
C MC68EC060RC50<br />
PGA—RC Suffix 66 MHz 110°<br />
C 0°<br />
C MC68EC060RC66<br />
PGA—RC Suffix 75 MHz 110°<br />
C 0°<br />
C MC68EC060RC75<br />
The following are the pin assignments for the MC68060, MC68LC060, and MC68EC060<br />
package types.<br />
13-1 <strong>M68060</strong> USER’S MANUAL MOTOROLA
Ordering Information and Mechanical Data<br />
13.2.1 MC68060, MC68LC060, and MC68EC060 Pin Grid Array (RC Suffix)<br />
T<br />
S<br />
R<br />
Q<br />
P<br />
N<br />
M<br />
L<br />
K<br />
J<br />
H<br />
G<br />
F<br />
E<br />
D<br />
C<br />
B<br />
A<br />
A29<br />
TDO TRST JTAG CDIS IPL2 IPL1 IPL0 TCI AVEC BG TA PST0 PST3 BB BR<br />
IPEND EVSS TDI TCK TMS MDIS RSTI IVDD IVSS IVSS TBI TEA PST1 EVSS EVDD EVSS LOCK<br />
CIOUT EVDD RSTO IVSS IVDD IVSS IVDD CLK IVSS IVDD IVSS PST2 TIP TS EVDD LOCKE<br />
UPA1 EVSS UPA0<br />
A10 TT1 TT0<br />
A12 EVSS A11<br />
A13<br />
EVDD<br />
A14 EVSS IVSS<br />
A15 A16 IVSS<br />
A17 A19<br />
A18 EVSS<br />
A20 EVDD A23<br />
A21 EVSS A25<br />
A22 A26 A28<br />
A24 EVSS A30<br />
A27 EVDD D0 D2 IVDD IVSS IVSS IVDD IVSS IVDD IVSS IVDD IVSS IVDD D23<br />
EVSS D1 EVSS EVDD EVSS D8 EVSS EVDD EVSS D16 D18 EVSS EVDD EVSS<br />
A31 D3 D4 D5 D6 D7 D9 D10 D11 D12 D13 D14 D15 D17 D19<br />
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18<br />
Pin Groups GND (VSS) VCC (VDD)<br />
Internal Logic<br />
Output Drivers<br />
IVDD<br />
IVDD<br />
IVDD<br />
BS0 BS1 BS2 BS3 CLKEN EVSS EVDD BGR TRA PST4 SAS BTT<br />
EVDD<br />
EVDD<br />
EVDD<br />
IVSS<br />
EVDD<br />
EVSS<br />
EVDD<br />
223 PIN LOCATIONS—206 USED<br />
18 x 18 CAVITY DOWN PGA<br />
122 SIGNAL PINS<br />
50 EVDD/EVSS<br />
34 IVDD/IVSS<br />
17 NO CONNECT<br />
C6, C7, C9, C11, C13, F15, H4, H15,K3,<br />
K16, L3, M16, R4, R6, R11, R13, S9, S10<br />
B2, B4, B6, B8, B10, B13, B15, B17, D2,<br />
D17, F2, F4, F17, H2, H17, L2, L17, N2, N17,<br />
Q2, Q9, Q17, S2, S15, S17<br />
SNOOP SIZ1<br />
C5, C8, C10, C12, C14, E15, H3, H16, J3,<br />
J16, L16, M3, R5, R8, R12, S8<br />
B5, B9, B14, C2, C17, D8, D10, D12, D15,<br />
E4, G2, G4, G15, G17, J4, J15, L4, M2, M17,<br />
N15, P4, Q10, R2, R17, S16<br />
13-2 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
EVDD<br />
THERM1<br />
THERM0<br />
CLA<br />
EVDD<br />
IVSS<br />
EVDD<br />
IVSS<br />
IVDD<br />
EVDD EVDD EVDD<br />
EVDD<br />
R/W<br />
IVSS<br />
IVDD<br />
IVSS<br />
IVDD<br />
IVDD<br />
EVSS TLN0<br />
SIZ0<br />
EVSS<br />
EVDD<br />
TM0<br />
EVSS A0<br />
TM2<br />
TLN1<br />
TM1<br />
A1<br />
A2 A3<br />
EVSS A4<br />
A6 EVDD A5<br />
A9 EVSS A7<br />
D29 D30 A8<br />
D27 EVSS D31<br />
D25 EVDD D28<br />
D22 EVSS D26<br />
D20 D21 D24
13.2.2 MC68060, MC68LC060, and MC68EC060<br />
IVDD<br />
IVSS<br />
RST0<br />
EVSS<br />
TD0<br />
EVDD<br />
TMS<br />
JTAG<br />
BS0<br />
EVSS<br />
BS1<br />
EVDD<br />
BS2<br />
BS3<br />
MDIS<br />
CDIS<br />
IVSS<br />
IVDD<br />
RSTI<br />
IPL2<br />
IPL1<br />
IPL0<br />
CLKEN<br />
IVSS<br />
CLK<br />
IVSS<br />
IVSS<br />
TCI<br />
AVEC<br />
TBI<br />
IVSS<br />
IVDD<br />
BGR<br />
BG<br />
TRA<br />
TEA<br />
TA<br />
PST0<br />
PST1<br />
EVDD<br />
PST2<br />
EVSS<br />
PST3<br />
PST4<br />
IVDD<br />
IVSS<br />
SAS<br />
BTT<br />
EVSS<br />
EVDD<br />
TS<br />
TIP<br />
Ordering Information and Mechanical Data<br />
PIN GROUPS GND (VSS) VCC (VDD)<br />
Internal Logic<br />
Output Drivers<br />
TCK<br />
TRST<br />
TDI<br />
IPEND<br />
EVSS<br />
CIOUT<br />
EVDD<br />
UPA0<br />
UPA1<br />
IVSS<br />
IVDD<br />
IVSS<br />
TT0<br />
TT1<br />
EVSS<br />
A10<br />
EVDD<br />
A11<br />
A12<br />
EVSS<br />
A13<br />
EVDD<br />
A14<br />
A15<br />
IVDD<br />
IVSS<br />
A16<br />
A17<br />
EVSS<br />
A18<br />
EVDD<br />
A19<br />
A20<br />
EVSS<br />
A21<br />
EVDD<br />
A22<br />
A23<br />
IVDD<br />
IVSS<br />
A24<br />
A25<br />
EVSS<br />
A26<br />
EVDD<br />
A27<br />
A28<br />
EVSS<br />
A29<br />
EVDD<br />
A30<br />
A31<br />
208 183<br />
157<br />
1<br />
156<br />
26<br />
52<br />
53<br />
IVSS<br />
IVDD<br />
SNOOP<br />
BB<br />
THERM1<br />
EVSS<br />
(TOP VIEW)<br />
208 PIN CQFP<br />
122 SIGNAL PINS<br />
50 EVDD/EVSS<br />
36 IVDD/IVSS<br />
QFP PACKAGE NOT AVAILABLE<br />
UPDATED 3/25/98<br />
BR<br />
EVDD<br />
LOCK<br />
LOCKE<br />
IVDD<br />
IVSS<br />
TLN0<br />
SIZ0<br />
EVSS<br />
SIZ1<br />
EVDD<br />
THERM0<br />
R/W<br />
TLN1<br />
EVSS<br />
TM0<br />
EVDD<br />
TM1<br />
TM2<br />
IVDD<br />
IVSS<br />
A0<br />
A1<br />
EVDD<br />
CLA<br />
EVSS<br />
A2<br />
A3<br />
EVSS<br />
A4<br />
IVDD<br />
IVSS<br />
A5<br />
2, 17, 24, 26, 27, 31, 46, 53, 64, 79, 90, 106,<br />
113, 128, 142, 155, 169, 183, 197, 199<br />
4, 10, 42, 49, 58, 67, 73, 84, 87, 95, 100, 109,<br />
117, 122, 131, 136, 145, 150, 161, 166, 175,<br />
180, 189, 194, 204<br />
105<br />
78 104<br />
1, 18, 32, 53, 63, 78, 89, 105, 114, 127, 141,<br />
156, 170, 184, 198<br />
6, 12, 40, 50, 60, 69, 75, 82, 92, 97, 102, 111,<br />
119, 124, 133, 138, 147, 152, 159, 164, 173,<br />
178, 187, 192, 202<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL 13-3<br />
EVDD<br />
A6<br />
A7<br />
EVSS<br />
A8<br />
EVDD<br />
A9<br />
D31<br />
EVSS<br />
D30<br />
EVDD<br />
D29<br />
D28<br />
131<br />
IVDD<br />
IVSS<br />
D0<br />
D1<br />
EVDD<br />
D2<br />
EVSS<br />
D3<br />
D4<br />
EVDD<br />
D5<br />
EVSS<br />
D6<br />
D7<br />
IVSS<br />
IVDD<br />
D8<br />
D9<br />
EVDD<br />
D10<br />
EVSS<br />
D11<br />
D12<br />
EVDD<br />
D13<br />
EVSS<br />
D14<br />
D15<br />
IVSS<br />
IVDD<br />
D16<br />
D17<br />
EVDD<br />
D18<br />
EVSS<br />
D19<br />
D20<br />
EVDD<br />
D21<br />
EVSS<br />
D22<br />
D23<br />
IVDD<br />
IVSS<br />
D24<br />
EVDD<br />
D25<br />
EVSS<br />
D26<br />
D27<br />
IVSS<br />
IVDD
Ordering Information and Mechanical Data<br />
13.3 MECHANICAL DATA<br />
Figure 13-1 illustrates the MC68060, MC68LC060 and MC68EC060 PGA package dimensions.<br />
Figure 13-2 illustrates the MC68060, MC68LC060, and MC68EC060 CQFP package<br />
dimensions. Due to space limitation, Figure 13-2 is represented by a general (smaller) package<br />
outline rather than showing all 208 leads.<br />
MC68060 PGA<br />
CASE NUMBER: 993A-01<br />
DIM<br />
A<br />
B<br />
C<br />
D<br />
G<br />
K<br />
PIN A1 INDICATOR<br />
– A –<br />
– T –<br />
A K<br />
G<br />
MILLIMETERS INCHES<br />
MIN MAX<br />
46.74 47.75<br />
46.74 47.75<br />
2.79 3.05<br />
0.41 0.51<br />
2.54 BSC<br />
3.81 4.32<br />
B<br />
– B –<br />
C<br />
MIN MAX<br />
1.840 1.880<br />
1.840 1.880<br />
0.110 0.140<br />
0.016 0.020<br />
0.100 BSC<br />
0.150 0.170<br />
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18<br />
Figure 13-1. PGA Package Dimensions (RC Suffix)<br />
13-4 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
D<br />
T<br />
S<br />
R<br />
Q<br />
P<br />
N<br />
M<br />
L<br />
K<br />
J<br />
H<br />
G<br />
F<br />
E<br />
D<br />
C<br />
B<br />
A<br />
206 PLACES<br />
.020 (.51) M T A M B M<br />
.008 (.20) M T<br />
NOTES:<br />
1. DIMENSIONS AND TOLERANCING PER<br />
ANSI Y14.5M 1982.<br />
2. CONTROLLING DIMENSION: INCH<br />
G
Ordering Information and Mechanical Data<br />
MC68060 CQFP<br />
4 x 52 TIPS<br />
CASE NUMBER: 994-01 ∩ 0.20 (0.008) H A – B D<br />
U<br />
DETAIL "A"<br />
C<br />
C<br />
SEATING<br />
PLANE<br />
E<br />
P<br />
W<br />
A, B, D<br />
DIM<br />
MILLIMETERS<br />
MIN MAX<br />
INCHES<br />
MIN MAX<br />
A 26.86 27.75 1.057 .1.093<br />
B 26.86 27.75 1.057 .1.093<br />
C — 4.15 — 0.163<br />
D 0.18 0.27 0.007 0.011<br />
E 3.00 3.70 0.118 0.146<br />
F 0.17 0.23 0.007 0.009<br />
G .0.50 BSC<br />
0.020 BSC<br />
W 0.25 — 0.010 —<br />
J 0.13 0.18 0.005 0.007<br />
K 0.45 0.55 0.018 0.022<br />
U 15.30 BSC 0.602 BSC<br />
P 0.25 BSC 0.010 BSC<br />
θ2 1° 7° 1° 7°<br />
R 0.15 REF 0.006 REF<br />
S 30.60 BSC 1.205 BSC<br />
U 15.30 BSC 0.602 BSC<br />
V 30.60 BSC 1.205 BSC<br />
AB 0.95 REF 0.037 REF<br />
AA 1.80 REF<br />
0.071 REF<br />
Y 15.30 BSC 0.602 BSC<br />
Z 0.12 0.13 0.005 0.005<br />
θ1 1° 7° 1° 7°<br />
V<br />
Y<br />
A<br />
156<br />
157<br />
J<br />
BASE METAL<br />
G<br />
208<br />
D<br />
DETAIL "B"<br />
A<br />
S<br />
DETAIL "B"<br />
DETAIL "A"<br />
1 52<br />
F<br />
D<br />
Z<br />
Figure 13-2. QFP Package Dimensions (FE Suffix)<br />
13-5 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
105<br />
104<br />
53<br />
B<br />
0.13 (0.005) M C A – B S D S<br />
H<br />
B<br />
0.20 (0.008) M H A – B S D S<br />
DATUM<br />
PLANE<br />
H<br />
DETAIL "C"<br />
DATUM<br />
PLANE<br />
∩ 0.1 (0.004 )<br />
S S<br />
UPDATED 3/25/98<br />
DETAIL "C"<br />
Θ1<br />
R<br />
R<br />
K<br />
AB Θ2<br />
AA<br />
NOTES:<br />
1. DIMENSIONING AND TOLERANCING PER ANSI Y14.5M, 1982.<br />
2. CONTROLLING DIMENSION: MILLIMETER. INCHES ARE IN "( )".<br />
3. DATUM PLANE -H- IS LOCATED AT BOTTOM OF LEAD AND IS<br />
COINCIDENT WITH THE LEAD WHERE THE LEAD EXITS THE<br />
PLASTIC BODY AT THE BOTTOM OF THE PARTING LINE.<br />
4. DATUMS -A-, -B-, AND -D- TO BE DETERMINED AT DATUM PLANE -H-.<br />
5. DIMENSIONS S AND V TO BE DETERMINED AT SEATING PLANE -C-.<br />
6. DIMENSIONS A AND B DEFINE MAXIMUM CERAMIC BODY DIMENSIONS<br />
INCLUDING GLASS PROTRUSION AND MISMATCH OF CERAMIC BODY<br />
TOP AND BOTTOM.<br />
QFP PACKAGE NOT AVAILABLE
APPENDIX A<br />
MC68LC060<br />
The MC68LC060 is a derivative of the MC68060. The MC68LC060 has the same execution<br />
unit and MMU as the MC68060, but has no FPU. The MC68LC060 is 100% pin compatible<br />
with the MC68060. Disregard all information concerning the FPU when reading this manual.<br />
The following difference exists between the MC68LC060 and the MC68060:<br />
• The MC68LC060 does not contain an FPU. When floating-point instructions are encountered,<br />
a floating-point disabled exception is taken.<br />
• Bits 31–16 of the processor configuration register contain 0000010000110001, identifying<br />
the device as an MC68LC/EC060.<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
A-1
APPENDIX B<br />
MC68EC060<br />
The MC68EC060 is a derivative of the MC68060. The MC68EC060 has the same execution<br />
unit as the MC68060, but has no FPU or paged MMU, which embedded control applications<br />
generally do not require. Disregard information concerning the FPU and MMU when reading<br />
this manual. The MC68EC060 is pin compatible with the MC68060. The following differences<br />
exist between the MC68EC060 and the MC68060:<br />
• The MC68EC060 does not contain an FPU. When floating-point instructions are encountered,<br />
a floating-point disabled exception is taken.<br />
• Bits 31–16 of the processor configuration register contain 0000010000110001, identifying<br />
the device as an MC68LC/EC060.<br />
• The MDIS pin name has been changed to the JS0 pin and is included for boundary scan<br />
purposes only.<br />
B.1 ADDRESS TRANSLATION DIFFERENCES<br />
Although the MC68EC060 has no paged MMU, the four TTRs (ITT0, ITT1, DTT0, and DTT1)<br />
and the default transparent translation (defined by certain bits in the TCR) operate normally<br />
and can still be used to assign cache modes and supervisor and write protection for given<br />
address ranges. All addresses can be mapped by the four TTRs and the default transparent<br />
translation.<br />
B.2 INSTRUCTION DIFFERENCES<br />
The PFLUSH and PLPA instructions, the SRP and URP registers, and the E- and P-bits of<br />
the TCR are not supported by the MC68EC060 and must not be used. Use of these instructions<br />
and registers in the MC68EC060 exhibits poor programming practice since no useful<br />
results can be achieved. Any functional anomalies that may result from their use will require<br />
system software modification (to remove offending instructions) to achieve proper operation.<br />
The PLPA instruction operates normally except that when an address misses in the four<br />
TTRs, instead of performing a table search operation, the access cache mode and write protection<br />
properties are defined by the default transparent translation bits in the TCR. The<br />
address register contents are never changed since all addresses are always transparently<br />
translated. The PLPA instruction can only generate an access error exception only on supervisor<br />
or write protection violation cases. The PFLUSH instruction operates as a virtual NOP<br />
instruction.<br />
When the MOVEC instruction is used to access the SRP and URP registers and the E- and<br />
P-bits in the TCR, no exceptions are reported. However, those bits are undefined for the<br />
MC68EC060 and must not be used.<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
B-1
APPENDIX C<br />
MC68060 SOFTWARE PACKAGE<br />
The purpose of the <strong>M68060</strong> software package (<strong>M68060</strong>SP) is to supply, for a target operating<br />
system, system exception handlers and user library software that provide:<br />
• Software emulation for integer instructions not implemented in MC68060 hardware via<br />
the new unimplemented integer instruction exception.<br />
• System V ABI-compliant library subroutines to help avoid using unimplemented integer<br />
instructions.<br />
• IEEE floating-point support for the on-chip floating-point unit (FPU) as well as software<br />
emulation of floating-point instructions, data types, and addressing modes not implemented<br />
in MC68060 hardware.<br />
• System V ABI-compliant library subroutines to help avoid using unimplemented floating-point<br />
instructions.<br />
The design goals in implementing the <strong>M68060</strong>SP are as follows:<br />
• Position-independent code<br />
• Re-entrant code<br />
• Object code size of less than 64 Kbytes for the complete kernel release<br />
• No assembly-code-to-assembly-code conversion software required<br />
• Minimum assembly code compilation required for system integration<br />
• One-time port; future upgrades done by software patch instead of recompilation<br />
• Easily downloadable from a bulletin board<br />
The <strong>M68060</strong>SP is divided into five separate modules. This partitioning provides system integrators<br />
flexibility in choosing portions of the <strong>M68060</strong>SP that are applicable to their system.<br />
For instance, a system using the MC68EC060 or MC68LC060 has no use for the floatingpoint<br />
related modules. The following modules are provided:<br />
1. Unimplemented integer instruction exception handler<br />
2. Unimplemented integer instruction library<br />
3. Full floating-point kernel exception handlers<br />
4. Partial floating-point kernel exception handlers<br />
5. Floating-point library<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
C-1
MC68060 Software Package<br />
Each module has pre-defined addresses used by the target operating system as entry points<br />
into the <strong>M68060</strong>SP routines. These pre-defined addresses will remain unchanged to ensure<br />
that future releases of the <strong>M68060</strong>SP do not require recompilation.<br />
The three kernel modules require some system-dependent subroutines to be supplied by<br />
the target system. These modules also contain a call-out dispatch table. Each entry in the<br />
call-out dispatch table represents an external function needed by that module. The call-out<br />
dispatch table must be filled by the system integrator with the relative address (relative to<br />
the top of the module) of the desired external function. This module-relative addressing<br />
ensures full position independence.<br />
C.1 MODULE FORMAT<br />
Each module consists of the following parts:<br />
1. Call-out Dispatch Table<br />
2. Entry-point Dispatch Section<br />
3. Code section<br />
The call-out dispatch table is used by the module to reference external functions. The unimplemented<br />
integer and floating-point library modules do not require call-out dispatch tables.<br />
For the other three modules, the call-out dispatch table contains a maximum of 32 call-out<br />
entries. Each entry is 4 bytes long; hence, the call-out dispatch table size is 128 bytes. This<br />
table must be supplied by the system integrator. Each entry must contain the relative<br />
addresses of external functions, relative to the top of the call-out table.<br />
For example, if the call-out dispatch table defines the first location to be the _mem_read<br />
entry and the third entry defines the _mem_write entry, the table appears as shown in Figure<br />
C-1.<br />
C-2<br />
_top:<br />
xref _mem_read, _mem_write<br />
xdef _top<br />
dc.l _mem_read - _top<br />
dc.l _mem_write - _top<br />
•<br />
•<br />
•<br />
dc.l $00000000<br />
* End of Call-out Dispatch Table. The module (pseudo-assembly module) must<br />
* immediately follow:<br />
Figure C-1. Call-Out Dispatch Table Example<br />
The MC68060SP release has an example call-out dispatch table for each module. Since the<br />
call-out dispatch table is system dependent, it is placed in a file separate from the next two<br />
sections of the module. Care must be taken when porting the MC68060SP to ensure that<br />
each module is kept intact.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
The next two sections of the module do not require system customizing. To provide these<br />
sections in a “black box”, they are packaged in “pseudo-assembly” files. The main advantage<br />
of this method of packaging is that changing the syntax of this pseudo-assembly file<br />
can be done by any word processor with global search and replace capability. Also, when it<br />
is time to update the MC68060SP, only these pseudo-assembly files need to be replaced,<br />
the system customized code does not need modification.<br />
Figure C-2 shows an example pseudo-assembly file.<br />
dc.l $60ff0000,$20920000,$60ff0000,$1f5c0000<br />
dc.l $60ff0000,$0d040000,$60ff0000,$0eb80000<br />
dc.l $60ff0000,$24300000,$60ff0000,$22ca0000<br />
•<br />
•<br />
•<br />
dc.l $00000000,$00000000,$00000000,$00000000<br />
Figure C-2. Example Pseudo-Assembly File<br />
The Entry-point Dispatch Section must immediately follow the call-out dispatch table (kernel<br />
modules only). The function entry points are implemented as address offsets from the top<br />
of the module. Each function entry point is eight bytes in width. Each entry point contains an<br />
unconditional branch to another location within the code section. This feature ensures that<br />
future releases of the module would not necessitate a recompile of the system-customized<br />
software envelope.<br />
For example, consider the case of the <strong>M68060</strong>SP floating-point kernel module. This module<br />
has a 128-byte call-out dispatch table. Assuming that a symbol _060FPSP_TOP points to<br />
the top of the module, and a jump to the third function of the module is needed, the system<br />
call is as such:<br />
bra _060FPSP_TOP+128+(2*8)<br />
To gain additional performance, it is possible to avoid the double-branch penalty through the<br />
Entry-point Dispatch Section by determining the branch target of each entry point into the<br />
associated code section function addresses. However, this may make it more difficult to<br />
upgrade to future releases without recompiling software envelopes that call into the<br />
<strong>M68060</strong>SP.<br />
The code section contains the actual <strong>M68060</strong>SP software. If the code section requires a call<br />
to an external function, it calculates the address of the external function given the information<br />
contained in the appropriate call-out entry. The code section is normally entered via a<br />
branch instruction from the entry-point dispatch section.<br />
Figure C-3 provides a visual example of the module interface. The symbol names outside<br />
the boxes represent global symbol names defined by the system integrator. Internal symbols<br />
used by the <strong>M68060</strong>SP source code are represented as labels inside the boxes. Note<br />
that the call-out code example contains approximate code and is shown to emphasize that<br />
module-relative address needs to be filled into the call-out dispatch table.<br />
C-3
MC68060 Software Package<br />
C-4<br />
_done:<br />
CALL-OUT DISPATCH<br />
TABLE MUST IMMEDIATELY<br />
PRECEDE THE THE ENTRY-<br />
POINT SECTION<br />
CALLING ROUTINE<br />
bra _top+func_offset<br />
next instruction<br />
Figure C-3. Module Call-In, Call-Out Example<br />
Table C-1 shows the code size of each module.<br />
Table C-1. Call-Out Dispatch Table and Module Size<br />
Module Name<br />
_top<br />
MODULE FUNCTIONS<br />
ARE FIXED OFFSETS<br />
FROM THE LABEL _top<br />
_top+func_offset<br />
MODULE<br />
CALL-OUT DISPATCH TABLE<br />
L1: _call_out - _top<br />
L2: _done - _top<br />
ENTRY-POINT DISPATCH SECTION<br />
bra f1<br />
CODE SECTION<br />
f1: Actual func code<br />
*Do a call-out<br />
lea _top,A0<br />
add.1 L1,A0<br />
jsr (a0)<br />
next instruction<br />
lea _top,A0<br />
add.1 L2,A0<br />
jmp (a0)<br />
Call-Out Dispatch<br />
Table Size<br />
C.2 UNIMPLEMENTED INTEGER INSTRUCTIONS<br />
The MC68060 left some low-use integer instructions unimplemented to streamline internal<br />
operations. This results in overall system performance improvement at the expense of software<br />
emulation of the unimplemented integer instructions. The <strong>M68060</strong>SP provides user<br />
object-code compatibility by providing the code needed to emulate these instructions via the<br />
unimplemented integer instruction exception. The <strong>M68060</strong>SP also provides a software<br />
<strong>M68060</strong> USER’S MANUAL<br />
THE ENTRY-POINT AND CODE<br />
SECTIONS ARE INTHE<br />
PSEUDO-ASSEMBLY FILE<br />
_call_out: call_out code here<br />
Entry-Point + Code<br />
Section Size<br />
OPERATING SYSTEM-SUPPLIED CODE<br />
Total Module<br />
Size<br />
Unimplemented Integer 128 bytes 8K-128 bytes 8K bytes<br />
Unimplemented Integer Instruction Library 0 bytes 4K bytes 4K bytes<br />
Full Floating-Point Kernel 128 bytes 56K-128 bytes 56K bytes<br />
Floating-Point Library 0 bytes 34K bytes 34K bytes<br />
Partial Floating-Point Kernel 128 bytes 35K-128 bytes 35K bytes<br />
rts<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
library that can be used to avoid these unimplemented instructions for new programs that<br />
can be recompiled.<br />
The unimplemented integer instructions include 64-bit divide and multiply, move peripheral<br />
data, CMP2, CHK2, and CAS2. In addition, CAS used with a misaligned effective address<br />
is also unimplemented. Refer to the M68000 Family Programmer’s Reference <strong>Manual</strong><br />
(M68000PM/AD) for details on the operation of these instructions. The unimplemented<br />
integer instructions are:<br />
DIVU.L ,Dr:Dq 64/32 ⇒ 32r,32q<br />
DIVS.L ,Dr:Dq 64/32 ⇒ 32r,32q<br />
MULU.L ,Dr:Dq 32*32 ⇒ 64<br />
MULS.L ,Dr:Dq 32*32 ⇒ 64<br />
MOVEP Dx,(d16,Ay) size = W or L<br />
MOVEP (d16,Ay),Dx size = W or L<br />
CHK2 ,Rn size = B, W, or L<br />
CMP2 ,Rn size = B, W, or L<br />
CAS2 Dc1:Dc2,Du1:Du2,(Rn1):(Rn2) size = W or L<br />
CAS Dc,Du, size = W or L, misaligned <br />
C.2.1 Integer Emulation Results<br />
Numerical and condition code results produced by the MC68060ISP (see C.2.2 Module 1:<br />
Unimplemented Integer Instruction Exception (MC68060ISP) ) are equivalent to those in<br />
previous M68000 family processors. In addition, as with the MC68060 hardware, if any condition<br />
code bits are stated as undefined for the exceptional instruction, then they remain<br />
unchanged from the previous instruction.<br />
C.2.2 Module 1: Unimplemented Integer Instruction Exception<br />
(MC68060ISP)<br />
When the MC68060 encounters an unimplemented integer instruction, the MC68060 initiates<br />
exception processing at vector number 61. A type $0, four-word stack frame is created.<br />
The stack frame’s stacked program counter (PC) points to the unimplemented integer<br />
instruction.<br />
The <strong>M68060</strong>SP determines the instruction that caused the exception and emulates the<br />
instruction using implemented integer instructions. This emulation includes the proper condition<br />
code effects as produced by the instruction if it had been implemented in hardware.<br />
No floating-point instructions are used within this module (to ensure that this module can be<br />
used for the MC68LC060 and MC68EC060).<br />
When emulating the unimplemented integer instructions, there are conditions that require<br />
the <strong>M68060</strong>SP to emulate an exception. The <strong>M68060</strong>SP emulates an exception by cleaning<br />
up the stack to the conditions prior to executing the exception handler, converting the original<br />
stack frame to the appropriate stack frame, and then branching to those system-supplied<br />
exception handlers.<br />
C-5
MC68060 Software Package<br />
C.2.2.1 UNIMPLEMENTED INTEGER INSTRUCTION EXCEPTION MODULE ENTRY<br />
POINTS. The _isp_unimp function is implemented such that the unimplemented integer<br />
instruction exception vector table entry typically points directly to _isp_unimp. If the system<br />
software chooses to perform operations prior to entering the _isp_unimp function, it may do<br />
so as long as the system stack points to the exception stack frame at the time of entry.<br />
C.2.2.2 UNIMPLEMENTED INTEGER INSTRUCTION EXCEPTION MODULE CALL-<br />
OUTS. The call-outs _real_trace, _real_chk, _real_divbyzero, and _real_access are defined<br />
to provide the system integrator a choice of either having the module point directly to the<br />
actual trace, chk, divide-by-zero, and access error handler, or to an alternate routine that<br />
would fetch the address of the exception handler from the vector table prior to jumping to<br />
the actual handlers. The direct implementation is ideal for systems that do not anticipate any<br />
changes to the vector table and performance is more critical. The indirect approach of consulting<br />
the vector table is more accurate in that if the instruction were implemented, the<br />
actual handler’s address is fetched from the appropriate vector table entry before branching<br />
there.<br />
Other call-outs which are common to the floating-point kernel module are discussed in C.4<br />
Operating System Dependencies.<br />
These call-outs include the discussion of the<br />
_real_access and other operating-system-dependent functions.<br />
The _isp_done call-out is provided as a means for the system to do any clean-up, if any is<br />
necessary, before executing the RTE instruction to return to normal instruction execution.<br />
The unimplemented integer instruction exception handler will either branch to this call-out or<br />
create an appropriate exception frame and branch to the call-outs _real_trace, _real_chk,<br />
_real_divbyzero, or _real_access routines as outlined previously.<br />
C.2.2.3 CAS MISALIGNED ADDRESS AND CAS2 EMULATION-RELATED CALL-OUTS<br />
AND ENTRY POINTS. The CAS instruction with misaligned address and CAS2 emulation<br />
is the most system dependent of all MC68060ISP code. The emulation code may require<br />
interaction with a system’s interrupt, paging and access error recovery mechanisms. The<br />
emulation algorithm uses the MOVEC of the BUSCR register to assert the LOCK and<br />
LOCKE signals during emulation. The following is a description of the main steps in the emulation<br />
process:<br />
1. Decode instruction and fetch all data from registers as necessary. In addition, if any of<br />
the operand pages are non-resident, then they must be paged in and not be allowed<br />
to be paged out or marked invalid for any reason until the emulation process ends. For<br />
each operand address, the MC68060ISP calls _real_lock_page() which must be provided<br />
by the host operating system to “lock” the pages. This routine should also check<br />
to see if the address passed is valid and writable. If not, then an error result should be<br />
returned to the MC68060ISP.<br />
2. The MC68060ISP then calls the “core” emulation code for either “cas” or “cas2”. The<br />
MC68060ISP references the “core” routines by calling either the _real_cas() or<br />
_real_cas2() call-outs. If the emulation code provided is sufficient for a given system,<br />
then the system integrator can make these call-outs immediately re-enter the package<br />
by calling either _isp_cas() or _isp_cas2() entry points.These entry points will perform<br />
the required emulation. If the “core” routines provided need to be replaced by a more<br />
C-6<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
system-specific solution, then the new user-generated emulation code should supply<br />
the routines via the _real_cas()/_real_cas2() call-outs, and should then re-enter the<br />
MC68060ISP through the entry point _isp_cas_finish() or _isp_cas2_finish() when<br />
complete.<br />
3. After emulation is completed, the pages which may have been “locked” from being<br />
paged out earlier must now be “unlocked”. To accomplish this, the MC68060ISP executes<br />
a _real_unlock_page() call-out for each operand.<br />
For most systems, the entry-points _isp_cas() and _isp_cas2() routines should provide sufficient<br />
emulation results. However, it is up to the system integrator to judge whether or not<br />
these routines are sufficient, or that a more system-specific solution is needed. The following<br />
is a description of some aspects of the _isp_cas() and _isp_cas2() emulation code.<br />
1. Interrupt levels 0-6 are immediately masked. If the appropriate pages have been<br />
paged in and have been checked for write permission in _real_lock_page(), then only<br />
physical bus errors can occur within this code sequence. The routine restores the previous<br />
interrupt mask level upon completion of the algorithm. (Note: if a system, by design,<br />
allows level 7 interrupts to occur while emulating the CAS or CAS2 instructions,<br />
then the operand data corruption may occur. External hardware may be added to the<br />
system to physically mask all interrupts whenever LOCK is asserted.)<br />
2. The operand ATC is loaded for each operand using the PLPAW instruction. In addition,<br />
any fresh cache entries corresponding to the operands are pushed from the<br />
cache using CPUSHL instruction. Note: the MC68040 processor initiated the pushes,<br />
if necessary, within the locked bus region. MC68060 hardware, however, pushes the<br />
cache lines, if necessary, outside of the locked bus region for TAS and aligned CAS<br />
instructions. The MC68060ISP emulates the MC68060 processor approach.<br />
3. The main algorithm steps are pre-fetched into the instruction cache if the cache is enabled.<br />
The algorithm attempts to allow only operand data bus accesses during the<br />
locked bus instruction sequence. This strategy reduces the number of cycles that the<br />
LOCK signal will be asserted.<br />
4. Before performing the read(s)/write(s), the bus LOCK signal is asserted by the emulation<br />
code by using the MOVEC of the BUSCR register. All reads and writes when<br />
LOCK is asserted will be precise. LOCK will not actually appear on the bus until the<br />
first bus read cycle.<br />
5. The LOCKE signal will be asserted for the final operand write of the emulation sequence.<br />
6. The actual read(s)/write(s) are performed using the MOVES instruction for both user<br />
and supervisor accesses. The system DFC is set to the appropriate mode before executing<br />
MOVES and PLPAW instructions.<br />
C-7
MC68060 Software Package<br />
Assuming that the system integrator elects to use the _isp_cas() and _isp_cas2() entry<br />
points for instruction emulation, three routines are made available to the access error exception<br />
handler to provide more options when a bus error (TEA) is encountered when in these<br />
critical routines:<br />
1. _isp_cas_inrange(): Accepts an instruction address as an input argument and returns<br />
a failing or passing value corresponding to whether the address is within the<br />
_isp_cas() or _isp_cas2() code region. This function can be used within a system’s access<br />
error handler to determine if a PLPA or MOVES instruction has incurred a bus<br />
error (TEA asserted) within the _isp_cas() or _isp_cas2() code region.<br />
2. _isp_cas_restart(): If an access error handler encounters a recoverable physical bus<br />
error (TEA asserted) and the _isp_cas_inrange() routine returns an “in-range” value,<br />
then the operand read/write sequence will be restarted through this entry point. Note<br />
that by design of the MC68060, any exception occurring while LOCK is asserted automatically<br />
negates it.<br />
3. _isp_cas_terminate(): If an access error handler encounters a non-recoverable physical<br />
bus error (TEA asserted) and the _isp_cas_inrange() routine returns an “in-range”<br />
value, it can re-enter the package through this entry point. The package creates a new<br />
access error frame.<br />
As long as the _real_lock_page() routine operates properly, only physical bus errors caused<br />
by the PLPA or MOVES instructions can occur within the critical code sequence. It is the<br />
access error handler’s responsibility to determine whether or not it is appropriate to restart<br />
the locked sequence or to terminate the CAS or CAS2 emulation. More than likely, at the<br />
time of the bus error, all maskable interrupts have been masked. It is the responsibility of<br />
the access error handler to re-enable the interrupts if desired.<br />
For the recoverable bus error cases, the stacked PC of the access error frame can be<br />
replaced with the _isp_cas_restart() address once the cause of the bus error has been<br />
removed. Code execution continues at the _isp_cas_restart() entry point, when the RTE of<br />
the access error handler is executed.<br />
For the non-recoverable bus error case, the stacked PC must be replaced with the<br />
_isp_cas_terminate() address to ensure that the original CAS or CAS2 emulation stack<br />
frame is removed from the system stack, and system is placed in the same state just before<br />
the CAS or CAS2 emulation was attempted. Also, the Fault Address FSLW must be copied<br />
to the appropriate registers prior to executing the RTE of the access error handler. After the<br />
RTE instruction is executed, code execution resumes at the _isp_cas_terminate() entry<br />
point. When the access error handler is re-entered, the stacked PC contains the address of<br />
the CAS or CAS2 instruction, the Fault Address contains the passed Fault Address from the<br />
previous access error handling, and the FSLW contains the passed FSLW from the previous<br />
access error handling. Figure C-4 outlines the call-outs and entry-points associated with the<br />
CAS and CAS2 emulation.<br />
C-8<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
* _real_cas(), _real_cas2(): MC68060ISP Call-out to provide choice<br />
* of using supplied _isp_cas() and _isp_cas2() routines or to<br />
* write an alternate routine more fitted for the system.<br />
* _isp_cas(), _isp_cas2(): CAS and CAS2 core routine entry point that<br />
* can be called from _real_cas() and _real_cas2() if the system wishes<br />
* to use the CAS and CAS2 emulation code provided with the package.<br />
* The flow is:<br />
* (exception) -> _isp_unimp -> _real_cas{2) -> _isp_cas{2}<br />
* _isp_cas_inrange(): Subroutine entry point provided by the 68060ISP<br />
* for use by the access error handler that reports if a given<br />
* address resides within the _isp_cas() or _isp_cas2() routines.<br />
* Inputs:<br />
* a0 = instruction address in question<br />
* Outputs:<br />
* d0 = 0 -> success; non-zero -> failure<br />
* _isp_cas_terminate(): Entry point provided by the MC68060ISP for<br />
* use by an access error handler to create an access error frame for<br />
* a process and to exit the CAS or CAS2 emulation gracefully.<br />
* Inputs:<br />
* a0 = faulting address<br />
* d0 = Fault Status Longword<br />
* _isp_cas_restart(): Entry point provided by the 68060ISP for use<br />
* by an access error handler to re-start _isp_cas() and _isp_cas2()<br />
* if a recoverable bus error occurs within the _isp_cas() and _isp_cas2()<br />
* routines.<br />
* _isp_cas_finish(), _isp_cas2_finish(): Entry point provided by the<br />
* MC68060ISP for use by system-specific implementations of cas. Enter<br />
* here to exit gracefully through the package.<br />
* The flow is:<br />
* (exception) ->_isp_unimp -> _real_cas{2} -> (new code)<br />
* -> _isp_cas{2}_finish<br />
* This requires close examination of the _isp_cas() and _isp_cas2() source<br />
* code.<br />
Figure C-4. CAS and CAS2 Call-Outs and Entry Points<br />
C.2.3 Module 2: Unimplemented Integer Instruction Library<br />
(MC68060ILSP)<br />
The <strong>M68060</strong>SP provides a library version of the following unimplemented integer instructions:<br />
64-bit divide, 64-bit multiply, and CMP2. This version can be compiled with user applications<br />
desiring the functionality of these instructions. Using the library method, an<br />
application does not have to incur the overhead of the unimplemented integer instruction<br />
exception.<br />
The routines are System V ABI compliant. Currently, the arguments are expected on the<br />
stack by the <strong>M68060</strong>SP library routines. For _divu64, _divs64, _mulu64, and _muls64, the<br />
results are not returned in a pair of data registers as with the actual instructions, but rather<br />
in a two-long-word memory array pointed to by a pointer argument provided by the caller.<br />
C-9
MC68060 Software Package<br />
The condition code register upon return from all of the library routines is correct. Figure C-5<br />
provides a C-code representation of the integer library routines in the <strong>M68060</strong>SP.<br />
C-10<br />
/* 64-bit (32x32 -> 64) unsigned multiply routine */<br />
void _mulu64(multiplier,multiplicand,result)<br />
unsigned int multiplier;<br />
unsigned int multiplicand;<br />
unsigned int *result; /* array for result */<br />
/* 64-bit (32x32 -> 64) signed multiply routine */<br />
void _muls64(multiplier,multiplicand,result)<br />
int multiplier;<br />
int multiplicand;<br />
int *result; /* array for result */<br />
/* 64-bit (32/32 -> 32r:32q) unsigned divide routine */<br />
void _divu64(divisor,dividend_hi,dividend_lo,result)<br />
unsigned int divisor;<br />
unsigned int dividend_hi, dividend_lo;<br />
unsigned int *result; /* array for result */<br />
/* 64-bit (32/32 -> 32r:32q) signed divide routine */<br />
void _divs64(divisor,dividend_hi,dividend_lo,result)<br />
int divisor;<br />
int dividend_hi,dividend_lo;<br />
int *result; /* array for result */<br />
/* CMP2 using an “A”ddress or “D”ata register. size = byte. */<br />
void _cmp2_{D,A}b(rn,bounds)<br />
int rn;<br />
char *bounds; /* pointer to byte bounds array */<br />
/* CMP2 using an “A”ddress or “D”ata register. size = word. */<br />
void _cmp2_{D,A}w(rn,bounds)<br />
int rn;<br />
short *bounds; /* pointer to word bounds array */<br />
/* CMP2 using an “A”ddress or “D”ata register. size = longword. */<br />
void _cmp2_{D,A}l(rn,bounds)<br />
int rn;<br />
int *bounds; /* pointer to longword bounds array */<br />
Figure C-5. C-Code Representation of Integer Library Routines<br />
For example, to use a 64-bit divide instruction, do a “bsr” or “jsr” to the entry-point defined<br />
by the MC68060ILSP entry table. A compiler-generated code sequence for unsigned multiply<br />
could resemble Figure C-6.<br />
The library routines also return the correct condition code register value. If this is important,<br />
then the caller of the library routine must make sure that the value is not lost while popping<br />
other items off of the stack. An example of using the CMP2 instruction is given in Figure C-7.<br />
The unimplemented integer instruction library module contains no operating system dependencies<br />
and does not require a call-out dispatch table. If the instruction being emulated is a<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
* mulu.l ,Dh:Dl<br />
* mulu.l _multiplier,d1:d0<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
subq.l #$8,sp ; make room for result on stack<br />
pea (sp) ; pass: result addr on stack<br />
move.l d0,-(sp) ; pass: multiplicand on stack<br />
move.l _multiplier,-(sp) ; pass: multiplier on stack<br />
bsr.l _060LISP_TOP+$18 ; branch to multiply routine<br />
add.l #$c,sp ; clear arguments from stack<br />
move.l (sp)+,d1 ; load result[63:32]<br />
move.l (sp)+,d0 ; load result[31:0]<br />
Figure C-6. MUL Instruction Call Example<br />
* cmp2.l ,Rn<br />
* cmp2.l _bounds,d0<br />
pea _bounds ; pass ptr to bounds<br />
move.l d0,-(sp) ; pass Rn<br />
bsr.l _060LSP_TOP_+$48 ; branch to “cmp2” routine<br />
add.l #$8,sp ; clear arguments from stack<br />
Figure C-7. CMP2 Instruction Call Example<br />
divide and the source operand is a zero, then the library routine (as it is last instruction) executes<br />
an implemented divide using a zero source operand so that an integer divide-by-zero<br />
exception will be taken. Although the exception stack frame will not point to the correct<br />
instruction, the user can at least be able to record that such an event occurred.<br />
C.3 FLOATING-POINT EMULATION PACKAGE (MC68060FPSP)<br />
The MC68060 does not implement some floating-point instructions, addressing modes, and<br />
data types on-chip in order to streamline internal operations. This results in an overall system<br />
performance improvement at the expense of software emulation of these unimplemented<br />
instructions, addressing modes, and data types. The <strong>M68060</strong>SP provides three<br />
separate modules that are related to floating-point operations. The first floating-point module<br />
is the full floating-point kernel module. This module is used for applications that require emulation<br />
of the full MC68881 floating-point instruction set, data-types, and IEEE-754 exception<br />
handling. The second floating-point module is the floating-point library. This library is provided<br />
as a separate module for applications that need to avoid the latency incurred by the<br />
F-line exception processing for unimplemented floating-point instructions. However, this<br />
method requires recompiling of existing software to implement subroutine calls. The third<br />
floating-point module, the partial floating-point kernel module, is optional and is used primarily<br />
in systems that also integrate the floating-point library. The partial floating-point kernel<br />
module is similar in function to the full floating-point kernel except that it does not contain<br />
the unimplemented floating-point instruction exception handler. This module is provided for<br />
the purpose of saving memory space. Otherwise, the full floating-point kernel module must<br />
be used instead.<br />
C-11
MC68060 Software Package<br />
The floating-point emulation package provides the following services:<br />
1. Floating-point unimplemented instruction exception handler<br />
2. Floating-point unimplemented data-type exception handler<br />
3. Floating-point unimplemented effective address handler<br />
4. Floating-point arithmetic exception handlers<br />
5. Floating-point library<br />
Table C-2 lists a brief comparison among the M68000 family floating-point processors.<br />
C-12<br />
Table C-2. FPU Comparison<br />
Is the default result stored in the destination register for exception-enabled register-toregister<br />
or memory-to-register operations?<br />
FPU INEX DIVZ OPERR SNAN<br />
MC68881/882 Yes No No No<br />
MC68040 Yes No No No<br />
MC68060 Yes* No No No<br />
Is the default result stored for exception-enabled FMOVE OUT?<br />
FPU INEX DIVZ OPERR SNAN<br />
MC68881/882 Yes — Yes Yes<br />
MC68040 Yes — Yes+* Yes+*<br />
MC68060 Yes+* — Yes+* Yes+*<br />
+ Undefined result written by processor<br />
* Floating-point software package assistance needed to store the default result<br />
The unimplemented floating-point instructions, effective addresses, and data types that are<br />
handled by the <strong>M68060</strong>SP are outlined in Table C-3 and Table C-4.<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
Table C-3. Unimplemented Instructions<br />
General Monadic Operations<br />
FACOS FLOGN<br />
FASIN FLOGNP1<br />
FATAN FMOVECR<br />
FATANH FSIN<br />
FCOS FSINCOS<br />
FCOSH FSINH<br />
FETOX FTAN<br />
FETOXM1 FTANH<br />
FGETEXP FTENTOX<br />
FGETMAN FTWOTOX<br />
FLOG10 FLOG2<br />
General Dyadic Operations<br />
FMOD FREM<br />
FSCALE —<br />
Conditionals<br />
FTRAPcc FDBcc<br />
FScc –<br />
Unimplemented Effective Address<br />
FMOVEM.X (dynamic register list)<br />
FMOVEM.L #immediate of<br />
2 or 3 control regs<br />
F.X #immediate,FPn F.P #immediate,FPn<br />
Table C-4. Unimplemented Data Formats and Data Types<br />
C.3.1 Floating-Point Emulation Results<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
Data Formats/Data Types SGL DBL EXT DEC Byte Word Long<br />
Normalized S S S U S S S<br />
Zero S S S U S S S<br />
Infinity S S S U — — —<br />
NAN S S S U — — —<br />
Denormalized U U U U — — —<br />
Unnormalized — — U U — — —<br />
Where:<br />
S = Implemented Data Format, handled by the MC68060<br />
U = Unimplemented Data Format, handled by the <strong>M68060</strong>SP<br />
All numerical results and condition code settings produced by the <strong>M68060</strong>FPSP and visible<br />
to the user are identical to those produced by the MC68881/882 and MC68040 with the following<br />
exception: the <strong>M68060</strong>FPSP transcendental calculation results are not the same as<br />
for the MC68881/882, because the algorithms used in the MC68881/882 (CORDIC) cannot<br />
be effectively implemented in software. However, the error bound of the <strong>M68060</strong>FPSP transcendental<br />
routines (same as for the MC68040 routines) are equivalent or superior.<br />
For floating-point arithmetic instructions, the error bound is one-half unit in the last place of<br />
the destination format in the round-to-nearest mode, and one unit in the last place in the<br />
C-13
MC68060 Software Package<br />
other rounding modes. Transcendental instructions have an error bound of less than 0.6 unit<br />
in the last place of double precision. The error bound for decimal conversions is 0.97 unit in<br />
the destination precision for the round-to-nearest mode and 1.47 units in the last digit of the<br />
destination precision for the other rounding modes.<br />
C.3.2 Module 3: Full Floating-Point Kernel<br />
The full floating-point kernel includes the following exception handlers:<br />
1. Floating-point unimplemented instruction handler<br />
2. Floating-point unimplemented data type handler<br />
3. Unimplemented effective address handler<br />
4. Floating-point arithmetic exception handlers<br />
When the full floating-point kernel is integrated into the system, the entire MC68881 floatingpoint<br />
coprocessor instruction set object-code compatibility is attained, and IEEE-754 trap<br />
reporting compliance is achieved. This module stands on its own and is ideal for systems<br />
whose applications were written with the full MC68881 instruction set in mind.<br />
C.3.2.1 FULL FLOATING-POINT KERNEL MODULE ENTRY POINTS. The _fpsp_fline,<br />
_fpsp_unsupp and _fpsp_effadd are entry points supplied for the floating-point unimplemented<br />
instruction, floating-point unimplemented data type and unimplemented effective<br />
address handlers respectively. The _fpsp_snan, _fpsp_operr, _fpsp_ovfl, _fpsp_unfl,<br />
_fpsp_dz, _fpsp_inex entry points are supplied as the floating-point arithmetic exception<br />
handlers. These entry points are implemented such that the appropriate vector table entries<br />
typically point directly to these functions. If the system chooses to perform certain system<br />
functions prior to entering these entry points, the system can do so with the condition that<br />
the system stack pointer must point to the exception stack frame at the time of the function<br />
entry. Figure C-12 illustrates the relationship of the module to the vector table and system<br />
software envelope.<br />
C.3.2.2 FULL FLOATING-POINT KERNEL MODULE CALL-OUTS. The full floating-point<br />
kernel requires the following call-outs: _real_fline, _real_fpu_disabled, _real_trace,<br />
_real_trap, _real_bsun, _real_snan, _real_operr, _real_ovfl, _real_unfl, _real_dz,<br />
_real_inex, _fpsp_done. In addition, C.4 Operating System Dependencies discusses the<br />
_real_access call-out and other call-outs that are common to the unimplemented integer<br />
instruction exception module.<br />
C.3.2.2.1 The F-Line Exception Call-Outs. When the _fpsp_fline function is entered, it<br />
checks the stack frame format and determines whether this is an unimplemented floatingpoint<br />
instruction, FPU disabled or F-line illegal exception. If it is determined that the FPU is<br />
disabled, the call-out _real_fpu_disabled is taken. It is up to the system software to either<br />
emulate the instruction using integer instructions or simply turn on the FPU before returning<br />
to restart the instruction. If the instruction is not recognized as an MC68881 instruction, the<br />
call-out _real_fline is taken. The system software is responsible for taking the appropriate<br />
action. If neither the FPU disabled or F-line illegal exception cases is true, then the<br />
<strong>M68060</strong>SP emulates the instruction.<br />
C-14<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
C.3.2.2.2 System-Supplied Floating-Point Arithmetic Exception Handler Call-Outs.<br />
The call-outs _real_bsun, _real_snan, _real_operr, _real_ovfl, _real_unfl, _real_dz,<br />
_real_inex are needed only if the system turns on the floating-point exceptions via the floating-point<br />
control register (FPCR) exception enable byte. These call-outs point to the arithmetic<br />
handlers that must be supplied for IEEE trap enabled operation. Documentation for<br />
these handlers are fully explained in Section 6 Floating-Point Unit.<br />
Additional information<br />
on how these call-outs are reached is found in C.3.2.3 Bypassing Module-Supplied Floating-Point<br />
Arithmetic Handlers and C.3.2.4 Exceptions During Emulation.<br />
C.3.2.2.3 Exception-Related Call-Outs. When in the process of emulating any of the floating-point<br />
exception handlers, there are conditions that require the <strong>M68060</strong>SP to emulate an<br />
access error, trace, or trap exception. The <strong>M68060</strong>SP does so by cleaning up the stack to<br />
the conditions prior to executing the exception handler, converting the original stack frame<br />
to the appropriate stack frame and then branching to those system-supplied exception handlers.<br />
The call-outs _real_access, _real_trace, and _real_trap are defined to provide the system<br />
integrator a choice of either having the module point directly to the actual access error, trace<br />
and trap exception handlers or to an alternate routine that would calculate the exception<br />
handler address from the vector table prior to jumping to actual handlers. The direct implementation<br />
is ideal for systems that do not anticipate any changes to the vector table, and for<br />
which performance is more critical. The indirect approach of consulting the vector table is<br />
more accurate in that if the instruction were implemented, the actual handler’s address is<br />
fetched from the appropriate vector table entry before branching there.<br />
C.3.2.2.4 Exit Point Call-Outs. The _fpsp_done call-out is provided as a means for the<br />
system to do any clean-up, if necessary, before executing the RTE instruction to return to<br />
normal instruction execution. All the supplied floating-point handlers will either branch to this<br />
call-out or exit through the call-outs _real_fline, _real_fpu_disabled, _real_trace, _real_trap,<br />
_real_access, _real_bsun, _real_snan, _real_operr, _real_ovfl, _real_unfl, _real_dz, and<br />
_real_inex exit points.<br />
C.3.2.3 BYPASSING MODULE-SUPPLIED FLOATING-POINT ARITHMETIC<br />
HANDLERS. A system that does not require full IEEE trap enabled exception compliance<br />
or does not require the services of the exceptional operand, may choose to bypass the<br />
_fpsp_{ovfl,unfl,snan,operr,dz,inex} entry points. To better assess whether or not to write a<br />
customized floating-point arithmetic handler, it is important to know what the processor<br />
hardware does and what the <strong>M68060</strong>SP handlers do individually.<br />
The term “opclass” is used in the following paragraphs. An opclass zero instruction refers to<br />
a floating-point general instruction whose source operand(s) and destination operand are all<br />
floating-point data registers (no operands in memory). An opclass two instruction refers to a<br />
floating-point general instruction in which one source operand is in memory or an integer<br />
data register, but the destination is a floating-point data register. An opclass three instruction<br />
refers to an FMOVE instruction that has a memory or integer data register destination.<br />
C-15
MC68060 Software Package<br />
C.3.2.3.1 Overflow/Underflow. Floating-point overflow and underflow are nonmaskable<br />
exceptions on the MC68060 (as they were on the MC68040). When either occur, the corresponding<br />
exception is taken regardless, whether the user overflow or underflow enable bit<br />
is set in the FPCR or not. The purpose of these nonmaskable exceptions is to allow software<br />
to generate the default underflow and overflow results as produced by the MC68881/882.<br />
The <strong>M68060</strong>FPSP acts differently according to the four following cases:<br />
1. Overflow/Underflow disabled, overflow occurred, and inexact is enabled—the<br />
<strong>M68060</strong>FPSP exception handler, _fpsp_ovfl, calculates the default result and stores<br />
this value at the destination. Second, the exceptional operand value is calculated and<br />
restored, with exceptional status, into the FPU with an FRESTORE instruction. The<br />
overflow stack frame is then converted into an inexact stack frame. Finally, a branch<br />
is taken to the operating system-supplied call-out (_real_inex) for the user enabled inexact<br />
exception handler.<br />
2. Overflow/Underflow disabled, underflow occurred, inexact is enabled, and the result is<br />
inexact—the <strong>M68060</strong>FPSP exception handler, _fpsp_unfl, calculates the default result<br />
and stores this value at the destination. Second, the exceptional operand value is<br />
calculated and restored, with exceptional status, into the FPU with an FRESTORE instruction.<br />
The overflow stack frame is then converted into an inexact stack frame. Finally,<br />
a branch is taken to the operating system-supplied call-out (_real_inex) for the<br />
user-enabled inexact exception handler.<br />
3. Overflow, underflow, and inexact disabled—the <strong>M68060</strong>FPSP exception handler,<br />
_fpsp_ovfl or _fpsp_unfl, calculates the default result rounded to the proper mode and<br />
precision, and stores this result at the destination. The handler then returns the processor<br />
to normal processing.<br />
4. Overflow or underflow enabled—the <strong>M68060</strong>FPSP exception handler, _fpsp_ovfl or<br />
_fpsp_unfl, calculates the default result and stores this value at the destination. Second,<br />
the exceptional operand value is calculated and restored, with exceptional status,<br />
into the FPU with an FRESTORE instruction. Next, a branch is taken to the operating<br />
system-supplied call-out (_real_{ovfl,unfl}) for the user enabled overflow or underflow<br />
exception handler. At this point, the overflow/underflow exception frame is on the<br />
stack. The exceptional operand can be located in the FSAVE frame. The destination<br />
operand is not available. The source operand may not be available. The following<br />
short list details the information available to _real_{ovfl,unfl} when the <strong>M68060</strong>FPSP<br />
passes control there:<br />
• Memory or data register destination<br />
—exception stack frame: the six-word post-instruction stack frame contains the<br />
PC of the next instruction and the effective address of the destination operand.<br />
—in the FSAVE frame: the exceptional operand which is the intermediate result<br />
rounded to the destination precision, with the 15-bit exponent biased as a normal<br />
extended-precision number. The user ovfl/unfl handler must execute an<br />
“FSAVE” to retrieve this value.<br />
—at the destination location: default result (same as with exceptions disabled).<br />
—FPIAR: address of the instruction that underflowed/overflowed.<br />
C-16<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Software Package<br />
• Floating-point data register destination:<br />
—exception stack frame: the four-word pre-instruction stack frame contains the<br />
PC of the next instruction.<br />
—in the FSAVE frame: the exceptional operand which is the intermediate result<br />
mantissa rounded to extended precision, with an exponent bias of<br />
$3FFF+$6000 for underflow and $3FFF-$6000 for overflow rather than $3FFF.<br />
In cases of catastrophic overflow/underflow, the exceptional operand exponent<br />
is set to $0000. The user ovfl/unfl handler must execute an FSAVE to retrieve<br />
this value.<br />
—at the destination location: the default underflow/overflow result.<br />
—FPIAR: address of the instruction that underflowed/overflowed.<br />
—FPSR: the bits are set according to the default result.<br />
Note<br />
Unlike the MC68040, the MC68060 FPU hardware does not provide<br />
the exceptional operand on overflow or underflow for use by<br />
an exception handler. Therefore, the <strong>M68060</strong>FPSP overflow<br />
and underflow handlers must emulate the entire faulted instruction<br />
in order to calculate the exceptional operand for the user enabled<br />
overflow or underflow handler.<br />
Finally, if the result of the floating-point multiplication unit is a normalized extended-precision<br />
number with a zero exponent, then the processor will incorrectly take an underflow exception.<br />
The <strong>M68060</strong>SP detects and corrects this case.<br />
C.3.2.3.2 Signalling Not-A-Number, Operand Error. On the MC68060, the signalling nota-number<br />
(SNAN) and operand error (OPERR) exceptions cause pre-instruction exceptions<br />
for opclass zero and two instructions and post-instruction exceptions for opclass three<br />
instructions. The processor takes exception vector number fifty-four for the SNAN exception<br />
and vector number fifty-two for the OPERR exception. The FSAVE frames for the exceptions<br />
are valid and contain the source operands converted to extended precision.<br />
SNAN and OPERR were non-maskable exceptions on the MC68040 for opclass three<br />
instructions with byte, word, or long-word destination formats. The exceptions were nonmaskable<br />
so that the MC68040FPSP software could provide the default SNAN or OPERR<br />
results when the exceptions were disabled. With the MC68060, as with the MC68881/882,<br />
SNAN and OPERR are entirely maskable since the default trap disabled results are provided<br />
by floating-point hardware.<br />
C-17
MC68060 Software Package<br />
<strong>M68060</strong>FPSP SNAN and OPERR exception handlers, _fpsp_snan and _fpsp_operr, will be<br />
provided for SNAN and OPERR enabled exceptions for the following reasons:<br />
• For opclass two pre-instruction exceptions using a single or double source format with<br />
an infinity, denorm, NAN, or zero source operand, the processor does not create the<br />
correct extended-precision value for the FSAVE frame. The MC68060FPSP handlers<br />
convert the value in the FSAVE frame to extended-precision format before passing control<br />
to the user enabled SNAN or OPERR exception handlers (_real_{snan,operr}). No<br />
parameters are passed to the user enabled SNAN or OPERR exception handlers from<br />
the <strong>M68060</strong>FPSP package since the package provides the illusion that it never existed.<br />
• For opclass three post-instruction exceptions, the processor does not store the default<br />
result to the destination memory or integer data register before taking the enabled exception.<br />
The MC68881/882 stored the default result in this scenario. Therefore, to maintain<br />
compatibility, the <strong>M68060</strong>FPSP SNAN and OPERR exception handlers calculate<br />
and store the default result before passing control to the user enabled SNAN and OP-<br />
ERR exception handlers (_real_{snan,operr}). No parameters are passed to the user<br />
SNAN or OPERR exception handlers since the <strong>M68060</strong>FPSP provides the illusion that<br />
it never existed.<br />
A simple pseudo-code diagram for the SNAN and OPERR handlers is provided in the code<br />
sequence shown in Figure C-8.<br />
C-18<br />
_fpsp_{snan,operr}() {<br />
if ((opclass == 0) || (opclass == 2)) {<br />
/*<br />
* if src operand is a sgl or dbl<br />
* zero,NAN,denorm, or infinity,<br />
* fix operand in FSAVE frame.<br />
*/<br />
fix_FSAVE_op();<br />
bra.l _real_{snan,operr}();<br />
}<br />
else {/* opclass 3 */<br />
/*<br />
* save default result to memory<br />
* or integer register file.<br />
*/<br />
save_default_result();<br />
bra.l _real_{snan,operr}();<br />
Figure C-8. SNAN/OPERR Exception Handler Pseudo-Code<br />
C.3.2.3.3 Inexact Exception. Opclass zero and two exception instructions taking the inexact<br />
exception cause pre-instruction exceptions, and opclass three instructions cause postinstruction<br />
inexact exceptions. The processor takes exception vector number forty-nine for<br />
the inexact exception. The FSAVE frame for the exception is valid and contains the source<br />
operand converted to extended precision.<br />
The inexact exception is a maskable exception on the MC68060 for the trap-disabled case.<br />
The floating-point hardware produces the correct result when the inexact exception enable<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
MC68060 Software Package<br />
bit is clear in the FPCR. Therefore, no software assistance is required in this case to maintain<br />
MC68881/882 compatibility. An <strong>M68060</strong>FPSP handler, _fpsp_inex, is provided for enabled<br />
inexact exceptions for the following reasons:<br />
• For opclass two pre-instruction exceptions, the processor does not store the default result<br />
to the destination floating-point register before taking the enabled inexact exception.<br />
The MC68881/882 stored the default result in this scenario. Therefore, to maintain<br />
compatibility, the <strong>M68060</strong>FPSP inexact exception handler calculates and stores the default<br />
result before passing control to the user enabled inexact exception handler<br />
(_real_inex). No parameters are passed to the user enabled inexact exception handler<br />
since the <strong>M68060</strong>FPSP handler provides the illusion that it never existed.<br />
• In addition, for opclass two pre-instruction exceptions using a single or double source<br />
format with an infinity, denorm, or zero source operand, the processor does not create<br />
the correct extended-precision value for the FSAVE frame. The correct extended-precision<br />
value is also not created when the source format is a longword integer. The<br />
<strong>M68060</strong>FPSP inexact handler converts the value in the FSAVE frame to extended-precision<br />
format for these cases before passing control to the user enabled inexact exception<br />
handler (_real_inex).<br />
• For opclass three post-instruction exceptions, the processor does not store the default<br />
result to the destination memory or integer data register before taking the enabled inexact<br />
exception. The MC68881/882 stored the default result in this scenario. Therefore,<br />
to maintain compatibility, the <strong>M68060</strong>FPSP inexact exception handler calculates and<br />
stores the default result before passing control to the user enabled inexact exception<br />
handler (_real_inex). No parameters are passed to the user enabled inexact exception<br />
handler since the <strong>M68060</strong>FPSP handler provides the illusion that it never existed.<br />
C.3.2.3.4 Divide-by-Zero Exception. Only opclass zero and two instructions can take the<br />
divide-by-zero floating-point (DZ) exception. The processor takes exception vector number<br />
fifty with a type zero stack frame for this case. The FSAVE frame for the DZ exception is<br />
valid and contains the source operand converted to extended precision.<br />
The divide-by-zero exception is a maskable exception on the MC68060 for the trap disabled<br />
case. The FPU produces the correct result when the DZ bit in the FPCR is clear. No<br />
<strong>M68060</strong>FPSP assistance is required to maintain MC68881/882 compatibility for DZ disabled.<br />
A handler, _fpsp_dz, is provided for enabled DZ exceptions. This <strong>M68060</strong>FPSP handler<br />
converts the FSAVE source operand to extended precision if the source operand is a<br />
zero in single or double format. The handler then passes control to the user enabled divideby-zero<br />
exception handler (_real_dz). No parameters are passed to the user DZ exception<br />
handler from the <strong>M68060</strong>FPSP package since the package provides the illusion that it never<br />
existed.<br />
C.3.2.3.5 Branch/Set on Unordered Exception. The MC68060 processor provides the<br />
correct results and actions for both the branch/set on unordered (BSUN) exception enabled<br />
and disabled cases. Therefore, no <strong>M68060</strong>FPSP assistance is required for MC68881/882<br />
compatibility.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-19
MC68060 Software Package<br />
C.3.2.4 EXCEPTIONS DURING EMULATION. Unimplemented data type, unimplemented<br />
effective address, and unimplemented floating-point instruction exception software emulation<br />
by the <strong>M68060</strong>FPSP may determine that the instruction being emulated should take a<br />
BSUN, SNAN, OPERR, OVFL, UNFL, DZ, or INEX exception. These exceptions may either<br />
be enabled or disabled (see examples in Figure C-9).<br />
fsin.x fp0<br />
<br />
<br />
<br />
<br />
TAKES FLOATING-POINT UNIMPLEMENTED<br />
EXCEPTION IMMEDIATELY<br />
(1) "fsin" software emulation determines that the sine operation should cause an underflow.<br />
(2) If UNFL is:<br />
• DISABLED: the default result is calculated and returned at point "a"; the "exception present"<br />
bit in the FPU is clear.<br />
• ENABLED: an fsave frame with the underflow exception set is restored into the FPU at point "a"<br />
with the "exception present" bit set.<br />
The actual underflow will occur as a pre-instruction exception at point "b".<br />
fdiv.x fp0, fp1<br />
<br />
<br />
<br />
<br />
(a)<br />
Figure C-9. Disabled vs. Enabled Exception Actions<br />
C.3.2.4.1 Trap-Disabled Operation. If a newly found exception is disabled by the user,<br />
then the default result for that exception is returned as the result of emulation by the<br />
<strong>M68060</strong>FPSP. The handler then returns the processor to normal processing.<br />
C-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA<br />
(a)<br />
(b)<br />
TAKES FLOATING-POINT UNIMPLEMENTED<br />
DATA TYPE EXCEPTION HERE<br />
(1) fp0 contains a denormalized number and fp1 contains an SNAN; the exceptionis taken as a preinstruction<br />
exception at point "a".<br />
(2) "fdiv" software emulation determines that the divide should cause a signalling non exception.<br />
(2) If SNAN is:<br />
• DISABLED: The default result is calculated and returned at point "a"; the exception present"<br />
bit in the FPU is clear.<br />
• ENABLED: an fsave frame with the SNAN exception set is restored into the FPU at point "a" with<br />
the "exception present" bit set. The actual SNAN exception will then occur immediately as a preinstruction<br />
exception when the unimplemented floating point data type handler<br />
(b)<br />
(a)
MC68060 Software Package<br />
For example, the FSIN operation in Figure C-9(a) will take an unimplemented floating-point<br />
instruction exception. If FSIN emulation discovers that the result should cause an underflow,<br />
and underflow is disabled, then the fp0 register is assigned the default underflow result value<br />
before program execution continues to the next integer or floating-point instruction.<br />
Note<br />
A “true” pre-instruction exception solution would have inserted<br />
an FSAVE frame of type underflow into the FPU so that the underflow<br />
processing would be delayed until the next floating-point<br />
instruction triggered a pre-instruction underflow exception. The<br />
approach taken by the <strong>M68060</strong>FPSP in this case avoids the<br />
overhead of the second exception.<br />
C.3.2.4.2 Trap-Enabled Operation. If an exception is enabled and the instruction is of<br />
opclass zero or two, then an FSAVE frame of that exception type is restored into the FPU<br />
by the <strong>M68060</strong>FPSP. Second, the stack frame is cleaned up to the point just before the original<br />
exception handler was entered. Next, the original exception stack frame is converted to<br />
a stack frame for the new exception type. Finally, the handler returns the processor to normal<br />
processing. The new exception is then taken as a pre-instruction exception upon<br />
encountering the next floating-point instruction.<br />
From the previous FSIN example of Figure C-9(a), if the emulation encountered an underflow<br />
condition and underflow was enabled, an FSAVE frame with the underflow exception<br />
bit set would be inserted into the FPU. An underflow pre-instruction exception would then be<br />
taken upon encountering the next floating-point instruction.<br />
This restoring procedure is used for enabled exceptions so that an exception will not enter<br />
through an unimplemented data type, unimplemented effective address, or unimplemented<br />
floating-point instruction exception and then exit through an SNAN, OPERR, OVFL, UNFL,<br />
DZ, or INEX exception handler for an opclass zero or two instruction. Some operating systems<br />
may be confused by this type of flow change.<br />
Opclass three instruction emulation that encounters an enabled exception is physically<br />
unable to insert the appropriate exception frame into the FPU and return to normal processing<br />
to await the next floating-point instruction. So, the <strong>M68060</strong>FPSP converts the existing<br />
exception stack frame to a frame of the enabled exception’s type and inserts the exceptional<br />
state into the FPU with an FRESTORE. Then, the <strong>M68060</strong>FPSP package branches to the<br />
appropriate host operating system-supplied interface (_real_{SNAN, OPERR, OVFL, UNFL,<br />
INEX}) for the enabled exception. This approach was also used with the MC68040FPSP.<br />
C.3.3 Module 4: Partial Floating-Point Kernel<br />
This module is identical to the full floating-point kernel in every aspect with the exception that<br />
the floating-point unimplemented exception handler code is not included. This module is typically<br />
used with the floating-point library in a system that does not encounter MC68881<br />
instructions that are unimplemented in the MC68060.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-21
MC68060 Software Package<br />
C.3.4 Module 5: Floating-Point Library (<strong>M68060</strong>FPLSP)<br />
The <strong>M68060</strong>SP provides a library version of the unimplemented general monadic and<br />
dyadic floating-point instructions shown in Table C-3. These routines are System V ABI<br />
compliant as well as IEEE exception-reporting compliant. They are not, however, UNIX<br />
exception-reporting compliant. This library implementation can be compiled with user applications<br />
desiring the functionality of these instructions without having to incur the overhead<br />
of the floating-point unimplemented instruction” exception. The floating-point library contains<br />
floating-point instructions that are implemented by the MC68060. The floating-point library<br />
requires the partial floating-point kernel or full floating-point kernel to be ported to the system<br />
for proper operation.<br />
In addition, the FABS, FADD, FDIV, FINT, FINTRZ, FMUL, FNEG, FSQRT, and FSUB<br />
functions are provided for the convenience of older compilers that make subroutine calls for<br />
all floating-point instructions. The code does not emulate these instructions in integer, but<br />
rather simply executes them.<br />
All input variables must be pushed onto the stack prior to calling the supplied library routine.<br />
For each function, three entry points are provided, each accepting one of the three<br />
possible input operand data types: single, double, and extended precision. For dyadic<br />
operations both input operands are defined to have the same operand data type. For<br />
instance, for a monadic instruction such as the FSIN instruction, the functions are:<br />
_fsins(single-precision input operand), _fsind(double-precision input operand),<br />
_fsinx(extended-precision input operand). For dyadic operations such as the FDIV instruction,<br />
the entry points provided are: _fdivs(both single-precision input operands), _fdivd(both<br />
double-precision input operands, _fdivx(both extended-precision input operands).<br />
To properly call a monadic subroutine, the calling routine must push the input operand onto<br />
the stack first. For instance:<br />
* This example replaces the “fsin.x fp1,fp0” instruction<br />
* Note that _fsinx is actually implemented as an offset from the<br />
* top of the Floating-point Library Module.<br />
fmove.x fp1,-(sp) ; push operand to stack<br />
bsr _fsinx ; result returned in fp0<br />
add.w #12,sp ; clean up stack<br />
To properly call a dyadic subroutine, the calling routine must push the second operand<br />
onto the stack before pushing the first operand onto the stack. For instance:<br />
* This example replaces the “fdiv.x fp1,fp0” instruction<br />
* Note that _fdivx is actually implemented as an offset from the<br />
* top of the Floating-point Library Module.<br />
fmove.x fp1,-(sp) ; push 2nd operand to stack<br />
fmove.x fp0,-(sp) ; push 1st operand to stack<br />
bsr _fdivx ; result returned in fp0<br />
add.w #24,sp ; clean up stack<br />
All routines return the operation result in the register fp0. It is the responsibility of the calling<br />
routine to remove the input operands from the stack after the routine has been executed.<br />
The result’s rounding precision and mode, as well as exception reporting, is dictated by the<br />
value of the FPCR upon subroutine entry. The floating-point status register (FPSR) is set<br />
C-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Software Package<br />
appropriately upon subroutine return. The floating-point address register (FPIAR) is undefined.<br />
This module contains no operating system dependencies. There is no call-out dispatch<br />
table. To report an exception, the emulation routine uses the FPCR exception enable byte<br />
to determine whether or not to report an exception. If the exception is enabled, the exception<br />
is forced using implemented floating-point instructions.<br />
For instance, if the instruction being emulated should cause a floating-point OPERR exception,<br />
then the library routine, as its last instruction, executes an FMUL of a zero and infinity<br />
to force an OPERR exception. Although the exception stack frame will not point to the correct<br />
instruction, the user can record that such an event occurred.<br />
C.4 OPERATING SYSTEM DEPENDENCIES<br />
When porting the unimplemented integer, full or partial floating-point kernel modules, some<br />
routines need to be written outside and are not provided by the <strong>M68060</strong>SP.<br />
C.4.1 Instruction and Data Fetches<br />
In traditional UNIX systems, portability is promoted by the abstracting of reads/writes from<br />
and to user space into calls to the routines _copyin and _copyout see Table C-5. The<br />
MC68040FPSP provided one higher level of abstraction with the routines _mem_read and<br />
_mem_write. These routines were a superset of the UNIX routines in that they handled both<br />
user and supervisor accesses Figure C-10.<br />
Table C-5. UNIX Operating System Calls<br />
Function Call Parameters<br />
copyin (user_addr, super_addr, nbytes)<br />
copyout (super_addr, user_addr, nbytes)<br />
void mem_read(src_addr, dst_addr, nbytes) {<br />
if (SR[supervisor_bit]) {<br />
/* supervisor mode */<br />
while (nbytes--) {<br />
mem[dst_addr+nbytes] = mem[src_addr+nbytes];<br />
}<br />
}<br />
else /* user mode */<br />
_copyin(src_addr, dst_addr, nbytes);<br />
Figure C-10. _mem_read Pseudo-Code<br />
This approach provided a high degree of portability for the MC68040FPSP. The installer<br />
simply had to replace the references to _copy{in,out} in _mem_{read,write} with the host<br />
operating system’s (UNIX or non-UNIX) corresponding calls. In addition, any pre-processing<br />
necessary before a potential read/write fault (user or supervisor) was confined to these routines.<br />
As a result, several operating system types could be supported with only minor modifications.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-23
MC68060 Software Package<br />
Since the MC68040FPSP obtained most of its necessary information from the complex<br />
stack frames, very few calls to _mem_{read,write} were required. For the <strong>M68060</strong>SP, less<br />
information is provided by the processor. Therefore, several accesses to/from user code<br />
and data space may be necessary for emulation. Providing the MC68040FPSP level of subroutine<br />
abstraction in the <strong>M68060</strong>SP will slightly degrade performance.<br />
In order to compensate for this loss, the <strong>M68060</strong>SP adds to the list of operating system-supplied<br />
call-outs that read/write user/supervisor data/instruction memory. The current routines<br />
are _imem_read_{word,long} and _dmem_{read,write}_{byte,word,long}. These provide<br />
a finer granularity than the traditional _mem_{read,write} which is also provided. Figure<br />
C-11 outlines the register usage of these routines.<br />
Unlike the MC68040, which stored all necessary operands and decoding information on the<br />
stack, the MC68060 processor does not always “touch” the entire instruction and operand<br />
before entering an exception handler. Therefore, unlike with the MC68040FPSP, the<br />
<strong>M68060</strong>SP memory read and write routines may encounter bad addresses. For example,<br />
the instruction FSIN.x ADDR,fp0 will enter the <strong>M68060</strong>SP. When the <strong>M68060</strong>SP package<br />
executes a _dmem_read to fetch the extended-precision operand, the routine may return a<br />
failing value if ADDR points to inappropriate memory.<br />
If _mem_{read,write} returns a non-zero status value to the <strong>M68060</strong>SP, the <strong>M68060</strong>SP creates<br />
an access error exception stack frame out of the existing exception stack frame and<br />
branches to the user-supplied call-out _real_access. The _real_access call-out must contain<br />
the actual access error handler, a short program that examines the vector table to find<br />
the actual access error handler address and branch to it, or an entirely separate access error<br />
handler for this specific case.<br />
The PC on the access error stack frame points to the instruction the caused the original<br />
exception. The stacked address will point to the address passed to _mem_{read,write}<br />
before it returned a failing value. The stacked fault status long word (FSLW) will have the<br />
SEE bit set. The other FSLW bits may or may not be defined, depending on the <strong>M68060</strong>SP<br />
release. The initial release of the <strong>M68060</strong>SP does not define the other FSLW bits. However,<br />
future releases may define these bits. The handler supplied by the operating system for<br />
_real_access (most likely the system’s access error handler) should check for this bit and<br />
take appropriate action if set. An example action could be that the process executing the<br />
instruction that originally entered the <strong>M68060</strong>SP is terminated.<br />
C-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
* _dmem_write():<br />
* Writes to data memory while in supervisor mode.<br />
* INPUTS:<br />
* a0 - supervisor source address<br />
* a1 - user destination address<br />
* d0 - number of bytes to write<br />
* $4(a6),bit5 - 1 = supervisor mode, 0 = user mode<br />
* OUTPUTS:<br />
* d1 - 0 = success, !0 = failure<br />
* _imem_read(), _dmem_read():<br />
* Reads from data/instruction memory while in supervisor mode.<br />
* INPUTS:<br />
* a0 - user source address<br />
* a1 - supervisor destination address<br />
* d0 - number of bytes to read<br />
* $4(a6),bit5 - 1 = supervisor mode, 0 = user mode<br />
* OUTPUTS:<br />
* d1 - 0 = success, !0 = failure<br />
* _dmem_read_byte(), _dmem_read_word(), _dmem_read_long():<br />
* Read a data byte/word/long from user memory.<br />
* INPUTS:<br />
* a0 - user source address<br />
* $4(a6),bit5 - 1 = supervisor mode, 0 = user mode<br />
* OUTPUTS:<br />
* d0 - data byte/word/long in d0<br />
* d1 - 0 = success, !0 = failure<br />
* _dmem_write_byte(), dmem_write_word(), dmem_write_long():<br />
* Write a data byte/word/long to user memory.<br />
* INPUTS:<br />
* a0 - user destination address<br />
* d0 - data byte/word/long in d0<br />
* $4(a6),bit5 - 1 = supervisor mode, 0 = user mode<br />
* OUTPUTS:<br />
* d1 - 0 = success, !0 = failure<br />
MC68060 Software Package<br />
* _imem_read_word(), _imem_read_long():<br />
* Read an instruction word/long from user memory.<br />
* INPUTS:<br />
* a0 - user source address<br />
* $4(a6),bit5 - 1 = supervisor mode, 0 = user mode<br />
* OUTPUTS:<br />
* d0 - instruction word/long in d0<br />
* d1 - 0 = success, !0 = failure<br />
Figure C-11. Register Usage of {i,d}mem_{read,write}_{b,w,l}<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-25
MC68060 Software Package<br />
C.4.2 Instructions Not Recommended<br />
Emulated instructions that use the pre-decrement and post-increment addressing mode on<br />
the system stack must not contradict the basic definition of a stack. An operation that uses<br />
input operands below the stack (using the pre-decrement addressing mode) exhibits poor<br />
programming structure since the instruction is using a value before it has been defined. In<br />
addition, instructions that place a result on the stack using the post-increment addressing<br />
mode exhibit poor programming structure since an unexpected exception such as an interrupt<br />
or an unimplemented instruction exception would corrupt the result. The <strong>M68060</strong>SP<br />
does not handle these instruction cases properly, and unpredictable behavior will be exhibited<br />
when executing code of this type.<br />
The <strong>M68060</strong>SP does not recover gracefully from these instruction cases because a performance<br />
penalty would be incurred to handle them properly. To avoid imposing this performance<br />
penalty on well-behaved systems, the task of avoiding these cases has been left<br />
outside the <strong>M68060</strong>SP. If the system absolutely requires that these cases be handled gracefully,<br />
the system software envelope can pre-filter these cases prior to entering the<br />
<strong>M68060</strong>SP. Table C-6 outlines these instructions.<br />
Table C-6. Instructions Not Handled by the <strong>M68060</strong>SP<br />
Instruction Exception<br />
Address<br />
Mode<br />
div{u,s}.l (64-bit) Integer Unimplemented –(ssp), dr:dq<br />
mul{u,s}.l (64-bit) Integer Unimplemented –(ssp), dr:dq<br />
cas.{w,l} (mis) Integer Unimplemented dc:du,–(ssp)<br />
cas.{w,l} (mis) Integer Unimplemented dc:du,(ssp)+<br />
f.p (all) Floating-Point Unimplemented Data Type –(ssp), fpn<br />
f.p Floating-Point Unimplemented Data Type fpn, (ssp)+<br />
f.{b,w,l,s,d,x} Floating-Point Unimplemented Instruction –(ssp), fpn<br />
fs.b Floating-Point Unimplemented Instruction –(ssp)<br />
fmovem.x Floating-Point Unimplemented Instruction –(ssp), dn<br />
fmovem.x Floating-Point Unimplemented Instruction dn, (ssp)+<br />
f.x Underflow,SNAN fpn, (ssp)+<br />
f.{b,w,l} Enabled OPERR fpn, (ssp)+<br />
C-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA
C.5 INSTALLATION NOTES<br />
MC68060 Software Package<br />
This section provides a guide on how to install the <strong>M68060</strong>SP. The files provided in an<br />
<strong>M68060</strong>SP release are shown on Table C-7.<br />
Table C-7. Files Provided in an <strong>M68060</strong>SP Release<br />
File Description<br />
fpsp.sa Full floating-point kernel module<br />
pfpsp.sa Partial floating-point kernel module<br />
isp.sa Integer unimplemented exception handler module<br />
fplsp.sa Floating-point library module<br />
ilsp.sa Integer library module<br />
fskeleton.s Sample call-outs needed by fpsp.sa and pfpsp.sa<br />
iskeleton.s Sample call-outs needed by isp.sa<br />
os.s<br />
C.5.1 Installing the Library Modules<br />
The integer and floating-point library modules (files ilsp.sa and fplsp.sa) require a very simple<br />
installation procedure. A symbolic label needs to be added to the module top so that calling<br />
routines can use this to reference the other entry-points supplied by these modules as<br />
an offset from the top of the module. It is the responsibility of the calling routine to enter the<br />
package through the proper offset relative to the top of the module.<br />
C.5.2 Installing the Kernel Modules<br />
Sample call-outs needed by fpsp.sa, pfpsp.sa and<br />
isp.sa<br />
fpsp.doc Release documentation for fpsp.sa and pfpsp.sa<br />
isp.doc Release documentation for isp.sa<br />
fplsp.doc Release documentation for fplsp.sa<br />
ilsp.doc Release documentation for ilsp.sa<br />
fpsp.s Source code of fpsp.sa<br />
pfpsp.s Source code of pfpsp.sa<br />
isp.s Source code of isp.sa<br />
fplsp.s Source code of fplsp.sa<br />
ilsp.s Source code of ilsp.sa<br />
The unimplemented integer instruction exception handler and full and/or partial floatingpoint<br />
kernel modules (files fpsp.sa, isp.sa, pfpsp.sa) may require additional steps. To aid in<br />
installation, three assembly language files are made available in the <strong>M68060</strong>SP release.<br />
These files contain the sample call-out routines and call-out dispatch tables for the unimplemented<br />
integer instruction exception handler module (iskeleton.s file), full or partial floatingpoint<br />
kernel modules (fskeleton.s file), and call-outs common to both (os.s file). When mod-<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-27
MC68060 Software Package<br />
ifying the call-out dispatch table, keep in mind that these need to be supplied and filled-in<br />
with module-relative, and not absolute addresses.<br />
The next step is to prepare the exception vector table. The appropriate vector table entries<br />
must be filled with the addresses of the appropriate entry points. Since the modified pseudoassembly<br />
module contains symbols that indicate the top of the module, the appropriate vector<br />
table entries must contain the symbol of the appropriate module top plus the pre-defined<br />
offset. Another alternative is to use the module code size information given in Table C-1 to<br />
concatenate the modules and use a single symbolic label to describe the combined module.<br />
Figure C-12 illustrates the relationship of the vector table to the <strong>M68060</strong>SP.<br />
VECTOR TABLE<br />
x_060SP:<br />
Figure C-12. Vector Table and <strong>M68060</strong>SP Relationship<br />
The last step is to link everything. Be aware that the files must be linked such that the parts<br />
of the module that are in different files are kept together. Be aware that the included files<br />
are for a very simple installation procedure and may not be appropriate for all systems. For<br />
instance, the supplied _real_trace routine would be inappropriate for a system in which the<br />
trace vector table entry is dynamically changed. For that system, the _real_trace routine<br />
must include vector table query before jumping to the actual trace routine.<br />
C.5.3 Release Notes and Module Offset Assignments<br />
OR<br />
os_code:<br />
<br />
VECTOR TABLE<br />
jmp os_done<br />
jmp x_060SP<br />
VECTOR ENTRY VECTOR ENTRY<br />
OS_done:<br />
<br />
rte<br />
(A) STRAIGHT ENTRY<br />
(B) INDIRECT ENTRY<br />
NOTE: X_060SP represents a generic <strong>M68060</strong>SP handler entry point and is not intended to imply a single shared handler entry<br />
point for all MC68060 exception handlers.<br />
To obtain the most up-to-date offset assignments for the call-out dispatch table and the module<br />
Entry-point Dispatch Section assignments, four document files are provided with the<br />
<strong>M68060</strong>SP release. The files isp.doc, ilsp.doc, fpsp.doc, and fplsp.doc define the offsets for<br />
the unimplemented integer instruction exception handler, unimplemented integer subroutine,<br />
full (or partial) floating-point kernel and floating-point library modules respectively. The<br />
current module sizes are shown in Table C-1. If a module increases in code size or if additional<br />
entry points are made available in future releases, they will be documented in these<br />
four files.<br />
C-28 <strong>M68060</strong> USER’S MANUAL MOTOROLA
C.5.4 AESOP Electronic Bulletin Board<br />
MC68060 Software Package<br />
Motorola’s AESOP electronic bulletin board contains the most current release of the<br />
<strong>M68060</strong>SP, as well as older releases of the <strong>M68060</strong>SP. The source code used to create the<br />
five pseudo-assembly files is provided for documentation purposes only and should not be<br />
used for generating a customized software package. Doing so would create versions of the<br />
package that is untested and unsupported by Motorola. Motorola will not create an assembly-to-assembly<br />
conversion software to provide a different assembler syntax than is already<br />
available. AESOP requires VT100 terminal emulation, 9600 Baud, 8 bits, no parity, and 1<br />
stop bit. The modem supports V.32bis and V.42bis and MNP5 protocols. The kermit protocol<br />
is needed to download from AESOP. AESOP can be reached at (800)843-3451 or (512)891-<br />
3650.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL C-29
APPENDIX D<br />
MC68060 INSTRUCTIONS<br />
This appendix provides a quick reference to instructions of the MC68060 that differ in<br />
description to the instruction description found in the M68000 Family Programmer’s Reference<br />
<strong>Manual</strong> (M68000PM/AD).<br />
To provide a quick summary of which instructions require software assistance from the<br />
<strong>M68060</strong> software package (<strong>M68060</strong>SP), and to indicate differences of the MC68060 relative<br />
to earlier members of the M68000 family, Table D-1 is provided. Table A-2 lists the M68000<br />
family instructions by mnemonics followed by the descriptive name. Table D-3 provides all<br />
assigned vector table entries up to, and including the MC68060. This may be useful for writing<br />
handlers that apply to multiple members of the M68000 family of processors.<br />
Since some of the MC68060 instructions require software-assist from the MC68060SP, it is<br />
assumed that the MC68060SP has already been installed properly in the system. Given this<br />
assumption, most of the description found in the M68000 FamilyProgrammer’s Reference<br />
<strong>Manual</strong> applies to the MC68060. In general, instruction descriptions that apply to the<br />
M68000 family, MC68040 or M68040FPSP apply also to the MC68060 or MC68060SP,<br />
unless otherwise provided in this appendix.<br />
MOTOROLA<br />
Table D-1. M68000 Family Instruction Set and Processor Cross-Reference<br />
Mnemonic MC68000/<br />
MC68008<br />
MC68010 MC68020 MC68030 MC68040 MC68060 MC68881/<br />
MC68882<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68851 CPU32<br />
ABCD X X X X X X X<br />
ADD X X X X X X X<br />
ADDA X X X X X X X<br />
ADDI X X X X X X X<br />
ADDQ X X X X X X X<br />
ADDX X X X X X X X<br />
AND X X X X X X X<br />
ANDI X X X X X X X<br />
ANDI to CCR X X X X X X X<br />
ANDI to SR1<br />
X X X X X X X<br />
ASL, ASR X X X X X X X<br />
Bcc X X X X X X X<br />
BCHG X X X X X X X<br />
BCLR X X X X X X X<br />
BFCHG X X X X<br />
BFCLR X X X X<br />
BFEXTS X X X X<br />
BFEXTU X X X X<br />
BFFFO X X X X<br />
D-1
MC68060 Instructions<br />
Table D-1. M68000 Family Instruction Set and Processor Cross-Reference (Continued)<br />
BFINS X X X X<br />
BFSET X X X X<br />
BFTST X X X X<br />
BGND X<br />
BKPT X X X X X X<br />
BRA X X X X X X X<br />
BSET X X X X X X X<br />
BSR X X X X X X X<br />
BTST X X X X X X X<br />
CALLM X<br />
CAS, CAS2 X X X X,3<br />
CHK X X X X X X X<br />
CHK2 X X X 3 X<br />
CINV1<br />
X X<br />
CLR X X X X X X X<br />
CMP X X X X X X X<br />
CMPA X X X X X X X<br />
CMPI X X X X X X X<br />
CMPM X X X X X X X<br />
CMP2 X X X 3 X<br />
cpBcc X X<br />
cpDBcc X X<br />
cpGEN X X<br />
cpRESTORE1<br />
D-2<br />
Mnemonic MC68000/<br />
MC68008<br />
MC68010 MC68020 MC68030 MC68040 MC68060 MC68881/<br />
MC68882<br />
X X<br />
cpSAVE1<br />
X X<br />
cpScc X X<br />
cpTRAPcc X X<br />
CPUSH1<br />
X X<br />
DBcc X X X X X X X<br />
DIVS X X X X X X,3 X<br />
DIVSL X X X X X<br />
DIVU X X X X X X,3 X<br />
DIVUL X X X X X<br />
EOR X X X X X X X<br />
EORI X X X X X X X<br />
EORI to CCR X X X X X X X<br />
EORI to SR1<br />
X X X X X X X<br />
EXG X X X X X X X<br />
EXT X X X X X X X<br />
EXTB X X X X X<br />
FABS X,2 X,2 X<br />
FSABS,<br />
FDABS<br />
X,2 X,2<br />
FACOS 2,3 2,3 X<br />
FADD X,2 X,2 X<br />
FSADD,<br />
FDADD<br />
X,2 X,2<br />
FASIN 2,3 2,3 X<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68851 CPU32<br />
MOTOROLA
FATAN 2,3 2,3 X<br />
FATANH 2,3 2,3 X<br />
FBcc X,2 X,2 X<br />
FCMP X,2 X,2 X<br />
FCOS 2,3 2,3 X<br />
FCOSH 2,3 2,3 X<br />
FDBcc X,2 2,3 X<br />
FDIV X,2 X,2 X<br />
FSDIV, FDDIV X,2 X,2<br />
FETOX 2,3 2,3 X<br />
FETOXM1 2,3 2,3 X<br />
FGETEXP 2,3 2,3 X<br />
FGETMAN 2,3 2,3 X<br />
FINT 2,3 X,2 X<br />
FINTRZ 2,3 X,2 X<br />
FLOG10 2,3 2,3 X<br />
FLOG2 2,3 2,3 X<br />
FLOGN 2,3 2,3 X<br />
FLOGNP1 2,3 2,3<br />
FMOD 2,3 2,3 X<br />
FMOVE X,2 X,2 X<br />
FSMOVE,<br />
FDMOVE<br />
X,2 X,2<br />
FMOVECR 2,3 2,3 X<br />
FMOVEM X,2 X,2,3 X<br />
FMUL X,2 X,2 X<br />
FSMUL,<br />
FDMUL<br />
X,2 X,2<br />
FNEG X,2 X,2 X<br />
FSNEG,<br />
FDNEG<br />
X,2 X,2<br />
FNOP X,2 X,2 X<br />
FREM 2,3 2,3 X<br />
FRESTORE1<br />
X,2 X,2 X<br />
FSAVE* X,2 X,2 X<br />
FSCALE 2,3 2,3 X<br />
FScc X,2 2,3 X<br />
FSGLDIV 2,3 2,3 X<br />
FSGLMUL 2,3 2,3 X<br />
FSIN 2,3 2,3 X<br />
FSINCOS 2,3 2,3 X<br />
FSINH 2,3 2,3 X<br />
FSQRT X,2 X,2 X<br />
FSSQRT,<br />
FDSQRT<br />
X,2 X,2<br />
FSUB X,2 X,2 X<br />
FSSUB,<br />
FDSUB<br />
X,2 X,2<br />
FTAN 2,3 2,3 X<br />
FTANH 2,3 2,3 X<br />
MOTOROLA<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
Table D-1. M68000 Family Instruction Set and Processor Cross-Reference (Continued)<br />
Mnemonic MC68000/<br />
MC68008<br />
MC68010 MC68020 MC68030 MC68040 MC68060 MC68881/<br />
MC68882<br />
MC68851 CPU32<br />
D-3
MC68060 Instructions<br />
Table D-1. M68000 Family Instruction Set and Processor Cross-Reference (Continued)<br />
FTENTOX 2,3 2,3 X<br />
FTRAPcc X,2 2,3 X<br />
FTST X,2 X,2 X<br />
FTWOTOX 2,3 2,3 X<br />
ILLEGAL X X X X X X X<br />
JMP X X X X X X X<br />
JSR X X X X X X X<br />
LEA X X X X X X X<br />
LINK X X X X X X X<br />
LPSTOP X<br />
LSL,LSR X X X X X X X<br />
MOVE X X X X X X X<br />
MOVEA X X X X X X X<br />
MOVE from<br />
CCR<br />
X X X X X X<br />
MOVE to CCR X X X X X X X<br />
MOVE<br />
from SR1<br />
4 X X X X X X<br />
MOVE<br />
to SR1<br />
X X X X X X X<br />
MOVE USP1<br />
X X X X X X X<br />
MOVE16 X X<br />
MOVEC1<br />
X X X X X X<br />
MOVEM X X X X X X X<br />
MOVEP X X X X X X<br />
MOVEQ X X X X X X X<br />
MOVES1<br />
X X X X X X<br />
MULS X X X X X X,3 X<br />
MULU X X X X X X,3 X<br />
NBCD X X X X X X X<br />
NEG X X X X X X X<br />
NEGX X X X X X X X<br />
NOP X X X X X X X<br />
NOT X X X X X X X<br />
OR X X X X X X X<br />
ORI X X X X X X X<br />
ORI to CCR X X X X X X X<br />
ORI to SR1<br />
X X X X X X X<br />
PACK X X X X<br />
PBcc1<br />
PDBcc1<br />
X<br />
PEA X X X X X X X<br />
D-4<br />
Mnemonic MC68000/<br />
MC68008<br />
PFLUSH1<br />
PFLUSHA1<br />
PFLUSHR1<br />
MC68010 MC68020 MC68030 MC68040 MC68060 MC68881/<br />
MC68882<br />
X,5 X X X<br />
X,5 X<br />
PFLUSHS1<br />
PLPA X<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68851 CPU32<br />
X<br />
X<br />
X<br />
MOTOROLA
PLOAD1<br />
PMOVE1<br />
PRESTORE1<br />
PSAVE1<br />
PScc1<br />
PTEST1<br />
MOTOROLA<br />
X,5 X<br />
X X<br />
X X X<br />
PTRAPcc1<br />
X<br />
PVALID X<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
Table D-1. M68000 Family Instruction Set and Processor Cross-Reference (Continued)<br />
Mnemonic MC68000/<br />
MC68008<br />
MC68010 MC68020 MC68030 MC68040 MC68060 MC68881/<br />
MC68882<br />
MC68851 CPU32<br />
RESET1<br />
X X X X X X X<br />
ROL,ROR X X X X X X X<br />
ROXL,<br />
ROXR<br />
X X X X X X X<br />
RTD X X X X X X<br />
RTE1<br />
X X X X X X X<br />
RTM X<br />
RTR X X X X X X X<br />
RTS X X X X X X X<br />
SBCD X X X X X X X<br />
Scc X X X X X X X<br />
STOP1<br />
X X X X X X X<br />
SUB X X X X X X X<br />
SUBA X X X X X X X<br />
SUBI X X X X X X X<br />
SUBQ X X X X X X X<br />
SUBX X X X X X X X<br />
SWAP X X X X X X X<br />
TAS X X X X X X X<br />
TBLS,<br />
TBLSN<br />
X<br />
TBLU,<br />
TBLUN<br />
X<br />
TRAP X X X X X X X<br />
TRAPcc X X X X X<br />
TRAPV X X X X X X X<br />
TST X X X X X X X<br />
UNLK X X X X X X X<br />
UNPK<br />
NOTES:<br />
X X X X<br />
1. Privileged (Supervisor) Instruction<br />
2. Not applicable to the MC68EC040, MC68LC040, MC68EC060, and MC68LC060.<br />
3. These are software-supported instructions on the MC68040 and MC68060.<br />
4. This instruction is not privileged for the MC68000 and MC68008.<br />
5. Not applicable to MC68EC030.<br />
6. All MC68060 and MC68040 Floating-point instructions require software assistance for unimplemented data types<br />
(MC68040 and MC68060) and unimplemented effective addresses (MC68060 only).<br />
X<br />
X<br />
X<br />
D-5
MC68060 Instructions<br />
D-6<br />
Table D-2. M68000 Family Instruction Set<br />
Mnemonic Description<br />
ABCD<br />
ADD<br />
ADDA<br />
ADDI<br />
ADDQ<br />
ADDX<br />
AND<br />
ANDI<br />
ANDI to CCR<br />
ANDI to SR<br />
ASL, ASR<br />
Bcc<br />
BCHG<br />
BCLR<br />
BFCHG<br />
BFCLR<br />
BFEXTS<br />
BFEXTU<br />
BFFFO<br />
BFINS<br />
BFSET<br />
BFTST<br />
BGND<br />
BKPT<br />
BRA<br />
BSET<br />
BSR<br />
BTST<br />
CALLM<br />
CAS<br />
CAS2<br />
CHK<br />
CHK2<br />
CINV<br />
CLR<br />
CMP<br />
CMPA<br />
CMPI<br />
CMPM<br />
CMP2<br />
cpBcc<br />
cpDBcc<br />
cpGEN<br />
cpRESTORE<br />
cpSAVE<br />
cpScc<br />
cpTRAPcc<br />
DBcc<br />
DIVS, DIVSL<br />
DIVU, DIVUL<br />
EOR<br />
EORI<br />
EORI to CCR<br />
EORI to SR<br />
EXG<br />
EXT, EXTB<br />
Add Decimal with Extend<br />
Add<br />
Address<br />
Add Immediate<br />
Add Quick<br />
Add with Extend<br />
Logical AND<br />
Logical AND Immediate<br />
AND Immediate to Condition Code Register<br />
AND Immediate to Status Register<br />
Arithmetic Shift Left and Right<br />
Branch Conditionally<br />
Test Bit and Change<br />
Test Bit and Clear<br />
Test Bit Field and Change<br />
Test Bit Field and Clear<br />
Signed Bit Field Extract<br />
Unsigned Bit Field Extract<br />
Bit Field Find First One<br />
Bit Field Insert<br />
Test Bit Field and Set<br />
Test Bit Field<br />
Enter Background Mode<br />
Breakpoint<br />
Branch<br />
Test Bit and Set<br />
Branch to Subroutine<br />
Test Bit<br />
CALL Module<br />
Compare and Swap Operands<br />
Compare and Swap Dual Operands<br />
Check Register Against Bound<br />
Check Register Against Upper and Lower Bounds<br />
Invalidate Cache Entries<br />
Clear<br />
Compare<br />
Compare Address<br />
Compare Immediate<br />
Compare Memory to Memory<br />
Compare Register Against Upper and Lower Bounds<br />
Branch on Coprocessor Condition<br />
Test Coprocessor Condition Decrement and Branch<br />
Coprocessor General Function<br />
Coprocessor Restore Function<br />
Coprocessor Save Function<br />
Set on Coprocessor Condition<br />
Trap on Coprocessor Condition<br />
Test Condition, Decrement and Branch<br />
Signed Divide<br />
Unsigned Divide<br />
Logical Exclusive-OR<br />
Logical Exclusive-OR Immediate<br />
Exclusive-OR Immediate to Condition Code Register<br />
Exclusive-OR Immediate to Status Register<br />
Exchange Registers<br />
Sign Extend<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
FABS<br />
FSFABS, FDFABS<br />
FACOS<br />
FADD<br />
FSADD, FDADD<br />
FASIN<br />
FATAN<br />
FATANH<br />
FBcc<br />
FCMP<br />
FCOS<br />
FCOSH<br />
FDBcc<br />
FDIV<br />
FSDIV, FDDIV<br />
FETOX<br />
FETOXM1<br />
FGETEXP<br />
FGETMAN<br />
FINT<br />
FINTRZ<br />
FLOG10<br />
FLOG2<br />
FLOGN<br />
FLOGNP1<br />
FMOD<br />
FMOVE<br />
FSMOVE,FDMOVE<br />
FMOVECR<br />
FMOVEM<br />
FMUL<br />
FSMUL,FDMUL<br />
FNEG<br />
FSNEG,FDNEG<br />
FNOP<br />
FREM<br />
FRESTORE<br />
FSAVE<br />
FSCALE<br />
FScc<br />
FSGLDIV<br />
FSGLMUL<br />
FSIN<br />
FSINCOS<br />
FSINH<br />
FSQRT<br />
FSSQRT,FDSQRT<br />
FSUB<br />
FSSUB,FDSUB<br />
FTAN<br />
FTANH<br />
FTENTOX<br />
FTRAPcc<br />
FTST<br />
FTWOTOX<br />
MOTOROLA<br />
Table D-2. M68000 Family Instruction Set (Continued)<br />
Mnemonic Description<br />
Floating-Point Absolute Value<br />
Floating-Point Absolute Value (Single/Double Precision)<br />
Floating-Point Arc Cosine<br />
Floating-Point Add<br />
Floating-Point Add (Single/Double Precision)<br />
Floating-Point Arc Sine<br />
Floating-Point Arc Tangent<br />
Floating-Point Hyperbolic Arc Tangent<br />
Floating-Point Branch<br />
Floating-Point Compare<br />
Floating-Point Cosine<br />
Floating-Point Hyperbolic Cosine<br />
Floating-Point Decrement and Branch<br />
Floating-Point Divide<br />
Floating-Point Divide (Single/Double Precision)<br />
Floating-Point ex<br />
Floating-Point e<br />
x<br />
–1<br />
Floating-Point Get Exponent<br />
Floating-Point Get Mantissa<br />
Floating-Point Integer Part<br />
Floating-Point Integer Part, Round-to-Zero<br />
Floating-Point Log10<br />
Floating-Point Log2<br />
Floating-Point Loge<br />
(x+1)<br />
Floating-Point Loge<br />
Floating-Point Modulo Remainder<br />
Move Floating-Point Register<br />
Move Floating-Point Register (Single/Double Precision)<br />
Move Constant ROM<br />
Move Multiple Floating-Point Registers<br />
Floating-Point Multiply<br />
Floating-Point Multiply (Single/Double Precision)<br />
Floating-Point Negate<br />
Floating-Point Negate (Single/Double Precision)<br />
Floating-Point No Operation<br />
IEEE Remainder<br />
Restore Floating-Point Internal State<br />
Save Floating-Point Internal State<br />
Floating-Point Scale Exponent<br />
Floating-Point Set According to Condition<br />
Single-Precision Divide<br />
Single-Precision Multiply<br />
Sine<br />
Simultaneous Sine and Cosine<br />
Hyperbolic Sine<br />
Floating-Point Square Root<br />
Floating-Point Square Root (Single/Double Precision)<br />
Floating-Point Subtract<br />
Floating-Point Subtract (Single/Double Precision)<br />
Tangent<br />
Hyperbolic Tangent<br />
Floating-Point 10x<br />
Floating-Point Trap on Condition<br />
Floating-Point Test<br />
Floating-Point 2x<br />
ILLEGAL Take Illegal Instruction Trap<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
D-7
MC68060 Instructions<br />
JMP<br />
JSR<br />
LEA<br />
LINK<br />
LPSTOP<br />
LSL, LSR<br />
MOVE<br />
MOVEA<br />
MOVE from CCR<br />
MOVE from SR<br />
MOVE to CCR<br />
MOVE to SR<br />
MOVE USP<br />
MOVE16<br />
MOVEC<br />
MOVEM<br />
MOVEP<br />
MOVEQ<br />
MOVES<br />
MULS<br />
MULU<br />
NBCD<br />
NEG<br />
NEGX<br />
NOP<br />
NOT<br />
OR<br />
ORI<br />
ORI to CCR<br />
ORI to SR<br />
PACK<br />
PBcc<br />
PDBcc<br />
PEA<br />
PFLUSH<br />
PFLUSHA<br />
PFLUSHR<br />
PFLUSHS<br />
PLOAD<br />
PLPA<br />
PMOVE<br />
PRESTORE<br />
PSAVE<br />
PScc<br />
PTEST<br />
PTRAPcc<br />
PVALID<br />
RESET<br />
ROL, ROR<br />
ROXL, ROXR<br />
RTD<br />
RTE<br />
RTM<br />
RTR<br />
RTS<br />
D-8<br />
Table D-2. M68000 Family Instruction Set (Continued)<br />
Mnemonic Description<br />
Jump<br />
Jump to Subroutine<br />
Load Effective Address<br />
Link and Allocate<br />
Low-Power Stop<br />
Logical Shift Left and Right<br />
Move<br />
Move Address<br />
Move from Condition Code Register<br />
Move from Status Register<br />
Move to Condition Code Register<br />
Move to Status Register<br />
Move User Stack Pointer<br />
16-Byte Block Move<br />
Move Control Register<br />
Move Multiple Registers<br />
Move Peripheral<br />
Move Quick<br />
Move Alternate Address Space<br />
Signed Multiply<br />
Unsigned Multiply<br />
Negate Decimal with Extend<br />
Negate<br />
Negate with Extend<br />
No Operation<br />
Logical Complement<br />
Logical Inclusive-OR<br />
Logical Inclusive-OR Immediate<br />
Inclusive-OR Immediate to Condition Code Register<br />
Inclusive-OR Immediate to Status Register<br />
Pack BCD<br />
Branch on PMMU Condition<br />
Test, Decrement, and Branch on PMMU Condition<br />
Push Effective Address<br />
Flush Entry(ies) in the ATCs<br />
Flush Entry(ies) in the ATCs<br />
Flush Entry(ies) in the ATCs and RPT Entries<br />
Flush Entry(ies) in the ATCs<br />
Load an Entry into the ATC<br />
Load Physical Address<br />
Move PMMU Register<br />
PMMU Restore Function<br />
PMMU Save Function<br />
Set on PMMU Condition<br />
Test a Logical Address<br />
Trap on PMMU Condition<br />
Validate a Pointer<br />
Reset External Devices<br />
Rotate Left and Right<br />
Rotate with Extend Left and Right<br />
Return and Deallocate<br />
Return from Exception<br />
Return from Module<br />
Return and Restore<br />
Return from Subroutine<br />
<strong>M68060</strong> USER’S MANUAL<br />
MOTOROLA
SBCD<br />
Scc<br />
STOP<br />
SUB<br />
SUBA<br />
SUBI<br />
SUBQ<br />
SUBX<br />
SWAP<br />
TAS<br />
TBLS, TBLSN<br />
TBLU, TBLUN<br />
TRAP<br />
TRAPcc<br />
TRAPV<br />
TST<br />
UNLK<br />
UNPK<br />
MOTOROLA<br />
Table D-2. M68000 Family Instruction Set (Continued)<br />
Mnemonic Description<br />
Subtract Decimal with Extend<br />
Set Conditionally<br />
Stop<br />
Subtract<br />
Subtract Address<br />
Subtract Immediate<br />
Subtract Quick<br />
Subtract with Extend<br />
Swap Register Words<br />
Test Operand and Set<br />
Signed Table Lookup with Interpolate<br />
Unsigned Table Lookup with Interpolate<br />
Trap<br />
Trap Conditionally<br />
Trap on Overflow<br />
Test Operand<br />
Unlink<br />
Unpack BCD<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
D-9
MC68060 Instructions<br />
D-10<br />
Vector<br />
Number(s)<br />
Table D-3. Exception Vector Assignments for the M68000 Family<br />
Vector<br />
Offset (Hex)<br />
<strong>M68060</strong> USER’S MANUAL<br />
Assignment<br />
0 000 Reset Initial Interrupt Stack Pointer<br />
1 004 Reset Initial Program Counter<br />
2 008 Access Fault<br />
3 00C Address Error<br />
4 010 Illegal Instruction<br />
5 014 Integer Divide-by-Zero<br />
6 018 CHK, CHK2 Instruction<br />
7 01C FTRAPcc, TRAPcc, TRAPV Instructions<br />
8 020 Privilege Violation<br />
9 024 Trace<br />
10 028 Line 1010 Emulator (Unimplemented A-Line Opcode)<br />
11 02C Line 1111 Emulator (Unimplemented F-Line Opcode)<br />
12 030 (Reserved)<br />
13 034 Coprocessor Protocol Violation (Defined for MC68020 and MC68030)<br />
14 038 Format Error<br />
15 03C Uninitialized Interrupt<br />
16–23 040–05C (Unassigned, Reserved)<br />
24 060 Spurious Interrupt<br />
25 064 Level 1 Interrupt Autovector<br />
26 068 Level 2 Interrupt Autovector<br />
27 06C Level 3 Interrupt Autovector<br />
28 070 Level 4 Interrupt Autovector<br />
29 074 Level 5 Interrupt Autovector<br />
30 078 Level 6 Interrupt Autovector<br />
31 07C Level 7 Interrupt Autovector<br />
32–47 080–0BC TRAP #0–15 Instruction Vectors<br />
48 0C0<br />
Floating-Point Branch or Set on Unordered Condition<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
49 0C4<br />
Floating-Point Inexact Result<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
50 0C8<br />
Floating-Point Divide-by-Zero<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
51 0CC<br />
Floating-Point Underflow<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
52 0D0<br />
Floating-Point Operand Error<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
53 0D4<br />
Floating-Point Overflow<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
54 0D8<br />
Floating-Point Signaling NAN<br />
(Defined for MC68881, MC68882, MC68040, and MC68060)<br />
55 0DC<br />
Floating-Point Unimplemented Data Type<br />
(Defined for MC68040 and MC68060)<br />
56 0E0 MMU Configuration Error (Defined for MC68030 and MC68851)<br />
57 0E4 MMU Illegal Operation Error (Defined for MC68851)<br />
58 0E8 MMU Access Level Violation Error (Defined for MC68851)<br />
59 0EC (Unassigned, Reserved)<br />
60 0F0 Unimplemented Effective Address (Defined for MC68060)<br />
61 0F4 Unimplemented Integer Instruction (Defined for MC68060)<br />
62–63 0F8–0FC (Unassigned, Reserved)<br />
64–255 100–3FC User Defined Vectors (192)<br />
MOTOROLA
CPUSH<br />
Operation:<br />
Assembler<br />
Syntax:<br />
Attributes:<br />
MOTOROLA<br />
Push and Possibly Invalidate Cache Line<br />
(MC68060, MC68LC060, MC68EC060)<br />
If Supervisor State, Then<br />
If Data Cache, Then<br />
Push Selected Dirty Data Cache Lines<br />
If DPI bit of CACR = 0, Then<br />
Invalidate Selected Cache Lines<br />
Endif<br />
Endif<br />
If Instruction Cache, Then<br />
Invalidate Selected Cache lines<br />
Endif<br />
Endif<br />
Else TRAP<br />
CPUSHL,(An)<br />
CPUSHP,(An)<br />
CPUSHA<br />
Where specifies the instruction cache, data<br />
cache, both caches, or neither cache.<br />
Unsized<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
CPUSH<br />
Description: Pushes and possibly invalidates selected cache lines. The data cache,<br />
instruction cache, both caches, or neither cache can be specified. When the data<br />
cache is specified, the selected data cache lines are first pushed to memory (if they<br />
contain dirty data) and then invalidated if the DPI bit of the CACR is cleared. Otherwise,<br />
the selected data cache lines remain valid. Selected instruction cache lines are invalidated.<br />
The CACR is accessed via the MOVEC instruction.<br />
Specific cache lines can be selected in three ways:<br />
1. CPUSHL pushes and possibly invalidates the cache line (if any) matching the<br />
physical address in the specified address register.<br />
2. CPUSHP pushes and possibly invalidates the cache lines (if any) matching the<br />
physical memory page in the specified address register. For example, if 4K-byte<br />
page sizes are selected and An contains $12345000, all cache lines matching<br />
page $12345000 are selected.<br />
3. CPUSHA pushes and possibly invalidates all cache entries.<br />
D-11
MC68060 Instructions<br />
CPUSH<br />
Condition Codes:<br />
Not affected.<br />
Instruction Format:<br />
Instruction Fields:<br />
D-12<br />
Push and Possibly Invalidate Cache Line<br />
(MC68060, MC68LC060, MC68EC060)<br />
<strong>M68060</strong> USER’S MANUAL<br />
CPUSH<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 1 0 0 CACHE 1 SCOPE REGISTER<br />
Cache field—Specifies the Cache.<br />
00—No Operation<br />
01—Data Cache<br />
10—Instruction Cache<br />
11—Data and Instruction Caches<br />
Scope field—Specifies the Scope of the Operation.<br />
00—Illegal (causes illegal instruction trap)<br />
01—Line<br />
10—Page<br />
11—All<br />
Register field—Specifies the address register for line and page operations. For line<br />
operations, the low-order bits 3–0 of the address are don’t care. Bits 11–0 or 12–0 of<br />
the address are don’t care for 4K-byte or 8K-byte page operations, respectively.<br />
MOTOROLA
FRESTORE<br />
Operation:<br />
Assembler<br />
Syntax:<br />
Attributes:<br />
MOTOROLA<br />
Restore Internal<br />
Floating-Point State<br />
(MC68060 only)<br />
If in Supervisor State<br />
Then FPU State Frame ➧ Internal State<br />
Else TRAP<br />
FRESTORE<br />
Unsized<br />
<strong>M68060</strong> USER’S MANUAL<br />
MC68060 Instructions<br />
FRESTORE<br />
Description: Aborts the execution of any floating-point operation in progress and loads<br />
a new floating-point unit internal state from the state frame located at the effective<br />
address. The state frame always contains three long words. The third byte from of the<br />
state frame specifies the frame format. The fourth byte of the state frame contains the<br />
exception vector. If the frame format is invalid, the FRESTORE aborts, and a format<br />
exception is generated. If the frame format is valid, the state frame is loaded, starting<br />
at the specified location and proceeding through higher addresses.<br />
The FRESTORE instruction does not normally affect the programmer’s model registers<br />
of the floating-point coprocessor, except for the NULL state frame. The FRESTORE<br />
instruction is used with the FMOVEM instruction to perform a full context restoration of<br />
the floating-point unit, including the floating-point data registers and system control registers.<br />
To accomplish a complete restoration, the FMOVEM instructions are first executed<br />
to load the programmer’s model, followed by the FRESTORE instruction to load<br />
the internal state.<br />
D-13
MC68060 Instructions<br />
FRESTORE<br />
D-14<br />
Restore Internal<br />
Floating-Point State<br />
(MC68060 only)<br />
<strong>M68060</strong> USER’S MANUAL<br />
FRESTORE<br />
The current implementation of the MC68060 supports the following four state frames:<br />
NULL: This state frame has a frame format of $00. An FRESTORE operation with<br />
this state frame is equivalent to a hardware reset of the floating-point unit.<br />
The programmer’s model is set to the reset state, with nonsignaling NANs<br />
in the floating-point data registers and zeros in the floating-point control register,<br />
floating-point status register, and floating-point instruction address<br />
register. (Thus, it is unnecessary to load the programmer’s model before<br />
this operation.)<br />
IDLE: This state frame has a frame format of $60. An FRESTORE operation with<br />
this state frame causes the floating-point unit to be restored to the idle state,<br />
waiting for the initiation of the next instruction, with no exceptions pending.<br />
The programmer’s model is not affected by loading this type of state frame.<br />
EXCP: This state frame has a frame format of $E0. An FRESTORE operation with<br />
this state frame causes the floating-point unit to be restored to an exceptional<br />
state. The exception vector field defines the type of exception that is<br />
pending. When in this state, initiation of any floating-point instruction with<br />
the exception of FSAVE or another FRESTORE causes the pending exception<br />
to be taken.The floating-point unit remains in this state until an FSAVE<br />
instruction is executed, then, it enters the idle state. The programmer’s<br />
model is not affected by loading this type of state frame.<br />
Floating-Point Status Register: Cleared if the state size is NULL; otherwise, not affected.<br />
MOTOROLA
MC68060 Instructions<br />
FRESTORE Restore Internal FRESTORE<br />
Floating-Point State<br />
Instruction Format:<br />
(MC68060 only)<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 0 1 1 0 1<br />
EFFECTIVE ADDRESS<br />
MODE REGISTER<br />
Instruction Field:<br />
Effective Address field—Determines the addressing mode for the state frame. Only<br />
postincrement or control addressing modes can be used as listed in the following table:<br />
Addressing Mode Mode Register Addressing Mode Mode Register<br />
Dn — — (xxx).W 111 000<br />
An — — (xxx).L 111 001<br />
(An) 010 reg. number:An # — —<br />
(An) + 011 reg. number:An<br />
–(An) — —<br />
(d16,An) 101 reg. number:An (d16,PC) 111 010<br />
(d8,An,Xn) 110 reg. number:An (d8,PC,Xn) 111 011<br />
(bd,An,Xn) 110 reg. number:An (bd,PC,Xn) 111 011<br />
([bd,An,Xn],od) 110 reg. number:An ([bd,PC,Xn],od) 111 011<br />
([bd,An],Xn,od) 110 reg. number:An ([bd,PC],Xn,od) 111 011<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-15
MC68060 Instructions<br />
FSAVE Save Internal Floating-Point State FSAVE<br />
(MC68060 only)<br />
Operation: If in Supervisor State<br />
Then FPU Internal State ➧ State Frame<br />
Else TRAP<br />
Assembler<br />
Syntax: FSAVE<br />
Attributes: Unsized<br />
Description: FSAVE allows the completion of any floating-point operation in progress. It<br />
saves the internal state of the floating-point unit in a state frame located at the effective<br />
address. After the save operation, the floating-point unit is in the idle state, waiting for<br />
the execution of the next instruction. The first long word written to the state frame contains<br />
the frame format on the third byte. The state frame always contains three long<br />
words.<br />
Any floating-point operation in progress when an FSAVE instruction is encountered<br />
can be completed before the FSAVE executes, saving an IDLE state frame. An IDLE<br />
state frame is created by the FSAVE if no exceptions occurred; otherwise, an EXCP<br />
state frame is created.<br />
D-16 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Instructions<br />
FSAVE Save Internal Floating-Point State FSAVE<br />
(MC68060 only)<br />
The following state frames apply to the MC68060.<br />
NULL: An FSAVE instruction that generates this state frame indicates that the<br />
floating-point unit state has not been modified since the last hardware reset<br />
or FRESTORE instruction with a NULL state frame. This indicates that the<br />
programmer’s model is in the reset state, with nonsignaling NANs in the<br />
floating-point data registers and zeros in the floating-point control register,<br />
floating-point status register, and floating-point instruction address register.<br />
(Thus, it is not necessary to save the programmer’s model.)<br />
IDLE: An FSAVE instruction that generates this state frame indicates that the<br />
floating-point unit finished in an idle condition and is without any pending<br />
exceptions waiting for the initiation of the next instruction.<br />
EXCP: An FSAVE instruction that generates this size state frame indicates that the<br />
floating-point unit encountered an exception while attempting to complete<br />
the execution of the previous floating-point instructions, or that an FRE-<br />
STORE of an EXCP frame occurred previously.<br />
The FSAVE does not save the programmer’s model registers of the floating-point unit;<br />
it saves only the user invisible portion of the machine. The FSAVE instruction may be<br />
used with the FMOVEM instruction to perform a full context save of the floating-point<br />
unit that includes the floating-point data registers and system control registers. To<br />
accomplish a complete context save, first execute an FSAVE instruction to suspend<br />
the current operation and save the internal state, then execute the appropriate<br />
FMOVEM instructions to store the programmer’s model.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-17
MC68060 Instructions<br />
FSAVE Save Internal Floating-Point State FSAVE<br />
(MC68060 only)<br />
Floating-Point Status Register: Not affected.<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 0 1 1 0 0<br />
EFFECTIVE ADDRESS<br />
MODEREGISTER<br />
Instruction Field:<br />
Effective Address field—Determines the addressing mode for the state frame. Only predecrement<br />
or control alterable addressing modes can be used as listed in the following<br />
table:<br />
Addressing Mode Mode Register Addressing Mode Mode Register<br />
Dn — — (xxx).W 111 000<br />
An — — (xxx).L 111 001<br />
(An) 010 reg. number:An # — —<br />
(An) + — —<br />
–(An) 100 reg. number:An<br />
(d16,An) 101 reg. number:An (d16,PC) — —<br />
(d8,An,Xn) 110 reg. number:An (d8,PC,Xn) — —<br />
(bd,An,Xn) 110 reg. number:An (bd,PC,Xn) — —<br />
([bd,An,Xn],od) 110 reg. number:An ([bd,PC,Xn],od) — —<br />
([bd,An],Xn,od) 110 reg. number:An ([bd,PC],Xn,od) — —<br />
D-18 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Instructions<br />
LPSTOP Low-Power Stop LPSTOP<br />
(MC68060, MC68LC060, MC68EC060)<br />
Operation: If Supervisor State<br />
Generate an LPSTOP Broadcast Cycle<br />
Immediate Data ➧ SR<br />
“10110” ➧ PST[4:0]<br />
STOP<br />
Else TRAP<br />
Assembler<br />
Syntax: LPSTOP #<br />
Attributes: Size = (Word) Privileged<br />
Description: Moves the immediate operand into the status register (SR). The program<br />
counter (PC) is advanced to the next instruction and the processor stops fetching and<br />
executing instructions.<br />
An interrupt or reset exception causes the processor to resume instruction execution<br />
from an LPSTOP state. If an interrupt request is asserted with a higher priority than the<br />
current priority level set by the new SR value, an interrupt exception occurs: otherwise<br />
the interrupt request is ignored. An external reset always initiates reset exception processing.<br />
A trace exception occurs if the trace bit in the SR is enabled when the LPSTOP instruction<br />
begins execution.<br />
A privilege violation is caused by attempting to clear the S-bit of the SR on LPSTOP.<br />
The MC68060 executes the LPSTOP instruction as follows:<br />
1. It synchronizes the pipelines.<br />
2. An LPSTOP broadcast cycle is generated (write cycle):<br />
TT1–TT0 = 3<br />
TM2–TM0 = 0<br />
SIZ1–SIZ0 = 2<br />
31–A0 = $FFFFFFFE<br />
D15–D0 = immediate data<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-19
MC68060 Instructions<br />
LPSTOP Low-Power Stop LPSTOP<br />
(MC68060, MC68LC060, MC68EC060)<br />
3. At the time of the bus cycle termination, (TA or TEA) the state of bus grant<br />
determines how the processor will leave the system bus while in the low-power<br />
stopped state. If the processor is granted the bus, it will drive the transfer<br />
attributes, address bus, data bus, and most control signals high while in the<br />
low-power stopped state. If the bus grant is removed from the processor, it will<br />
threestate all threestateable signals of the system bus at the conclusion of the<br />
bus write broadcast cycle.<br />
4. After the broadcast cycle is complete the processor will load the immediate<br />
operand into the SR and drive the PST lines signalling the low-power stopped<br />
state has been entered.<br />
5. Once the low-power stopped state has been entered, the internal processor<br />
clock is disabled (except to a small number of flip flops to support interrupt and<br />
reset recognition) and all input signals except the RSTI and IPLx, may float.<br />
The processor clock (CLK) input may be stopped during the low-power<br />
stopped state for additional power saving. If this is done, CLK must be stopped<br />
in the low state.<br />
6. During entry into the low-power stopped state, the system bus must be quiescent<br />
from the cycle after the broadcast cycle termination until the PST signals<br />
indicate the low-power stopped state. During exit from the low-power stopped<br />
state, the system bus must be quiescent and control signal inputs to the processor<br />
negated, beginning with the cycle RSTI, or IPLx is asserted until the<br />
PST signals indicate that the processor is in an exception processing state.<br />
Condition Codes:<br />
Set according to the immediate operand.<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0<br />
0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0<br />
IMMEDIATE DATA<br />
Instruction Fields:<br />
Immediate field—Specifies the data to be loaded into the status register.<br />
D-20 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Instructions<br />
MOVEC Move Control Register MOVEC<br />
(MC68060, MC68LC060 and MC68EC060)<br />
Operation: If Supervisor State<br />
Then Rc ➧ Rn or Rn ➧ Rc<br />
Else TRAP<br />
Assembler MOVEC Rc,Rn<br />
Syntax: MOVEC Rn,Rc<br />
Attributes: Size = (Long)<br />
Description: Moves the contents of the specified control register (Rc) to the specified<br />
general register (Rn) or copies the contents of the specified general register to the<br />
specified control register. This is always a 32-bit transfer, even though the control register<br />
may be implemented with fewer bits. Unimplemented bits are read as zeros.<br />
Condition Codes: Not affected.<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
0 1 0 0 1 1 1 0 0 1 1 1 1 0 1 dr<br />
A/D REGISTER CONTROL REGISTER<br />
Instruction Fields:<br />
dr field—Specifies the direction of the transfer.<br />
0—Control register to general register.<br />
1—General register to control register.<br />
A/D field—Specifies the type of general register.<br />
0—Data Register<br />
1—Address Register<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-21
MC68060 Instructions<br />
MOVEC Move Control Register MOVEC<br />
(MC68060, MC68LC060 and MC68EC060)<br />
Register field—Specifies the register number.<br />
Control Register field—Specifies the control register.<br />
Hex1 Control Register<br />
000 Source Function Code (SFC)<br />
001 Destination Function Code (DFC)<br />
002 Cache Control Register (CACR)<br />
003 2 MMU Translation Control Register (TC)<br />
004 Instruction Transparent Translation Register 0 (ITT0)<br />
005 Instruction Transparent Translation Register 1 (ITT1)<br />
006 Data Transparent Translation Register 0 (DTT0)<br />
007 Data Transparent Translation Register 1 (DTT1)<br />
008 Bus Control Register (BUSCR)<br />
800 User Stack Pointer (USP)<br />
801 Vector Base Register (VBR)<br />
806 3 User Root Pointer (URP)<br />
807 3 Supervisor Root Pointer (SRP)<br />
808 Processor Configuration Register (PCR)<br />
NOTES:<br />
1. Any other code causes an illegal instruction exception.<br />
2. The E and P bits are undefined for the MC68EC060.<br />
3. These registers are undefined for the MC68EC060.<br />
D-22 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Instructions<br />
PLPA Load Physical Address PLPA<br />
(MC68060, MC68LC060)<br />
Operation: If Supervisor State<br />
Then Logical Address {DFC,An} translated to Physical<br />
Address ➧ An<br />
Else TRAP<br />
Assembler<br />
Syntax: PLPAR (An)<br />
PLPAW (An)<br />
Attributes: Unsized<br />
Description: Translates the logical address defined by the contents of the destination<br />
function code register (DFC2–DFC0) and the address register (An31–An0), using full<br />
paged MMU functionality including TTRs, and generates a 32-bit physical address,<br />
which is loaded into An. All access error checks are performed during the translation,<br />
including in the checks the read/write instruction type, and an access error exception<br />
will be taken for faulting conditions.<br />
PLPA is a privileged instruction; attempted execution in user mode will result in a privilege<br />
violation exception.<br />
As with normal address translation activity:<br />
If Data TTR hit<br />
Then Use TTR translation and An stays the same<br />
Else if E bit of TC Register = 0 or MDIS pin asserted<br />
Then Use Default TTR translation and An stays the same<br />
Else if E bit of TC Register =1 and MDIS pin negated and Data ATC hit<br />
Then use ATC translation and An = Physical Address<br />
Else if E bit of TC Register =1 and MDIS pin negated and Data ATC miss<br />
Then Tablewalk<br />
If Valid Page Descriptor Encountered<br />
Then update Data ATC and An = Physical Address<br />
Else Take Access Error Exception<br />
EndIF<br />
Condition Codes:<br />
Not affected.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-23
MC68060 Instructions<br />
PLPA Test a Logical Address PLPA<br />
(MC68060, MC68LC060)<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 1 0 1 1 R/W 0 0 1 ADDRESS REGISTER<br />
Instruction Fields:<br />
R/W field—Specifies simulating a read or write bus transfer.<br />
0—Write<br />
1—Read<br />
Register field—Specifies the address register containing the effective address for the<br />
instruction.<br />
D-24 <strong>M68060</strong> USER’S MANUAL MOTOROLA
MC68060 Instructions<br />
PLPA Load Physical Address PLPA<br />
(MC68EC060 Only)<br />
Operation: If Supervisor State<br />
Then No Operation<br />
Else TRAP<br />
Assembler<br />
Syntax: PLPAR (An)<br />
PLPAW (An)<br />
Attributes: Unsized<br />
Description: This instruction must not be executed on an MC68EC060.<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 1 0 1 1 R/W 0 0 1 ADDRESS REGISTER<br />
Instruction Fields:<br />
R/W field—Specifies simulating a read or write bus transfer.<br />
0—Write<br />
1—Read<br />
Register field—Specifies the address register containing the effective address for the<br />
instruction.<br />
MOTOROLA <strong>M68060</strong> USER’S MANUAL D-25
MC68060 Instructions<br />
PFLUSH Flush ATC Entries PFLUSH<br />
(MC68EC060 Only)<br />
Operation: If Supervisor State<br />
Then No Operation<br />
Else TRAP<br />
Assembler<br />
Syntax: PFLUSH (An)<br />
PFLUSHN (An)<br />
Attributes: Unsized<br />
Description: This instruction must not be executed on an MC68EC060.<br />
Instruction Format:<br />
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />
1 1 1 1 0 1 0 1 0 0 0 OPMODE ADDRESS REGISTER<br />
Instruction Fields:<br />
Opmode field—Specifies the flush destination. These bits are defined for the MC68060<br />
and MC68LC060, not for the MC68EC060.<br />
Register field—Specifies the address register containing the effective address for the<br />
instruction entry.<br />
D-26 <strong>M68060</strong> USER’S MANUAL MOTOROLA