OpenCores
URL https://opencores.org/ocsvn/aemb/aemb/trunk

Subversion Repositories aemb

[/] [aemb/] [tags/] [AEMB_711/] [rtl/] [verilog/] [aeMB_core.v] - Blame information for rev 16

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 3 sybreon
/*
2 16 sybreon
 * $Id: aeMB_core.v,v 1.3 2007-04-11 04:30:43 sybreon Exp $
3 3 sybreon
 *
4 11 sybreon
 * AEMB 32-bit Microblaze Compatible Core
5 3 sybreon
 * Copyright (C) 2006 Shawn Tan Ser Ngiap <shawn.tan@aeste.net>
6
 *
7
 * This library is free software; you can redistribute it and/or modify it
8
 * under the terms of the GNU Lesser General Public License as published by
9
 * the Free Software Foundation; either version 2.1 of the License,
10
 * or (at your option) any later version.
11
 *
12
 * This library is distributed in the hope that it will be useful, but
13
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
14
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
15
 * License for more details.
16
 *
17
 * You should have received a copy of the GNU Lesser General Public License
18
 * along with this library; if not, write to the Free Software Foundation, Inc.,
19
 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20
 *
21
 * DESCRIPTION
22
 * Microblaze compatible, WISHBONE compliant hardware core. This core is
23
 * capable of executing software compile for EDK 2.1 using GCC. It has the
24
 * capability of handling interrupts as well as exceptions.
25
 *
26
 * HISTORY
27
 * $Log: not supported by cvs2svn $
28 16 sybreon
 * Revision 1.2  2007/04/04 06:13:23  sybreon
29
 * Removed unused signals
30
 *
31 11 sybreon
 * Revision 1.1  2007/03/09 17:52:17  sybreon
32
 * initial import
33 3 sybreon
 *
34
 */
35
 
36
module aeMB_core (/*AUTOARG*/
37
   // Outputs
38 11 sybreon
   iwb_stb_o, iwb_adr_o, dwb_we_o, dwb_stb_o, dwb_dat_o, dwb_adr_o,
39 3 sybreon
   // Inputs
40 16 sybreon
   sys_rst_i, sys_int_i, sys_exc_i, sys_clk_i, iwb_dat_i, iwb_ack_i,
41
   dwb_dat_i, dwb_ack_i
42 3 sybreon
   );
43
   // Instruction WB address space
44
   parameter ISIZ = 32;
45
   // Data WB address space
46
   parameter DSIZ = 32;
47
 
48
   /*AUTOOUTPUT*/
49
   // Beginning of automatic outputs (from unused autoinst outputs)
50
   output [DSIZ-1:0]     dwb_adr_o;              // From aslu of aeMB_aslu.v
51
   output [31:0] dwb_dat_o;              // From regfile of aeMB_regfile.v
52
   output               dwb_stb_o;              // From decode of aeMB_decode.v
53
   output               dwb_we_o;               // From decode of aeMB_decode.v
54
   output [ISIZ-1:0]     iwb_adr_o;              // From fetch of aeMB_fetch.v
55
   output               iwb_stb_o;              // From decode of aeMB_decode.v
56
   // End of automatics
57
   /*AUTOINPUT*/
58
   // Beginning of automatic inputs (from unused autoinst inputs)
59
   input                dwb_ack_i;              // To control of aeMB_control.v
60
   input [31:0]          dwb_dat_i;              // To regfile of aeMB_regfile.v, ...
61
   input                iwb_ack_i;              // To control of aeMB_control.v
62
   input [31:0]          iwb_dat_i;              // To fetch of aeMB_fetch.v, ...
63
   input                sys_clk_i;              // To control of aeMB_control.v
64
   input                sys_exc_i;              // To control of aeMB_control.v
65
   input                sys_int_i;              // To control of aeMB_control.v
66
   input                sys_rst_i;              // To control of aeMB_control.v
67
   // End of automatics
68
   /*AUTOWIRE*/
69
   // Beginning of automatic wires (for undeclared instantiated-module outputs)
70
   wire                 drun;                   // From control of aeMB_control.v
