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

Subversion Repositories or1k

[/] [or1k/] [tags/] [rel_15/] [or1200/] [rtl/] [verilog/] [or1200_sprs.v] - Diff between revs 736 and 788

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 736 Rev 788
Line 42... Line 42...
//////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////
//
//
// CVS Revision History
// CVS Revision History
//
//
// $Log: not supported by cvs2svn $
// $Log: not supported by cvs2svn $
 
// Revision 1.6  2002/03/11 01:26:57  lampret
 
// Changed generation of SPR address. Now it is ORed from base and offset instead of a sum.
 
//
// Revision 1.5  2002/02/01 19:56:54  lampret
// Revision 1.5  2002/02/01 19:56:54  lampret
// Fixed combinational loops.
// Fixed combinational loops.
//
//
// Revision 1.4  2002/01/23 07:52:36  lampret
// Revision 1.4  2002/01/23 07:52:36  lampret
// Changed default reset values for SR and ESR to match or1ksim's. Fixed flop model in or1200_dpram_32x32 when OR1200_XILINX_RAM32X1D is defined.
// Changed default reset values for SR and ESR to match or1ksim's. Fixed flop model in or1200_dpram_32x32 when OR1200_XILINX_RAM32X1D is defined.
Line 97... Line 100...
                // Clk & Rst
                // Clk & Rst
                clk, rst,
                clk, rst,
 
 
                // Internal CPU interface
                // Internal CPU interface
                flagforw, flag_we, flag, addrbase, addrofs, dat_i, alu_op, branch_op,
                flagforw, flag_we, flag, addrbase, addrofs, dat_i, alu_op, branch_op,
                epcr, eear, esr, except_start, except_started,
                epcr, eear, esr, except_started,
                to_wbmux, epcr_we, eear_we, esr_we, pc_we, sr,
                to_wbmux, epcr_we, eear_we, esr_we, pc_we, sr,
                spr_dat_cfgr, spr_dat_rf, spr_dat_npc, spr_dat_ppc, spr_dat_mac,
                spr_dat_cfgr, spr_dat_rf, spr_dat_npc, spr_dat_ppc, spr_dat_mac,
 
 
                // From/to other RISC units
                // From/to other RISC units
                spr_dat_pic, spr_dat_tt, spr_dat_pm,
                spr_dat_pic, spr_dat_tt, spr_dat_pm,
Line 133... Line 136...
input   [`OR1200_ALUOP_WIDTH-1:0]        alu_op;         // ALU operation
input   [`OR1200_ALUOP_WIDTH-1:0]        alu_op;         // ALU operation
input   [`OR1200_BRANCHOP_WIDTH-1:0]     branch_op;      // Branch operation
input   [`OR1200_BRANCHOP_WIDTH-1:0]     branch_op;      // Branch operation
input   [width-1:0]              epcr;           // EPCR0
input   [width-1:0]              epcr;           // EPCR0
input   [width-1:0]              eear;           // EEAR0
input   [width-1:0]              eear;           // EEAR0
input   [`OR1200_SR_WIDTH-1:0]   esr;            // ESR0
input   [`OR1200_SR_WIDTH-1:0]   esr;            // ESR0
input                           except_start;   // Start of exception
 
input                           except_started; // Exception was started
input                           except_started; // Exception was started
output  [width-1:0]              to_wbmux;       // For l.mfspr
output  [width-1:0]              to_wbmux;       // For l.mfspr
output                          epcr_we;        // EPCR0 write enable
output                          epcr_we;        // EPCR0 write enable
output                          eear_we;        // EEAR0 write enable
output                          eear_we;        // EEAR0 write enable
output                          esr_we;         // ESR0 write enable
output                          esr_we;         // ESR0 write enable
Line 340... Line 342...
//
//
// MTSPR/MFSPR interface
// MTSPR/MFSPR interface
//
//
always @(sprs_op or spr_addr or sys_data or spr_dat_mac or spr_dat_pic or spr_dat_pm or
always @(sprs_op or spr_addr or sys_data or spr_dat_mac or spr_dat_pic or spr_dat_pm or
        spr_dat_dmmu or spr_dat_immu or spr_dat_du or spr_dat_tt) begin
        spr_dat_dmmu or spr_dat_immu or spr_dat_du or spr_dat_tt) begin
        case (sprs_op)  // synopsys full_case parallel_case
        case (sprs_op)  // synopsys parallel_case
                `OR1200_ALUOP_MTSR : begin
                `OR1200_ALUOP_MTSR : begin
                        write_spr = 1'b1;
                        write_spr = 1'b1;
                        read_spr = 1'b0;
                        read_spr = 1'b0;
                        to_wbmux = 32'b0;
                        to_wbmux = 32'b0;
                end
                end
                `OR1200_ALUOP_MFSR : begin
                `OR1200_ALUOP_MFSR : begin
                        casex (spr_addr[`OR1200_SPR_GROUP_BITS])
                        casex (spr_addr[`OR1200_SPR_GROUP_BITS]) // synopsys parallel_case
                                `OR1200_SPR_GROUP_TT:
                                `OR1200_SPR_GROUP_TT:
                                        to_wbmux = spr_dat_tt;
                                        to_wbmux = spr_dat_tt;
                                `OR1200_SPR_GROUP_PIC:
                                `OR1200_SPR_GROUP_PIC:
                                        to_wbmux = spr_dat_pic;
                                        to_wbmux = spr_dat_pic;
                                `OR1200_SPR_GROUP_PM:
                                `OR1200_SPR_GROUP_PM:

powered by: WebSVN 2.1.0

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