Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
7f82b46
Add simple Docker environment variable
AFOliveira Dec 13, 2024
7141a9c
Fix errors due to incorrect parsing of VM
AFOliveira Dec 18, 2024
6e45c3b
First Refactor to pytest
AFOliveira Dec 19, 2024
ac04c28
Allow 16 bit instructions for C extension
AFOliveira Dec 19, 2024
f1b8613
Revert bad parsing
AFOliveira Dec 19, 2024
e3e7456
Allow only one value
AFOliveira Dec 19, 2024
4355eb0
Use AsmString instead of name
AFOliveira Dec 19, 2024
8492581
Small Refactor on parsing.py
AFOliveira Dec 22, 2024
3bd1d2c
refactor to do unit tests
AFOliveira Dec 22, 2024
6b9fdda
refactor to file name
AFOliveira Dec 22, 2024
831a10b
Modify to have seveal Unit tests instead of just one
AFOliveira Dec 23, 2024
655e1d6
Clean up and code reorganization
AFOliveira Dec 23, 2024
d61fb3b
Ensure it is not pseudo
AFOliveira Dec 23, 2024
5992124
Skip aq/rl instructions
AFOliveira Dec 23, 2024
c2e6e92
add pytest to requirements
AFOliveira Dec 23, 2024
7c9c65b
add LLVM path as environment variable
AFOliveira Dec 27, 2024
3178538
remove and ignor python cache
AFOliveira Dec 27, 2024
11d4c60
Add LLVM test to the Rakefile
AFOliveira Dec 27, 2024
2185239
Optimizations to test logic and modify test order
AFOliveira Dec 27, 2024
64a7525
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Jan 8, 2025
9b9bce5
Add prerequisites syntax
Jan 9, 2025
3939224
Fix merge conflict
Jan 9, 2025
daae5d5
Fix pre-commit related issues
Jan 10, 2025
450c65b
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Jan 14, 2025
d9e45b3
Add LLVM tblgen to regress.yaml && change Rakefile for new changes
AFOliveira Jan 17, 2025
0fa5bdd
Fix caching
AFOliveira Jan 17, 2025
56412ac
Fix caching
AFOliveira Jan 17, 2025
b2748e0
Fix caching
AFOliveira Jan 17, 2025
6968919
Add dependencie for smoke test
AFOliveira Jan 17, 2025
25aa928
Change logic for LLVM's path
AFOliveira Jan 17, 2025
5ee8496
Change CI logic for LLVM
AFOliveira Jan 20, 2025
92f9c99
Add cache and update paths
AFOliveira Jan 20, 2025
34e769e
Add corner case when implementation of LLVM does not need to follow t…
AFOliveira Jan 20, 2025
b3c523c
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Jan 20, 2025
15b12f3
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Jan 22, 2025
af0acae
Work around for FENCE. ISA and compiler should treat it differently
AFOliveira Jan 27, 2025
b1e0ee6
Set CM instruction length 16 bit instead of 32
AFOliveira Jan 27, 2025
f99e556
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Jan 27, 2025
4510bed
merged
AFOliveira Apr 11, 2025
7b1697f
Merge remote-tracking branch 'origin/main' into AFOliveira/LLVM
dhower-qc Apr 18, 2025
7bfe623
Merge branch 'main' into AFOliveira/LLVM
AFOliveira Apr 21, 2025
b2f102e
Add LICENSE compliant to UDB native files.
AFOliveira Apr 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/regress.yml
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,29 @@
- uses: actions/setup-python@v5
- uses: pre-commit/[email protected]
regress-smoke:
needs: build-llvm
runs-on: ubuntu-latest
env:
SINGULARITY: 1
steps:
- name: Clone Github Repo Action
uses: actions/checkout@v4
- name: Get current LLVM submodule commit SHA
id: get-llvm-sha
run: echo "LLVM_SHA=$(git ls-tree HEAD ext/llvm-project | awk '{print $3}')" >> $GITHUB_ENV
- name: Restore cache RISC-V JSON
id: cache-riscv
uses: actions/cache@v4
with:
path: ext/llvm-project/riscv.json
key: ${{ runner.os }}-riscv-json-${{ env.LLVM_SHA }}
restore-keys: |
${{ runner.os }}-riscv-json-
- name: singularity setup
uses: ./.github/actions/singularity-setup
- name: Run smoke
run: ./do test:smoke
regress-gen-isa-manual:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
runs-on: ubuntu-latest
env:
MANUAL_NAME: isa
Expand Down Expand Up @@ -98,7 +110,55 @@
uses: ./.github/actions/singularity-setup
- name: Generate extension PDF
run: ./do gen:profile_release_pdf[Mock]
build-llvm:
runs-on: ubuntu-latest
steps:
- name: Check out repository (no submodules, shallow fetch)
uses: actions/checkout@v4
with:
submodules: false
fetch-depth: 1
- name: Get current LLVM submodule commit SHA
id: get-llvm-sha
run: echo "LLVM_SHA=$(git ls-tree HEAD ext/llvm-project | awk '{print $3}')" >> $GITHUB_ENV
- name: Cache RISC-V JSON
id: cache-riscv
uses: actions/cache@v4
with:
path: ext/llvm-project/riscv.json
key: ${{ runner.os }}-riscv-json-${{ env.LLVM_SHA }}
restore-keys: |
${{ runner.os }}-riscv-json-
- name: Initialize LLVM submodule (shallow + sparse)
if: ${{ steps.cache-riscv.outputs.cache-hit != 'true' }}
run: |
git submodule sync --recursive
git submodule update --init --recursive --depth=1 ext/llvm-project

