Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mingw-w64-i686-gdb 7.12-1 crashed #716

Closed
mateczek opened this issue Oct 23, 2016 · 6 comments
Closed

mingw-w64-i686-gdb 7.12-1 crashed #716

mateczek opened this issue Oct 23, 2016 · 6 comments

Comments

@mateczek
Copy link

@mateczek mateczek commented Oct 23, 2016

The problem is on my win7 32 bits (second computer with msys64 work ok)
Below log from msys2 MINGW32 console:

MINGW32 ~
$ gdb
GNU gdb (GDB) 7.12
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
(gdb) t

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

Next Full log from QtCreator when I try debug default "HeloWorld" cpp project

Uruchamianie debuggera "GdbEngine" dla ABI "x86-windows-msys-pe-32bit"...
Start parameters: 'nienazwany1' mode: 1
ABI: x86-windows-msys-pe-32bit
Languages: c++ 
Executable: C:\Users\Automatycy\Documents\build-nienazwany1-esktop_Qt_MinGW_w64_32bit_MSYS2-Debug\debug\nienazwany1.exe  [terminal]
Directory: C:\Users\Automatycy\Documents\build-nienazwany1-Desktop_Qt_MinGW_w64_32bit_MSYS2-Debug
Debugger: C:\msys32\mingw32\bin\gdb.exe
Project: C:\Users\Automatycy\Documents\nienazwany1Addtional Search Directories:
Remote: :0
Sysroot: 
Debug Source Location: 
Debugger settings: 
ExtraDumperFile:   (default: )
AlwaysAdjustColumnWidths: true  (default: true)
AdditionalArguments:   (default: )
GdbCustomDumperCommands:   (default: )
SourcePaths:   (default: )
SymbolPaths:   (default: )
BreakOnCrtDbgReport: false  (default: false)
BreakEvent: eh  (default: )  ***
UseToolTips: true  (default: true)
ShowThreadNames: false  (default: false)
UseToolTipsInBreakpointsView: false  (default: false)
UseToolTipsInLocalsView: false  (default: false)
UseAddressInBreakpointsView: false  (default: false)
UseToolTipsInBreakpointsView: false  (default: true)  ***
RegisterForPostMortem: false  (default: false)
UseAddressInStackView: false  (default: false)
CloseMemoryBuffersOnExit: true  (default: true)
CloseBuffersOnExit: false  (default: false)
BreakpointsFullPath: false  (default: false)
SwitchModeOnExit: false  (default: false)
StationaryEditorWhileStepping: false  (default: false)
RaiseOnInterrupt: true  (default: true)
UseCodeModel: true  (default: true)
UseDebuggingHelper: true  (default: true)
UseAlternatingRowColours: false  (default: false)
UseMessageBoxForSignals: true  (default: true)
FontSizeFollowsEditor: false  (default: false)
AutoQuit: false  (default: false)
LogTimeStamps: false  (default: false)
DisplayStringLimit: 100  (default: 100)
MaximalStringLength: 10000  (default: 10000)
EnableReverseDebugging: false  (default: false)
SkipKnownFrames: false  (default: false)
AllPluginBreakpoints: true  (default: true)
AdjustBreakpointLocations: true  (default: true)
SelectedPluginBreakpoints: false  (default: false)
MaximalStackDepth: 20  (default: 20)
ShowStandardNamespace: true  (default: true)
ShowQObjectNames: false  (default: false)
ShowQtNamespace: true  (default: true)
AutoDerefPointers: true  (default: true)
SortStructMembers: true  (default: true)
AutoEnrichParameters: true  (default: true)
WatchdogTimeout: 20  (default: 20)
TargetAsync: false  (default: false)
UseDynamicType: true  (default: true)
MultiInferior: false  (default: false)
WarnOnReleaseBuilds: true  (default: true)
IdentifyDebugInfoPackages: false  (default: false)
IntelFlavor: false  (default: false)
BreakpointCorrection: true  (default: true)
CDB_Console: false  (default: false)
LoadGdbInit: true  (default: true)
IgnoreFirstChanceAccessViolation: false  (default: false)
AttemptQuickStart: false  (default: false)
LoadGdbDumpers2: false  (default: false)
GdbPostAttachCommands:   (default: )
GdbStartupCommands:   (default: )
QmlInspector.ShowAppOnTop: false  (default: false)
SelectedPluginBreakpointsPattern: .*  (default: .*)
NoPluginBreakpoints: false  (default: false)
BreakOnCatch: false  (default: false)
BreakOnThrow: false  (default: false)
BreakOnFatal: false  (default: false)
BreakOnWarning: false  (default: false)
ShowQmlObjectTree: true  (default: true)
BreakOnAbort: false  (default: false)
State changed from DebuggerNotReady(0) to EngineSetupRequested(1) [master]
QUEUE: SETUP ENGINE
CALL: SETUP ENGINE
TRYING TO START ADAPTER
ENABLING TEST CASE: 0
STARTING C:/msys32/mingw32/bin/gdb.exe -i mi
GDB STARTED, INITIALIZING IT
<19show version
<20show debug-file-directory
<21set print object on
<22set breakpoint pending on
<23set print elements 10000
<24set unwindonsignal on
<25set width 0
<26set height 0
Ustawianie podprocesu...
<27set substitute-path C:/work/build/qt5_workdir/w/s C:/msys32/mingw32
<28set substitute-path Q:/qt5_workdir/w/s C:/msys32/mingw32
<29set substitute-path c:/Users/qt/work/install C:/msys32/mingw32
<30set substitute-path c:/users/qt/work/qt C:/msys32/mingw32
<31-interpreter-exec console "set auto-solib-add on"
<32python sys.path.insert(1, 'C:/msys32/mingw32/share/qtcreator/debugger/')
<33python sys.path.append('C:/msys32/mingw32/bin/data-directory/python')
<34python from gdbbridge import *
<35python theDumper.loadDumpers({"token":35})

