Commit Graph

955 Commits

Author SHA1 Message Date
Hansung Kim
ab55c04d0c Add localparam for internal/external smem switch 2024-01-01 19:48:06 -08:00
Hansung Kim
b64f0c2794 Add if-stmt to switch between external/internal smem 2024-01-01 12:46:59 -08:00
Hansung Kim
22f656fec1 Add ports for smem TL and connect to smem bus 2024-01-01 02:22:49 -08:00
Hansung Kim
b6cc0c285e Remove unused tilelink ports in VX_core_wrapper 2024-01-01 01:09:55 -08:00
Hansung Kim
144521e19c Expose smem ports at VX_core top
smem_unit stays inside the core, and the two separate buses to dcache
and smem are exposed at VX_core.

Currently core_wrapper ties req valid to 1'b0, stalling kernels that
reads from sharedmem.
2023-12-31 23:57:31 -08:00
Hansung Kim
5825680303 [BUGFIX] Revert way_idx fix
The added code results in width mismatch for NUM_WAYS = 4.
2023-11-28 18:44:47 -08:00
Hansung Kim
c3c9a4b5d8 [BUGFIX] Fix wrong bitwidth of way_idx when NUM_WAYS=1
When NUM_WAYS=1, CLOG2(NUM_WAYS)-1 becomes -1, setting the MSB of
way_idx to a wrong value.
2023-11-28 16:05:41 -08:00
Hansung Kim
9a8020a683 Force-include gpu_pkg in VX_cache_define.vh 2023-11-28 13:55:11 -08:00
Hansung Kim
5e5c625759 Write 0 instead of x for VX_CSR_MPM_RESERVED
Otherwise it makes verification hard with tools that don't process x's
well.
2023-11-27 16:06:16 -08:00
Hansung Kim
f41b50fc07 Define DBG_TRACE_CORE_PIPELINE_VCS for selective debug trace 2023-11-27 16:05:15 -08:00
Hansung Kim
99207c862c Revert PutPartial -> PutFull spoofing 2023-11-19 17:48:38 -08:00
Hansung Kim
e2d4894343 Add missing valid bit check for write acks 2023-11-17 20:32:53 -08:00
Hansung Kim
bc71c126ef Fix STORE HEAP trace print in verilog wrapper 2023-11-17 20:25:01 -08:00
Hansung Kim
faf5fe3838 Assert ready when write response is coming back
Since the core's response ready signal depends on response valid, but core does
not accept write ACKs, we need to manually assert ready when there is a valid
response coming in for a write regardless of the core's ready state (which would
be 0).
2023-11-17 19:08:32 -08:00
Hansung Kim
90e21e8e58 [CHANGE] Work around uninitialized signal issue with === operator
It seems many of the initial arch/uarch states, including the GPR, are
uninitialized in the VCS simulation, which results in functional errors caused
by propagated X's.  In this particular case it resulted in a dcache request not
being fired due to the rs1 data for an lw instruction having values as X,
causing the smem_unit to not arbitrate the request correctly.

A workaround of this issue is to stop the X propagation by using the
===-operation instead of == in the GPR unit, which had been the main source of X
propagation into the raddr port of the GPR.

