Skip to content

Commit

Permalink
Switch to Capstone 5.x
Browse files Browse the repository at this point in the history
  • Loading branch information
mrexodia committed Aug 9, 2024
1 parent dffea2a commit 237029b
Show file tree
Hide file tree
Showing 18 changed files with 50 additions and 137 deletions.
20 changes: 10 additions & 10 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ configuration:
clone_folder: c:\projects\triton

environment:
CAPSTONE_INCLUDE_DIRS: c:\projects\triton\build\capstone-4.0.2\include
CAPSTONE_INCLUDE_DIRS: c:\projects\triton\build\capstone-5.0.1\include
PLATFORM_TOOLSET: v142
CMAKE_TEMPLATE: Visual Studio 16 2019
CMAKE_GENERATOR: Visual Studio 16 2019

matrix:
# 64-bit, python3.8, boost off
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python38-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-5.0.1\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp38-cp38-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Expand All @@ -33,7 +33,7 @@ environment:
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python39-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-5.0.1\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp39-cp39-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Expand All @@ -46,7 +46,7 @@ environment:
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python310-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-5.0.1\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp310-cp310-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Expand All @@ -59,7 +59,7 @@ environment:
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
PYTHON: C:\Python310-x64
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-4.0.2\msvc\x64\%configuration%\capstone.lib
CAPSTONE_LIBRARIES: c:\projects\triton\build\capstone-5.0.1\msvc\x64\%configuration%\capstone.lib
LIEF_VERSION: 0.12.1
LIEF_ZIP: lief-0.12.1-cp310-cp310-win_amd64.whl
Z3_INCLUDE_DIRS: c:\projects\triton\build\z3-4.8.9-x64-win\include
Expand All @@ -84,18 +84,18 @@ install:
- set PYTHONPATH=C:\projects\triton\build\%Z3_PKG_NAME%\bin\python;%PYTHONPATH%
# Install capstone
- cmd: echo Downloading capstone...
- cmd: appveyor DownloadFile https://github.com/aquynh/capstone/archive/4.0.2.zip
- cmd: 7z x 4.0.2.zip
- cmd: appveyor DownloadFile https://github.com/capstone-engine/capstone/archive/refs/tags/5.0.1.zip
- cmd: 7z x 5.0.1.zip
- cmd: echo Building capstone...
- cmd: msbuild capstone-4.0.2\msvc\capstone.sln /p:Configuration=%configuration% /p:Platform=%platform% /p:PlatformToolset=%PLATFORM_TOOLSET% /t:capstone_static /m
- cmd: msbuild capstone-5.0.1\msvc\capstone.sln /p:Configuration=%configuration% /p:Platform=%platform% /p:PlatformToolset=%PLATFORM_TOOLSET% /t:capstone_static /m
# Install LIEF
- cmd: echo Downloading LIEF...
- cmd: appveyor DownloadFile https://github.com/lief-project/LIEF/releases/download/%LIEF_VERSION%/%LIEF_ZIP%
- cmd: echo Install LIEF...
- cmd: python -m pip install %LIEF_ZIP%
# Running cmake for Triton
- cmd: echo Running cmake for Triton...
- cmd: cmake -DPython3_ROOT_DIR=%PYTHON% -DBOOST_INTERFACE=%BOOST_INTERFACE% -DPYTHON_VERSION=%PYTHON_VERSION% .. -A %platform% -G "%CMAKE_TEMPLATE%"
- cmd: cmake -DPython3_ROOT_DIR=%PYTHON% -DBOOST_INTERFACE=%BOOST_INTERFACE% -DPYTHON_VERSION=%PYTHON_VERSION% .. -A %platform% -G "%CMAKE_GENERATOR%"

build_script:
- cmd: msbuild c:\projects\triton\build\triton.sln /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /t:python-triton /m:3
Expand Down
30 changes: 10 additions & 20 deletions .github/workflows/vcpkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,22 @@ jobs:
os:
- macOS-latest
- ubuntu-20.04
# FIXME
#- windows-2022
- windows-2022
include:
#- os: windows-2022
# platform: windows
# vcpkg-triplet: x64-windows-static-release-md
# cmake-preset: windows-x64
# capstone-library: capstone.lib
# python-executable: python
- os: windows-2022
platform: windows
vcpkg-triplet: x64-windows-static-release-md
cmake-preset: windows-x64
python-executable: python
- os: ubuntu-20.04
platform: linux
vcpkg-triplet: x64-linux-release
cmake-preset: linux-x64
capstone-library: libcapstone.a
python-executable: python3
- os: macOS-latest
platform: macos
vcpkg-triplet: x64-osx-release
cmake-preset: macos-x64
capstone-library: libcapstone.a
python-executable: python3

