Hi list,
I hit another weird problem after use gcc 5.3 (If I use gcc 4.9, there is no any
issue) with android.
With arm gcc 5.3, the C++ apps crash in one class constructor call. And gdb
shows some vtbl items of the class are not relocated.
With arm gcc 4.9, if set breakpoint in that constructor, we could see the vtbl
items of the class are relocated.
And Yes. I know the android bionic loader take response to do relocation. But if
it works with gcc 4.9, I suppose bionic loader work well (unless gcc 5.3 create
some new situation not handled by it).
I attached the vtbl dump in gdb for gcc 5.3 and 4.9 both. We could see all valid
entries in vtbl are relocated in 4.9 dump. But not all entries in vtbl are
relocated in 5.3 dump (the address is not started with 0xf).
Suggestions/hints are welcome. Thanks a lot.
Regards
Yin, Fengwei
(gdb) x/32xw 0xf6a1ed00
0xf6a1ed00
<_ZTVN7android12SortedVectorINS_16key_value_pair_tIiNS_2spINS_8AMessageEEEEEEE+32>:
0x004be99d 0x004bea1d 0x004bd9bf 0x00000000
0xf6a1ed10 <_ZTVN7android15ARTSPConnectionE+4>: 0x00000000 0x004be1c9
0x004be23d 0xf745d675
0xf6a1ed20 <_ZTVN7android15ARTSPConnectionE+20>: 0xf745d675
0xf745f649 0xf745d675 0x004bf9c9
0xf6a1ed30 <_ZTVN7android18ARawAudioAssemblerE>: 0x00000000
0x00000000 0x004bfc2d 0x004bfc59
0xf6a1ed40 <_ZTVN7android18ARawAudioAssemblerE+16>: 0xf745d675
0xf745d675 0xf745f649 0xf745d675
0xf6a1ed50 <_ZTVN7android18ARawAudioAssemblerE+32>: 0x004bfc6d
0x004bfddd 0x004bfb15 0x00000000
0xf6a1ed60 <_ZTVN7android6VectorINS_11KeyedVectorINS_7AStringES2_EEEE+4>:
0x00000000 0x004bfef1 0x004bff19 0x004c099d
0xf6a1ed70 <_ZTVN7android6VectorINS_11KeyedVectorINS_7AStringES2_EEEE+20>:
0x004bfea5 0x004bfebd 0x004bffa5 0x004bfde1
(gdb)
0xf6a1ed80 <_ZTVN7android6VectorINS_11KeyedVectorINS_7AStringES2_EEEE+36>:
0x004bfde1 0x00000000 0x00000000 0x004bff2d
0xf6a1ed90 <_ZTVN7android6VectorINS_7AStringEEE+12>: 0x004bff55
0x004bfe8b 0x004bfe27 0x004bfded
0xf6a1eda0 <_ZTVN7android6VectorINS_7AStringEEE+28>: 0x004bfe0b
0x004bfe3d 0x004bfe67 0x00000000
0xf6a1edb0 <_ZTVN7android19ASessionDescriptionE+4>: 0x00000000
0x004bff69 0x004bff91 0xf745d675
0xf6a1edc0 <_ZTVN7android19ASessionDescriptionE+20>: 0xf745d675
0xf745f649 0xf745d675 0x00000000
0xf6a1edd0 <_ZTVN7android21RtspConnectionHandlerE+4>: 0x00000000
0x004c11c9 0x004c124d 0xf745d675
0xf6a1ede0 <_ZTVN7android21RtspConnectionHandlerE+20>: 0xf745d675
0xf745f649 0xf745d675 0x004c2981
0xf6a1edf0 <_ZTVN7android4ListINS_7AStringEEE>: 0x00000000 0x00000000
0x004c0a59 0x004c0a85
(gdb) info symbol 0xf745d675
android::RefBase::weakref_type::printRefs() const + 1 in section .text of
symbols/system/lib/libutils.so
(gdb)
(gdb) x/32xw 0xf6ac1bfc
0xf6ac1bfc <_ZTVN7android15ARTSPConnectionE+4>: 0x00000000 0xf430ce89
0xf430cf21 0xf7399705
0xf6ac1c0c <_ZTVN7android15ARTSPConnectionE+20>: 0xf7399705
0xf739b651 0xf7399705 0xf430e6ad
0xf6ac1c1c: 0x00000000 0x00000000 0x00000000 0xf430e94d
0xf6ac1c2c <_ZTVN7android18ARawAudioAssemblerE+12>: 0xf430e979
0xf7399705 0xf7399705 0xf739b651
0xf6ac1c3c <_ZTVN7android18ARawAudioAssemblerE+28>: 0xf7399705
0xf430e98d 0xf430eb01 0xf430e80d
0xf6ac1c4c: 0x00000000 0x00000000 0x00000000 0xf430ebdd
0xf6ac1c5c <_ZTVN7android6VectorINS_11KeyedVectorINS_7AStringES2_EEEE+12>:
0xf430ebfd 0xf430ecd9 0xf430ebc7 0xf430ecad
0xf6ac1c6c <_ZTVN7android6VectorINS_11KeyedVectorINS_7AStringES2_EEEE+28>:
0xf430ec81 0xf430eb05 0xf430eb05 0x00000000
(gdb)
0xf6ac1c7c <_ZTVN7android6VectorINS_7AStringEEE+4>: 0x00000000
0xf430ec11 0xf430ec31 0xf430ebaf
0xf6ac1c8c <_ZTVN7android6VectorINS_7AStringEEE+20>: 0xf430eb4b
0xf430eb11 0xf430eb2f 0xf430eb61
0xf6ac1c9c <_ZTVN7android6VectorINS_7AStringEEE+36>: 0xf430eb8b
0x00000000 0x00000000 0xf430ec45
0xf6ac1cac <_ZTVN7android19ASessionDescriptionE+12>: 0xf430ec6d
0xf7399705 0xf7399705 0xf739b651
0xf6ac1cbc <_ZTVN7android19ASessionDescriptionE+28>: 0xf7399705
0x00000000 0x00000000 0xf430fec1
0xf6ac1ccc <_ZTVN7android21RtspConnectionHandlerE+12>: 0xf430ff45
0xf7399705 0xf7399705 0xf739b651
0xf6ac1cdc <_ZTVN7android21RtspConnectionHandlerE+28>: 0xf7399705
0xf43116d5 0x00000000 0x00000000
0xf6ac1cec <_ZTVN7android4ListINS_7AStringEEE+4>: 0x00000000
0xf430f769 0xf430f78d 0x00000000
_______________________________________________
linaro-toolchain mailing list
linaro-toolchain@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/linaro-toolchain