-
Notifications
You must be signed in to change notification settings - Fork 663
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FPGA prototyping platform VCS simulation #871
Closed
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
036f429
Adding a new config for Arty simulation.
ece1ca4
Don't tie off success IO in the harness when using sim serial. Not a …
bff86e2
First pass at using an Arty-specific TestDriver. Done in a kludgy way…
254f0c7
Adding ArtyTestDriver in the easiest place to avoid circular dependen…
193d55c
Small changes to ArtyTestDriver.
bf0225f
Makefile includes sim-fpga target that goes up to compiling vivado si…
1ad47a5
Make rule to generate additional VCS sim collateral. Now ready to add…
975d6c0
More collateral generation.
14f464a
Have Vivado generate list of System C files.
634ab89
Now have make target for building the simulation binary. Same problem…
96c45e8
Removed TestDriver from old location, which didn't work due to circul…
badbc0a
Addressed spacing issues, default sim_name, and SerialTLKey comments …
eba846c
Small fix to sim_name assignment, as it is already defined.
6156c7e
Adding makefile variable for vivado version, to be used in a version …
a28e846
Less hacky project creation .tcl script.
7cbc4ee
Fix ordering of config fragments.
03f8fde
Tie off success if no TL serial
6dc0d4b
Fixed floating success in testharness.
54b4ebc
debugging sim peripheral reset harnessbinder
b2f5d89
cleaned up binder
9a41942
Fixing binder ordering in config.
863e2d9
Making reset active low in Arty test driver to match the active low r…
9b0f10f
Setting SRST_n (JTAG reset, active low) to true by default. Arty rese…
dff7d2c
Making VCS run in debug mode in sim-fpga make target.
e45f82d
Merging dev into arty-sim to synchronize.
2bcc78a
Cleanup.
8f48540
Comments.
c2d00ae
Parameterizing testbench in sim flow
7c55be1
Merge branch 'dev' into arty-sim
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Set the variable for the directory that includes all scripts | ||
|
||
set scriptdir [file join [file dirname [info script]] "../fpga-shells/xilinx/common/tcl"] | ||
|
||
# Set up variables and Vivado objects | ||
source [file join $scriptdir "prologue.tcl"] | ||
|
||
# Initialize Vivado project files | ||
source [file join $scriptdir "init.tcl"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#### Command line arguments to this script | ||
# argv[0] = fpga family | ||
# argv[1] = build directory | ||
# argv[2] = chipyard model definition | ||
# argv[3] = test driver | ||
|
||
set family [lindex $argv 0] | ||
set build_dir [lindex $argv 1] | ||
set model [lindex $argv 2] | ||
set tb [lindex $argv 3] | ||
|
||
# compile the simulation libraries for vcs | ||
compile_simlib -directory $build_dir/$model.cache/compile_simlib -family $family -simulator vcs_mx -library all | ||
# set the top level of the design | ||
set_property top $tb [current_fileset -simset] | ||
# generate other vcs simulation collateral | ||
export_simulation -force -simulator vcs -ip_user_files_dir $build_dir/$model.ip_user_files -lib_map_path $build_dir/$model.cache/compile_simlib -use_ip_compiled_libs -directory $build_dir/export_sim | ||
# Add vivado library mapping to synopsys_sim.setup file | ||
set synopsys_libraries [open $build_dir/synopsys_sim.setup a] | ||
puts $synopsys_libraries "xil_defaultlib : vcs_lib/xil_defaultlib" | ||
close $synopsys_libraries | ||
# generate separate lists of verilog, vhdl, and cc sim sources | ||
set fpga_sim_verilog_sources [open $build_dir/fpga_sim_verilog_sources.f w] | ||
foreach source [get_files -compile_order sources -used_in simulation -filter {FILE_TYPE == Verilog}] {puts $fpga_sim_verilog_sources $source} | ||
foreach source [get_files -compile_order sources -used_in simulation -filter {FILE_TYPE == SystemVerilog}] {puts $fpga_sim_verilog_sources $source} | ||
# add vivado's glbl.v | ||
puts $fpga_sim_verilog_sources $build_dir/export_sim/vcs/glbl.v | ||
close $fpga_sim_verilog_sources | ||
set fpga_sim_vhdl_sources [open $build_dir/fpga_sim_vhdl_sources.f w] | ||
foreach source [get_files -compile_order sources -used_in simulation -filter {FILE_TYPE == VHDL}] {puts $fpga_sim_vhdl_sources $source} | ||
close $fpga_sim_vhdl_sources | ||
set fpga_sim_cc_sources [open $build_dir/fpga_sim_cc_sources.f w] | ||
foreach source [get_files *.cc] {puts $fpga_sim_cc_sources $source} | ||
close $fpga_sim_cc_sources |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If Vivado isn't on the path this pollutes the terminal output. Maybe pipe stderr to
/dev/null
. Also, where is this checked/used?