Also, we run the simulation with GSR_RESET set to 1 so that the contents of the
GPR are initialized at the beginning of the simulation (however, this alone does
not prevent reading in X's, hence this fix.)

FIXME: This is a slight deviation from the upstream code; ideally, we want to do
clean & full initialization of microarchitectural states.
2023-11-17 17:20:54 -08:00
Hansung Kim
9651cc6bc5 Fix wrong dcache tag width in wrapper
Need to use DCACHE_NOSM_TAG_WIDTH instead of DCACHE_TAG_WIDTH; otherwise, the
`ASSIGN_VX_MEM_BUS_IF macro in VX_smem_unit.sv does assignment of packed structs
with different widths for the tag field, resulting in misaligned bit error.
This results in wrong memory addresses for the core requests.
2023-11-17 17:12:41 -08:00
Hansung Kim
e2d3d93dea Properly initialize DCR in wrapper code 2023-11-16 17:59:57 -08:00
Hansung Kim
963c2765d9 Move force-include of gpu_pkg to non-cache modules 2023-11-15 22:02:44 -08:00
Hansung Kim
448a253af3 Add Verilog wrapper module for VX_core 2023-11-15 20:09:53 -08:00
Hansung Kim
bbacf9a25e Remove verilated vpi code, add missing includes for C++
Vortex rtlsim defines sim_trace_enabled... functions in the Verilated
C++ code for use in dpi_trace, which we don't need.
2023-11-15 20:06:58 -08:00
Hansung Kim
7e0b63a3b3 Change result type for dpi calls from wire -> reg
VCS requires the output of the dpi calls to be of a type that can come
at the LHS of a procedural assignment, i.e. reg type.  Seems to be a
different requirement from Verilator.
2023-11-15 19:26:12 -08:00
Hansung Kim
d2d7ee61bb Define SIMULATION for VCS in VX_platform.vh 2023-11-15 19:14:58 -08:00
Hansung Kim
512fc0da1c Copy VX_platform macros for VCS from VERILATOR 2023-11-15 00:20:18 -08:00
Hansung Kim
20a9e6d102 Force include VX_gpu_pkg as compile order workaround
addResource() calls in Chisel BlackBox does not preserve order of the
files being included; the actual compile order for these files are
re-arranged to be in alphabetical order.

Therefore, while VX_gpu_pkg.sv has to be compiled before all the other
modules because it holds the top-level package definition, that order
cannot be ensured from Chisel.  As a hacky workaround, simply `include
this file in some of the sv files whose name starts earlier than
VX_gpu_pkg in lexicographical order.
2023-11-14 23:00:43 -08:00
Blaise Tine
6e93787e59 minor update 2023-11-06 00:16:24 -08:00
Blaise Tine
d13c5f2986 hw unit tests fixes 2023-11-05 18:51:31 -08:00
Blaise Tine
1fd5a95f5a minor update 2023-11-03 18:04:05 -04:00
Blaise Tine
9f1f1ecaa3 minor update 2023-11-03 08:36:28 -04:00
Blaise Tine
c9e6518e05 cache bindings and memory perf refactory 2023-11-03 08:18:18 -04:00
Blaise Tine
69f9ae778d cleanup 2023-11-03 08:12:03 -04:00
Blaise Tine
1c100c4cf5 minor update 2023-10-22 23:31:58 -07:00
Blaise Tine
8fe373891f minor update 2023-10-21 17:55:29 -07:00
Blaise Tine
d47cccc157 Vortex 2.0 changes:
+ Microarchitecture optimizations
+ 64-bit support
+ Xilinx FPGA support
+ LLVM-16 support
+ Refactoring and quality control fixes
2023-10-19 20:51:22 -07:00
Blaise Tine
d69a64c32c minor update 2023-05-16 04:59:01 -04:00
Santosh Srivatsan
b7e5a83ba3 Merged branch xlen-parameterization into staging 2022-02-05 13:47:42 -05:00
Santosh Srivatsan
836c777680 XLEN parameterization for simx 2022-02-03 15:19:31 -05:00
Blaise Tine
a06812f93f minor updates 2022-02-01 22:51:33 -05:00
Blaise Tine
d48f1c1c5f minor updates 2022-02-01 06:53:31 -05:00
Santosh Srivatsan
91c22a2592 Fixed some riscv-tests 2022-01-22 12:54:10 -05:00
Santosh Srivatsan
d762d401cd Added 64-bit linker script 2022-01-11 17:22:16 -05:00
Santosh Srivatsan
f93303bac7 Minor update 2021-12-15 17:21:38 -05:00
Santosh Srivatsan
e82d5fe48f Removed all comments labelled \'simx64\' 2021-12-13 19:52:13 -05:00
Santosh Srivatsan
5edb9098ce Merge branch 'simx64' 2021-12-10 21:48:29 -05:00
Blaise Tine
d7737542e4 cache uuid support 2021-12-09 20:43:22 -05:00
Blaise Tine
38f166f090 texture unit hardware optimizations 2021-12-02 10:22:21 -08:00
Santosh Raghav Srivatsan
f0dc04ad04 Added tests to commit. 64 bit simx still not working 2021-12-01 02:44:14 -05:00
Blaise Tine
4477cbeed1 blackbox caching fix 2021-11-30 15:36:59 -05:00
Blaise Tine
41d7e6c63a cummulative fixes, RTL uuid trace, texture unit fixes, simx timing fixes 2021-11-30 07:08:15 -05:00
Blaise Tine
b995843a5b cocogfx fixes and refactoring 2021-11-25 13:58:09 -05:00
Blaise Tine
a671e1a05d moving submodules into third_party folder 2021-11-24 18:10:00 -05:00