uftrace v0.15
This version comes with a new architecture support as well as
many bug fixes and various improvements.
RISC-V Architecture Support
uftrace can trace functions of RV64G binaries compiled by gcc/clang with
appropriate options (-pg
or -finstrument-functions
). Library functions
are also traced and you can see the arguments and return values too.
(There are issues in argument handling, but library functions should be
fine.) However dynamic tracing is not supported yet.
$ uftrace --force -a -t 3us -- uname -m
riscv64
# DURATION TID FUNCTION
263.004 us [138960] | strrchr("uname", '/') = "NULL";
87.751 us [138960] | setlocale(LC_ALL, "") = "NULL";
5.000 us [138960] | bindtextdomain("coreutils", "/usr/share/locale");
4.000 us [138960] | getopt_long(2, 0x3fecdcf328, "asnrvmpio") = 109;
4.000 us [138960] | uname();
8.250 us [138960] | fputs_unlocked();
443.257 us [138960] | __overflow();
3.250 us [138960] | __fpending();
4.500 us [138960] | fclose(&_IO_2_1_stdout_) = 0;
Other Notable Improvements
As libtraceevent is available on recent distros, the kernel tracing uses
the system installed library and drops the old copy in the uftrace source.
This should help resolving possible future kernel issues and reduce the
maintenance burden.
Also some distros build binaries without PLT and it can confuse uftrace
about the library call tracing. It now detects the case by verifying
PLT entries not to miss library calls without it.
What's Changed
- configure: fix error when building out of source by @licy183 in #1737
- doc: Update README.md for user space function tracing by @honggyukim in #1742
- docs: uftrace slides update by @paranlee in #1744
- Refactor the kernel depth option and documentation by @ChoKyuWon in #1759
- tests: fix t151 recv_runcmd test code. by @kang-hyuck in #1765
- dynamic: Refactor patch pattern logic by @clementguidi in #1703
- tests: Changing test case statistics conditions. by @coyotek in #1771
- utils: fix demangle_full to only demangle mangled C++ symbols by @jyf111 in #1780
- doc: Fix --task name in uftrace graph man page by @honggyukim in #1785
- misc: modify manual to build dockerfile by @haileynam in #1783
- doc/ko: Update README in Korean by @mirusu400 in #1760
- tests: fix
gen_port()
to select unbind ports by @mirusu400 in #1769 - dump: Fix Mermaid to work properly by specifying the version of Mermaid by @mirusu400 in #1794
- utils: Fix an issue not finding tracefs on some kernels by @gichoel in #1762
- doc: Fix typo in uftrace.md by @mirusu400 in #1786
- doc/ko: Update CONTRIBUTING.md in Korean by @jigsaw-0 in #1790
- doc/ko: Add missing options in man pages by @jeonghwanin in #1806
- filter: Remove obsolete function add_trigger by @sypark9646 in #1807
- doc: Add = sign for '--depth' option in uftrace-dump.md by @SEOKMIN83 in #1788
- misc: Add wget-pr.sh script by @honggyukim in #1808
- utils: Remove unused function: get_event_name by @SEOKMIN83 in #1817
- mcount-dynamic: Use MAP_FIXED_NOREPLACE for trampoline by @oldiob in #1798
- tests: Change tests/runtest.py to match the pylint code style by @sypark9646 in #1810
- dynamic: Fix -U for -fpatchable-function-entry by @honggyukim in #1799
- libmcount: support no-plt binary by @ChoKyuWon in #1820
- uftrace: fix a memory leak when option parsing failed by @ChoKyuWon in #1823
- arch/riscv64: Add basic mcount tracing support for RISC-V 64bit by @gichoel in #1815
- explicit python3 instead of python2 support by @RobertBerger in #1831
- replay: Revise the logic of setting NEEDS_PAREN to correctly add parentheses by @jyf111 in #1832
- build: Fix build errors due to low kernel version by @MichelleJin12 in #1838
- build: Fix compile warning message by @keepgoingxxx in #1768
- uftrace: Add help message for make by @kangtegong in #1842
- misc: Enhance and rename wget-pr script by @kangtegong in #1844
- mcount: Restore/reset rstack only when the return address is hijacked by @jyf111 in #1841
- README.md: Fix duplicated "with" by @bernhardkaindl in #1668
- doc: Fix typos and improve language in README.md by @bernhardkaindl in #1669
- Fix broken kernel tracing in presence of offline CPUs by @shoffmeister in #1849
- uftrace: Fix dead store warnings found by infer by @paranlee in #1757
- utils: Fix warnings implicit declaration of function 'close' by @paranlee in #1860
- libmcount: Remove UFTRACE_PIPE related code by @honggyukim in #1871
- utils: Fix incorrect header includes by @honggyukim in #1872
- utils: Add DTRAP macro and use it in pr_err by @honggyukim in #1854
- New release v0.15 by @namhyung in #1863
New Contributors
- @licy183 made their first contribution in #1737
- @kang-hyuck made their first contribution in #1765
- @coyotek made their first contribution in #1771
- @jyf111 made their first contribution in #1780
- @haileynam made their first contribution in #1783
- @mirusu400 made their first contribution in #1760
- @gichoel made their first contribution in #1762
- @jigsaw-0 made their first contribution in #1790
- @jeonghwanin made their first contribution in #1806
- @sypark9646 made their first contribution in #1807
- @SEOKMIN83 made their first contribution in #1788
- @oldiob made their first contribution in #1798
- @RobertBerger made their first contribution in #1831
- @keepgoingxxx made their first contribution in #1768
- @shoffmeister made their first contribution in #1849
Full Changelog: v0.14...v0.15