Skip to content

Commit

Permalink
Modify check_verilator_version (#1)
Browse files Browse the repository at this point in the history
* modify check_verilator_version

* Update utils.py

---------

Co-authored-by: Minseong Jang <[email protected]>
  • Loading branch information
woojinnn and minseongg authored Sep 2, 2024
1 parent 257fc02 commit 6dd1793
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions scripts/cpu/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,10 @@ def check_verilator_version():
if result.returncode == 0:
# Extract the version number from the output
version_output = result.stdout.splitlines()[0] # Extracting the first line
version_string = version_output.split()[
-1
] # Assuming version number is the last item
version_string = version_output.split()[1] # Assuming version number is the second item

# Extracting major version number
major_version = int(version_string.split(".")[0][1])
major_version = int(version_string.split(".")[0])
minor_version = int(version_string.split(".")[1][:3])

return major_version + (minor_version / 1000)
Expand Down

0 comments on commit 6dd1793

Please sign in to comment.