On Thu, Feb 13, 2014 at 5:39 PM, Renato Golin <renato.golin at linaro.org> wrote:> On 13 February 2014 11:35, Evgeniy Stepanov <eugenis at google.com> wrote: >> Unwind table index '.ARM.exidx' at offset 0x818 contains 4 entries: >> 0x5d4 <main>: 0x1 [cantunwind] > > This is exactly what I meant. > > >> because the latter prevent any unwinding, breaking >> debuggers/profilers/sanitizers. > > In that case, my argument stands again. > > >> As I understand, the right way to enable basic unwind through any >> function (without emitting landing pands etc, unless they are needed >> for something else) is -funwind-tables. I'm going to add that in the >> driver for all sanitizers then. > > -funwind-tables are not yet understood by ARM, but it is for Dwarf EH. > I plan on moving ARM to the same style as Dwarf, so you can assume it > is correct.Hm, I see that -funwind-tables on arm-linux-androideabi target replaces this "cantunwind" with a proper unwind table. Hence http://llvm-reviews.chandlerc.com/D2762.
On 13 February 2014 13:47, Evgeniy Stepanov <eugenis at google.com> wrote:> Hm, I see that -funwind-tables on arm-linux-androideabi target > replaces this "cantunwind" with a proper unwind table. > Hence http://llvm-reviews.chandlerc.com/D2762.If Android is using EHABI (I think it is), the default now is to output full tables all the time, everywhere. This will change to be the same as x86 soon. --renato
On Thu, Feb 13, 2014 at 5:52 PM, Renato Golin <renato.golin at linaro.org> wrote:> On 13 February 2014 13:47, Evgeniy Stepanov <eugenis at google.com> wrote: >> Hm, I see that -funwind-tables on arm-linux-androideabi target >> replaces this "cantunwind" with a proper unwind table. >> Hence http://llvm-reviews.chandlerc.com/D2762. > > If Android is using EHABI (I think it is), the default now is to > output full tables all the time, everywhere. This will change to be > the same as x86 soon.It does use EHABI, but at r201326: $ cat 1.cc int f() {} $ ./bin/clang++ -target arm-linux-androideabi 1.cc -c $ readelf -u 1.o 0x0 <_Z1fv>: 0x1 [cantunwind] $ ./bin/clang++ -target arm-linux-androideabi 1.cc -c -funwind-tables $ readelf -u 1.o 0x0 <_Z1fv>: 0x8000b0b0 Compact model 0 0x00 vsp = vsp + 4 0xb0 finish 0xb0 finish
Seemingly Similar Threads
- [LLVMdev] [cfe-dev] Unwind behaviour in Clang/LLVM
- [LLVMdev] [cfe-dev] Unwind behaviour in Clang/LLVM
- [LLVMdev] [cfe-dev] Unwind behaviour in Clang/LLVM
- [LLVMdev] Unwind, exception handling, debuggers and profilers
- [LLVMdev] Unwind, exception handling, debuggers and profilers