Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
linux-clang-tests-asan,
linux-gcc-tests-codecov,
capstone-v3,
capstone-next,
capstone-v4,
]
include:
- name: linux-meson-clang-tests
Expand Down Expand Up @@ -135,11 +135,11 @@ jobs:
timeout: 45
cflags: "-Wno-cpp"
allow_failure: false
- name: capstone-next
- name: capstone-v4
os: ubuntu-20.04
build_system: meson
compiler: gcc
meson_options: -Dbuildtype=release -Duse_capstone_version=next --werror
meson_options: -Dbuildtype=release -Duse_capstone_version=v4 --werror
run_tests: false
enabled: ${{ (github.event_name != 'pull_request' || contains(github.head_ref, 'capstone')) && needs.changes.outputs.edited == 'true' }}
timeout: 45
Expand Down
2 changes: 1 addition & 1 deletion doc/PACKAGERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ directories used by Rizin, have a look at options `rizin_sdb`, `rizin_zigns`,
etc. in [meson_options.txt][].

Rizin uses the Capstone disassembly engine and supports versions 3, 4, and 5.
By default we use a custom version of Capstone based on v4 and statically link
By default we use a custom version of Capstone based on v5 and statically link
it into the Rizin executables. Some distributions might prefer that a system
version of Capstone be dynamically linked at runtime. To do this, use the
`-Duse_sys_capstone=enabled` command line option when running `meson`.
Expand Down
2 changes: 1 addition & 1 deletion meson_options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ option('rizin_version_commit', type: 'string', value: '')
option('rizin_gittip', type: 'string', value: '')
option('checks_level', type: 'integer', value: 9999, description: 'Value between 0 and 3 to enable different level of assert (see RZ_CHECKS_LEVEL). By default its value depends on buildtype (2 on debug, 1 on release).')
option('use_sys_capstone', type: 'feature', value: 'disabled')
option('use_capstone_version', type: 'combo', choices: ['v3', 'v4', 'next', 'bundled'], value: 'bundled', description: 'Specify which version of capstone to use')
option('use_capstone_version', type: 'combo', choices: ['v3', 'v4', 'next', 'bundled'], value: 'next', description: 'Specify which version of capstone to use')
option('use_sys_magic', type: 'feature', value: 'disabled')
option('use_sys_libzip', type: 'feature', value: 'disabled')
option('use_sys_libzip_openssl', type: 'boolean', value: false, description: 'Whether to use or not system openssl dependency to build libzip')
Expand Down
6 changes: 3 additions & 3 deletions subprojects/capstone-next.wrap
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[wrap-git]
url = https://github.com/aquynh/capstone.git
revision = d956ceddabcbe544ee8f074ba75c86c6381b34e6
url = https://github.com/capstone-engine/capstone.git
revision = 08d1b0ccd5526c29b4162d0ff616a6a1785237a7
directory = capstone-next
patch_directory = capstone-next
patch_directory = capstone-next
4 changes: 2 additions & 2 deletions subprojects/capstone-v3.wrap
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[wrap-file]
source_url = https://github.com/aquynh/capstone/archive/3.0.5.tar.gz
source_url = https://github.com/capstone-engine/capstone/archive/3.0.5.tar.gz
source_filename = 3.0.5.tar.gz
source_hash = 913dd695e7c5a2b972a6f427cb31f2e93677ec1c38f39dda37d18a91c70b6df1
patch_directory = capstone-3.0.5
directory = capstone-3.0.5
directory = capstone-3.0.5
4 changes: 2 additions & 2 deletions subprojects/capstone-v4.wrap
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[wrap-file]
source_url = https://github.com/aquynh/capstone/archive/4.0.2.tar.gz
source_url = https://github.com/capstone-engine/capstone/archive/4.0.2.tar.gz
source_filename = 4.0.2.tar.gz
source_hash = 7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
patch_directory = capstone-4.0.2
directory = capstone-4.0.2
directory = capstone-4.0.2
2 changes: 1 addition & 1 deletion test/db/analysis/arm
Original file line number Diff line number Diff line change
Expand Up @@ -913,7 +913,7 @@ pseudo: push (r3, lr)
mnemonic: push
mask: ffffffff
prefix: 0
id: 424
id: 128
bytes: 08402de9
refptr: 0
size: 4
Expand Down
2 changes: 1 addition & 1 deletion test/db/analysis/ppc
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,7 @@ EXPECT=<<EOF
"esil": "r1,-16,r1,+,=[4],-16,r1,+=",
"sign": false,
"prefix": 0,
"id": 594,
"id": 1072,
"opex": {
"operands": [
{
Expand Down
2 changes: 1 addition & 1 deletion test/db/analysis/x86_16
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ EXPECT=<<EOF
"esil": "2,sp,-=,eflags,sp,=[2]",
"sign": false,
"prefix": 0,
"id": 591,
"id": 612,
"opex": {
"operands": [
{
Expand Down
6 changes: 3 additions & 3 deletions test/db/analysis/x86_32
Original file line number Diff line number Diff line change
Expand Up @@ -3015,7 +3015,7 @@ EXPECT=<<EOF
"esil": "eax,eax,^=,$z,zf,:=,$p,pf,:=,31,$s,sf,:=,0,cf,:=,0,of,:=",
"sign": false,
"prefix": 0,
"id": 334,
"id": 1503,
"opex": {
"operands": [
{
Expand Down Expand Up @@ -3070,7 +3070,7 @@ EXPECT=<<EOF
"esil": "4,esp,-=,eflags,esp,=[4]",
"sign": false,
"prefix": 0,
"id": 591,
"id": 612,
"opex": {
"operands": [
{
Expand Down Expand Up @@ -3322,7 +3322,7 @@ mnemonic: nop
description: no operation
mask: ff
prefix: 0
id: 494
id: 510
bytes: 90
refptr: 0
size: 1
Expand Down
4 changes: 2 additions & 2 deletions test/db/analysis/x86_64
Original file line number Diff line number Diff line change
Expand Up @@ -2151,7 +2151,7 @@ EXPECT=<<EOF
"esil": "8,rsp,-=,eflags,rsp,=[8]",
"sign": false,
"prefix": 0,
"id": 591,
"id": 612,
"opex": {
"operands": [
{
Expand Down Expand Up @@ -3082,7 +3082,7 @@ mnemonic: push
description: push word, doubleword or quadword onto the stack
mask: ff
prefix: 0
id: 588
id: 609
bytes: 55
refptr: 0
size: 1
Expand Down
25 changes: 8 additions & 17 deletions test/db/asm/x86_32
Original file line number Diff line number Diff line change
Expand Up @@ -517,13 +517,6 @@ d "xadd byte [eax], al" 0fc000
d "xadd dword [eax], eax" 0fc100
d "xchg byte [eax], al" 8600
d "xchg dword [eax], eax" 8700
d "xchg eax, ebp" 95
d "xchg eax, ebx" 93
d "xchg eax, ecx" 91
d "xchg eax, edi" 97
d "xchg eax, edx" 92
d "xchg eax, esi" 96
d "xchg eax, esp" 94
d "xgetbv" 0f01d0
d "xlatb" D7
d "xor al, 0" 3400
Expand Down Expand Up @@ -2150,19 +2143,17 @@ aB "xchg byte [eax], al" 8600
a "xchg dword [eax], eax" 8700
ad "xchg al, dl" 86d0
ad "xchg dl, al" 86c2
ad "xchg ax, dx" 6692
a "xchg dx, ax" 6692
ad "xchg dx, ax" 6692
ad "xchg ah, dh" 86f4
ad "xchg dh, ah" 86e6
a "xchg eax, eax" 90
ad "xchg eax, ebp" 95
ad "xchg eax, ebx" 93
ad "xchg eax, ebx" 93
ad "xchg eax, ecx" 91
ad "xchg eax, edi" 97
ad "xchg eax, edx" 92
ad "xchg eax, esi" 96
ad "xchg eax, esp" 94
ad "xchg ebp, eax" 95
ad "xchg ebx, eax" 93
ad "xchg ecx, eax" 91
ad "xchg edi, eax" 97
ad "xchg edx, eax" 92
ad "xchg esi, eax" 96
ad "xchg esp, eax" 94
ad "xchg ebx, ecx" 87cb
ad "xchg ecx, ebp" 87e9
ad "xchg ecx, ebx" 87d9
Expand Down
9 changes: 3 additions & 6 deletions test/db/asm/x86_64
Original file line number Diff line number Diff line change
Expand Up @@ -961,12 +961,9 @@ a "bswap r15" 490fcf
a "bswap eax" 0fc8
a "bswap r15d" 410fcf
ad "endbr64" f30f1efa
ad "xchg eax, r8d" 4190
a "xchg r8d, eax" 4190
ad "xchg rax, rdx" 4892
a "xchg rdx, rax" 4892
ad "xchg rax, r8" 4990
a "xchg r8, rax" 4990
ad "xchg r8d, eax" 4190
ad "xchg rdx, rax" 4892
ad "xchg r8, rax" 4990
ad "xchg rdx, rbx" 4887da
ad "xchg rbx, rdx" 4887d3
ad "xchg r8, r15" 4d87f8
Expand Down
4 changes: 2 additions & 2 deletions test/db/cmd/cmd_ao
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ mnemonic: mov
description: moves data from src to dst
mask: ffffffffffffff
prefix: 0
id: 449
id: 460
bytes: c745f400000000
val: 0x00000000
disp: 0xfffffffffffffff4
Expand All @@ -54,7 +54,7 @@ stackptr: 8
"esil": "0,0xc,rbp,-,=[4]",
"sign": false,
"prefix": 0,
"id": 449,
"id": 460,
"opex": {
"operands": [
{
Expand Down