71
   wire                 frun;                   // From control of aeMB_control.v
72
   wire                 nclk;                   // From control of aeMB_control.v
73
   wire                 nrst;                   // From control of aeMB_control.v
74 16 sybreon
   wire                 nrun;                   // From control of aeMB_control.v
75 3 sybreon
   wire                 rBRA;                   // From decode of aeMB_decode.v
76
   wire                 rDLY;                   // From decode of aeMB_decode.v
77
   wire                 rDWBSTB;                // From decode of aeMB_decode.v
78
   wire                 rDWBWE;                 // From decode of aeMB_decode.v
79
   wire [1:0]            rFSM;                   // From control of aeMB_control.v
80
   wire [15:0]           rIMM;                   // From decode of aeMB_decode.v
81
   wire                 rIWBSTB;                // From decode of aeMB_decode.v
82
   wire                 rLNK;                   // From decode of aeMB_decode.v
83
   wire [1:0]            rMXALU;                 // From decode of aeMB_decode.v
84 11 sybreon
   wire [1:0]            rMXLDST;                // From decode of aeMB_decode.v
85 3 sybreon
   wire [1:0]            rMXSRC;                 // From decode of aeMB_decode.v
86
   wire [1:0]            rMXTGT;                 // From decode of aeMB_decode.v
87
   wire [5:0]            rOPC;                   // From decode of aeMB_decode.v
88
   wire [31:0]           rPC;                    // From fetch of aeMB_fetch.v
89
   wire [4:0]            rRA;                    // From decode of aeMB_decode.v
90
   wire [4:0]            rRB;                    // From decode of aeMB_decode.v
91
   wire [4:0]            rRD;                    // From decode of aeMB_decode.v
92
   wire [4:0]            rRD_;                   // From decode of aeMB_decode.v
93
   wire [31:0]           rREGA;                  // From regfile of aeMB_regfile.v
94
   wire [31:0]           rREGB;                  // From regfile of aeMB_regfile.v
95
   wire [31:0]           rRESULT;                // From aslu of aeMB_aslu.v
96
   wire                 rRWE;                   // From decode of aeMB_decode.v
97
   wire [31:0]           rSIMM;                  // From decode of aeMB_decode.v
98
   // End of automatics
99
 
100
   aeMB_regfile #(DSIZ)
101
     regfile (/*AUTOINST*/
102
              // Outputs
103
              .dwb_dat_o                (dwb_dat_o[31:0]),
104
              .rREGA                    (rREGA[31:0]),
105
              .rREGB                    (rREGB[31:0]),
106
              // Inputs
107
              .dwb_dat_i                (dwb_dat_i[31:0]),
108
              .rDWBSTB                  (rDWBSTB),
109
              .rDWBWE                   (rDWBWE),
110
              .rRA                      (rRA[4:0]),
111
              .rRB                      (rRB[4:0]),
112
              .rRD                      (rRD[4:0]),
113
              .rRD_                     (rRD_[4:0]),
114
              .rRESULT                  (rRESULT[31:0]),
115
              .rFSM                     (rFSM[1:0]),
116
              .rPC                      (rPC[31:0]),
117
              .rLNK                     (rLNK),
118
              .rRWE                     (rRWE),
119
              .nclk                     (nclk),
120
              .nrst                     (nrst),
121
              .drun                     (drun),
122 16 sybreon
              .nrun                     (nrun));
123 3 sybreon
 
124
   aeMB_fetch #(ISIZ)
125
     fetch (/*AUTOINST*/
126
            // Outputs
127
            .iwb_adr_o                  (iwb_adr_o[ISIZ-1:0]),
128
            .rPC                        (rPC[31:0]),
129
            // Inputs
130
            .iwb_dat_i                  (iwb_dat_i[31:0]),
131
            .nclk                       (nclk),
132
            .nrst                       (nrst),
133 16 sybreon
            .nrun                       (nrun),
134 3 sybreon
            .rFSM                       (rFSM[1:0]),
135
            .rBRA                       (rBRA),
136
            .rRESULT                    (rRESULT[31:0]));
137
 
138
   aeMB_control