steps:
Expand Down Expand Up @@ -64,29 +60,23 @@ jobs:
- name: Configure (Windows)
if: ${{ matrix.platform == 'windows' }}
run: |
cmake --preset=${{ matrix.cmake-preset }} -DBUILD_SHARED_LIBS:BOOL=ON -DCS_VERSION_MAJOR:STRING=5 -DVCPKG_OVERLAY_TRIPLETS:PATH=${{ github.workspace }}\vcpkg\triplets -DVCPKG_TARGET_TRIPLET:STRING=${{ matrix.vcpkg-triplet }}
cmake --preset=${{ matrix.cmake-preset }} -DBUILD_SHARED_LIBS:BOOL=ON -DVCPKG_OVERLAY_TRIPLETS:PATH=${{ github.workspace }}\vcpkg\triplets -DVCPKG_TARGET_TRIPLET:STRING=${{ matrix.vcpkg-triplet }}
env:
# capstone 4.0.2 does not produce a CMake Config, hence the need to point directly to include directories and libraries
CAPSTONE_INCLUDE_DIRS: ${{ github.workspace }}/build/${{ matrix.cmake-preset }}/vcpkg_installed/${{ matrix.vcpkg-triplet }}/include
CAPSTONE_LIBRARIES: ${{ github.workspace }}/build/${{ matrix.cmake-preset }}/vcpkg_installed/${{ matrix.vcpkg-triplet }}/lib/${{ matrix.capstone-library }}
VCPKG_ROOT: ${{ github.workspace }}/_vcpkg
VCPKG_FEATURE_FLAGS: manifests,versions,binarycaching,registries

- name: Configure (UNIX)
if: ${{ matrix.platform != 'windows' }}
run: |
python -m pip install importlib-resources
cmake --preset=${{ matrix.cmake-preset }} -DBUILD_SHARED_LIBS:BOOL=ON -DCS_VERSION_MAJOR:STRING=5 -DVCPKG_OVERLAY_TRIPLETS:PATH=${{ github.workspace }}/vcpkg/triplets -DVCPKG_TARGET_TRIPLET:STRING=${{ matrix.vcpkg-triplet }}
cmake --preset=${{ matrix.cmake-preset }} -DBUILD_SHARED_LIBS:BOOL=ON -DVCPKG_OVERLAY_TRIPLETS:PATH=${{ github.workspace }}/vcpkg/triplets -DVCPKG_TARGET_TRIPLET:STRING=${{ matrix.vcpkg-triplet }}
env:
# capstone 4.0.2 does not produce a CMake Config, hence the need to point directly to include directories and libraries
CAPSTONE_INCLUDE_DIRS: ${{ github.workspace }}/build/${{ matrix.cmake-preset }}/vcpkg_installed/${{ matrix.vcpkg-triplet }}/include
CAPSTONE_LIBRARIES: ${{ github.workspace }}/build/${{ matrix.cmake-preset }}/vcpkg_installed/${{ matrix.vcpkg-triplet }}/lib/${{ matrix.capstone-library }}
VCPKG_ROOT: ${{ github.workspace }}/_vcpkg
VCPKG_FEATURE_FLAGS: manifests,versions,binarycaching,registries

- name: Build
run: |
cmake --build --preset build-${{ matrix.cmake-preset }} --config Release -DCS_VERSION_MAJOR:STRING=5
cmake --build --preset build-${{ matrix.cmake-preset }} --config Release
- name: Test
# Test disabled on Windows `pip install lief` fails as there is no ready to use .whl and compilation fails
Expand All @@ -98,7 +88,7 @@ jobs:
- name: Install
run: |
cmake --build --preset build-${{ matrix.cmake-preset }} --config Release --target install -DCS_VERSION_MAJOR:STRING=5
cmake --build --preset build-${{ matrix.cmake-preset }} --config Release --target install
- name: Upload
uses: actions/upload-artifact@v3
Expand Down
3 changes: 0 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,6 @@ endif()
message(STATUS "Compiling with Capstone")
find_package(CAPSTONE 5 REQUIRED)
message(STATUS "CAPSTONE version: ${CAPSTONE_VERSION}")
if(${CS_VERSION_MAJOR} GREATER_EQUAL 5)
add_definitions(-DCOMPILE_RISCV)
endif()
if(TARGET capstone::capstone)
link_libraries(capstone::capstone)
elseif(DEFINED CAPSTONE_INCLUDE_DIRS)
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ from triton import *
Triton relies on the following dependencies:

```
* libcapstone >= 4.0.x https://github.com/capstone-engine/capstone
* libcapstone >= 5.0.x https://github.com/capstone-engine/capstone
* libboost (optional) >= 1.68
* libpython (optional) >= 3.6
* libz3 (optional) >= 4.6.0 https://github.com/Z3Prover/z3
Expand Down Expand Up @@ -164,8 +164,8 @@ You can use cmake to generate the .sln file of libTriton.
-DPYTHON_LIBRARIES="C:/Python36/libs/python36.lib" \
-DZ3_INCLUDE_DIRS="C:/Users/jonathan/Works/Tools/z3-4.6.0-x64-win/include" \
-DZ3_LIBRARIES="C:/Users/jonathan/Works/Tools/z3-4.6.0-x64-win/bin/libz3.lib" \
-DCAPSTONE_INCLUDE_DIRS="C:/Users/jonathan/Works/Tools/capstone-4.0.2-win64/include" \
-DCAPSTONE_LIBRARIES="C:/Users/jonathan/Works/Tools/capstone-4.0.2-win64/capstone.lib" ..
-DCAPSTONE_INCLUDE_DIRS="C:/Users/jonathan/Works/Tools/capstone-5.0.1-win64/include" \
-DCAPSTONE_LIBRARIES="C:/Users/jonathan/Works/Tools/capstone-5.0.1-win64/capstone.lib" ..
```

However, if you prefer to directly download the precompiled library, check out our AppVeyor's [artefacts](https://ci.appveyor.com/project/JonathanSalwan/triton/history).
Expand Down
36 changes: 9 additions & 27 deletions doc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,42 +36,24 @@ add_custom_target(gen_rv32_doc_from_spec
DEPENDS ${TRITON_ROOT}/src/libtriton/includes/triton/riscv32.spec
)

if(${CS_VERSION_MAJOR} GREATER_EQUAL 5)
add_custom_target(doc
COMMAND doxygen ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
DEPENDS gen_x86_doc_from_spec
DEPENDS gen_aarch64_doc_from_spec
DEPENDS gen_arm32_doc_from_spec
DEPENDS gen_rv64_doc_from_spec
DEPENDS gen_rv32_doc_from_spec
)
else()
add_custom_target(doc
COMMAND doxygen ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
DEPENDS gen_x86_doc_from_spec
DEPENDS gen_aarch64_doc_from_spec
DEPENDS gen_arm32_doc_from_spec
)
endif()
add_custom_target(doc
COMMAND doxygen ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
DEPENDS gen_x86_doc_from_spec
DEPENDS gen_aarch64_doc_from_spec
DEPENDS gen_arm32_doc_from_spec
DEPENDS gen_rv64_doc_from_spec
DEPENDS gen_rv32_doc_from_spec
)

if(PYTHON_BINDINGS_AUTOCOMPLETE)
if(${CS_VERSION_MAJOR} GREATER_EQUAL 5)
add_custom_target(python_autocomplete
add_custom_target(python_autocomplete
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_LIST_DIR}/autocomplete/generate_autocomplete.py "--basedir" "${CMAKE_CURRENT_BINARY_DIR}" "$<$<BOOL:${BITWUZLA_INTERFACE}>:--bitwuzla>" "$<$<BOOL:${Z3_INTERFACE}>:--z3>"
DEPENDS gen_x86_doc_from_spec
DEPENDS gen_aarch64_doc_from_spec
DEPENDS gen_arm32_doc_from_spec
DEPENDS gen_rv64_doc_from_spec
DEPENDS gen_rv32_doc_from_spec
)
else()
add_custom_target(python_autocomplete
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_LIST_DIR}/autocomplete/generate_autocomplete.py "--basedir" "${CMAKE_CURRENT_BINARY_DIR}" "$<$<BOOL:${BITWUZLA_INTERFACE}>:--bitwuzla>" "$<$<BOOL:${Z3_INTERFACE}>:--z3>"
DEPENDS gen_x86_doc_from_spec
DEPENDS gen_aarch64_doc_from_spec
DEPENDS gen_arm32_doc_from_spec
)
endif()
if (NOT DEFINED PYTHON_SITE_PACKAGES)
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from sysconfig import get_path; print(get_path('platlib'))" OUTPUT_VARIABLE PYTHON_SITE_PACKAGES OUTPUT_STRIP_TRAILING_WHITESPACE)
endif()
Expand Down
30 changes: 14 additions & 16 deletions src/libtriton/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -148,22 +148,20 @@ set(LIBTRITON_HEADER_FILES
)

