Page MenuHomePhabricator

Filters: add Event_Information struct.

Authored by Deepwarrior on Jul 14 2017, 6:39 AM.



This struct contain information about event with some name. List of all events
replace arrays with names and colors. Any flag(like filtred) can be added to
event easy.

Refactoring: fix string compares.

Use strncmp instead strcmp in cases when compares strings without
first symbol. It could cause errors in case event names with only one
symbol like "+".

Filters: replace color find function with event info find.

More information about event now needed: color and filter_status.

Do not show thread events with flag "filtred"

Add genlist and filters for thread events.

Genlist contain all thread events names and toggle check.
Add callback on changes on this check which change flag filtered in chosen
Filters will be apply on next interval change.

Add filters for CPU events.

Use Eina_List of Event_Information struct for states instead array.

It give ability to easy add any flags for state event name.

Add state events to filtration genlist.

Merge branch 'filters'

Test Plan

Open log, open filter window from menu. Apply some filters and change interval.
Chosen events must disapear.

Diff Detail

No Linters Available
No Unit Test Coverage
Build Status
Buildable 4164
Build 4229: arc lint + arc unit
Deepwarrior created this revision.Jul 14 2017, 6:39 AM
NikaWhite requested changes to this revision.Jul 27 2017, 4:56 AM

Possible to open more than one instance of filter dialog window.




gettext macro need to be used here.


gettext macro need to be used here.


"CPU frequency" - translatable?
The same below

This revision now requires changes to proceed.Jul 27 2017, 4:56 AM

Steps to reproduce a segfault:

  1. Launch Profiling Viewer
  2. Open log file
  3. Open filter and select some events as filtered
  4. Open another log file. The filters window still opened.
  5. Scroll content of the filters window.

Result: Segfault.
Expected: After load new file finished - content of filter window refreshed.


#0  0x00007ffff5e3a1a6 in strlen () at /usr/lib/
#1  0x00007ffff5e39ebe in strdup () at /usr/lib/
#2  0x00007ffff64fb2db in _item_text_realize (target=target@entry=0x800004a89682ed51, source=source@entry=0x3d06c98, parts=parts@entry=0x0, it=<optimized out>, it=<optimized out>) at lib/elementary/elm_genlist.c:347
#3  0x00007ffff64fb8c9 in _view_inflate (view=0x800004a89682ed51, it=it@entry=0x3d06c40, sources=sources@entry=0x3d06c98, contents=contents@entry=0x3d06ca0) at lib/elementary/elm_genlist.c:1350
#4  0x00007ffff64fd802 in _item_realize (it=it@entry=0x3d06c40, index=index@entry=15, calc=calc@entry=0 '\000') at lib/elementary/elm_genlist.c:1904
#5  0x00007ffff6501fe4 in _item_block_position (itb=itb@entry=0x4419bd0, blk_idx=blk_idx@entry=0) at lib/elementary/elm_genlist.c:2362
#6  0x00007ffff650534f in _elm_genlist_pan_efl_canvas_group_group_calculate (obj=0x8000034abe829e19, psd=0x10505b0) at lib/elementary/elm_genlist.c:2522
#7  0x00007ffff6c7a416 in efl_canvas_group_calculate (obj=0x8000034abe829e19) at ../src/lib/evas/canvas/efl_canvas_group.eo.c:16
#8  0x00007ffff6c7b365 in evas_call_smarts_calculate (eo_e=eo_e@entry=0x8000034676829d90) at lib/evas/canvas/evas_object_smart.c:1033
#9  0x00007ffff6cc79fd in evas_render_updates_internal (eo_e=eo_e@entry=0x8000034676829d90, make_updates=make_updates@entry=1 '\001', do_draw=do_draw@entry=1 '\001', done_func=done_func@entry=0x0, done_data=done_data@entry=0x0, do_async=do_async@entry=0 '\000') at lib/evas/canvas/evas_render.c:3119
#10 0x00007ffff6cca4ef in evas_render_updates_internal_wait (eo_e=eo_e@entry=0x8000034676829d90, make_updates=make_updates@entry=1 '\001', do_draw=1 '\001') at lib/evas/canvas/evas_render.c:3797
#11 0x00007ffff6ccad1c in _evas_canvas_render_updates (eo_e=0x8000034676829d90, e=<optimized out>) at lib/evas/canvas/evas_render.c:3819
#12 0x00007ffff6c52a06 in evas_canvas_render_updates (obj=0x8000034676829d90) at ../src/lib/evas/canvas/evas_canvas.eo.c:240
#13 0x00007ffff6c55a95 in evas_render_updates (obj=<optimized out>) at ../src/lib/evas/canvas/evas_canvas.eo.c:804
#14 0x00007fffdf5da045 in _ecore_evas_x_render (ee=0x426af50) at modules/ecore_evas/engines/x/ecore_evas_x.c:805
#15 0x00007ffff7276d50 in _ecore_evas_idle_enter (data=<optimized out>) at lib/ecore_evas/ecore_evas.c:284
#16 0x00007ffff76f921f in _ecore_call_task_cb (data=<optimized out>, func=<optimized out>) at lib/ecore/ecore_private.h:291
#17 0x00007ffff76f921f in _ecore_factorized_idle_process (data=0x652330, event=<optimized out>) at lib/ecore/ecore_idler.c:35
#18 0x00007ffff4924b27 in _event_callback_call (legacy_compare=0 '\000', event_info=<optimized out>, desc=0x7ffff7927f40 <_EFL_LOOP_EVENT_IDLE_ENTER>, pd=0x64bc60, obj_id=<optimized out>) at lib/eo/eo_base_class.c:1473
#19 0x00007ffff4924b27 in _efl_object_event_callback_call (obj_id=<optimized out>, pd=0x64bc60, desc=0x7ffff7927f40 <_EFL_LOOP_EVENT_IDLE_ENTER>, event_info=<optimized out>) at lib/eo/eo_base_class.c:1557
#20 0x00007ffff492048e in efl_event_callback_call (obj=0x800000000e81fbce, desc=0x7ffff7927f40 <_EFL_LOOP_EVENT_IDLE_ENTER>, event_info=event_info@entry=0x0) at lib/eo/eo_base_class.c:1560
#21 0x00007ffff76f90ee in _ecore_idle_enterer_call (loop=<optimized out>) at lib/ecore/ecore_idle_enterer.c:48
#22 0x00007ffff76fc2b6 in _ecore_main_loop_iterate_internal (once_only=once_only@entry=0) at lib/ecore/ecore_main.c:2309
#23 0x00007ffff76fc8f7 in ecore_main_loop_begin () at lib/ecore/ecore_main.c:1299
#24 0x00007ffff65532f5 in elm_run () at lib/elementary/elm_main.c:1337
#25 0x0000000000404703 in elm_main (argc=argc@entry=1, argv=argv@entry=0x7fffffffe5a8) at /home/nikawhite/repos/enlightenment/efl_profiler_viewer/src/bin/main.c:112
#26 0x00000000004044cc in main (argc=1, argv=0x7fffffffe5a8) at /home/nikawhite/repos/enlightenment/efl_profiler_viewer/src/bin/main.c:117
Deepwarrior edited edge metadata.

I fix your comments, thanks.

Deepwarrior abandoned this revision.Aug 1 2017, 2:46 AM