Unwinding info for cancellable syscalls
Max Filippov <[email protected]> Mon, 14 Sep 2015 05:02:56 +0300
| Newsgroups | gmane.comp.lib.uclibc.general |
|---|---|
| Message-ID | <CAMo8Bf+gz_58yRongcbiLjgySGHK2FpkPEes0v80BmKyzO6=7Q@mail.gmail.com> |
Hello, I've noticed that several NPTL tst-cancelx* tests fail on ARM, because functions invoking cancellable syscalls are compiled without -fasynchronous-unwind-tables making it impossible for the libgcc DWARF unwinder to unwind stack past the syscall and call the cleanup routine. They work on x86_64, because x86_64 gcc has -fasynchronous-unwind-tables enabled by default, and on xtensa because it uses custom unwinding code. I haven't checked, but AFAIU it should fail on other architectures that use DWARF unwinder. Can anybody confirm that? I guess that at least all functions that invoke cancellable syscalls need to be built with -fasynchronous-unwind-tables in their CFLAGS. I've tried that with couple of functions and it fixes corresponding tests. And that's what glibc does in nptl/Makefile. Does that sound right for uClibc? -- Thanks. -- Max