# Add riscv source and header files
if(${CS_VERSION_MAJOR} GREATER_EQUAL 5)
list(APPEND LIBTRITON_SOURCE_FILES
arch/riscv/riscv32Cpu.cpp
arch/riscv/riscv64Cpu.cpp
arch/riscv/riscvSemantics.cpp
arch/riscv/riscvSpecifications.cpp
)
list(APPEND LIBTRITON_HEADER_FILES
includes/triton/riscv32.spec
includes/triton/riscv64.spec
includes/triton/riscv32Cpu.hpp
includes/triton/riscv64Cpu.hpp
includes/triton/riscvSemantics.hpp
includes/triton/riscvSpecifications.hpp
)
endif()
list(APPEND LIBTRITON_SOURCE_FILES
arch/riscv/riscv32Cpu.cpp
arch/riscv/riscv64Cpu.cpp
arch/riscv/riscvSemantics.cpp
arch/riscv/riscvSpecifications.cpp
)
list(APPEND LIBTRITON_HEADER_FILES
includes/triton/riscv32.spec
includes/triton/riscv64.spec
includes/triton/riscv32Cpu.hpp
includes/triton/riscv64Cpu.hpp
includes/triton/riscvSemantics.hpp
includes/triton/riscvSpecifications.hpp
)