>=thread-group-added,id="i1"
>~"GNU gdb (GDB) 7.12\n"
>~"Copyright (C) 2016 Free Software Foundation, Inc.\n"
>~"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.  Type \"show copying\"\nand \"show warranty\" for details.\n"
>~"This GDB was configured as \"i686-w64-mingw32\".\nType \"show configuration\" for configuration details."
>~"\nFor bug reporting instructions, please see:\n"
>~"<http://www.gnu.org/software/gdb/bugs/>.\n"
>~"Find the GDB manual and other documentation resources online at:\n<http://www.gnu.org/software/gdb/documentation/>.\n"
>~"For help, type \"help\".\n"
>~"Type \"apropos word\" to search for commands related to \"word\".\n"

>&"show version\n"
>~"GNU gdb (GDB) 7.12\n"
>~"Copyright (C) 2016 Free Software Foundation, Inc.\n"
>~"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law.  Type \"show copying\"\nand \"show warranty\" for details.\n"
>~"This GDB was configured as \"i686-w64-mingw32\".\nType \"show configuration\" for configuration details."
>~"\nFor bug reporting instructions, please see:\n"
>~"<http://www.gnu.org/software/gdb/bugs/>.\n"
>~"Find the GDB manual and other documentation resources online at:\n<http://www.gnu.org/software/gdb/documentation/>.\n"
>~"For help, type \"help\".\n"
>~"Type \"apropos word\" to search for commands related to \"word\".\n"
>19^done
PARSING VERSION: 19^done
SUPPORTED GDB VERSION GNU gdb (GDB) 7.12
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
GNU gdb (GDB) 7.12
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
USING GDB VERSION: 71200, BUILD: 2016
<36-interpreter-exec console "set target-async off"

>&"show debug-file-directory\n"
>~"The directory where separate debug symbols are searched for is \"c:\\mingw32\\lib\\debug\".\n"
>20^done

>&"set print object on\n"
>=cmd-param-changed,param="print object",value="on"
>21^done

>&"set breakpoint pending on\n"
>=cmd-param-changed,param="breakpoint pending",value="on"
>22^done

>&"set print elements 10000\n"
>=cmd-param-changed,param="print elements",value="10000"
>23^done

>&"set unwindonsignal on\n"
>=cmd-param-changed,param="unwindonsignal",value="on"
>24^done

>&"set width 0\n"
>=cmd-param-changed,param="width",value="4294967295"
>25^done

>&"set height 0\n"
>26^done

>&"set substitute-path C:/work/build/qt5_workdir/w/s C:/msys32/mingw32\n"
>27^done

>&"set substitute-path Q:/qt5_workdir/w/s C:/msys32/mingw32\n"
>28^done