- name: Check for required directories and files
if: ${{ steps.cache-riscv.outputs.cache-hit != 'true' }}
run: |
ls -l ext/llvm-project/llvm/include
ls -l ext/llvm-project/llvm/lib/Target/RISCV
ls -l ext/llvm-project/llvm/lib/Target/RISCV/RISCV.td
- name: Configure and build llvm-tblgen
if: ${{ steps.cache-riscv.outputs.cache-hit != 'true' }}
run: |
cmake -S ext/llvm-project/llvm -B ext/llvm-project/build -DCMAKE_BUILD_TYPE=Release
cmake --build ext/llvm-project/build --target llvm-tblgen
- name: Generate RISC-V JSON
if: ${{ steps.cache-riscv.outputs.cache-hit != 'true' }}
run: |
chmod +x ./ext/llvm-project/build/bin/llvm-tblgen
./ext/llvm-project/build/bin/llvm-tblgen \
-I ext/llvm-project/llvm/include \
-I ext/llvm-project/llvm/lib/Target/RISCV \
ext/llvm-project/llvm/lib/Target/RISCV/RISCV.td \
--dump-json \
-o ext/llvm-project/riscv.json
- name: Show riscv.json output
run: ls -l ext/llvm-project/riscv.json
regress-gen-go:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
runs-on: ubuntu-latest
env:
SINGULARITY: 1
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,8 @@ gen
node_modules
_site
images
__pycache__/
*.pyc
.pytest_cache/
*.bak
*.log
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
[submodule "ext/riscv-isa-manual"]
path = ext/riscv-isa-manual
url = https://github.com/riscv/riscv-isa-manual
[submodule "ext/llvm-project"]
path = ext/llvm-project
url = https://github.com/llvm/llvm-project.git
branch = main
[submodule "ext/riscv-tests"]
path = ext/riscv-tests
url = https://github.com/riscv-software-src/riscv-tests.git
11 changes: 11 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,15 @@ namespace :serve do
end

namespace :test do

# "Run the cross-validation against LLVM"
task :llvm do
begin
sh "#{$root}/.home/.venv/bin/python3 -m pytest ext/auto-inst/test_parsing.py -v"
rescue => e
raise unless e.message.include?("status (5)") # don't fail on skipped tests
end
end
# "Run the IDL compiler test suite"
task :idl_compiler do
t = Minitest::TestTask.new(:lib_test)
Expand Down Expand Up @@ -430,6 +439,8 @@ namespace :test do
Rake::Task["test:idl"].invoke
puts "UPDATE: Running test:inst_encodings"
Rake::Task["test:inst_encodings"].invoke
puts "UPDATE: Running test:llvm"
Rake::Task["test:llvm"].invoke
puts "UPDATE: Done test:smoke"
end

Expand Down
Loading
Loading