diff --git a/data/test_exemplars/mule_main_9ff1e58f_step_regressions_0/exemplar_windows b/data/test_exemplars/mule_main_9ff1e58f_step_regressions_0/exemplar_windows index 96d94635..e4c74f42 100644 --- a/data/test_exemplars/mule_main_9ff1e58f_step_regressions_0/exemplar_windows +++ b/data/test_exemplars/mule_main_9ff1e58f_step_regressions_0/exemplar_windows @@ -58,9 +58,6 @@ lines: } ip_voff: 0x1044 ip_voff_symbol: raddbg_thread_id__impl -lines -ip_voff: 0x15890 -ip_voff_symbol: "" lines: { { @@ -166,9 +163,6 @@ lines: } ip_voff: 0x1044 ip_voff_symbol: raddbg_thread_id__impl -lines -ip_voff: 0x15890 -ip_voff_symbol: "" lines: { { @@ -364,9 +358,6 @@ lines: } ip_voff: 0x1af4 ip_voff_symbol: mule_init -lines -ip_voff: 0x20830 -ip_voff_symbol: "" lines: { { diff --git a/data/test_exemplars/mule_main_9ff1e58f_step_regressions_1/exemplar_windows b/data/test_exemplars/mule_main_9ff1e58f_step_regressions_1/exemplar_windows index 6262f50b..bc6bde92 100644 --- a/data/test_exemplars/mule_main_9ff1e58f_step_regressions_1/exemplar_windows +++ b/data/test_exemplars/mule_main_9ff1e58f_step_regressions_1/exemplar_windows @@ -73,9 +73,6 @@ lines: } ip_voff: 0x1044 ip_voff_symbol: raddbg_thread_id__impl -lines -ip_voff: 0x15890 -ip_voff_symbol: "" lines: { { @@ -271,9 +268,6 @@ lines: } ip_voff: 0x1af4 ip_voff_symbol: mule_init -lines -ip_voff: 0x20830 -ip_voff_symbol: "" lines: { { diff --git a/data/test_inputs/mule_main_9ff1e58f/mule_main.rdi b/data/test_inputs/mule_main_9ff1e58f/mule_main.rdi index 049f7503..2125b838 100644 --- a/data/test_inputs/mule_main_9ff1e58f/mule_main.rdi +++ b/data/test_inputs/mule_main_9ff1e58f/mule_main.rdi @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:87783650d5ceb1dd991ae3a01ca4a55cefc9eacd54ead4fcc5deb72af4f9b8a3 -size 2667692 +oid sha256:446e9b14f298e3824edccf61d857108d6100a3c1a3a5dcd7fa7d52fe5a1d6a8d +size 2768548 diff --git a/data/test_inputs/mule_main_9ff1e58f/mule_module.rdi b/data/test_inputs/mule_main_9ff1e58f/mule_module.rdi index eaa2a9c0..9e6b1501 100644 --- a/data/test_inputs/mule_main_9ff1e58f/mule_module.rdi +++ b/data/test_inputs/mule_main_9ff1e58f/mule_module.rdi @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3bc47bac888fae6cbeb969e59763431847e30f380e24c9ccfd05565beacc9995 -size 5379652 +oid sha256:73c47bf20d8d12057fa9e4d12873620f6c860b1bc5d4f831b4925f03e9f7c0b4 +size 5518096 diff --git a/project.4coder b/project.4coder index 8819400a..65fc2cce 100644 --- a/project.4coder +++ b/project.4coder @@ -49,7 +49,7 @@ commands = // .f1 = { .win = "raddbg_stable --ipc kill_all && build raddbg", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, // .f1 = { .win = "raddbg_stable --ipc kill_all && build raddbg debug telemetry", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, // .f1 = { .win = "raddbg_stable --ipc kill_all && build radbin", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, - .f1 = { .win = "raddbg_stable --ipc kill_all && build raddbg telemetry", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, + .f1 = { .win = "raddbg_stable --ipc kill_all && build torture", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, //- rjf: [raddbg wsl] // .f1 = { .win = "wsl ./build.sh raddbg", .linux = "", .out = "*compilation*", .footer_panel = true, .save_dirty_files = true, .cursor_at_end = false, }, diff --git a/project.raddbg b/project.raddbg index 4f2ecc8e..e45bc52e 100644 --- a/project.raddbg +++ b/project.raddbg @@ -10,13 +10,6 @@ target: enabled: 1 } target: -{ - executable: "../raddebugger_exemplar/build/raddbg.exe" - working_directory: "../raddebugger" - arguments: "--user:C:/devel/raddebugger/build/raddbg_test.user --project:C:/devel/raddebugger/build/raddbg_test.project" - debug_subprocesses: 0 -} -target: { executable: "build/mule_main.exe" working_directory: build @@ -37,32 +30,3 @@ target: working_directory: build arguments: "--rdi raddbg" } -target: -{ - executable: "build/debugstringperf.exe" - working_directory: build -} -target: -{ - executable: "build/radbin.exe" - working_directory: build - arguments: "--rdi raddbg.exe --thread_count=1" -} -target: -{ - executable: "build/raddbg.exe" - working_directory: build - arguments: "--bin --quiet --rdi --out:C:/devel/raddebugger_stable/build/radbin.rdi --thread_count:1 C:/devel/raddebugger_stable/build/radbin.exe" -} -target: -{ - executable: "build/raddbg.exe" - working_directory: build - arguments: "--bin --rdi C:\\SymbolCache\\ntdll.pdb\\180BF1B90AA75697D0EFEA5E5630AC7E1\\ntdll.pdb --thread_count=1" -} -target: -{ - executable: "build/raddbg.exe" - working_directory: build - arguments: "--bin --rdi --thread_count=1 C:/SymbolCache/kernel32.pdb/E02F64ED8DA50EC6E7691C0AC0BC25781/kernel32.pdb" -} diff --git a/src/mule/mule_main.cpp b/src/mule/mule_main.cpp index 8aa12f8b..2d8e933c 100644 --- a/src/mule/mule_main.cpp +++ b/src/mule/mule_main.cpp @@ -6,6 +6,10 @@ ** stepping, breakpoints, evaluation, cross-module calls. */ +#if defined(__clang__) +#define _ALLOW_COMPILER_AND_STL_VERSION_MISMATCH 1 +#endif + #if _WIN32 && _DEBUG #pragma comment(linker, "/nodefaultlib:libcmt") #pragma comment(lib, "libcmtd") @@ -2363,7 +2367,8 @@ overloaded_function(int x){ // NOTE(allen): Control Flow Stepping static void -control_flow_stepping_tests(void){ +control_flow_stepping_tests(void) +{ { int a = 1; if (a < 1){ @@ -2532,6 +2537,15 @@ control_flow_stepping_tests(void){ } while (i < 10); } +#if defined(__clang__) + for (int i = 0; i < 1; + ++i, ({ goto exit; })) + { + int x = 0; + } + exit:; +#endif + { int i = 17; diff --git a/src/raddbg/raddbg_core.c b/src/raddbg/raddbg_core.c index 4eadb5ab..62125b16 100644 --- a/src/raddbg/raddbg_core.c +++ b/src/raddbg/raddbg_core.c @@ -13059,6 +13059,7 @@ rd_frame(void) RDI_Symbol *procedure = rdi_procedure_from_voff(rdi, voff); String8 name = fully_qualified_str8_from_rdi_symbol(scratch.arena, rdi, procedure); name = escaped_from_raw_str8(scratch.arena, name); + str8_list_pushf(rd_state->cmd_output_arena, &rd_state->cmd_outputs, " ip_module: \"%S\"\n", str8_skip_last_slash(module->string)); str8_list_pushf(rd_state->cmd_output_arena, &rd_state->cmd_outputs, " ip_voff: 0x%I64x\n", voff); str8_list_pushf(rd_state->cmd_output_arena, &rd_state->cmd_outputs, " ip_voff_symbol: \"%S\"\n", name); access_close(access); diff --git a/src/raddbg/tests/raddbg_tests.c b/src/raddbg/tests/raddbg_tests.c index 6956d14c..394853ef 100644 --- a/src/raddbg/tests/raddbg_tests.c +++ b/src/raddbg/tests/raddbg_tests.c @@ -181,15 +181,20 @@ rd_test__stepping_regressions(Arena *arena, TestCtx *ctx, String8 target_binary, // rjf: if we are ready for the next operation, then accumulate deterministic log info if(ready_for_next_operation) { - MD_Node *lines = md_child_from_string(state, s("lines"), 0); - MD_Node *ip_voff = md_child_from_string(state, s("ip_voff"), 0); - MD_Node *ip_voff_symbol = md_child_from_string(state, s("ip_voff_symbol"), 0); - String8 lines_dump = md_string_from_tree(scratch.arena, lines); - String8 ip_voff_dump = md_string_from_tree(scratch.arena, ip_voff); - String8 ip_voff_symbol_dump = md_string_from_tree(scratch.arena, ip_voff_symbol); - str8_list_push(scratch.arena, &test_log_strings, lines_dump); - str8_list_push(scratch.arena, &test_log_strings, ip_voff_dump); - str8_list_push(scratch.arena, &test_log_strings, ip_voff_symbol_dump); + MD_Node *ip_module = md_child_from_string(state, s("ip_module"), 0); + String8 ip_module_name = ip_module->first->string; + if(str8_match(str8_chop_last_dot(ip_module_name), target_binary, 0)) + { + MD_Node *lines = md_child_from_string(state, s("lines"), 0); + MD_Node *ip_voff = md_child_from_string(state, s("ip_voff"), 0); + MD_Node *ip_voff_symbol = md_child_from_string(state, s("ip_voff_symbol"), 0); + String8 lines_dump = md_string_from_tree(scratch.arena, lines); + String8 ip_voff_dump = md_string_from_tree(scratch.arena, ip_voff); + String8 ip_voff_symbol_dump = md_string_from_tree(scratch.arena, ip_voff_symbol); + str8_list_push(scratch.arena, &test_log_strings, lines_dump); + str8_list_push(scratch.arena, &test_log_strings, ip_voff_dump); + str8_list_push(scratch.arena, &test_log_strings, ip_voff_symbol_dump); + } } // rjf: are we without line info? -> step out diff --git a/src/torture/torture_main.c b/src/torture/torture_main.c index 567157c9..bb4fa18d 100644 --- a/src/torture/torture_main.c +++ b/src/torture/torture_main.c @@ -33,6 +33,8 @@ #include "mdesk/mdesk.h" #include "metagen/metagen.h" #include "window_manager/window_manager_inc.h" +#include "http/http_inc.h" +#include "symbol_server/symbol_server_inc.h" #include "config/config_inc.h" #include "content/content.h" #include "file_stream/file_stream.h" @@ -111,6 +113,8 @@ #include "mdesk/mdesk.c" #include "metagen/metagen.c" #include "window_manager/window_manager_inc.c" +#include "http/http_inc.c" +#include "symbol_server/symbol_server_inc.c" #include "config/config_inc.c" #include "content/content.c" #include "file_stream/file_stream.c"