>&"set substitute-path c:/Users/qt/work/install C:/msys32/mingw32\n"
>29^done

>&"set substitute-path c:/users/qt/work/qt C:/msys32/mingw32\n"
>30^done

>31^done

>&"python sys.path.insert(1, 'C:/msys32/mingw32/share/qtcreator/debugger/')\n"
>32^done

>&"python sys.path.append('C:/msys32/mingw32/bin/data-directory/python')\n"
>33^done

>&"python from gdbbridge import *\n"
UNEXPECTED GDB STDERR: 
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

GDB PROCESS FINISHED, status 0, exit code 3
NOTE: ENGINE ILL ******
State changed from EngineSetupRequested(1) to EngineShutdownRequested(19) [master]
QUEUE: SHUTDOWN ENGINE
CALL: SHUTDOWN ENGINE
INITIATE GDBENGINE SHUTDOWN IN STATE 1, PROC: 0
NOTE: ENGINE SHUTDOWN OK
State changed from EngineShutdownRequested(19) to EngineShutdownOk(21) [master]
State changed from EngineShutdownOk(21) to DebuggerFinished(22) [master]
QUEUE: FINISH DEBUGGER
NOTE: FINISH DEBUGGER
HANDLE RUNCONTROL FINISHED
Debugger zakończył pracę.
@hrompato
Copy link

@hrompato hrompato commented Oct 31, 2016

same thing in my instalation, any idea?

@hrompato
Copy link

@hrompato hrompato commented Oct 31, 2016

I've downgrade to version 7.11-1 and gdb returned to work. Obviously the problem is the version 7.12

@mwhessel
Copy link

@mwhessel mwhessel commented Dec 10, 2016

I have the same issue, downgrade to version 7.11-1 and gdb returned to work ...

@mwhessel
Copy link

@mwhessel mwhessel commented Jan 27, 2017

Still the same issue with gdb 7.12.2 :(

@orgads
Copy link
Contributor

@orgads orgads commented Mar 7, 2017

Easily reproducible by typing an invalid command.

Looks like a C++ exception is thrown by error(), but it is not catched in catch_errors().

Trace:

1  msvcrt!abort
2  uw_init_context_1
3  _Unwind_RaiseException
4  __cxa_throw
5  throw_exception_cxx                        common-exceptions.c 303
6  throw_exception                            common-exceptions.c 317
7  throw_it                                   common-exceptions.c 373
8  throw_verror                               common-exceptions.c 379
9  verror                                     utils.c             525
10 error                                      errors.c            43
11 undef_cmd_error                            cli-decode.c        1475
12 lookup_cmd                                 cli-decode.c        1517
13 execute_command                            top.c               630
14 command_handler                            event-top.c         641
15 command_line_handler                       event-top.c         833
16 gdb_rl_callback_handler                    event-top.c         213
17 rl_callback_read_char                      callback.c          220
18 gdb_rl_callback_read_char_wrapper_noexcept event-top.c         175
19 gdb_rl_callback_read_char_wrapper          event-top.c         192
20 stdin_event_handler                        event-top.c         568
21 handle_file_event                          event-loop.c        733
22 gdb_wait_for_event                         event-loop.c        884
23 gdb_do_one_event                           event-loop.c        347
24 gdb_do_one_event                           common-exceptions.h 225
25 start_event_loop                           event-loop.c        371
26 captured_command_loop                      main.c              324
27 catch_errors                               exceptions.c        236
28 captured_main                              main.c              1149
29 gdb_main                                   main.c              1159
30 main                                       gdb.c               32
orgads added a commit to orgads/MINGW-packages that referenced this issue Mar 7, 2017
orgads added a commit to orgads/MINGW-packages that referenced this issue Mar 7, 2017
Alexpux added a commit to msys2/MINGW-packages that referenced this issue Mar 7, 2017
Fixes msys2/MSYS2-packages#716.

Future versions of gdb will have a flag for that[1].

[1] https://sourceware.org/bugzilla/show_bug.cgi?id=21187
@genusistimelord
Copy link

@genusistimelord genusistimelord commented Mar 9, 2017

thank you for this fix as well this also was another fix that helped prevent crashing of GDB with IDE's.

emmenlau added a commit to BioDataAnalysis/MINGW-packages that referenced this issue Mar 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants