URL
https://opencores.org/ocsvn/or1200gct/or1200gct/trunk
Subversion Repositories or1200gct
[/] [or1200gct/] [trunk/] [or1200.tk] - Rev 9
Compare with Previous | Blame | View Log
#//////////////////////////////////////////////////////////////////////
#//// ////
#//// OR1200 graphic configuration tool ////
#//// ////
#//// Description ////
#//// Graphic configuration tool for OR1200 core ////
#//// ////
#//// To Do: ////
#//// - find bugs ////
#//// ////
#//// Author(s): ////
#//// - Javier Castillo, jcastillo@opencores.org ////
#//// ////
#//////////////////////////////////////////////////////////////////////
#//// ////
#//// Copyright (C) 2000 Authors and OPENCORES.ORG ////
#//// ////
#//// This source file may be used and distributed without ////
#//// restriction provided that this copyright statement is not ////
#//// removed from the file and that any derivative work contains ////
#//// the original copyright notice and the associated disclaimer. ////
#//// ////
#//// This source file is free software; you can redistribute it ////
#//// and/or modify it under the terms of the GNU Lesser General ////
#//// Public License as published by the Free Software Foundation; ////
#//// either version 2.1 of the License, or (at your option) any ////
#//// later version. ////
#//// ////
#//// This source is distributed in the hope that it will be ////
#//// useful, but WITHOUT ANY WARRANTY; without even the implied ////
#//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR ////
#//// PURPOSE. See the GNU Lesser General Public License for more ////
#//// details. ////
#//// ////
#//// You should have received a copy of the GNU Lesser General ////
#//// Public License along with this source; if not, download it ////
#//// from http://www.opencores.org/lgpl.shtml ////
#//// ////
#//////////////////////////////////////////////////////////////////////
#//
#// CVS Revision History
#//
#// $Log: not supported by cvs2svn $
#// Revision 1.5 2004/10/19 08:34:23 jcastillo
#// About window works in Windows
#// Version 0.1.2
#//
#// Revision 1.4 2004/10/19 08:23:37 jcastillo
#// Flash prefix generation corrected
#//
#// Revision 1.1.1.1 2004/09/23 10:03:08 jcastillo
#// First import
#//
#Defines variables for parameters and its default values
proc defaultvals { } {
global ASIC
global VCD_DUMP
global VERBOSE
global targetFPGA
global targetASIC
global ASIC_MULTP2_32X32
global BIST
global RF_RAM
#Wishbone defines
global REGISTERED_OUTPUTS
global REGISTERED_INPUTS
global NO_BURSTS
global WB_RETRY
global WB_CAB
global WB_B3
global CLKDIV2_SUPPORT
global CLKDIV4_SUPPORT
#Misc
global ADDITIONAL_SYNOPSYS_DIRECTIVES
global CASE_DEFAULT
global IMPL_MEM2REG
#IU defines
global SR_EPH_DEF
global IMPL_ADDC
global IMPL_CY
global ADDITIONAL_FLAG_MODIFIERS
global IMPL_DIV
global IMPL_ALU_ROTATE
global MULT_IMPLEMENTED
global LWPWR_MULT
global ALU_COMP
#PM defines
global PM_IMPLEMENTED
global PM_READREGS
global PM_UNUSED_ZERO
global PM_PARTIAL_DECODING
#DU defines
global DU_IMPLEMENTED
global DU_HWBKPTS
global DU_TB_IMPLEMENTED
global DU_READREGS
global DU_UNUSED_ZERO
global DU_STATUS_UNIMPLEMENTED
#PIC defines
global PIC_IMPLEMENTED
global PIC_READREGS
global PIC_UNUSED_ZERO
global PIC_PICMR
global PIC_PICSR
global PIC_INTS
#TT defines
global TT_IMPLEMENTED
global TT_TTMR
global TT_TTSR
global TT_READREGS
#IC CACHES
global NO_IC
global IC_WAYS
global IC_SIZE
global ICLS
#DC defines
global NO_DC
global DC_WAYS
global DC_SIZE
global DCLS
global SB_IMPLEMENTED
global SB_ENTRIES
global SB_LOG
#MMU defines
global NO_IMMU
global NO_DMMU
#QMEM defines
global QMEM_IMPLEMENTED
global QMEM_BSEL
global QMEM_ACK
#MISC defines
global MAC_IMPLEMENTED
global MAC_SPR_WE
global CFGR_IMPLEMENTED
global SYS_FULL_DECODE
#Target defines
set ASIC 0
set VCD_DUMP 0
set VERBOSE 0
set targetFPGA XILINX_RAMB4
set targetASIC VIRTUALSILICON_SSP
set ASIC_MULTP2_32X32 0
set BIST 0
set RF_RAM 2
#Wishbone defines
set REGISTERED_OUTPUTS 1
set REGISTERED_INPUTS 0
set NO_BURSTS 0
set WB_RETRY 0
set WB_CAB 1
set WB_B3 0
set CLKDIV2_SUPPORT 1
set CLKDIV4_SUPPORT 0
#Misc
set ADDITIONAL_SYNOPSYS_DIRECTIVES 0
set CASE_DEFAULT 1
set IMPL_MEM2REG 1
#IU defines
set SR_EPH_DEF 0
set IMPL_ADDC 1
set IMPL_CY 1
set ADDITIONAL_FLAG_MODIFIERS 0
set IMPL_DIV 0
set IMPL_ALU_ROTATE 0
set MULT_IMPLEMENTED 1
set LWPWR_MULT 0
set ALU_COMP 2
#PM defines
set PM_IMPLEMENTED 1
set PM_READREGS 1
set PM_UNUSED_ZERO 1
set PM_PARTIAL_DECODING 1
#DU defines
set DU_IMPLEMENTED 1
set DU_HWBKPTS 0
if { $ASIC==0 && ( $targetFPGA=="XILINX_RAMB4" || $targetFPGA=="XILINX_RAM32x1D" ) } {
set DU_TB_IMPLEMENTED 1
} else {
set DU_TB_IMPLEMENTED 0
}
set DU_READREGS 1
set DU_UNUSED_ZERO 1
set DU_STATUS_UNIMPLEMENTED 1
#PIC defines
set PIC_IMPLEMENTED 1
set PIC_READREGS 1
set PIC_UNUSED_ZERO 1
set PIC_PICMR 1
set PIC_PICSR 1
set PIC_INTS 20
#TT defines
set TT_IMPLEMENTED 1
set TT_TTMR 1
set TT_TTSR 1
set TT_READREGS 1
#IC defines
set NO_IC 0
set IC_WAYS 1
set IC_SIZE 8KB
set ICLS 16
#DC defines
set NO_DC 0
set DC_WAYS 1
set DC_SIZE 8KB
set DCLS 16
set SB_IMPLEMENTED 0
set SB_ENTRIES 4
set SB_LOG 2
#MMU defines
set NO_IMMU 0
set NO_DMMU 0
#QMEM defines
set QMEM_IMPLEMENTED 0
set QMEM_BSEL 0
set QMEM_ACK 0
#MISC defines
set MAC_IMPLEMENTED 1
set MAC_SPR_WE 1
set CFGR_IMPLEMENTED 1
set SYS_FULL_DECODE 1
}
#Target memories
lappend memFPGA "GENERIC" "ALTERA_LPM" "XILINX_RAMB4" "XILINX_RAM32x1D" "USE_RAM16x1D_FOR_RAM32X1D"
lappend memASIC "GENERIC" "ARTISAN_SSP" "ARTISAN_SDP" "ARTISAN_STP" "VIRTUALSILICON_SSP" "VIRTUALSILICON_STP_T1" "VIRTUALSILICON_STP_T2"
proc confFPGA { } {
global memFPGA
global ASIC_MULTP2_32X32
global targetFPGA
global RF_RAM
destroy .screen.memframe
destroy .screen.multframe
destroy .screen.bistframe
destroy .screen.rfframe
#Create a frame for the memory type selection
frame .screen.memframe -bd 2 -relief groove
pack .screen.memframe -side left -padx 2m -pady 2m
label .screen.memframe.meml -text "Target FPGA memories"
pack .screen.memframe.meml -side top
#Create the list for memories
set i 1
foreach mem $memFPGA {
radiobutton .screen.memframe.b$i -text $mem -variable targetFPGA -value $mem
pack .screen.memframe.b$i -side top -anchor w
incr i 1
}
#Create a frame for Register File memory type
frame .screen.rfframe -bd 2 -relief groove
pack .screen.rfframe -side top -padx 2m -pady 2m
label .screen.rfframe.rflab1 -text "Type of Register File RAM"
pack .screen.rfframe.rflab1 -side top
radiobutton .screen.rfframe.rf1 -text "Generic (flip-flop based) " -variable RF_RAM -value 0
radiobutton .screen.rfframe.rf2 -text "Two port RAM" -variable RF_RAM -value 1
radiobutton .screen.rfframe.rf3 -text "Dual port RAM" -variable RF_RAM -value 2
pack .screen.rfframe.rf1 .screen.rfframe.rf2 .screen.rfframe.rf3 -side top -anchor w
#Create a frame for the multiplier type selection
set ASIC_MULTP2_32X32 0
frame .screen.multframe -bd 2 -relief groove
pack .screen.multframe -side left -padx 2m -pady 2m
label .screen.multframe.multl -text "Multiplier"
pack .screen.multframe.multl -side top
radiobutton .screen.multframe.rmul1 -text "GENERIC 32x32 MULTIPLIER" -variable ASIC_MULTP2_32X32 -value 0
pack .screen.multframe.rmul1 -side top -anchor w
}
proc confASIC { } {
#Global var with all the posible target memories for ASIC
global memASIC
global targetASIC
global ASIC_MULTP2_32X32
global RF_RAM
destroy .screen.memframe
destroy .screen.multframe
destroy .screen.bistframe
destroy .screen.rfframe
#Create a frame for the memory type selection
frame .screen.memframe -bd 2 -relief groove
pack .screen.memframe -side left -padx 2m -pady 2m
label .screen.memframe.meml -text "Target ASIC memories"
pack .screen.memframe.meml -side top
#Create the list for memories
set i 1
foreach mem $memASIC {
radiobutton .screen.memframe.b$i -text $mem -variable targetASIC -value $mem
pack .screen.memframe.b$i -side top -anchor w
incr i 1
}
#Create a frame for Register File memory type
frame .screen.rfframe -bd 2 -relief groove
pack .screen.rfframe -side top -padx 2m -pady 2m
label .screen.rfframe.rflab1 -text "Type of Register File RAM"
pack .screen.rfframe.rflab1 -side top
radiobutton .screen.rfframe.rf1 -text "Generic (flip-flop based) " -variable RF_RAM -value 0
radiobutton .screen.rfframe.rf2 -text "Two port RAM" -variable RF_RAM -value 1
radiobutton .screen.rfframe.rf3 -text "Dual port RAM" -variable RF_RAM -value 2
pack .screen.rfframe.rf1 .screen.rfframe.rf2 .screen.rfframe.rf3 -side top -anchor w
#Create a frame for the multiplier type selection
frame .screen.multframe -bd 2 -relief groove
pack .screen.multframe -side top -padx 2m -pady 2m
label .screen.multframe.multl -text "Multiplier"
pack .screen.multframe.multl -side top
radiobutton .screen.multframe.rmul1 -text "GENERIC 32x32 MULTIPLIER" -variable ASIC_MULTP2_32X32 -value 0
radiobutton .screen.multframe.rmul2 -text "ASIC 32x32 MULTIPLIER" -variable ASIC_MULTP2_32X32 -value 1
pack .screen.multframe.rmul1 -side top -anchor w
pack .screen.multframe.rmul2 -side top -anchor w
}
proc about { } {
toplevel .dabout -class Dialog
wm title .dabout About
wm iconname .dabout Dialog
frame .dabout.top -relief raised -bd 1
pack .dabout.top -side top -fill both
frame .dabout.bot -relief raised -bd 1
pack .dabout.bot -side bottom -fill both
message .dabout.top.msg -width 8i -text "OpenRisc 1200 graphic configuration tool"
message .dabout.top.msg2 -width 8i -text "javier.castillo@urjc.es"
message .dabout.top.msg3 -width 8i -text "Version 0.1.2"
pack .dabout.top.msg .dabout.top.msg2 .dabout.top.msg3 -side top -expand 1 -fill both -padx 3m -pady 3m
}
proc confOR1200 { } {
destroy .d
toplevel .d -class Dialog
wm title .d "OpenRISC 1200 Core Configuration"
frame .d.left -relief raised -bd 1 -relief flat
frame .d.right -relief raised -bd 1 -relief flat
pack .d.left -side left -fill both
pack .d.right -side right -fill both
#Add buttons
button .d.left.iub -text "Integer Unit" -command { confIU }
button .d.left.icb -text "Instruction Cache" -command { confIC }
button .d.left.dcb -text "Data Cache" -command { confDC }
button .d.left.mmub -text "MMU" -command { confMMU }
button .d.left.dub -text "Debug Unit" -command { confDU }
button .d.left.pmb -text "Power Management" -command { confPM }
button .d.right.picb -text "PIC" -command { confPIC }
button .d.right.ttb -text "Tick Timer" -command { confTT }
button .d.right.qmb -text "Quick Embedded Memory" -command { confQM }
button .d.right.mcb -text "Misc" -command { confMISC }
button .d.right.exb -text "Exit" -command { destroy .d }
pack .d.left.iub .d.left.icb .d.left.dcb .d.left.mmub -padx 10m -fill x
pack .d.left.dub .d.left.pmb .d.right.picb -padx 10m -fill x
pack .d.right.ttb .d.right.qmb .d.right.mcb .d.right.exb -padx 10m -fill x
}
proc confIU { } {
destroy .diu
destroy .dmi
toplevel .diu -class Dialog
wm title .diu "Integer Unit"
frame .diu.top -relief raised -bd 1 -relief flat
frame .diu.top2 -relief raised -bd 1 -relief groove
frame .diu.top3 -relief raised -bd 1 -relief groove
frame .diu.top4 -relief raised -bd 1 -relief groove
frame .diu.top5 -relief raised -bd 1 -relief groove
frame .diu.top6 -relief raised -bd 1 -relief groove
frame .diu.top7 -relief raised -bd 1 -relief groove
frame .diu.top8 -relief raised -bd 1 -relief groove
frame .diu.top9 -relief raised -bd 1 -relief groove
frame .diu.top10 -relief raised -bd 1 -relief groove
frame .diu.top11 -relief raised -bd 1 -relief groove
pack .diu.top -side top -fill both
pack .diu.top2 -side top -fill both
pack .diu.top3 -side top -fill both
pack .diu.top4 -side top -fill both
pack .diu.top5 -side top -fill both
pack .diu.top6 -side top -fill both
pack .diu.top7 -side top -fill both
pack .diu.top8 -side top -fill both
pack .diu.top9 -side top -fill both
pack .diu.top10 -side top -fill both
pack .diu.top11 -side top -fill both
label .diu.top.opl -text "OpenRISC 1200 Integer Unit Configuration" -relief raised
pack .diu.top.opl -side top -pady 5m -padx 10m
radiobutton .diu.top2.flashy -text y -variable SR_EPH_DEF -value 1
radiobutton .diu.top2.flashn -text n -variable SR_EPH_DEF -value 0
pack .diu.top2.flashy .diu.top2.flashn -side left
radiobutton .diu.top3.addcy -text y -variable IMPL_ADDC -value 1
radiobutton .diu.top3.addcn -text n -variable IMPL_ADDC -value 0
pack .diu.top3.addcy .diu.top3.addcn -side left
radiobutton .diu.top4.cyy -text y -variable IMPL_CY -value 1
radiobutton .diu.top4.cyn -text n -variable IMPL_CY -value 0
pack .diu.top4.cyy .diu.top4.cyn -side left
radiobutton .diu.top5.addcompy -text y -variable ADDITIONAL_FLAG_MODIFIERS -value 1
radiobutton .diu.top5.addcompn -text n -variable ADDITIONAL_FLAG_MODIFIERS -value 0
pack .diu.top5.addcompy .diu.top5.addcompn -side left
radiobutton .diu.top6.divy -text y -variable IMPL_DIV -value 1
radiobutton .diu.top6.divn -text n -variable IMPL_DIV -value 0
pack .diu.top6.divy .diu.top6.divn -side left
radiobutton .diu.top7.roty -text y -variable IMPL_ALU_ROTATE -value 1
radiobutton .diu.top7.rotn -text n -variable IMPL_ALU_ROTATE -value 0
pack .diu.top7.roty .diu.top7.rotn -side left
radiobutton .diu.top8.muly -text y -variable MULT_IMPLEMENTED -value 1
radiobutton .diu.top8.muln -text n -variable MULT_IMPLEMENTED -value 0
pack .diu.top8.muly .diu.top8.muln -side left
radiobutton .diu.top9.lpmuly -text y -variable LWPWR_MULT -value 1
radiobutton .diu.top9.lpmuln -text n -variable LWPWR_MULT -value 0
pack .diu.top9.lpmuly .diu.top9.lpmuln -side left
radiobutton .diu.top10.comp1 -text 1 -variable ALU_COMP -value 1
radiobutton .diu.top10.comp2 -text 2 -variable ALU_COMP -value 2
pack .diu.top10.comp1 .diu.top10.comp2 -side left
label .diu.top2.flashl -text " Exception vectors in FLASH"
label .diu.top3.addcl -text " Implement l.addc instruction"
label .diu.top4.cyl -text " Implement carry bit SR\[CY\]"
label .diu.top5.fml -text " Add operations set compare flag when result is zero"
label .diu.top6.divl -text " Implement optional l.div/l.divu operations"
label .diu.top7.rotl -text " Implement rotate in the ALU"
label .diu.top8.mull -text " Implement multiplier"
label .diu.top9.lpmull -text " Low power multiplier"
label .diu.top10.compl -text " Type of ALU compare to implement"
pack .diu.top2.flashl .diu.top3.addcl .diu.top4.cyl .diu.top5.fml .diu.top6.divl .diu.top7.rotl .diu.top8.mull .diu.top9.lpmull .diu.top10.compl -side left
frame .diu.top11.left -relief raised -bd 1 -relief flat
frame .diu.top11.right -relief raised -bd 1 -relief flat
pack .diu.top11.left -side left -fill both
pack .diu.top11.right -side right -fill both
button .diu.top11.left.nextb -text "Next" -command { confIC }
button .diu.top11.right.exitb -text "Exit" -command { destroy .diu }
pack .diu.top11.left.nextb -side top -padx 10m -pady 5m -fill x
pack .diu.top11.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confPM { } {
destroy .dpm
destroy .ddu
toplevel .dpm -class Dialog
wm title .dpm "Power Management"
wm iconname .dpm Dialog
frame .dpm.top -relief raised -bd 1 -relief flat
frame .dpm.top2 -relief raised -bd 1 -relief groove
frame .dpm.top3 -relief raised -bd 1 -relief groove
frame .dpm.top4 -relief raised -bd 1 -relief groove
frame .dpm.top5 -relief raised -bd 1 -relief groove
frame .dpm.top6 -relief raised -bd 1 -relief groove
pack .dpm.top -side top -fill both
pack .dpm.top2 -side top -fill both
pack .dpm.top3 -side top -fill both
pack .dpm.top4 -side top -fill both
pack .dpm.top5 -side top -fill both
pack .dpm.top6 -side top -fill both
label .dpm.top.opl -text "OpenRISC 1200 Power Management Configuration" -relief raised
pack .dpm.top.opl -side top -pady 5m -padx 10m
radiobutton .dpm.top2.imply -text y -variable PM_IMPLEMENTED -value 1
radiobutton .dpm.top2.impln -text n -variable PM_IMPLEMENTED -value 0
pack .dpm.top2.imply .dpm.top2.impln -side left
radiobutton .dpm.top3.ready -text y -variable PM_READREGS -value 1
radiobutton .dpm.top3.readn -text n -variable PM_READREGS -value 0
pack .dpm.top3.ready .dpm.top3.readn -side left
radiobutton .dpm.top4.unusedy -text y -variable PM_UNUSED_ZERO -value 1
radiobutton .dpm.top4.unusedn -text n -variable PM_UNUSED_ZERO -value 0
pack .dpm.top4.unusedy .dpm.top4.unusedn -side left
radiobutton .dpm.top5.pary -text y -variable PM_PARTIAL_DECODING -value 1
radiobutton .dpm.top5.parn -text n -variable PM_PARTIAL_DECODING -value 0
pack .dpm.top5.pary .dpm.top5.parn -side left
label .dpm.top2.impll -text " Power Management Unit Implemented"
label .dpm.top3.readl -text " Read PMR is allowed"
label .dpm.top4.unusedl -text " Unused PMR bits should be zero"
label .dpm.top5.parl -text " PMR can be read/written at any address inside PM group"
pack .dpm.top2.impll -side left
pack .dpm.top3.readl -side left
pack .dpm.top4.unusedl -side left
pack .dpm.top5.parl -side left
frame .dpm.top6.left -relief raised -bd 1 -relief flat
frame .dpm.top6.right -relief raised -bd 1 -relief flat
pack .dpm.top6.left -side left -fill both
pack .dpm.top6.right -side right -fill both
button .dpm.top6.left.nextb -text "Next" -command { confPIC }
button .dpm.top6.right.exitb -text "Exit" -command { destroy .dpm }
pack .dpm.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dpm.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confDU { } {
global ASIC
global targetFPGA
destroy .dmu
destroy .ddu
toplevel .ddu -class Dialog
wm title .ddu "Debug Unit"
wm iconname .ddu Dialog
frame .ddu.top -relief raised -bd 1 -relief flat
frame .ddu.top2 -relief raised -bd 1 -relief groove
frame .ddu.top3 -relief raised -bd 1 -relief groove
frame .ddu.top4 -relief raised -bd 1 -relief groove
frame .ddu.top5 -relief raised -bd 1 -relief groove
frame .ddu.top6 -relief raised -bd 1 -relief groove
frame .ddu.top7 -relief raised -bd 1 -relief groove
frame .ddu.top8 -relief raised -bd 1 -relief groove
pack .ddu.top -side top -fill both
pack .ddu.top2 -side top -fill both
pack .ddu.top3 -side top -fill both
pack .ddu.top4 -side top -fill both
pack .ddu.top5 -side top -fill both
pack .ddu.top6 -side top -fill both
pack .ddu.top7 -side top -fill both
pack .ddu.top8 -side top -fill both
label .ddu.top.opl -text "OpenRISC 1200 Debug Unit Configuration" -relief raised
pack .ddu.top.opl -side top -pady 5m -padx 10m
radiobutton .ddu.top2.imply -text y -variable DU_IMPLEMENTED -value 1
radiobutton .ddu.top2.impln -text n -variable DU_IMPLEMENTED -value 0
pack .ddu.top2.imply .ddu.top2.impln -side left
radiobutton .ddu.top3.hwby -text y -variable DU_HWBKPTS -value 1
radiobutton .ddu.top3.hwbn -text n -variable DU_HWBKPTS -value 0
pack .ddu.top3.hwby .ddu.top3.hwbn -side left
#Trace buffer option only if Virtex FPGA selected
if { $ASIC==0 && ( $targetFPGA=="XILINX_RAMB4" || $targetFPGA=="XILINX_RAM32x1D" ) } {
radiobutton .ddu.top4.tby -text y -variable DU_TB_IMPLEMENTED -value 1
radiobutton .ddu.top4.tbn -text n -variable DU_TB_IMPLEMENTED -value 0
pack .ddu.top4.tby .ddu.top4.tbn -side left
label .ddu.top4.bufl -text " Trace Buffer implemented (Only for Xilinx FPGA)"
pack .ddu.top4.bufl -side left
} else {
set DU_TB_IMPLEMENTED 0
}
radiobutton .ddu.top5.ready -text y -variable DU_READREGS -value 1
radiobutton .ddu.top5.readn -text n -variable DU_READREGS -value 0
pack .ddu.top5.ready .ddu.top5.readn -side left
radiobutton .ddu.top6.unusedy -text y -variable DU_UNUSED_ZERO -value 1
radiobutton .ddu.top6.unusedn -text n -variable DU_UNUSED_ZERO -value 0
pack .ddu.top6.unusedy .ddu.top6.unusedn -side left
radiobutton .ddu.top7.ifstaty -text y -variable DU_STATUS_UNIMPLEMENTED -value 1
radiobutton .ddu.top7.ifstatn -text n -variable DU_STATUS_UNIMPLEMENTED -value 0
pack .ddu.top7.ifstaty .ddu.top7.ifstatn -side left
label .ddu.top2.impll -text " Debug Unit Implemented"
label .ddu.top3.hwbl -text " Hardware breakpoints implemented"
label .ddu.top5.readl -text " Read DU registers is allowed"
label .ddu.top6.unusedl -text " Unused DU registers bits should be zero"
label .ddu.top7.ifstatl -text " IF/LSU status is not needed by devel I/F"
pack .ddu.top2.impll -side left
pack .ddu.top3.hwbl -side left
pack .ddu.top5.readl -side left
pack .ddu.top6.unusedl -side left
pack .ddu.top7.ifstatl -side left
frame .ddu.top8.left -relief raised -bd 1 -relief flat
frame .ddu.top8.right -relief raised -bd 1 -relief flat
pack .ddu.top8.left -side left -fill both
pack .ddu.top8.right -side right -fill both
button .ddu.top8.left.nextb -text "Next" -command { confPM }
button .ddu.top8.right.exitb -text "Exit" -command { destroy .ddu }
pack .ddu.top8.left.nextb -side top -padx 10m -pady 5m -fill x
pack .ddu.top8.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confPIC { } {
destroy .dpic
destroy .dpm
toplevel .dpic -class Dialog
wm title .dpic "PIC"
wm iconname .dpic Dialog
frame .dpic.top -relief raised -bd 1 -relief flat
frame .dpic.top2 -relief raised -bd 1 -relief groove
frame .dpic.top3 -relief raised -bd 1 -relief groove
frame .dpic.top4 -relief raised -bd 1 -relief groove
frame .dpic.top5 -relief raised -bd 1 -relief groove
frame .dpic.top6 -relief raised -bd 1 -relief groove
frame .dpic.top7 -relief raised -bd 1 -relief groove
frame .dpic.top8 -relief raised -bd 1 -relief groove
pack .dpic.top -side top -fill both
pack .dpic.top2 -side top -fill both
pack .dpic.top3 -side top -fill both
pack .dpic.top4 -side top -fill both
pack .dpic.top5 -side top -fill both
pack .dpic.top6 -side top -fill both
pack .dpic.top7 -side top -fill both
pack .dpic.top8 -side top -fill both
label .dpic.top.opl -text "OpenRISC 1200 PIC Configuration" -relief raised
pack .dpic.top.opl -side top -pady 5m -padx 10m
radiobutton .dpic.top2.imply -text y -variable PIC_IMPLEMENTED -value 1
radiobutton .dpic.top2.impln -text n -variable PIC_IMPLEMENTED -value 0
pack .dpic.top2.imply .dpic.top2.impln -side left
entry .dpic.top3.entry1 -width 3 -relief sunken -bd 2 -textvariable PIC_INTS
pack .dpic.top3.entry1 -side left
radiobutton .dpic.top4.ready -text y -variable PIC_READREGS -value 1
radiobutton .dpic.top4.readn -text n -variable PIC_READREGS -value 0
pack .dpic.top4.ready .dpic.top4.readn -side left
radiobutton .dpic.top5.unusedy -text y -variable PIC_UNUSED_ZERO -value 1
radiobutton .dpic.top5.unusedn -text n -variable PIC_UNUSED_ZERO -value 0
pack .dpic.top5.unusedy .dpic.top5.unusedn -side left
radiobutton .dpic.top6.mry -text y -variable PIC_PICMR -value 1
radiobutton .dpic.top6.mrn -text n -variable PIC_PICMR -value 0
pack .dpic.top6.mry .dpic.top6.mrn -side left
radiobutton .dpic.top7.sry -text y -variable PIC_PICSR -value 1
radiobutton .dpic.top7.srn -text n -variable PIC_PICSR -value 0
pack .dpic.top7.sry .dpic.top7.srn -side left
label .dpic.top2.impll -text " PIC Implemented"
label .dpic.top3.numl -text " Number of interrupt inputs (2-31)"
label .dpic.top4.unusedl -text " Read PIC registers is allowed"
label .dpic.top5.parl -text " Unused PIC bits should be zero"
label .dpic.top6.mrl -text " Implement PICMR register"
label .dpic.top7.srl -text " Implement PICSR register"
pack .dpic.top2.impll -side left
pack .dpic.top3.numl -side left
pack .dpic.top4.unusedl -side left
pack .dpic.top5.parl -side left
pack .dpic.top6.mrl -side left
pack .dpic.top7.srl -side left
frame .dpic.top8.left -relief raised -bd 1 -relief flat
frame .dpic.top8.right -relief raised -bd 1 -relief flat
pack .dpic.top8.left -side left -fill both
pack .dpic.top8.right -side right -fill both
button .dpic.top8.left.nextb -text "Next" -command { confTT }
button .dpic.top8.right.exitb -text "Exit" -command { destroy .dpic }
pack .dpic.top8.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dpic.top8.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confTT { } {
destroy .dpic
destroy .dtt
toplevel .dtt -class Dialog
wm title .dtt "Tick Timer"
wm iconname .dtt Dialog
frame .dtt.top -relief raised -bd 1 -relief flat
frame .dtt.top2 -relief raised -bd 1 -relief groove
frame .dtt.top3 -relief raised -bd 1 -relief groove
frame .dtt.top4 -relief raised -bd 1 -relief groove
frame .dtt.top5 -relief raised -bd 1 -relief groove
frame .dtt.top6 -relief raised -bd 1 -relief groove
pack .dtt.top -side top -fill both
pack .dtt.top2 -side top -fill both
pack .dtt.top3 -side top -fill both
pack .dtt.top4 -side top -fill both
pack .dtt.top5 -side top -fill both
pack .dtt.top6 -side top -fill both
label .dtt.top.opl -text "OpenRISC 1200 Tick Timer Configuration" -relief raised
pack .dtt.top.opl -side top -pady 5m -padx 10m
radiobutton .dtt.top2.imply -text y -variable TT_IMPLEMENTED -value 1
radiobutton .dtt.top2.impln -text n -variable TT_IMPLEMENTED -value 0
pack .dtt.top2.imply .dtt.top2.impln -side left
radiobutton .dtt.top3.mry -text y -variable TT_TTMR -value 1
radiobutton .dtt.top3.mrn -text n -variable TT_TTMR -value 0
pack .dtt.top3.mry .dtt.top3.mrn -side left
radiobutton .dtt.top4.sry -text y -variable TT_TTSR -value 1
radiobutton .dtt.top4.srn -text n -variable TT_TTSR -value 0
pack .dtt.top4.sry .dtt.top4.srn -side left
radiobutton .dtt.top5.ready -text y -variable TT_READREGS -value 1
radiobutton .dtt.top5.readn -text n -variable TT_READREGS -value 0
pack .dtt.top5.ready .dtt.top5.readn -side left
label .dtt.top2.impll -text " Tick Timer Implemented"
label .dtt.top3.mrl -text " Implement TTMR register"
label .dtt.top4.srl -text " Implement TTSR register"
label .dtt.top5.readl -text " Read TT registers is allowed"
pack .dtt.top2.impll -side left
pack .dtt.top3.mrl -side left
pack .dtt.top4.srl -side left
pack .dtt.top5.readl -side left
frame .dtt.top6.left -relief raised -bd 1 -relief flat
frame .dtt.top6.right -relief raised -bd 1 -relief flat
pack .dtt.top6.left -side left -fill both
pack .dtt.top6.right -side right -fill both
button .dtt.top6.left.nextb -text "Next" -command { confQM }
button .dtt.top6.right.exitb -text "Exit" -command { destroy .dtt }
pack .dtt.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dtt.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confIC { } {
global IC_WAYS
global IC_SIZE
global ICLS
destroy .diu
destroy .dic
toplevel .dic -class Dialog
wm title .dic "Instruction Cache"
wm iconname .dic Dialog
frame .dic.top -relief raised -bd 1 -relief flat
frame .dic.top2 -relief raised -bd 1 -relief groove
frame .dic.top3 -relief raised -bd 1 -relief groove
frame .dic.top4 -relief raised -bd 1 -relief groove
frame .dic.top5 -relief raised -bd 1 -relief groove
frame .dic.top6 -relief raised -bd 1 -relief groove
pack .dic.top -side top -fill both
pack .dic.top2 -side top -fill both
pack .dic.top3 -side top -fill both
pack .dic.top4 -side top -fill both
pack .dic.top5 -side top -fill both
pack .dic.top6 -side top -fill both
label .dic.top.opl -text "OpenRISC 1200 Instruction Cache Configuration" -relief raised
pack .dic.top.opl -side top -pady 5m -padx 10m
radiobutton .dic.top2.imply -text y -variable NO_IC -value 0
radiobutton .dic.top2.impln -text n -variable NO_IC -value 1
pack .dic.top2.imply .dic.top2.impln -side left
menubutton .dic.top3.ways -text Ways -menu .dic.top3.ways.menu -relief raised
pack .dic.top3.ways -side left -fill both
menu .dic.top3.ways.menu
.dic.top3.ways.menu add radiobutton -label "1" -variable IC_WAYS -value 1
tk_menuBar .dic.top3.ways
menubutton .dic.top4.size -text Size -menu .dic.top4.size.menu -relief raised
pack .dic.top4.size -side left -fill both
menu .dic.top4.size.menu
.dic.top4.size.menu add radiobutton -label "512B" -variable IC_SIZE -value 512B
.dic.top4.size.menu add radiobutton -label "4KB" -variable IC_SIZE -value 4KB
.dic.top4.size.menu add radiobutton -label "8KB" -variable IC_SIZE -value 8KB
tk_menuBar .dic.top4.size
menubutton .dic.top5.lcls -text "Line Size" -menu .dic.top5.lcls.menu -relief raised
pack .dic.top5.lcls -side left -fill both
menu .dic.top5.lcls.menu
.dic.top5.lcls.menu add radiobutton -label "8" -variable ICLS -value 8
.dic.top5.lcls.menu add radiobutton -label "16" -variable ICLS -value 16
tk_menuBar .dic.top5.lcls
label .dic.top2.impll -text " Instruction Cache Implemented"
label .dic.top3.wayl -text " Instruction Cache Ways"
label .dic.top4.sizel -text " Instruction Cache Size"
label .dic.top5.lclsl -text " Instruction Cache Line Size in bytes"
pack .dic.top2.impll -side left
pack .dic.top3.wayl -side left
pack .dic.top4.sizel -side left
pack .dic.top5.lclsl -side left
frame .dic.top6.left -relief raised -bd 1 -relief flat
frame .dic.top6.right -relief raised -bd 1 -relief flat
pack .dic.top6.left -side left -fill both
pack .dic.top6.right -side right -fill both
button .dic.top6.left.nextb -text "Next" -command { confDC }
button .dic.top6.right.exitb -text "Exit" -command { destroy .dic }
pack .dic.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dic.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confDC { } {
global DC_WAYS
global DC_SIZE
global DCLS
destroy .ddc
destroy .dic
toplevel .ddc -class Dialog
wm title .ddc "Data Cache"
wm iconname .ddc Dialog
frame .ddc.top -relief raised -bd 1 -relief flat
frame .ddc.top2 -relief raised -bd 1 -relief groove
frame .ddc.top3 -relief raised -bd 1 -relief groove
frame .ddc.top4 -relief raised -bd 1 -relief groove
frame .ddc.top5 -relief raised -bd 1 -relief groove
frame .ddc.top6 -relief raised -bd 1 -relief groove
frame .ddc.top7 -relief raised -bd 1 -relief groove
frame .ddc.top8 -relief raised -bd 1 -relief groove
frame .ddc.top9 -relief raised -bd 1 -relief groove
frame .ddc.top10 -relief raised -bd 1 -relief groove
pack .ddc.top -side top -fill both
pack .ddc.top2 -side top -fill both
pack .ddc.top3 -side top -fill both
pack .ddc.top4 -side top -fill both
pack .ddc.top5 -side top -fill both
pack .ddc.top6 -side top -fill both
pack .ddc.top7 -side top -fill both
pack .ddc.top8 -side top -fill both
pack .ddc.top9 -side top -fill both
pack .ddc.top10 -side top -fill both
label .ddc.top.opl -text "OpenRISC 1200 Data Cache Configuration" -relief raised
pack .ddc.top.opl -side top -pady 5m -padx 10m
radiobutton .ddc.top2.imply -text y -variable NO_DC -value 0
radiobutton .ddc.top2.impln -text n -variable NO_DC -value 1
pack .ddc.top2.imply .ddc.top2.impln -side left
menubutton .ddc.top3.ways -text Ways -menu .ddc.top3.ways.menu -relief raised
pack .ddc.top3.ways -side left -fill both
menu .ddc.top3.ways.menu
.ddc.top3.ways.menu add radiobutton -label "1" -variable DC_WAYS -value 1
tk_menuBar .ddc.top3.ways
menubutton .ddc.top4.size -text Size -menu .ddc.top4.size.menu -relief raised
pack .ddc.top4.size -side left -fill both
menu .ddc.top4.size.menu
.ddc.top4.size.menu add radiobutton -label "4KB" -variable DC_SIZE -value 4KB
.ddc.top4.size.menu add radiobutton -label "8KB" -variable DC_SIZE -value 8KB
tk_menuBar .ddc.top4.size
menubutton .ddc.top5.lcls -text "Line Size" -menu .ddc.top5.lcls.menu -relief raised
pack .ddc.top5.lcls -side left -fill both
menu .ddc.top5.lcls.menu
.ddc.top5.lcls.menu add radiobutton -label "8" -variable DCLS -value 8
.ddc.top5.lcls.menu add radiobutton -label "16" -variable DCLS -value 16
tk_menuBar .ddc.top5.lcls
label .ddc.top6.opl -text "OpenRISC 1200 Store Buffer Configuration" -relief raised
pack .ddc.top6.opl -side top -pady 5m -padx 10m
radiobutton .ddc.top7.imply -text y -variable SB_IMPLEMENTED -value 1
radiobutton .ddc.top7.impln -text n -variable SB_IMPLEMENTED -value 0
pack .ddc.top7.imply .ddc.top7.impln -side left
menubutton .ddc.top8.sbs -text "Store Buffer Size" -menu .ddc.top8.sbs.menu -relief raised
pack .ddc.top8.sbs -side left -fill both
menu .ddc.top8.sbs.menu
.ddc.top8.sbs.menu add radiobutton -label "4" -variable SB_ENTRIES -value 4 -command { set SB_LOG 2 }
.ddc.top8.sbs.menu add radiobutton -label "8" -variable SB_ENTRIES -value 8 -command { set SB_LOG 3 }
tk_menuBar .ddc.top8.sbs
label .ddc.top2.impll -text " Data Cache Implemented"
label .ddc.top3.wayl -text " Data Cache Ways"
label .ddc.top4.sizel -text " Data Cache Size"
label .ddc.top5.lclsl -text " Data Cache Line Size in bytes"
label .ddc.top7.impl -text " Enable Store Buffer"
label .ddc.top8.sbel -text " Store Buffer Entries"
pack .ddc.top2.impll -side left
pack .ddc.top3.wayl -side left
pack .ddc.top4.sizel -side left
pack .ddc.top5.lclsl -side left
pack .ddc.top7.impl -side left
pack .ddc.top8.sbel -side left
frame .ddc.top10.left -relief raised -bd 1 -relief flat
frame .ddc.top10.right -relief raised -bd 1 -relief flat
pack .ddc.top10.left -side left -fill both
pack .ddc.top10.right -side right -fill both
button .ddc.top10.left.nextb -text "Next" -command { confMMU }
button .ddc.top10.right.exitb -text "Exit" -command { destroy .ddc }
pack .ddc.top10.left.nextb -side top -padx 10m -pady 5m -fill x
pack .ddc.top10.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confQM { } {
destroy .dqm
destroy .dtt
toplevel .dqm -class Dialog
wm title .dqm "Quick Embedded Memory"
wm iconname .dqm Dialog
frame .dqm.top -relief raised -bd 1 -relief flat
frame .dqm.top2 -relief raised -bd 1 -relief groove
frame .dqm.top3 -relief raised -bd 1 -relief groove
frame .dqm.top4 -relief raised -bd 1 -relief groove
frame .dqm.top6 -relief raised -bd 1 -relief groove
pack .dqm.top -side top -fill both
pack .dqm.top2 -side top -fill both
pack .dqm.top3 -side top -fill both
pack .dqm.top4 -side top -fill both
pack .dqm.top6 -side top -fill both
label .dqm.top.opl -text "OpenRISC 1200 Quick Embedded Memory Configuration" -relief raised
pack .dqm.top.opl -side top -pady 5m -padx 10m
radiobutton .dqm.top2.imply -text y -variable QMEM_IMPLEMENTED -value 1
radiobutton .dqm.top2.impln -text n -variable QMEM_IMPLEMENTED -value 0
pack .dqm.top2.imply .dqm.top2.impln -side left
radiobutton .dqm.top3.sely -text y -variable QMEM_BSEL -value 1
radiobutton .dqm.top3.seln -text n -variable QMEM_BSEL -value 0
pack .dqm.top3.sely .dqm.top3.seln -side left
radiobutton .dqm.top4.acky -text y -variable QMEM_ACK -value 1
radiobutton .dqm.top4.ackn -text n -variable QMEM_ACK -value 0
pack .dqm.top4.acky .dqm.top4.ackn -side left
label .dqm.top2.impll -text " Implement Quick Embedded Memory"
label .dqm.top3.sell -text " Enable qmem_sel* ports"
label .dqm.top4.ackl -text " Enable qmem_ack port"
pack .dqm.top2.impll -side left
pack .dqm.top3.sell -side left
pack .dqm.top4.ackl -side left
frame .dqm.top6.left -relief raised -bd 1 -relief flat
frame .dqm.top6.right -relief raised -bd 1 -relief flat
pack .dqm.top6.left -side left -fill both
pack .dqm.top6.right -side right -fill both
button .dqm.top6.left.nextb -text "Next" -command { confMISC }
button .dqm.top6.right.exitb -text "Exit" -command { destroy .dqm }
pack .dqm.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dqm.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confMMU { } {
destroy .dmu
destroy .ddc
toplevel .dmu -class Dialog
wm title .dmu "MMU"
wm iconname .dmu Dialog
frame .dmu.top -relief raised -bd 1 -relief flat
frame .dmu.top2 -relief raised -bd 1 -relief groove
frame .dmu.top3 -relief raised -bd 1 -relief groove
frame .dmu.top6 -relief raised -bd 1 -relief groove
pack .dmu.top -side top -fill both
pack .dmu.top2 -side top -fill both
pack .dmu.top3 -side top -fill both
pack .dmu.top6 -side top -fill both
label .dmu.top.opl -text "OpenRISC 1200 MMU Configuration" -relief raised
pack .dmu.top.opl -side top -pady 5m -padx 10m
radiobutton .dmu.top2.imply -text y -variable NO_IMMU -value 0
radiobutton .dmu.top2.impln -text n -variable NO_IMMU -value 1
pack .dmu.top2.imply .dmu.top2.impln -side left
radiobutton .dmu.top3.imply -text y -variable NO_DMMU -value 0
radiobutton .dmu.top3.impln -text n -variable NO_DMMU -value 1
pack .dmu.top3.imply .dmu.top3.impln -side left
label .dmu.top2.impll -text " Implement Instruction MMU"
label .dmu.top3.impll -text " Implement Data MMU"
pack .dmu.top2.impll -side left
pack .dmu.top3.impll -side left
frame .dmu.top6.left -relief raised -bd 1 -relief flat
frame .dmu.top6.right -relief raised -bd 1 -relief flat
pack .dmu.top6.left -side left -fill both
pack .dmu.top6.right -side right -fill both
button .dmu.top6.left.nextb -text "Next" -command { confDU }
button .dmu.top6.right.exitb -text "Exit" -command { destroy .dmu }
pack .dmu.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dmu.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc confMISC { } {
destroy .dmi
destroy .dqm
toplevel .dmi -class Dialog
wm title .dmi "Misc"
wm iconname .dmi Dialog
frame .dmi.top -relief raised -bd 1 -relief flat
frame .dmi.top2 -relief raised -bd 1 -relief groove
frame .dmi.top3 -relief raised -bd 1 -relief groove
frame .dmi.top4 -relief raised -bd 1 -relief groove
frame .dmi.top5 -relief raised -bd 1 -relief groove
frame .dmi.top6 -relief raised -bd 1 -relief groove
pack .dmi.top -side top -fill both
pack .dmi.top2 -side top -fill both
pack .dmi.top3 -side top -fill both
pack .dmi.top4 -side top -fill both
pack .dmi.top5 -side top -fill both
pack .dmi.top6 -side top -fill both
label .dmi.top.opl -text "OpenRISC 1200 Miscellaneous Configuration" -relief raised
pack .dmi.top.opl -side top -pady 5m -padx 10m
radiobutton .dmi.top2.imply -text y -variable MAC_IMPLEMENTED -value 1
radiobutton .dmi.top2.impln -text n -variable MAC_IMPLEMENTED -value 0
pack .dmi.top2.imply .dmi.top2.impln -side left
radiobutton .dmi.top3.macwey -text y -variable MAC_SPR_WE -value 1
radiobutton .dmi.top3.macwen -text n -variable MAC_SPR_WE -value 0
pack .dmi.top3.macwey .dmi.top3.macwen -side left
radiobutton .dmi.top4.imply -text y -variable CFGR_IMPLEMENTED -value 1
radiobutton .dmi.top4.impln -text n -variable CFGR_IMPLEMENTED -value 0
pack .dmi.top4.imply .dmi.top4.impln -side left
radiobutton .dmi.top5.sysy -text y -variable SYS_FULL_DECODE -value 1
radiobutton .dmi.top5.sysn -text n -variable SYS_FULL_DECODE -value 0
pack .dmi.top5.sysy .dmi.top5.sysn -side left
label .dmi.top2.impll -text " Implement Multiply and Accumulate (MAC) Unit"
label .dmi.top3.macwel -text " MACLO/MACHI registers are writable"
label .dmi.top4.impll -text " Implement configuration registers"
label .dmi.top5.sysl -text " Full address decode inside SYS group"
pack .dmi.top2.impll -side left
pack .dmi.top3.macwel -side left
pack .dmi.top4.impll -side left
pack .dmi.top5.sysl -side left
frame .dmi.top6.left -relief raised -bd 1 -relief flat
frame .dmi.top6.right -relief raised -bd 1 -relief flat
pack .dmi.top6.left -side left -fill both
pack .dmi.top6.right -side right -fill both
button .dmi.top6.left.nextb -text "Next" -command { confIU }
button .dmi.top6.right.exitb -text "Exit" -command { destroy .dmi }
pack .dmi.top6.left.nextb -side top -padx 10m -pady 5m -fill x
pack .dmi.top6.right.exitb -side top -padx 10m -pady 5m -fill x
}
proc saveconfdialog { } {
destroy .dsaveconf
toplevel .dsaveconf -class Dialog
wm title .dsaveconf "Save Configuration"
wm iconname .dsaveconf Dialog
frame .dsaveconf.top -relief raised -bd 1
pack .dsaveconf.top -side top -fill both
frame .dsaveconf.bot -relief raised -bd 1
pack .dsaveconf.bot -side top -fill both
label .dsaveconf.top.fn -text "Enter Filename" -relief raised
pack .dsaveconf.top.fn -side left -pady 5m -padx 10m
entry .dsaveconf.top.entry1 -width 20 -relief sunken -bd 2 -textvariable savefilename
pack .dsaveconf.top.entry1 -side left -pady 5m -padx 10m
frame .dsaveconf.bot.left -relief raised -bd 1 -relief flat
frame .dsaveconf.bot.right -relief raised -bd 1 -relief flat
pack .dsaveconf.bot.left -side left -fill both
pack .dsaveconf.bot.right -side right -fill both
button .dsaveconf.bot.left.okb -text "OK" -command { saveconf $savefilename }
button .dsaveconf.bot.right.cancelb -text "Cancel" -command { destroy .dsaveconf }
pack .dsaveconf.bot.left.okb -side top -padx 10m -pady 5m -fill x
pack .dsaveconf.bot.right.cancelb -side top -padx 10m -pady 5m -fill x
}
proc saveconf { file } {
global ASIC
global VCD_DUMP
global VERBOSE
global targetFPGA
global targetASIC
global ASIC_MULTP2_32X32
global BIST
global RF_RAM
#Wishbone defines
global REGISTERED_OUTPUTS
global REGISTERED_INPUTS
global NO_BURSTS
global WB_RETRY
global WB_CAB
global WB_B3
global CLKDIV2_SUPPORT
global CLKDIV4_SUPPORT
#Misc
global ADDITIONAL_SYNOPSYS_DIRECTIVES
global CASE_DEFAULT
global IMPL_MEM2REG
#IU defines
global SR_EPH_DEF
global IMPL_ADDC
global IMPL_CY
global ADDITIONAL_FLAG_MODIFIERS
global IMPL_DIV
global IMPL_ALU_ROTATE
global MULT_IMPLEMENTED
global LWPWR_MULT
global ALU_COMP
#PM defines
global PM_IMPLEMENTED
global PM_READREGS
global PM_UNUSED_ZERO
global PM_PARTIAL_DECODING
#DU defines
global DU_IMPLEMENTED
global DU_HWBKPTS
global DU_TB_IMPLEMENTED
global DU_READREGS
global DU_UNUSED_ZERO
global DU_STATUS_UNIMPLEMENTED
#PIC defines
global PIC_IMPLEMENTED
global PIC_READREGS
global PIC_UNUSED_ZERO
global PIC_PICMR
global PIC_PICSR
global PIC_INTS
#TT defines
global TT_IMPLEMENTED
global TT_TTMR
global TT_TTSR
global TT_READREGS
#IC CACHES
global NO_IC
global IC_WAYS
global IC_SIZE
global ICLS
#DC defines
global NO_DC
global DC_WAYS
global DC_SIZE
global DCLS
global SB_IMPLEMENTED
global SB_ENTRIES
global SB_LOG
#MMU defines
global NO_IMMU
global NO_DMMU
#QMEM defines
global QMEM_IMPLEMENTED
global QMEM_BSEL
global QMEM_ACK
#MISC defines
global MAC_IMPLEMENTED
global MAC_SPR_WE
global CFGR_IMPLEMENTED
global SYS_FULL_DECODE
set errorno [catch { set f [open $file w] } errorname ]
if { $errorno != 0 } {
errorfile
return
}
puts $f $ASIC
puts $f $VCD_DUMP
puts $f $VERBOSE
puts $f $targetFPGA
puts $f $targetASIC
puts $f $ASIC_MULTP2_32X32
puts $f $BIST
puts $f $RF_RAM
#Wishbone defines
puts $f $REGISTERED_OUTPUTS
puts $f $REGISTERED_INPUTS
puts $f $NO_BURSTS
puts $f $WB_RETRY
puts $f $WB_CAB
puts $f $WB_B3
puts $f $CLKDIV2_SUPPORT
puts $f $CLKDIV4_SUPPORT
#Misc
puts $f $ADDITIONAL_SYNOPSYS_DIRECTIVES
puts $f $CASE_DEFAULT
puts $f $IMPL_MEM2REG
#IU defines
puts $f $SR_EPH_DEF
puts $f $IMPL_ADDC
puts $f $IMPL_CY
puts $f $ADDITIONAL_FLAG_MODIFIERS
puts $f $IMPL_DIV
puts $f $IMPL_ALU_ROTATE
puts $f $MULT_IMPLEMENTED
puts $f $LWPWR_MULT
puts $f $ALU_COMP
#PM defines
puts $f $PM_IMPLEMENTED
puts $f $PM_READREGS
puts $f $PM_UNUSED_ZERO
puts $f $PM_PARTIAL_DECODING
#DU defines
puts $f $DU_IMPLEMENTED
puts $f $DU_HWBKPTS
puts $f $DU_TB_IMPLEMENTED
puts $f $DU_READREGS
puts $f $DU_UNUSED_ZERO
puts $f $DU_STATUS_UNIMPLEMENTED
#PIC defines
puts $f $PIC_IMPLEMENTED
puts $f $PIC_READREGS
puts $f $PIC_UNUSED_ZERO
puts $f $PIC_PICMR
puts $f $PIC_PICSR
puts $f $PIC_INTS
#TT defines
puts $f $TT_IMPLEMENTED
puts $f $TT_TTMR
puts $f $TT_TTSR
puts $f $TT_READREGS
#IC CACHES
puts $f $NO_IC
puts $f $IC_WAYS
puts $f $IC_SIZE
puts $f $ICLS
#DC defines
puts $f $NO_DC
puts $f $DC_WAYS
puts $f $DC_SIZE
puts $f $DCLS
puts $f $SB_IMPLEMENTED
puts $f $SB_ENTRIES
puts $f $SB_LOG
#MMU defines
puts $f $NO_IMMU
puts $f $NO_DMMU
#QMEM defines
puts $f $QMEM_IMPLEMENTED
puts $f $QMEM_BSEL
puts $f $QMEM_ACK
#MISC defines
puts $f $MAC_IMPLEMENTED
puts $f $MAC_SPR_WE
puts $f $CFGR_IMPLEMENTED
puts $f $SYS_FULL_DECODE
close $f
destroy .dsaveconf
}
proc loadconfdialog { } {
destroy .dloadconf
toplevel .dloadconf -class Dialog
wm title .dloadconf "Load Configuration"
wm iconname .dloadconf Dialog
frame .dloadconf.top -relief raised -bd 1
pack .dloadconf.top -side top -fill both
frame .dloadconf.bot -relief raised -bd 1
pack .dloadconf.bot -side top -fill both
label .dloadconf.top.fn -text "Enter Filename" -relief raised
pack .dloadconf.top.fn -side left -pady 5m -padx 10m
entry .dloadconf.top.entry1 -width 20 -relief sunken -bd 2 -textvariable loadfilename
pack .dloadconf.top.entry1 -side left -pady 5m -padx 10m
frame .dloadconf.bot.left -relief raised -bd 1 -relief flat
frame .dloadconf.bot.right -relief raised -bd 1 -relief flat
pack .dloadconf.bot.left -side left -fill both
pack .dloadconf.bot.right -side right -fill both
button .dloadconf.bot.left.okb -text "OK" -command { loadconf $loadfilename }
button .dloadconf.bot.right.cancelb -text "Cancel" -command { destroy .dloadconf }
pack .dloadconf.bot.left.okb -side top -padx 10m -pady 5m -fill x
pack .dloadconf.bot.right.cancelb -side top -padx 10m -pady 5m -fill x
}
proc loadconf { file } {
global ASIC
global VCD_DUMP
global VERBOSE
global targetFPGA
global targetASIC
global ASIC_MULTP2_32X32
global BIST
global RF_RAM
#Wishbone defines
global REGISTERED_OUTPUTS
global REGISTERED_INPUTS
global NO_BURSTS
global WB_RETRY
global WB_CAB
global WB_B3
global CLKDIV2_SUPPORT
global CLKDIV4_SUPPORT
#Misc
global ADDITIONAL_SYNOPSYS_DIRECTIVES
global CASE_DEFAULT
global IMPL_MEM2REG
#IU defines
global SR_EPH_DEF
global IMPL_ADDC
global IMPL_CY
global ADDITIONAL_FLAG_MODIFIERS
global IMPL_DIV
global IMPL_ALU_ROTATE
global MULT_IMPLEMENTED
global LWPWR_MULT
global ALU_COMP
#PM defines
global PM_IMPLEMENTED
global PM_READREGS
global PM_UNUSED_ZERO
global PM_PARTIAL_DECODING
#DU defines
global DU_IMPLEMENTED
global DU_HWBKPTS
global DU_TB_IMPLEMENTED
global DU_READREGS
global DU_UNUSED_ZERO
global DU_STATUS_UNIMPLEMENTED
#PIC defines
global PIC_IMPLEMENTED
global PIC_READREGS
global PIC_UNUSED_ZERO
global PIC_PICMR
global PIC_PICSR
global PIC_INTS
#TT defines
global TT_IMPLEMENTED
global TT_TTMR
global TT_TTSR
global TT_READREGS
#IC CACHES
global NO_IC
global IC_WAYS
global IC_SIZE
global ICLS
#DC defines
global NO_DC
global DC_WAYS
global DC_SIZE
global DCLS
global SB_IMPLEMENTED
global SB_ENTRIES
global SB_LOG
#MMU defines
global NO_IMMU
global NO_DMMU
#QMEM defines
global QMEM_IMPLEMENTED
global QMEM_BSEL
global QMEM_ACK
#MISC defines
global MAC_IMPLEMENTED
global MAC_SPR_WE
global CFGR_IMPLEMENTED
global SYS_FULL_DECODE
set errorno [catch { set f [open $file r] } errorname ]
if { $errorno != 0 } {
errorfile
return
}
set ASIC [gets $f]
set VCD_DUMP [gets $f]
set VERBOSE [gets $f]
set targetFPGA [gets $f]
set targetASIC [gets $f]
set ASIC_MULTP2_32X32 [gets $f]
set BIST [gets $f]
set RF_RAM [gets $f]
#Wishbone defines
set REGISTERED_OUTPUTS [gets $f]
set REGISTERED_INPUTS [gets $f]
set NO_BURSTS [gets $f]
set WB_RETRY [gets $f]
set WB_CAB [gets $f]
set WB_B3 [gets $f]
set CLKDIV2_SUPPORT [gets $f]
set CLKDIV4_SUPPORT [gets $f]
#Misc
set ADDITIONAL_SYNOPSYS_DIRECTIVES [gets $f]
set CASE_DEFAULT [gets $f]
set IMPL_MEM2REG [gets $f]
#IU defines
set SR_EPH_DEF [gets $f]
set IMPL_ADDC [gets $f]
set IMPL_CY [gets $f]
set ADDITIONAL_FLAG_MODIFIERS [gets $f]
set IMPL_DIV [gets $f]
set IMPL_ALU_ROTATE [gets $f]
set MULT_IMPLEMENTED [gets $f]
set LWPWR_MULT [gets $f]
set ALU_COMP [gets $f]
#PM defines
set PM_IMPLEMENTED [gets $f]
set PM_READREGS [gets $f]
set PM_UNUSED_ZERO [gets $f]
set PM_PARTIAL_DECODING [gets $f]
#DU defines
set DU_IMPLEMENTED [gets $f]
set DU_HWBKPTS [gets $f]
set DU_TB_IMPLEMENTED [gets $f]
set DU_READREGS [gets $f]
set DU_UNUSED_ZERO [gets $f]
set DU_STATUS_UNIMPLEMENTED [gets $f]
#PIC defines
set PIC_IMPLEMENTED [gets $f]
set PIC_READREGS [gets $f]
set PIC_UNUSED_ZERO [gets $f]
set PIC_PICMR [gets $f]
set PIC_PICSR [gets $f]
set PIC_INTS [gets $f]
#TT defines
set TT_IMPLEMENTED [gets $f]
set TT_TTMR [gets $f]
set TT_TTSR [gets $f]
set TT_READREGS [gets $f]
#IC CACHES
set NO_IC [gets $f]
set IC_WAYS [gets $f]
set IC_SIZE [gets $f]
set ICLS [gets $f]
#DC defines
set NO_DC [gets $f]
set DC_WAYS [gets $f]
set DC_SIZE [gets $f]
set DCLS [gets $f]
set SB_IMPLEMENTED [gets $f]
set SB_ENTRIES [gets $f]
set SB_LOG [gets $f]
#MMU defines
set NO_IMMU [gets $f]
set NO_DMMU [gets $f]
#QMEM defines
set QMEM_IMPLEMENTED [gets $f]
set QMEM_BSEL [gets $f]
set QMEM_ACK [gets $f]
#MISC defines
set MAC_IMPLEMENTED [gets $f]
set MAC_SPR_WE [gets $f]
set CFGR_IMPLEMENTED [gets $f]
set SYS_FULL_DECODE [gets $f]
close $f
destroy .dloadconf
}
proc export { } {
global ASIC
global VCD_DUMP
global VERBOSE
global targetFPGA
global targetASIC
global ASIC_MULTP2_32X32
global BIST
global RF_RAM
#Wishbone defines
global REGISTERED_OUTPUTS
global REGISTERED_INPUTS
global NO_BURSTS
global WB_RETRY
global WB_CAB
global WB_B3
global CLKDIV2_SUPPORT
global CLKDIV4_SUPPORT
#Misc
global ADDITIONAL_SYNOPSYS_DIRECTIVES
global CASE_DEFAULT
global IMPL_MEM2REG
#IU defines
global SR_EPH_DEF
global IMPL_ADDC
global IMPL_CY
global ADDITIONAL_FLAG_MODIFIERS
global IMPL_DIV
global IMPL_ALU_ROTATE
global MULT_IMPLEMENTED
global LWPWR_MULT
global ALU_COMP
#PM defines
global PM_IMPLEMENTED
global PM_READREGS
global PM_UNUSED_ZERO
global PM_PARTIAL_DECODING
#DU defines
global DU_IMPLEMENTED
global DU_HWBKPTS
global DU_TB_IMPLEMENTED
global DU_READREGS
global DU_UNUSED_ZERO
global DU_STATUS_UNIMPLEMENTED
#PIC defines
global PIC_IMPLEMENTED
global PIC_READREGS
global PIC_UNUSED_ZERO
global PIC_PICMR
global PIC_PICSR
global PIC_INTS
#TT defines
global TT_IMPLEMENTED
global TT_TTMR
global TT_TTSR
global TT_READREGS
#IC CACHES
global NO_IC
global IC_WAYS
global IC_SIZE
global ICLS
#DC defines
global NO_DC
global DC_WAYS
global DC_SIZE
global DCLS
global SB_IMPLEMENTED
global SB_ENTRIES
global SB_LOG
#MMU defines
global NO_IMMU
global NO_DMMU
#QMEM defines
global QMEM_IMPLEMENTED
global QMEM_BSEL
global QMEM_ACK
#MISC defines
global MAC_IMPLEMENTED
global MAC_SPR_WE
global CFGR_IMPLEMENTED
global SYS_FULL_DECODE
set errorno [catch { set f [open "or1200_config.v" w] } errorname ]
if { $errorno != 0 } {
errorfile
return
}
if { $ASIC == 1 } {
puts $f {`define OR1200_ASIC}
puts $f "`define OR1200_$targetASIC "
} else {
puts $f "`define OR1200_$targetFPGA "
}
if { $VCD_DUMP == 1 } {
puts $f {`define OR1200_VCD_DUMP }
}
if { $VERBOSE == 1 } {
puts $f {`define OR1200_VERBOSE }
}
if { $ASIC_MULTP2_32X32 == 1 } {
puts $f {`define OR1200_ASIC_MULTP2_32X32 }
} else {
puts $f {`define OR1200_GENERIC_MULTP2_32X32 }
}
if {$ASIC == 1 && ($targetASIC=="VIRTUALSILICON_SSP" | $targetASIC=="VIRTUALSILICON_STP_T1" | $targetASIC=="VIRTUALSILICON_STP_T2")} {
if { $BIST == 1 } {
puts $f {`define OR1200_BIST }
}
}
if { $RF_RAM == 0 } {
puts $f {`define OR1200_RFRAM_GENERIC }
} elseif { $RF_RAM == 1 } {
puts $f {`define OR1200_RFRAM_TWOPORT }
} else {
puts $f {`define OR1200_RFRAM_DUALPORT }
}
#Wishbone defines
if { $REGISTERED_OUTPUTS==1 } {
puts $f {`define OR1200_REGISTERED_OUTPUTS }
}
if { $REGISTERED_INPUTS==1 } {
puts $f {`define OR1200_REGISTERED_INPUTS }
}
if { $NO_BURSTS==1 } {
puts $f {`define OR1200_NO_BURSTS }
}
if { $WB_RETRY==1 } {
puts $f {`define OR1200_WB_RETRY }
}
if { $WB_CAB==1 } {
puts $f {`define OR1200_WB_CAB }
}
if { $WB_B3==1 } {
puts $f {`define OR1200_WB_B3 }
}
if { $CLKDIV2_SUPPORT==1 } {
puts $f {`define OR1200_CLKDIV2_SUPPORT }
}
if { $CLKDIV4_SUPPORT==1 } {
puts $f {`define OR1200_CLKDIV4_SUPPORT }
}
#Misc
if { $ADDITIONAL_SYNOPSYS_DIRECTIVES==1 } {
puts $f {`define OR1200_ADDITIONAL_SYNOPSYS_DIRECTIVES }
}
if { $CASE_DEFAULT==1 } {
puts $f {`define OR1200_CASE_DEFAULT }
}
if { $IMPL_MEM2REG==1 } {
puts $f {`define OR1200_IMPL_MEM2REG1 }
} else {
puts $f {`define OR1200_IMPL_MEM2REG2 }
}
#IU defines
if { $SR_EPH_DEF==1 } {
puts $f {`define OR1200_SR_EPH_DEF 1'b1}
} else {
puts $f {`define OR1200_SR_EPH_DEF 1'b0}
}
if { $IMPL_ADDC==1 } {
puts $f {`define OR1200_IMPL_ADDC }
}
if { $IMPL_CY==1 } {
puts $f {`define OR1200_IMPL_CY }
}
if { $ADDITIONAL_FLAG_MODIFIERS==1 } {
puts $f {`define OR1200_ADDITIONAL_FLAG_MODIFIERS }
}
if { $IMPL_DIV==1 } {
puts $f {`define OR1200_IMPL_DIV }
}
if { $IMPL_ALU_ROTATE==1 } {
puts $f {`define OR1200_IMPL_ALU_ROTATE }
}
if { $MULT_IMPLEMENTED==1 } {
puts $f {`define OR1200_MULT_IMPLEMENTED }
}
if { $LWPWR_MULT==1 } {
puts $f {`define OR1200_LWPWR_MULT }
}
if { $ALU_COMP==1 } {
puts $f {`define OR1200_ALU_COMP }
}
#PM defines
if { $PM_IMPLEMENTED==1 } {
puts $f {`define OR1200_PM_IMPLEMENTED }
}
if { $PM_READREGS==1 } {
puts $f {`define OR1200_PM_READREGS }
}
if { $PM_UNUSED_ZERO==1 } {
puts $f {`define OR1200_PM_UNUSED_ZERO }
}
if { $PM_PARTIAL_DECODING==1 } {
puts $f {`define OR1200_PM_PARTIAL_DECODING }
}
#DU defines
if { $DU_IMPLEMENTED==1 } {
puts $f {`define OR1200_DU_IMPLEMENTED }
}
if { $DU_HWBKPTS==1 } {
puts $f {`define OR1200_DU_HWBKPTS }
}
if { $DU_TB_IMPLEMENTED==1 && $ASIC==0 && $targetFPGA=="XILINX_RAMB4" } {
puts $f {`define OR1200_DU_TB_IMPLEMENTED }
}
if { $DU_READREGS==1 } {
puts $f {`define OR1200_DU_READREGS }
}
if { $DU_UNUSED_ZERO==1 } {
puts $f {`define OR1200_DU_UNUSED_ZERO }
}
if { $DU_STATUS_UNIMPLEMENTED==1 } {
puts $f {`define OR1200_DU_STATUS_UNIMPLEMENTED }
}
#PIC defines
if { $PIC_IMPLEMENTED==1 } {
puts $f {`define OR1200_PIC_IMPLEMENTED }
}
if { $PIC_READREGS==1 } {
puts $f {`define OR1200_PIC_READREGS }
}
if { $PIC_UNUSED_ZERO==1 } {
puts $f {`define OR1200_PIC_UNUSED_ZERO }
}
if { $PIC_PICMR==1 } {
puts $f {`define OR1200_PIC_PICMR }
}
if { $PIC_PICSR==1 } {
puts $f {`define OR1200_PIC_PICSR }
}
puts $f "`define OR1200_PIC_INTS $PIC_INTS"
#TT defines
if { $TT_IMPLEMENTED==1 } {
puts $f {`define OR1200_TT_IMPLEMENTED }
}
if { $TT_TTMR==1 } {
puts $f {`define OR1200_TT_TTMR }
}
if { $TT_TTSR==1 } {
puts $f {`define OR1200_TT_TTSR }
}
if { $TT_READREGS==1 } {
puts $f {`define OR1200_TT_READREGS }
}
#IC CACHES
if { $NO_IC==1 } {
puts $f {`define OR1200_NO_IC }
}
puts $f "`define OR1200_IC_$IC_WAYS\W_$IC_SIZE"
if { $ICLS==8 } {
puts $f {`define OR1200_ICLS 3 }
} else {
puts $f {`define OR1200_ICLS 4 }
}
#DC defines
if { $NO_DC==1 } {
puts $f {`define OR1200_NO_DC }
}
puts $f "`define OR1200_DC_$DC_WAYS\W_$DC_SIZE"
if { $DCLS==8 } {
puts $f {`define OR1200_DCLS 3 }
} else {
puts $f {`define OR1200_DCLS 4 }
}
if { $SB_IMPLEMENTED==1 } {
puts $f {`define OR1200_SB_IMPLEMENTED }
}
puts $f "`define OR1200_SB_ENTRIES $SB_ENTRIES"
puts $f "`define OR1200_SB_LOG $SB_LOG"
#MMU defines
if { $NO_IMMU==1 } {
puts $f {`define OR1200_NO_IMMU }
}
if { $NO_DMMU==1 } {
puts $f {`define OR1200_NO_DMMU }
}
#QMEM defines
if {$QMEM_IMPLEMENTED == 1} {
puts $f {`define OR1200_QMEM_IMPLEMENTED }
}
if {$QMEM_BSEL == 1} {
puts $f {`define OR1200_QMEM_BSEL }
}
if {$QMEM_ACK == 1} {
puts $f {`define OR1200_QMEM_ACK }
}
#MISC defines
if {$MAC_IMPLEMENTED == 1} {
puts $f {`define OR1200_MAC_IMPLEMENTED }
}
if {$MAC_SPR_WE == 1} {
puts $f {`define OR1200_MAC_SPR_WE }
}
if {$CFGR_IMPLEMENTED == 1} {
puts $f {`define OR1200_CFGR_IMPLEMENTED }
}
if {$SYS_FULL_DECODE == 1} {
puts $f {`define OR1200_SYS_FULL_DECODE }
}
close $f
}
proc errorfile { } {
destroy .derror
toplevel .derror -class Dialog
wm title .derror "Error in File Access"
wm iconname .derror Dialog
frame .derror.top -relief raised -bd 1
pack .derror.top -side top -fill both
frame .derror.bot -relief raised -bd 1
pack .derror.bot -side top -fill both
label .derror.top.fn -text "ERROR IN FILE ACCESS"
pack .derror.top.fn -side top -pady 5m -padx 10m
button .derror.bot.okb -text "OK" -command { destroy .derror }
pack .derror.bot.okb -side top -padx 10m -pady 5m -fill x
}
wm title . "OR1200 Graphic Configuration Tool"
#wm minsize . 1000 600
defaultvals
frame .mbar -relief raised -bd 2
frame .screen -width 15c -height 10c
pack .mbar .screen -side top -fill x
menubutton .mbar.file -text File -underline 0 -menu .mbar.file.menu
menubutton .mbar.synthesis -text Target -underline 0 -menu .mbar.synthesis.menu
menubutton .mbar.processor -text "Processor Settings" -underline 0 -menu .mbar.processor.menu
menubutton .mbar.wishbone -text Wishbone -underline 0 -menu .mbar.wishbone.menu
menubutton .mbar.misc -text Misc -underline 0 -menu .mbar.misc.menu
menubutton .mbar.simulation -text Simulation -underline 0 -menu .mbar.simulation.menu
menubutton .mbar.help -text Help -underline 0 -menu .mbar.help.menu
pack .mbar.file .mbar.synthesis .mbar.processor .mbar.wishbone .mbar.misc .mbar.simulation -side left
pack .mbar.help -side right
menu .mbar.file.menu
.mbar.file.menu add command -label "Load configuration" -command {loadconfdialog}
.mbar.file.menu add command -label "Save configuration" -command {saveconfdialog}
.mbar.file.menu add separator
.mbar.file.menu add command -label "Generate verilog configuration file" -command { export }
.mbar.file.menu add separator
.mbar.file.menu add command -label "Default values" -command {defaultvals}
.mbar.file.menu add separator
.mbar.file.menu add command -label "Exit" -command {exit}
menu .mbar.help.menu
.mbar.help.menu add command -label "About ..." -command about
menu .mbar.simulation.menu
.mbar.simulation.menu add checkbutton -label "Dump VCD file" -variable VCD_DUMP
.mbar.simulation.menu add separator
.mbar.simulation.menu add checkbutton -label "Generate debug messages" -variable VERBOSE
menu .mbar.synthesis.menu
.mbar.synthesis.menu add radiobutton -label "ASIC" -variable ASIC -value 1 -command {confASIC}
.mbar.synthesis.menu add radiobutton -label "FPGA" -variable ASIC -value 0 -command {confFPGA}
confFPGA
menu .mbar.processor.menu
.mbar.processor.menu add command -label "Configure OpenRISC" -command {confOR1200}
menu .mbar.wishbone.menu
.mbar.wishbone.menu add checkbutton -label "Register WB outputs" -variable REGISTERED_OUTPUTS
.mbar.wishbone.menu add checkbutton -label "Register WB inputs" -variable REGISTERED_INPUTS
.mbar.wishbone.menu add separator
.mbar.wishbone.menu add checkbutton -label "Disable memory bursts" -variable NO_BURSTS
.mbar.wishbone.menu add checkbutton -label "Remove CAB signals" -variable WB_CAB
.mbar.wishbone.menu add separator
.mbar.wishbone.menu add checkbutton -label "Wishbone B3 compatibility" -variable WB_B3
.mbar.wishbone.menu add separator
.mbar.wishbone.menu add checkbutton -label "WB:RISC 1:2 clock ratio" -variable CLKDIV2_SUPPORT
.mbar.wishbone.menu add checkbutton -label "WB:RISC 1:4 clock ratio" -variable CLKDIV4_SUPPORT
.mbar.wishbone.menu add separator
.mbar.wishbone.menu add checkbutton -label "Retry counter enabled" -variable WB_RETRY
menu .mbar.misc.menu
.mbar.misc.menu add checkbutton -label "Additional Synopsys directives" -variable ADDITIONAL_SYNOPSYS_DIRECTIVES
.mbar.misc.menu add checkbutton -label "Enable default statement in case blocks" -variable CASE_DEFAULT
.mbar.misc.menu add separator
.mbar.misc.menu add radiobutton -label "Type of mem2reg aligner 1" -variable IMPL_MEM2REG -value 1
.mbar.misc.menu add radiobutton -label "Type of mem2reg aligner 2" -variable IMPL_MEM2REG -value 2
.mbar.misc.menu add separator
.mbar.misc.menu add checkbutton -label "Enable BIST (only for VIRTUAL SILICON memories)" -variable BIST
tk_menuBar .mbar .mbar.file .mbar.synthesis .mbar.processor .mbar.misc .mbar.simulation .mbar.help
focus .mbar