mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-26 23:21:11 +00:00
Fix workflows
This commit is contained in:
parent
4d0bf508b2
commit
01fe52b2cc
16
.github/workflows/LLVM-Tblgen-Build.yml
vendored
16
.github/workflows/LLVM-Tblgen-Build.yml
vendored
@ -25,8 +25,10 @@ jobs:
|
|||||||
build-and-test-llvm-tblgen:
|
build-and-test-llvm-tblgen:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout llvm-capstone
|
- name: Checkout llvm-capstone (patched backends)
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
clean: false
|
||||||
|
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
@ -46,18 +48,26 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
./gen_cs_tables.sh
|
./gen_cs_tables.sh
|
||||||
|
|
||||||
- name: Checkout llvm-capstone
|
- name: Checkout LLVM
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
ref: auto-sync-18-base
|
with:
|
||||||
|
clean: false
|
||||||
|
ref: auto-sync-18-base
|
||||||
|
|
||||||
- name: Build LLVM llvm-tblgen
|
- name: Build LLVM llvm-tblgen
|
||||||
run: |
|
run: |
|
||||||
|
rm -rf build
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug ../llvm
|
cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug ../llvm
|
||||||
cmake --build . --target llvm-tblgen --config Debug
|
cmake --build . --target llvm-tblgen --config Debug
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
|
- name: Checkout llvm-capstone (patched backends)
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
clean: false
|
||||||
|
|
||||||
- name: Generate original LLVM tables
|
- name: Generate original LLVM tables
|
||||||
run: |
|
run: |
|
||||||
./gen_llvm_tables.sh
|
./gen_llvm_tables.sh
|
||||||
|
@ -1,9 +1,13 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# Compare the generated tables of our refactored TableGen to the original ones.
|
# Compare the generated tables of our refactored TableGen to the original ones.
|
||||||
|
archs="AArch64 ARM PPC"
|
||||||
|
file_names="GenAsmWriter GenDisassemblerTables GenInstrInfo GenRegisterInfo GenSubtargetInfo GenSystemOperands"
|
||||||
|
release="18"
|
||||||
|
gen_dir="output_tmp"
|
||||||
|
|
||||||
# Requires that LLVM tables were generated before.
|
# Requires that LLVM tables were generated before.
|
||||||
echo "Diff LLVM files"
|
echo "Diff LLVM files (blanks and empty lines are ignored)"
|
||||||
for arch in $archs; do
|
for arch in $archs; do
|
||||||
for file_name in $file_names; do
|
for file_name in $file_names; do
|
||||||
out_CPP_LLVM="$gen_dir/$arch$file_name""_CPP_LLVM.inc"
|
out_CPP_LLVM="$gen_dir/$arch$file_name""_CPP_LLVM.inc"
|
||||||
@ -15,7 +19,7 @@ for arch in $archs; do
|
|||||||
|
|
||||||
diff -w -B "$out_CPP_LLVM" "$out_CPP_CS" > /dev/null
|
diff -w -B "$out_CPP_LLVM" "$out_CPP_CS" > /dev/null
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo "The following files mismatch: $out_CPP_LLVM <-> $out_CPP_CS"
|
echo "The following files mismatch: $out_CPP_LLVM $out_CPP_CS"
|
||||||
mismatch="true"
|
mismatch="true"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
0
gen_cs_tables.sh
Normal file → Executable file
0
gen_cs_tables.sh
Normal file → Executable file
0
gen_llvm_tables.sh
Normal file → Executable file
0
gen_llvm_tables.sh
Normal file → Executable file
Loading…
Reference in New Issue
Block a user