namhyung / uftrace

Function graph tracer for C/C++/Rust/Python
https://uftrace.github.io/slide/
GNU General Public License v2.0
3.06k stars 472 forks source link

test failures in x86_64 with asan enabled #1213

Open honggyukim opened 4 years ago

honggyukim commented 4 years ago

Here is the output of failed-tests.txt.

$ make ASAN=1

$ cd tests

$ ./runtest.py -j4

$ cat failed-tests.txt
Test case                 pg             finstrument-fu
------------------------: O0 O1 O2 O3 Os O0 O1 O2 O3 Os
043 full_demangle       : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
067 report_diff         : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
117 time_range          : OK OK OK OK OK NG OK OK OK OK
125 report_range        : OK NG OK OK NG OK OK OK OK OK
135 trigger_time2       : OK OK OK OK OK OK NG OK OK OK
136 dynamic             : OK OK OK OK OK NG NG NG NG NG
147 event_sdt           : BI BI BI BI BI BI BI BI BI BI
150 recv_event          : BI BI BI BI BI BI BI BI BI BI
151 recv_runcmd         : NG NG NG NG NG NG NG NG NG NG
157 script_python       : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
158 report_diff_policy1 : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
159 report_diff_policy2 : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
160 report_diff_policy3 : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
162 pltbind_now_pie     : BI BI BI BI BI BI BI BI BI BI
169 script_args         : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
170 script_filter       : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
171 script_option       : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
177 report_diff_policy4 : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
199 script_info         : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
203 arg_dwarf3          : OK OK NG NG NG SK SK SK SK SK
204 arg_dwarf4          : OK OK NG NG OK SK SK SK SK SK
219 no_libcall_script   : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
220 trace_script        : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
221 taskname_time       : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
228 read_pmu_cycle3     : OK OK NG NG NG OK OK OK OK OK
232 dynamic_unpatch     : OK OK OK OK OK NG NG NG NG NG
239 report_diff_field1  : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
240 report_diff_field2  : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
241 report_diff_field3  : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
242 report_diff_field4  : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ
243 report_diff_field5  : NZ NZ NZ NZ NZ NZ NZ NZ NZ NZ

The normal test result without asan enabled is as follows.

$ cat failed-tests.txt
Test case                 pg             finstrument-fu
------------------------: O0 O1 O2 O3 Os O0 O1 O2 O3 Os
117 time_range          : OK OK OK OK OK OK NG OK OK OK
125 report_range        : OK OK OK OK NG OK OK OK OK OK
135 trigger_time2       : OK OK OK OK OK NG OK OK OK OK
136 dynamic             : OK OK OK OK OK NG NG NG NG NG
147 event_sdt           : BI BI BI BI BI BI BI BI BI BI
150 recv_event          : BI BI BI BI BI BI BI BI BI BI
151 recv_runcmd         : NG NG NG NG NG NG NG NG NG NG
158 report_diff_policy1 : OK OK OK OK OK NG OK OK OK OK
162 pltbind_now_pie     : BI BI BI BI BI BI BI BI BI BI
165 graph_sched         : OK OK OK OK OK OK NG OK OK OK
182 thread_exit         : OK OK OK OK OK NG OK OK NG OK
203 arg_dwarf3          : OK OK NG NG NG SK SK SK SK SK
204 arg_dwarf4          : OK OK NG NG OK SK SK SK SK SK
222 external_data       : NG OK OK OK OK OK OK OK OK OK
228 read_pmu_cycle3     : OK OK NG NG NG NG OK OK OK OK
232 dynamic_unpatch     : OK OK OK OK OK NG NG NG NG NG
namhyung commented 4 years ago

It seems we should test it with ASAN regularly.

namhyung commented 3 years ago

I found that the diff code has a problem. Will fix it soon.

namhyung commented 3 years ago

Other problems seem to be not in uftrace. The C++ full demangle code is in libstdc++ and script is from the python runtime. Maybe we should suppress ASAN for external codes if it's possible.