Jia Liu | 31d157a | 2012-02-18 12:03:15 +0000 | [diff] [blame] | 1 | //===- HexagonSchedule.td - Hexagon Scheduling Definitions -*- tablegen -*-===// |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | |
| 10 | // Functional Units |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 11 | def LSUNIT : FuncUnit; // SLOT0 |
| 12 | def LUNIT : FuncUnit; // SLOT1 |
| 13 | def MUNIT : FuncUnit; // SLOT2 |
| 14 | def SUNIT : FuncUnit; // SLOT3 |
| 15 | def LOOPUNIT : FuncUnit; |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 16 | |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 17 | // Itinerary classes |
| 18 | def ALU32 : InstrItinClass; |
| 19 | def ALU64 : InstrItinClass; |
| 20 | def CR : InstrItinClass; |
| 21 | def J : InstrItinClass; |
| 22 | def JR : InstrItinClass; |
| 23 | def LD : InstrItinClass; |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 24 | def LD0 : InstrItinClass; |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 25 | def M : InstrItinClass; |
| 26 | def ST : InstrItinClass; |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 27 | def ST0 : InstrItinClass; |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 28 | def S : InstrItinClass; |
Sirish Pande | 71d5646 | 2012-05-03 16:18:50 +0000 | [diff] [blame] | 29 | def SYS : InstrItinClass; |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 30 | def ENDLOOP : InstrItinClass; |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 31 | def PSEUDO : InstrItinClass; |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 32 | def PSEUDOM : InstrItinClass; |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 33 | |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 34 | def HexagonItineraries : |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 35 | ProcessorItineraries<[LSUNIT, LUNIT, MUNIT, SUNIT, LOOPUNIT], [], [ |
Sirish Pande | 71d5646 | 2012-05-03 16:18:50 +0000 | [diff] [blame] | 36 | InstrItinData<ALU32 , [InstrStage<1, [LUNIT, LSUNIT, MUNIT, SUNIT]>]>, |
| 37 | InstrItinData<ALU64 , [InstrStage<1, [MUNIT, SUNIT]>]>, |
| 38 | InstrItinData<CR , [InstrStage<1, [SUNIT]>]>, |
| 39 | InstrItinData<J , [InstrStage<1, [SUNIT, MUNIT]>]>, |
| 40 | InstrItinData<JR , [InstrStage<1, [MUNIT]>]>, |
| 41 | InstrItinData<LD , [InstrStage<1, [LUNIT, LSUNIT]>]>, |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 42 | InstrItinData<LD0 , [InstrStage<1, [LSUNIT]>]>, |
Sirish Pande | 71d5646 | 2012-05-03 16:18:50 +0000 | [diff] [blame] | 43 | InstrItinData<M , [InstrStage<1, [MUNIT, SUNIT]>]>, |
| 44 | InstrItinData<ST , [InstrStage<1, [LSUNIT]>]>, |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 45 | InstrItinData<ST0 , [InstrStage<1, [LSUNIT]>]>, |
Sirish Pande | 71d5646 | 2012-05-03 16:18:50 +0000 | [diff] [blame] | 46 | InstrItinData<S , [InstrStage<1, [SUNIT, MUNIT]>]>, |
| 47 | InstrItinData<SYS , [InstrStage<1, [LSUNIT]>]>, |
Jyotsna Verma | 84a2c2b | 2013-02-14 19:57:17 +0000 | [diff] [blame] | 48 | InstrItinData<ENDLOOP, [InstrStage<1, [LOOPUNIT]>]>, |
| 49 | InstrItinData<PSEUDO , [InstrStage<1, [LUNIT, LSUNIT, MUNIT, SUNIT]>]>, |
| 50 | InstrItinData<PSEUDOM, [InstrStage<1, [MUNIT, SUNIT], 0>, |
| 51 | InstrStage<1, [MUNIT, SUNIT]>]> |
Andrew Trick | 2661b41 | 2012-07-07 04:00:00 +0000 | [diff] [blame] | 52 | ]>; |
| 53 | |
| 54 | def HexagonModel : SchedMachineModel { |
Andrew Trick | fc99299 | 2012-06-05 03:44:40 +0000 | [diff] [blame] | 55 | // Max issue per cycle == bundle width. |
| 56 | let IssueWidth = 4; |
Andrew Trick | 2661b41 | 2012-07-07 04:00:00 +0000 | [diff] [blame] | 57 | let Itineraries = HexagonItineraries; |
Sergei Larin | 3e59040 | 2012-09-04 14:49:56 +0000 | [diff] [blame] | 58 | let LoadLatency = 1; |
Andrew Trick | fc99299 | 2012-06-05 03:44:40 +0000 | [diff] [blame] | 59 | } |
Tony Linthicum | b4b5415 | 2011-12-12 21:14:40 +0000 | [diff] [blame] | 60 | |
| 61 | //===----------------------------------------------------------------------===// |
| 62 | // V4 Machine Info + |
| 63 | //===----------------------------------------------------------------------===// |
| 64 | |
| 65 | include "HexagonScheduleV4.td" |
| 66 | |
| 67 | //===----------------------------------------------------------------------===// |
| 68 | // V4 Machine Info - |
| 69 | //===----------------------------------------------------------------------===// |