Skip to content

Commit 1865c33

Browse files
committed
specify collection qualifier for collection tabs; do not resolve to anything else
1 parent e17a089 commit 1865c33

File tree

3 files changed

+24
-17
lines changed

3 files changed

+24
-17
lines changed

src/eval/eval_types.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -565,6 +565,7 @@ e_type_kind_from_key(E_TypeKey key)
565565
internal E_Type *
566566
e_type_from_key(Arena *arena, E_TypeKey key)
567567
{
568+
ProfBeginFunction();
568569
E_Type *type = &e_type_nil;
569570
U64 reg_byte_count = 0;
570571
{
@@ -1115,6 +1116,7 @@ e_type_from_key(Arena *arena, E_TypeKey key)
11151116
}break;
11161117
}
11171118
}
1119+
ProfEnd();
11181120
return type;
11191121
}
11201122

src/eval_visualization/eval_visualization_core.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -671,6 +671,7 @@ ev_resolved_from_expr(Arena *arena, E_Expr *expr, EV_ViewRuleList *view_rules)
671671
internal EV_BlockTree
672672
ev_block_tree_from_expr(Arena *arena, EV_View *view, String8 filter, String8 string, E_Expr *expr, EV_ViewRuleList *view_rules)
673673
{
674+
ProfBeginFunction();
674675
EV_BlockTree tree = {&ev_nil_block};
675676
{
676677
Temp scratch = scratch_begin(&arena, 1);
@@ -874,12 +875,14 @@ ev_block_tree_from_expr(Arena *arena, EV_View *view, String8 filter, String8 str
874875
}
875876
scratch_end(scratch);
876877
}
878+
ProfEnd();
877879
return tree;
878880
}
879881

880882
internal EV_BlockTree
881883
ev_block_tree_from_string(Arena *arena, EV_View *view, String8 filter, String8 string, EV_ViewRuleList *view_rules)
882884
{
885+
ProfBeginFunction();
883886
EV_BlockTree tree = {0};
884887
Temp scratch = scratch_begin(&arena, 1);
885888
{
@@ -891,6 +894,7 @@ ev_block_tree_from_string(Arena *arena, EV_View *view, String8 filter, String8 s
891894
tree = ev_block_tree_from_expr(arena, view, filter, string, parse.expr, all_view_rules);
892895
}
893896
scratch_end(scratch);
897+
ProfEnd();
894898
return tree;
895899
}
896900

src/raddbg/raddbg_views.c

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1327,7 +1327,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
13271327
Vec2S64 cursor_tbl = {0};
13281328
Vec2S64 mark_tbl = {0};
13291329
Rng2S64 selection_tbl = {0};
1330-
if(!is_top_level_hook) UI_Focus(UI_FocusKind_On)
1330+
if(!is_top_level_hook) ProfScope("consume events & perform navigations/edits - calculate state") UI_Focus(UI_FocusKind_On)
13311331
{
13321332
B32 state_dirty = 1;
13331333
B32 snap_to_cursor = 0;
@@ -1338,7 +1338,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
13381338
//////////////////////////
13391339
//- rjf: state -> viz blocks
13401340
//
1341-
if(state_dirty)
1341+
if(state_dirty) ProfScope("state -> viz blocks")
13421342
{
13431343
MemoryZeroStruct(&block_tree);
13441344
MemoryZeroStruct(&block_ranges);
@@ -1350,6 +1350,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
13501350
//////////////////////////
13511351
//- rjf: block ranges -> ui row blocks
13521352
//
1353+
ProfScope("block ranges -> ui row blocks")
13531354
{
13541355
UI_ScrollListRowBlockChunkList row_block_chunks = {0};
13551356
for(EV_BlockRangeNode *n = block_ranges.first; n != 0; n = n->next)
@@ -2140,7 +2141,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
21402141
//- rjf: build ui
21412142
//
21422143
B32 pressed = 0;
2143-
if(!is_top_level_hook)
2144+
if(!is_top_level_hook) ProfScope("build ui")
21442145
{
21452146
F32 **col_pcts = push_array(scratch.arena, F32*, ewv->column_count);
21462147
{
@@ -5375,7 +5376,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(targets)
53755376
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1, .is_non_code = 0);
53765377
}
53775378
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5378-
str8_lit("targets"), str8_lit("only: label exe args working_directory entry_point stdout_path stderr_path stdin_path str"), 1, 10, rect);
5379+
str8_lit("collection:targets"), str8_lit("only: label exe args working_directory entry_point stdout_path stderr_path stdin_path str"), 1, 10, rect);
53795380
ProfEnd();
53805381
}
53815382

@@ -5393,7 +5394,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(file_path_map)
53935394
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1, .is_non_code = 0);
53945395
}
53955396
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5396-
str8_lit("file_path_maps"), str8_lit("only: source_path destination_path str"), 1, 10, rect);
5397+
str8_lit("collection:file_path_maps"), str8_lit("only: source_path destination_path str"), 1, 10, rect);
53975398
ProfEnd();
53985399
}
53995400

@@ -5411,7 +5412,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(auto_view_rules)
54115412
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1, .is_non_code = 0);
54125413
}
54135414
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5414-
str8_lit("auto_view_rules"), str8_lit("only: type view_rule str"), 1, 10, rect);
5415+
str8_lit("collection:auto_view_rules"), str8_lit("only: type view_rule str"), 1, 10, rect);
54155416
ProfEnd();
54165417
}
54175418

@@ -5429,7 +5430,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(breakpoints)
54295430
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1);
54305431
}
54315432
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5432-
str8_lit("breakpoints"), str8_lit("only: label condition str hit_count source_location address_location function_location"), 0, 10, rect);
5433+
str8_lit("collection:breakpoints"), str8_lit("only: label condition str hit_count source_location address_location function_location"), 0, 10, rect);
54335434
ProfEnd();
54345435
}
54355436

@@ -5447,7 +5448,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(watch_pins)
54475448
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1);
54485449
}
54495450
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5450-
str8_lit("watch_pins"), str8_lit("only: label source_location address_location str"), 0, 10, rect);
5451+
str8_lit("collection:watch_pins"), str8_lit("only: label source_location address_location str"), 0, 10, rect);
54515452
ProfEnd();
54525453
}
54535454

@@ -5465,7 +5466,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(scheduler)
54655466
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1);
54665467
}
54675468
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5468-
str8_lit("machines"), str8_lit("only: label str id callstack v count vaddr inline_depth"), 0, 10, rect);
5469+
str8_lit("collection:machines"), str8_lit("only: label str id callstack v count vaddr inline_depth"), 0, 10, rect);
54695470
ProfEnd();
54705471
}
54715472

@@ -5502,7 +5503,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(modules)
55025503
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.75f, .dequote_string = 1);
55035504
}
55045505
rd_watch_view_build(wv, RD_WatchViewFlag_NoHeader|RD_WatchViewFlag_PrettyNameMembers|RD_WatchViewFlag_PrettyEntityRows|RD_WatchViewFlag_DisableCacheLines,
5505-
str8_lit("modules"), str8_lit("only: exe dbg str vaddr_range min max"), 0, 16, rect);
5506+
str8_lit("collection:modules"), str8_lit("only: exe dbg str vaddr_range min max"), 0, 16, rect);
55065507
ProfEnd();
55075508
}
55085509

@@ -5521,7 +5522,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(watch)
55215522
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
55225523
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
55235524
}
5524-
rd_watch_view_build(wv, 0, str8_lit("watches"), str8_lit(""), 1, 10, rect);
5525+
rd_watch_view_build(wv, 0, str8_lit("collection:watches"), str8_lit(""), 1, 10, rect);
55255526
ProfEnd();
55265527
}
55275528

@@ -5540,7 +5541,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(locals)
55405541
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
55415542
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
55425543
}
5543-
rd_watch_view_build(wv, 0, str8_lit("locals"), str8_lit(""), 0, 10, rect);
5544+
rd_watch_view_build(wv, 0, str8_lit("collection:locals"), str8_lit(""), 0, 10, rect);
55445545
ProfEnd();
55455546
}
55465547

@@ -5559,7 +5560,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(registers)
55595560
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
55605561
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
55615562
}
5562-
rd_watch_view_build(wv, 0, str8_lit("registers"), str8_lit("hex"), 0, 16, rect);
5563+
rd_watch_view_build(wv, 0, str8_lit("collection:registers"), str8_lit("hex"), 0, 16, rect);
55635564
ProfEnd();
55645565
}
55655566

@@ -5578,7 +5579,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(globals)
55785579
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
55795580
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
55805581
}
5581-
rd_watch_view_build(wv, 0, str8_lit("globals"), str8_lit(""), 0, 10, rect);
5582+
rd_watch_view_build(wv, 0, str8_lit("collection:globals"), str8_lit(""), 0, 10, rect);
55825583
ProfEnd();
55835584
}
55845585

@@ -5597,7 +5598,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(thread_locals)
55975598
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
55985599
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
55995600
}
5600-
rd_watch_view_build(wv, 0, str8_lit("thread_locals"), str8_lit(""), 0, 10, rect);
5601+
rd_watch_view_build(wv, 0, str8_lit("collection:thread_locals"), str8_lit(""), 0, 10, rect);
56015602
ProfEnd();
56025603
}
56035604

@@ -5616,7 +5617,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(types)
56165617
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Type, 0.15f);
56175618
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.30f);
56185619
}
5619-
rd_watch_view_build(wv, 0, str8_lit("types"), str8_lit(""), 0, 10, rect);
5620+
rd_watch_view_build(wv, 0, str8_lit("collection:types"), str8_lit(""), 0, 10, rect);
56205621
ProfEnd();
56215622
}
56225623

@@ -5634,7 +5635,7 @@ RD_VIEW_RULE_UI_FUNCTION_DEF(procedures)
56345635
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_Value, 0.6f);
56355636
rd_watch_view_column_alloc(wv, RD_WatchViewColumnKind_ViewRule, 0.2f);
56365637
}
5637-
rd_watch_view_build(wv, 0, str8_lit("procedures"), str8_lit(""), 0, 10, rect);
5638+
rd_watch_view_build(wv, 0, str8_lit("collection:procedures"), str8_lit(""), 0, 10, rect);
56385639
ProfEnd();
56395640
}
56405641

0 commit comments

Comments
 (0)