# Define all resource files
set(LIBTRITON_RESOURCE_FILES
Expand Down
6 changes: 0 additions & 6 deletions src/libtriton/arch/architecture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,9 @@
#include <triton/arm32Cpu.hpp>
#include <triton/arm32Specifications.hpp>
#include <triton/exceptions.hpp>
#ifdef COMPILE_RISCV
#include <triton/riscv32Cpu.hpp>
#include <triton/riscv64Cpu.hpp>
#include <triton/riscvSpecifications.hpp>
#endif
#include <triton/x8664Cpu.hpp>
#include <triton/x86Cpu.hpp>
#include <triton/x86Specifications.hpp>
Expand Down Expand Up @@ -59,10 +57,8 @@ namespace triton {
case triton::arch::ARCH_X86: this->cpu.reset(new(std::nothrow) triton::arch::x86::x86Cpu(this->callbacks)); break;
case triton::arch::ARCH_AARCH64: this->cpu.reset(new(std::nothrow) triton::arch::arm::aarch64::AArch64Cpu(this->callbacks)); break;
case triton::arch::ARCH_ARM32: this->cpu.reset(new(std::nothrow) triton::arch::arm::arm32::Arm32Cpu(this->callbacks)); break;
#ifdef COMPILE_RISCV
case triton::arch::ARCH_RV64: this->cpu.reset(new(std::nothrow) triton::arch::riscv::riscv64Cpu(this->callbacks)); break;
case triton::arch::ARCH_RV32: this->cpu.reset(new(std::nothrow) triton::arch::riscv::riscv32Cpu(this->callbacks)); break;
#endif
default:
throw triton::exceptions::Architecture("Architecture::setArchitecture(): Architecture not supported.");
}
Expand Down Expand Up @@ -409,11 +405,9 @@ namespace triton {
case triton::arch::ARCH_X86_64:
return triton::arch::x86::nop;

#ifdef COMPILE_RISCV
case triton::arch::ARCH_RV64:
case triton::arch::ARCH_RV32:
return triton::arch::riscv::nop;
#endif

default:
throw triton::exceptions::Architecture("Architecture::getNopInstruction(): Invalid architecture.");
Expand Down
10 changes: 0 additions & 10 deletions src/libtriton/arch/irBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@
#include <triton/operandWrapper.hpp>
#include <triton/register.hpp>
#include <triton/x86Semantics.hpp>
#ifdef COMPILE_RISCV
#include <triton/riscvSemantics.hpp>
#endif


namespace triton {
Expand Down Expand Up @@ -46,14 +44,10 @@ namespace triton {
this->aarch64Isa = new(std::nothrow) triton::arch::arm::aarch64::AArch64Semantics(architecture, symbolicEngine, taintEngine, astCtxt);
this->arm32Isa = new(std::nothrow) triton::arch::arm::arm32::Arm32Semantics(architecture, symbolicEngine, taintEngine, astCtxt);
this->x86Isa = new(std::nothrow) triton::arch::x86::x86Semantics(architecture, symbolicEngine, taintEngine, modes, astCtxt);
#ifdef COMPILE_RISCV
this->riscvIsa = new(std::nothrow) triton::arch::riscv::riscvSemantics(architecture, symbolicEngine, taintEngine, modes, astCtxt);
#endif

if (this->x86Isa == nullptr || this->aarch64Isa == nullptr || this->arm32Isa == nullptr
#ifdef COMPILE_RISCV
|| this->riscvIsa == nullptr
#endif
)
throw triton::exceptions::IrBuilder("IrBuilder::IrBuilder(): Not enough memory.");
}
Expand All @@ -63,9 +57,7 @@ namespace triton {
delete this->aarch64Isa;
delete this->arm32Isa;
delete this->x86Isa;
#ifdef COMPILE_RISCV
delete this->riscvIsa;
#endif
}


Expand Down Expand Up @@ -101,12 +93,10 @@ namespace triton {
ret = this->x86Isa->buildSemantics(inst);
break;

#ifdef COMPILE_RISCV
case triton::arch::ARCH_RV64:
case triton::arch::ARCH_RV32:
ret = this->riscvIsa->buildSemantics(inst);
break;
#endif

default:
throw triton::exceptions::IrBuilder("IrBuilder::buildSemantics(): Architecture not supported.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,8 @@ namespace triton {
void initArchNamespace(PyObject* archDict) {
xPyDict_SetItemString(archDict, "AARCH64", PyLong_FromUint32(triton::arch::ARCH_AARCH64));
xPyDict_SetItemString(archDict, "ARM32", PyLong_FromUint32(triton::arch::ARCH_ARM32));
#ifdef COMPILE_RISCV
xPyDict_SetItemString(archDict, "RV32", PyLong_FromUint32(triton::arch::ARCH_RV32));
xPyDict_SetItemString(archDict, "RV64", PyLong_FromUint32(triton::arch::ARCH_RV64));
#endif
xPyDict_SetItemString(archDict, "X86", PyLong_FromUint32(triton::arch::ARCH_X86));
xPyDict_SetItemString(archDict, "X86_64", PyLong_FromUint32(triton::arch::ARCH_X86_64));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
#include <triton/pythonXFunctions.hpp>
#include <triton/aarch64Specifications.hpp>
#include <triton/arm32Specifications.hpp>
#ifdef COMPILE_RISCV
#include <triton/riscvSpecifications.hpp>
#endif
#include <triton/x86Specifications.hpp>


Expand Down Expand Up @@ -4529,7 +4527,6 @@ namespace triton {
xPyDict_SetItemString(opcodesDict, "ARM32", arm32OpcodesDictClass);


#ifdef COMPILE_RISCV
PyObject* riscv64OpcodesDict = xPyDict_New();

xPyDict_SetItemString(riscv64OpcodesDict, "ADD", PyLong_FromUint32(triton::arch::riscv::ID_INS_ADD));
Expand Down Expand Up @@ -4712,7 +4709,6 @@ namespace triton {

PyObject* riscv32OpcodesDictClass = xPyClass_New(nullptr, riscv32OpcodesDict, xPyString_FromString("RV32"));
xPyDict_SetItemString(opcodesDict, "RV32", riscv32OpcodesDictClass);
#endif
}

}; /* python namespace */
Expand Down
2 changes: 0 additions & 2 deletions src/libtriton/bindings/python/namespaces/initRegNamespace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ namespace triton {
PyObject* arm32RegistersDictClass = xPyClass_New(nullptr, arm32RegistersDict, xPyString_FromString("ARM32"));
xPyDict_SetItemString(registersDict, "ARM32", arm32RegistersDictClass);

#ifdef COMPILE_RISCV
// Create RISCV64 REG namespace

PyObject* riscv64RegistersDict = xPyDict_New();
Expand Down Expand Up @@ -168,7 +167,6 @@ namespace triton {

PyObject* riscv32RegistersDictClass = xPyClass_New(nullptr, riscv32RegistersDict, xPyString_FromString("RV32"));
xPyDict_SetItemString(registersDict, "RV32", riscv32RegistersDictClass);
#endif
}

}; /* python namespace */
Expand Down
Loading

0 comments on commit 237029b

Please sign in to comment.