1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
---
source: src/main.rs
expression: output
---
"──────────────────────────────────────────────────────────────────────── heretek v0.9.0 ────────────────────────────────────────────────────────────────────────"
" F1 Main | F2 Registers | F3 Stack | F4 Instructions | F5 Output | F6 Mapping | F7 Hexdump | F8 Symbols | F9 Source "
"── Registers ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────▲"
" rax → 0x401825 → main+0 (push rbp) █"
" rbx → 0x1 ║"
" rcx → <rcx_0> → 0x04 ║"
" rdx → <rdx_0> → <rdx_1> → <rdx_2> ║"
" rsi → <rsi_0> → <rsi_1> → <rsi_2> ║"
" rdi → 0x1 ║"
" rbp → <stack_8> → <rbp_1> → <rbp_2> → 0x00 ║"
" rsp → <stack_0> → <stack_6> → <stack_6_0> → <stack_6_1> → <rbp_1> → <rbp_2> → 0x00 ║"
" r8 → 0x110 ▼"
"── Stack ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────"
" <stack_0> (rsp)→ <stack_6> → <stack_6_0> → <stack_6_1> → <rbp_1> → <rbp_2> → 0x00 "
" <stack_1> → 0x40f022 → malloc+418 (test rax,rax) "
" <stack_2> → 0x494b00 → sbb al,0x0 "
" <stack_3> → 0x4a40e8 → DW.ref.__gcc_personality_v0+0 (xor BYTE PTR [rsi+0x47],ah) "
" <stack_4> → 0x00 "
" <stack_5> → 0x4ab198 → 0x00 "
" <stack_6> → <stack_6_0> → <stack_6_1> → <rbp_1> → <rbp_2> → 0x00 "
" <stack_7> → 0x01 "
" <stack_8> (rbp)→ <rbp_1> → <rbp_2> → 0x00 "
" <stack_9> → 0x401d68 → __libc_start_call_main+104 (mov edi,eax) "
"── Instructions main ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────"
" 0x401823 this+1e pop rbp "
" 0x401824 this+1f ret "
" 0x401825 main+00 push rbp "
" 0x401826 main+01 mov rbp,rsp "
" 0x401829 main+04 sub rsp,0x40 "
">>0x40182d main+08 mov QWORD PTR [rbp-0x8],0x11111111 "
" 0x401835 main+10 mov QWORD PTR [rbp-0x10],0x22222222 "
" 0x40183d main+18 mov QWORD PTR [rbp-0x18],0x33333333 "
" 0x401845 main+20 mov QWORD PTR [rbp-0x20],0x44444444 "
" 0x40184d main+28 mov QWORD PTR [rbp-0x28],0x55555555 "
"── Backtrace ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────"
" 0040182d → main "
"── Output ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────"
"h> -gdb-set mi-async on "
"run "
"file test-assets/test_render_app/a.out "
"Reading symbols from test-assets/test_render_app/a.out... "
"break main "
"Breakpoint 1 at 0x40182d: file test.c, line 11. "
"Breakpoint 1, main () at test.c:11 "
"warning: 11 test.c: No such file or directory "
" "
"┌──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐"
"│(gdb) │"
"└──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘"
" ● stopped in main @ test.c:11 │ bkptno=1, reason=breakpoint-hit, stopped-threads=all, thread-id=1 i input ? help "