139
     control (/*AUTOINST*/
140
              // Outputs
141
              .rFSM                     (rFSM[1:0]),
142
              .nclk                     (nclk),
143
              .nrst                     (nrst),
144 16 sybreon
              .nrun                     (nrun),
145 3 sybreon
              .frun                     (frun),
146
              .drun                     (drun),
147
              // Inputs
148
              .sys_rst_i                (sys_rst_i),
149
              .sys_clk_i                (sys_clk_i),
150
              .sys_int_i                (sys_int_i),
151
              .sys_exc_i                (sys_exc_i),
152
              .rIWBSTB                  (rIWBSTB),
153
              .iwb_ack_i                (iwb_ack_i),
154
              .rDWBSTB                  (rDWBSTB),
155
              .dwb_ack_i                (dwb_ack_i),
156
              .rBRA                     (rBRA),
157
              .rDLY                     (rDLY));
158
 
159
   aeMB_aslu #(DSIZ)
160
     aslu (/*AUTOINST*/
161
           // Outputs
162
           .dwb_adr_o                   (dwb_adr_o[DSIZ-1:0]),
163
           .rRESULT                     (rRESULT[31:0]),
164
           // Inputs
165
           .dwb_dat_i                   (dwb_dat_i[31:0]),
166
           .rBRA                        (rBRA),
167
           .rDLY                        (rDLY),
168
           .rREGA                       (rREGA[31:0]),
169
           .rREGB                       (rREGB[31:0]),
170
           .rSIMM                       (rSIMM[31:0]),
171
           .rMXSRC                      (rMXSRC[1:0]),
172
           .rMXTGT                      (rMXTGT[1:0]),
173
           .rMXALU                      (rMXALU[1:0]),
174
           .rOPC                        (rOPC[5:0]),
175
           .rPC                         (rPC[31:0]),
176
           .rIMM                        (rIMM[15:0]),
177
           .rRD                         (rRD[4:0]),
178
           .rRA                         (rRA[4:0]),
179 11 sybreon
           .rMXLDST                     (rMXLDST[1:0]),
180 3 sybreon
           .nclk                        (nclk),
181
           .nrst                        (nrst),
182
           .drun                        (drun),
183 16 sybreon
           .nrun                        (nrun));
184 3 sybreon
 
185
   aeMB_decode
186
     decode (/*AUTOINST*/
187
             // Outputs
188
             .rSIMM                     (rSIMM[31:0]),
189
             .rMXALU                    (rMXALU[1:0]),
190
             .rMXSRC                    (rMXSRC[1:0]),
191
             .rMXTGT                    (rMXTGT[1:0]),
192
             .rRA                       (rRA[4:0]),
193
             .rRB                       (rRB[4:0]),
194
             .rRD                       (rRD[4:0]),
195
             .rRD_                      (rRD_[4:0]),
196
             .rOPC                      (rOPC[5:0]),
197
             .rIMM                      (rIMM[15:0]),
198
             .rDWBSTB                   (rDWBSTB),
199
             .rDWBWE                    (rDWBWE),
200
             .rIWBSTB                   (rIWBSTB),
201
             .rDLY                      (rDLY),
202
             .rLNK                      (rLNK),
203
             .rBRA                      (rBRA),
204
             .rRWE                      (rRWE),
205 11 sybreon
             .rMXLDST                   (rMXLDST[1:0]),
206 3 sybreon
             .iwb_stb_o                 (iwb_stb_o),
207
             .dwb_stb_o                 (dwb_stb_o),
208
             .dwb_we_o                  (dwb_we_o),
209
             // Inputs
210
             .rREGA                     (rREGA[31:0]),
211
             .rRESULT                   (rRESULT[31:0]),
212
             .iwb_dat_i                 (iwb_dat_i[31:0]),
213
             .dwb_dat_i                 (dwb_dat_i[31:0]),
214
             .nclk                      (nclk),
215
             .nrst                      (nrst),
216
             .drun                      (drun),
217
             .frun                      (frun),
218 16 sybreon
             .nrun                      (nrun));
219 3 sybreon
 
220
endmodule // aeMB_core

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.