Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. How to detect crash point in Qt Creator debugger
QtWS25 Last Chance

How to detect crash point in Qt Creator debugger

Scheduled Pinned Locked Moved Mobile and Embedded
5 Posts 2 Posters 2.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    raj.qtdev
    wrote on 5 Oct 2013, 10:02 last edited by
    #1

    Hi all,

    i am using Qt creator 2.2.1 to develop a mobile application using Qt for symbian phones. The application is randomly crashing at some points when i try to on device debug the application. And whenever it crashes, it gives only one message SEGV fault and displays following on the screen:

    Disassembler (??)

    -----<qDebug() statements go here>----
    -----<qDebug() statements go here>----
    -----<qDebug() statements go here>----
    Could not load shared library symbols for 23 libraries, e.g. libm.dll.
    Use the "info sharedlibrary" command to see the complete listing.
    Do you need "set solib-search-path" or "set sysroot"?
    Debugging has finished

    In the upper half of the screen, it shows something like this:

    0x7d578768 add sp, #180 ; 0xb4
    0x7d57876a pop {r4, r5, r6, r7, pc}
    0x7d57876c push {r4, r5, r6, r7, lr}
    0x7d57876e movs r4, r0
    0x7d578770 movs r6, r1
    0x7d578772 ldr r5, [r1, #4]
    0x7d578774 sub sp, #92 ; 0x5c
    0x7d578776 ldr r0, [r5, #0]
    0x7d578778 adds r0, #255 ; 0xff
    0x7d57877a adds r0, #65 ; 0x41
    0x7d57877c ldr r2, [r0, #48] ; 0x30
    0x7d57877e movs r1, r5
    0x7d578780 add r0, sp, #12
    0x7d578782 blx r2
    0x7d578784 movs r0, r4
    0x7d578786 add r1, sp, #12
    0x7d578788 bl 0x7d62696c
    0x7d57878c movs r4, r0
    0x7d57878e add r0, sp, #12
    0x7d578790 bl 0x7d71f30c
    0x7d578794 movs r0, #5
    0x7d578796 lsls r0, r0, #7
    0x7d578798 adds r0, r6, r0
    0x7d57879a ldrb r0, [r0, #5]
    0x7d57879c movs r6, #1
    0x7d57879e cmp r0, #0
    0x7d5787a0 beq.n 0x7d5787a4
    0x7d5787a2 str r6, [r4, #80] ; 0x50
    0x7d5787a4 movs r1, r5
    0x7d5787a6 add r0, sp, #8
    0x7d5787a8 bl 0x7d5c507a
    0x7d5787ac movs r0, r4
    0x7d5787ae adds r0, #84 ; 0x54
    0x7d5787b0 movs r7, r0
    0x7d5787b2 add r1, sp, #8
    0x7d5787b4 blx 0x7d501640
    0x7d5787b8 movs r0, r7
    0x7d5787ba add r1, sp, #4
    0x7d5787bc str r6, [sp, #4]
    0x7d5787be blx 0x7d501648
    0x7d5787c2 str r5, [r4, #88] ; 0x58
    0x7d5787c4 add sp, #92 ; 0x5c
    0x7d5787c6 pop {r4, r5, r6, r7, pc}
    0x7d5787c8 push {r4, r5, r6, r7, lr}
    0x7d5787ca movs r4, r0
    0x7d5787cc movs r6, r2
    0x7d5787ce ldr r5, [r1, #4]
    0x7d5787d0 movs r1, r2
    0x7d5787d2 movs r0, r5
    0x7d5787d4 sub sp, #140 ; 0x8c
    0x7d5787d6 bl 0x7d72ba0e
    0x7d5787da cmp r0, #0
    0x7d5787dc beq.n 0x7d5787e8
    0x7d5787de movs r0, #255 ; 0xff

    The problem is that i cannot infer any information from these two screens. It does not point to the place where problem lies. Is there any other way we can find the near about place where problem lies? Please suggest something to get some useful information from the crash. I have not used the Qt-Creator too deep and that is why i don't know the exact tool i should use to find crashes in the app.

    Thanks

    1 Reply Last reply
    0
    • R Offline
      R Offline
      raven-worx
      Moderators
      wrote on 7 Oct 2013, 06:44 last edited by
      #2

      memory crashes can be very, very, very nasty because they seem to be random.
      If you are not experienced with such crashes the most easiest would probably to comment blocks of code away from your application until the crash is resolved. Then investigate what's wrong in the affected block.

      Hope it helps.

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      1 Reply Last reply
      0
      • R Offline
        R Offline
        raj.qtdev
        wrote on 7 Oct 2013, 11:10 last edited by
        #3

        Thanks for the suggestion raven but i was actually looking for some qt tool for this. Something using which i could tace down the exact function in which the problem lies. Manually comment/uncomment the code i can do anyway.

        Thanks

        1 Reply Last reply
        0
        • R Offline
          R Offline
          raven-worx
          Moderators
          wrote on 7 Oct 2013, 11:21 last edited by
          #4

          depending on the crash this may not be possible ... there is nothing to reconstruct if the memory got corrupted. Otherwise the debugger would already do it.

          --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
          If you have a question please use the forum so others can benefit from the solution in the future

          1 Reply Last reply
          0
          • R Offline
            R Offline
            raj.qtdev
            wrote on 7 Oct 2013, 14:26 last edited by
            #5

            yeah most of the time the app crashes, its the SEGMENTATION FAULT and i am helpless at that point. The calls show are like PUSH POP MOVS ADD etc. and they can't give any human understandable format. The screenshot at that point do not point to anything useful.

            1 Reply Last reply
            0

            2/5

            7 Oct 2013, 06:44

            • Login

            • Login or register to search.
            2 out of 5
            • First post
              2/5
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved