Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Cross-compiled application running on target gets killed and shows "Illegal Instruction".
Forum Updated to NodeBB v4.3 + New Features

Cross-compiled application running on target gets killed and shows "Illegal Instruction".

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
18 Posts 4 Posters 4.1k Views 2 Watching
  • 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.
  • jsulmJ jsulm

    @name_qt Well, SSE2 and SSE are not available on ARM, so if you see it in the output then yes it would be something to check.

    KartK Offline
    KartK Offline
    Kart
    wrote on last edited by Kart
    #7

    @jsulm I used strace and this is where webpage is getting killed.

    --- SIGILL {si_signo=SIGILL, si_code=ILL_ILLOPC, si_addr=0x46f2e500} ---                           
    rt_sigaction(SIGILL, {sa_handler=SIG_DFL, sa_mask=[ILL], sa_flags=SA_RESTORER|SA_RESTART, sa_resto0
    semctl(425985, 0, IPC_64|IPC_RMID, NULL) = 0                                                       
    ioctl(11, KDSKBMODE, 0x2)               = 0                                                        
    ioctl(11, SNDCTL_TMR_START or TCSETS, {B38400 -opost -isig -icanon -echo ...}) = 0                 
    ioctl(11, TCGETS, {B38400 -opost -isig -icanon -echo ...}) = 0                                     
    close(11)                               = 0                                                        
    ioctl(9, KDSETMODE, 0x1)                = 0                                                        
    write(9, "\33[9;15]\33[?33h\33[?25h\33[?0c\0", 25) = 25                                            
    close(9)                                = 0                                                        
    tgkill(1694, 1694, SIGILL)              = 0                                                        
    sigreturn({mask=[]})                    = 1182397424                                               
    --- SIGILL {si_signo=SIGILL, si_code=SI_TKILL, si_pid=1694, si_uid=0} ---                          
    +++ killed by SIGILL +++                                                                           
    Illegal instruction 
    

    Updation :
    webpage is a widget which displays google.com. The widget opens up and google.com front page gets loaded. When i enter something in the search box and press enter, the widget is killed with "Illegal instruction".

    jsulmJ 1 Reply Last reply
    0
    • KartK Kart

      @jsulm I used strace and this is where webpage is getting killed.

      --- SIGILL {si_signo=SIGILL, si_code=ILL_ILLOPC, si_addr=0x46f2e500} ---                           
      rt_sigaction(SIGILL, {sa_handler=SIG_DFL, sa_mask=[ILL], sa_flags=SA_RESTORER|SA_RESTART, sa_resto0
      semctl(425985, 0, IPC_64|IPC_RMID, NULL) = 0                                                       
      ioctl(11, KDSKBMODE, 0x2)               = 0                                                        
      ioctl(11, SNDCTL_TMR_START or TCSETS, {B38400 -opost -isig -icanon -echo ...}) = 0                 
      ioctl(11, TCGETS, {B38400 -opost -isig -icanon -echo ...}) = 0                                     
      close(11)                               = 0                                                        
      ioctl(9, KDSETMODE, 0x1)                = 0                                                        
      write(9, "\33[9;15]\33[?33h\33[?25h\33[?0c\0", 25) = 25                                            
      close(9)                                = 0                                                        
      tgkill(1694, 1694, SIGILL)              = 0                                                        
      sigreturn({mask=[]})                    = 1182397424                                               
      --- SIGILL {si_signo=SIGILL, si_code=SI_TKILL, si_pid=1694, si_uid=0} ---                          
      +++ killed by SIGILL +++                                                                           
      Illegal instruction 
      

      Updation :
      webpage is a widget which displays google.com. The widget opens up and google.com front page gets loaded. When i enter something in the search box and press enter, the widget is killed with "Illegal instruction".

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #8

      @name_qt What was before that part?

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      KartK 1 Reply Last reply
      0
      • jsulmJ jsulm

        @name_qt What was before that part?

        KartK Offline
        KartK Offline
        Kart
        wrote on last edited by
        #9

        @jsulm Please check this link.

        jsulmJ 1 Reply Last reply
        0
        • KartK Kart

          @jsulm Please check this link.

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #10

          @name_qt It would be better to run your app in gdb.

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          KartK 1 Reply Last reply
          0
          • jsulmJ jsulm

            @name_qt It would be better to run your app in gdb.

            KartK Offline
            KartK Offline
            Kart
            wrote on last edited by
            #11

            @jsulm GDB

            Starting program: /usr/bin/webpage -qws                                                            
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            (no debugging symbols found)                                                                       
            [Thread debugging using libthread_db enabled]                                                      
            [New Thread 0x40109000 (LWP 2281)]                                                                 
                                                                                                               
            Program received signal SIGILL, Illegal instruction.                                               
            [Switching to Thread 0x40109000 (LWP 2281)]                                                        
            0x444924a0 in ?? ()   
            
            jsulmJ 1 Reply Last reply
            0
            • KartK Kart

              @jsulm GDB

              Starting program: /usr/bin/webpage -qws                                                            
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              (no debugging symbols found)                                                                       
              [Thread debugging using libthread_db enabled]                                                      
              [New Thread 0x40109000 (LWP 2281)]                                                                 
                                                                                                                 
              Program received signal SIGILL, Illegal instruction.                                               
              [Switching to Thread 0x40109000 (LWP 2281)]                                                        
              0x444924a0 in ?? ()   
              
              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #12

              @name_qt Can you try with a debug build?
              Also, after it crashed you can get backtrace with bt in GDB.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              N 1 Reply Last reply
              1
              • jsulmJ jsulm

                @name_qt Can you try with a debug build?
                Also, after it crashed you can get backtrace with bt in GDB.

                N Offline
                N Offline
                nintyfan19
                wrote on last edited by
                #13

                @jsulm said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                @name_qt Can you try with a debug build?
                Also, after it crashed you can get backtrace with bt in GDB.

                0x00007fe64971e9d0 in real_push_to_main_loop (
                callback=0x7fe64a436e30 <call_mWidgets_loop>, data=0)
                at /src/Modules/QT5/src/widgets.cxx:395
                395 callback(data);
                Missing separate debuginfos, use: zypper install Mesa-dri-debuginfo-24.1.3-390.1.x86_64 Mesa-libEGL1-debuginfo-24.1.3-390.1.x86_64 Mesa-libglapi0-debuginfo-24.1.3-390.1.x86_64 libLLVM18-debuginfo-18.1.8-2.1.x86_64 libQt5Core5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5DBus5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5Gui5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5WaylandClient5-debuginfo-5.15.15+kde59-1.1.x86_64 libQt5Widgets5-debuginfo-5.15.15+kde127-1.1.x86_64 libSDL2-2_0-0-debuginfo-2.30.7-1.1.x86_64 libSDL2_image-2_0-0-debuginfo-2.8.2-1.3.x86_64 libX11-6-debuginfo-1.8.10-1.1.x86_64 libX11-xcb1-debuginfo-1.8.10-1.1.x86_64 libXau6-debuginfo-1.0.11-1.5.x86_64 libasound2-debuginfo-1.2.12-1.1.x86_64 libbrotlicommon1-debuginfo-1.1.0-1.3.x86_64 libbrotlidec1-debuginfo-1.1.0-1.3.x86_64 libbz2-1-debuginfo-1.0.8-5.10.x86_64 libcap2-debuginfo-2.70-1.1.x86_64 libdbus-1-3-debuginfo-1.14.10-3.1.x86_64 libdrm2-debuginfo-2.4.123-1.1.x86_64 libdrm_amdgpu1-debuginfo-2.4.123-1.1.x86_64 libdrm_intel1-debuginfo-2.4.123-1.1.x86_64 libdrm_radeon1-debuginfo-2.4.123-1.1.x86_64 libedit0-debuginfo-20210910.3.1-2.7.x86_64 libelf1-debuginfo-0.191-2.1.x86_64 libexpat1-debuginfo-2.6.2-1.1.x86_64 libexslt0-debuginfo-1.1.39-3.1.x86_64 libffi8-debuginfo-3.4.6-1.1.x86_64 libfontconfig1-debuginfo-2.15.0-2.1.x86_64 libfreetype6-debuginfo-2.13.2-2.2.x86_64 libgcc_s1-debuginfo-14.2.0+git10526-2.1.x86_64 libgcrypt20-debuginfo-1.11.0-1.1.x86_64 libglib-2_0-0-debuginfo-2.80.5-2.1.x86_64 libgpg-error0-debuginfo-1.50-1.1.x86_64 libharfbuzz0-debuginfo-9.0.0-1.1.x86_64 libicu75-debuginfo-75.1-1.1.x86_64 libjbig2-debuginfo-2.1-5.3.x86_64 libjitterentropy3-debuginfo-3.4.1-4.2.x86_64 libjpeg8-debuginfo-8.3.2-80.1.x86_64 liblzma5-debuginfo-5.6.2-1.1.x86_64 libpciaccess0-debuginfo-0.18.1-1.2.x86_64 libpcre2-16-0-debuginfo-10.44-1.1.x86_64 libpcre2-8-0-debuginfo-10.44-1.1.x86_64 libpng16-16-debuginfo-1.6.43-3.1.x86_64 libqt5-qtwayland-debuginfo-5.15.15+kde59-1.1.x86_64 libsharpyuv0-debuginfo-1.4.0-1.1.x86_64 libstdc++6-debuginfo-14.2.0+git10526-2.1.x86_64 libsystemd0-debuginfo-256.5-1.1.x86_64 libtiff6-debuginfo-4.6.0-5.1.x86_64 libvulkan1-debuginfo-1.3.290-1.1.x86_64 libwayland-client0-debuginfo-1.23.0-1.1.x86_64 libwayland-egl1-debuginfo-1.23.0-1.1.x86_64 libwayland-server0-debuginfo-1.23.0-1.1.x86_64 libwebp7-debuginfo-1.4.0-1.1.x86_64 libwebpdemux2-debuginfo-1.4.0-1.1.x86_64 libxcb-dri2-0-debuginfo-1.17.0-1.1.x86_64 libxcb-xfixes0-debuginfo-1.17.0-1.1.x86_64 libxcb1-debuginfo-1.17.0-1.1.x86_64 libxml2-2-debuginfo-2.12.9-1.1.x86_64 libzstd1-debuginfo-1.5.6-1.1.x86_64
                (gdb) backtrace
                #0 0x00007fe64971e9d0 in real_push_to_main_loop (
                callback=0x7fe64a436e30 <call_mWidgets_loop>, data=0)
                at /src/Modules/QT5/src/widgets.cxx:395
                #1 0x00007fe64a4379ee in handle_events (level=0xd027e0) at loop.c:323
                #2 0x0000000000400c73 in main (argc=1, argv=0x7ffcc9fd8a68) at główny.c:69

                jsulmJ 1 Reply Last reply
                0
                • N nintyfan19

                  @jsulm said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                  @name_qt Can you try with a debug build?
                  Also, after it crashed you can get backtrace with bt in GDB.

                  0x00007fe64971e9d0 in real_push_to_main_loop (
                  callback=0x7fe64a436e30 <call_mWidgets_loop>, data=0)
                  at /src/Modules/QT5/src/widgets.cxx:395
                  395 callback(data);
                  Missing separate debuginfos, use: zypper install Mesa-dri-debuginfo-24.1.3-390.1.x86_64 Mesa-libEGL1-debuginfo-24.1.3-390.1.x86_64 Mesa-libglapi0-debuginfo-24.1.3-390.1.x86_64 libLLVM18-debuginfo-18.1.8-2.1.x86_64 libQt5Core5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5DBus5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5Gui5-debuginfo-5.15.15+kde127-1.1.x86_64 libQt5WaylandClient5-debuginfo-5.15.15+kde59-1.1.x86_64 libQt5Widgets5-debuginfo-5.15.15+kde127-1.1.x86_64 libSDL2-2_0-0-debuginfo-2.30.7-1.1.x86_64 libSDL2_image-2_0-0-debuginfo-2.8.2-1.3.x86_64 libX11-6-debuginfo-1.8.10-1.1.x86_64 libX11-xcb1-debuginfo-1.8.10-1.1.x86_64 libXau6-debuginfo-1.0.11-1.5.x86_64 libasound2-debuginfo-1.2.12-1.1.x86_64 libbrotlicommon1-debuginfo-1.1.0-1.3.x86_64 libbrotlidec1-debuginfo-1.1.0-1.3.x86_64 libbz2-1-debuginfo-1.0.8-5.10.x86_64 libcap2-debuginfo-2.70-1.1.x86_64 libdbus-1-3-debuginfo-1.14.10-3.1.x86_64 libdrm2-debuginfo-2.4.123-1.1.x86_64 libdrm_amdgpu1-debuginfo-2.4.123-1.1.x86_64 libdrm_intel1-debuginfo-2.4.123-1.1.x86_64 libdrm_radeon1-debuginfo-2.4.123-1.1.x86_64 libedit0-debuginfo-20210910.3.1-2.7.x86_64 libelf1-debuginfo-0.191-2.1.x86_64 libexpat1-debuginfo-2.6.2-1.1.x86_64 libexslt0-debuginfo-1.1.39-3.1.x86_64 libffi8-debuginfo-3.4.6-1.1.x86_64 libfontconfig1-debuginfo-2.15.0-2.1.x86_64 libfreetype6-debuginfo-2.13.2-2.2.x86_64 libgcc_s1-debuginfo-14.2.0+git10526-2.1.x86_64 libgcrypt20-debuginfo-1.11.0-1.1.x86_64 libglib-2_0-0-debuginfo-2.80.5-2.1.x86_64 libgpg-error0-debuginfo-1.50-1.1.x86_64 libharfbuzz0-debuginfo-9.0.0-1.1.x86_64 libicu75-debuginfo-75.1-1.1.x86_64 libjbig2-debuginfo-2.1-5.3.x86_64 libjitterentropy3-debuginfo-3.4.1-4.2.x86_64 libjpeg8-debuginfo-8.3.2-80.1.x86_64 liblzma5-debuginfo-5.6.2-1.1.x86_64 libpciaccess0-debuginfo-0.18.1-1.2.x86_64 libpcre2-16-0-debuginfo-10.44-1.1.x86_64 libpcre2-8-0-debuginfo-10.44-1.1.x86_64 libpng16-16-debuginfo-1.6.43-3.1.x86_64 libqt5-qtwayland-debuginfo-5.15.15+kde59-1.1.x86_64 libsharpyuv0-debuginfo-1.4.0-1.1.x86_64 libstdc++6-debuginfo-14.2.0+git10526-2.1.x86_64 libsystemd0-debuginfo-256.5-1.1.x86_64 libtiff6-debuginfo-4.6.0-5.1.x86_64 libvulkan1-debuginfo-1.3.290-1.1.x86_64 libwayland-client0-debuginfo-1.23.0-1.1.x86_64 libwayland-egl1-debuginfo-1.23.0-1.1.x86_64 libwayland-server0-debuginfo-1.23.0-1.1.x86_64 libwebp7-debuginfo-1.4.0-1.1.x86_64 libwebpdemux2-debuginfo-1.4.0-1.1.x86_64 libxcb-dri2-0-debuginfo-1.17.0-1.1.x86_64 libxcb-xfixes0-debuginfo-1.17.0-1.1.x86_64 libxcb1-debuginfo-1.17.0-1.1.x86_64 libxml2-2-debuginfo-2.12.9-1.1.x86_64 libzstd1-debuginfo-1.5.6-1.1.x86_64
                  (gdb) backtrace
                  #0 0x00007fe64971e9d0 in real_push_to_main_loop (
                  callback=0x7fe64a436e30 <call_mWidgets_loop>, data=0)
                  at /src/Modules/QT5/src/widgets.cxx:395
                  #1 0x00007fe64a4379ee in handle_events (level=0xd027e0) at loop.c:323
                  #2 0x0000000000400c73 in main (argc=1, argv=0x7ffcc9fd8a68) at główny.c:69

                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #14

                  @nintyfan19 It would be helpful if you would provide some context, not just stack trace...

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0
                  • N Offline
                    N Offline
                    nintyfan19
                    wrote on last edited by
                    #15

                    Found an description of my problem:
                    https://stackoverflow.com/questions/77600344/sigill-illegal-instruction-when-running-eventfilter-in-qt-application-using-ne
                    It seems to works, but I do not known if I remove each no return statement in function with type error.

                    jsulmJ 1 Reply Last reply
                    0
                    • N nintyfan19

                      Found an description of my problem:
                      https://stackoverflow.com/questions/77600344/sigill-illegal-instruction-when-running-eventfilter-in-qt-application-using-ne
                      It seems to works, but I do not known if I remove each no return statement in function with type error.

                      jsulmJ Offline
                      jsulmJ Offline
                      jsulm
                      Lifetime Qt Champion
                      wrote on last edited by
                      #16

                      @nintyfan19 said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                      I do not known if I remove each no return statement in function with type error

                      I don't know what you mean here

                      https://forum.qt.io/topic/113070/qt-code-of-conduct

                      N 1 Reply Last reply
                      0
                      • jsulmJ jsulm

                        @nintyfan19 said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                        I do not known if I remove each no return statement in function with type error

                        I don't know what you mean here

                        N Offline
                        N Offline
                        nintyfan19
                        wrote on last edited by
                        #17

                        @jsulm said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                        @nintyfan19 said in Cross-compiled application running on target gets killed and shows "Illegal Instruction".:

                        I do not known if I remove each no return statement in function with type error

                        I don't know what you mean here

                        I mean problem was newer gcc-c++ generates bad instruction to wipe program, when function declared with type return nothing. That was my problem. I do not known If I correct each function in my code. Everything seems to work.

                        1 Reply Last reply
                        0
                        • SGaistS Offline
                          SGaistS Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on last edited by
                          #18

                          Hi,

                          If you are not returning anything from a function that has a return type then you enter undefined behaviour territory. You were just lucky it worked until now.
                          This also means that you ignored your compiler warnings which is usually the best way to have strange things such as this crash happening.

                          Interested in AI ? www.idiap.ch
                          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                          1 Reply Last reply
                          2

                          • Login

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