forked from ryuz/study_uvm
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmake.bat
More file actions
61 lines (51 loc) · 1.31 KB
/
make.bat
File metadata and controls
61 lines (51 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
@echo off
if "%DSIM_HOME%" == "" (
echo "DSIM_HOME is not set. Setup of DSim is done automatically."
REM call "%LOCALAPPDATA%\metrics-ca\dsim\20240923.9.0\shell_activate.bat"
call "%ProgramFiles%\Altair\DSim\2025\shell_activate.bat"
set DSIM_LICENSE=%LOCALAPPDATA%\metrics-ca\dsim-license.json
)
set TOP_MODULE=tb
if "%2" == "" (
set TEST_NAME=mem_test
) else (
set TEST_NAME=%2
)
REM Define a target named 'tmp'
if "%1" == "tmp" (
echo "Hello World (make.bat)"
goto :EOF
)
if "%1" == "" (
dsim -uvm 1.2 -top %TOP_MODULE% -f files.f +acc+b +UVM_TESTNAME=%TEST_NAME% -waves ./waves.mxd
goto :EOF
)
if "%1" == "build" (
dsim -uvm 1.2 -top %TOP_MODULE% -f files.f -genimage image +acc+b
goto :EOF
)
if "%1" == "run" (
dsim -uvm 1.2 -image image +UVM_TESTNAME=%TEST_NAME% -waves ./waves.mxd
goto :EOF
)
if "%1" == "log" (
code ./dsim.log
goto :EOF
)
if "%1" == "wave" (
code -n ./waves.mxd
goto :EOF
)
if "%1" == "clean" (
rmdir /S /Q "dsim_work"
del /Q "*.env" "metrics.db" "*.mxd" "*.vcd" "*.log"
goto :EOF
)
if "%1" == "help" (
echo "Usage: make.bat [target]"
echo "Targets:"
echo " tmp - Print Hello World"
echo " build - Build the application"
echo " run - Run the application"
echo " clean - Clean up the workspace"
)