|
|
Home » Community » Newbie corner » Cannot debug application on ubuntu linux
Re: Cannot debug application on ubuntu linux [message #57419 is a reply to message #57416] |
Thu, 05 August 2021 22:53   |
 |
mirek
Messages: 14265 Registered: November 2005
|
Ultimate Member |
|
|
alex-t wrote on Thu, 05 August 2021 14:50Hmm... A very strange. If I pick debugger breakpoint to line 6 instead of line 5, debugger stops!!!

Log from this case (I select run to finish program):
----- ConsoleTest ( MAIN CLANG DEBUG SHARED DEBUG_FULL BLITZ POSIX LINUX )
cd /data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest
/data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest (30024 B) is up to date.
OK. (0:00.00)
gdb -tty=/dev/pts/13 /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest
Command: set prompt <u++dbg-q98klwr835f427>
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 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 "x86_64-linux-gnu".
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"...
Reading symbols from /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest...
(gdb)
Time of `set prompt <u++dbg-q98klwr835f427>` 42.615 ms
=========== Result:
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 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 "x86_64-linux-gnu".
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"...
Reading symbols from /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest...
(gdb)
===================
Command: set disassembly-flavor intel
Time of `set disassembly-flavor intel` 20.791 ms
=========== Result:
===================
Command: set exec-done-display off
Time of `set exec-done-display off` 20.747 ms
=========== Result:
===================
Command: set annotate 1
Time of `set annotate 1` 20.841 ms
=========== Result:
===================
Command: set height 0
Time of `set height 0` 20.818 ms
=========== Result:
===================
Command: set width 0
Time of `set width 0` 20.876 ms
=========== Result:
===================
Command: set confirm off
Time of `set confirm off` 20.761 ms
=========== Result:
===================
Command: set print asm-demangle
Time of `set print asm-demangle` 20.867 ms
=========== Result:
===================
Command: set print static-members off
Time of `set print static-members off` 20.885 ms
=========== Result:
===================
Command: set print vtbl off
Time of `set print vtbl off` 671 us
=========== Result:
===================
Command: set print repeat 0
Time of `set print repeat 0` 20.772 ms
=========== Result:
===================
Command: set print null-stop
Time of `set print null-stop` 671 us
=========== Result:
===================
Fast Command: b /data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:6
Breakpoint 1 at 0x401211: file ConsoleTest.cpp, line 6.
Result: Breakpoint 1 at 0x401211: file ConsoleTest.cpp, line 6.
Command: start
Temporary breakpoint 2 at 0x4011e6: file ConsoleTest.cpp, line 5.
Starting program: /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest
Temporary breakpoint 2, main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:5
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:5:66:beg:0x4011e6
5 std::cout << "bla-bla-bla" << std::endl;
Time of `start` 182.494 ms
=========== Result:
Temporary breakpoint 2 at 0x4011e6: file ConsoleTest.cpp, line 5.
Starting program: /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest
Temporary breakpoint 2, main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:5
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:5:66:beg:0x4011e6
5 std::cout << "bla-bla-bla" << std::endl;
===================
Command: info inferior
Num Description Executable
* 1 process 162236 /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest
Time of `info inferior` 20.821 ms
=========== Result:
Num Description Executable
* 1 process 162236 /data/3/soft/devel/IDEs/upp/.cache/upp.out/MyApps/CLANG.Debug.Debug_Full.Shared/ConsoleTest
===================
Command: continue
Continuing.
Breakpoint 1, main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:6:109:beg:0x401211
6 std::cout << "bla-bla-bla2" << std::endl;
Time of `continue` 20.834 ms
=========== Result:
Continuing.
Breakpoint 1, main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:6:109:beg:0x401211
6 std::cout << "bla-bla-bla2" << std::endl;
===================
Fast Command: disas
Result: Dump of assembler code for function main(int, char const**):
0x00000000004011d0 <+0>: push rbp
0x00000000004011d1 <+1>: mov rbp,rsp
0x00000000004011d4 <+4>: sub rsp,0x20
0x00000000004011d8 <+8>: mov DWORD PTR [rbp-0x4],0x0
0x00000000004011df <+15>: mov DWORD PTR [rbp-0x8],edi
0x00000000004011e2 <+18>: mov QWORD PTR [rbp-0x10],rsi
0x00000000004011e6 <+22>: movabs rdi,0x404080
0x00000000004011f0 <+32>: movabs rsi,0x402004
0x00000000004011fa <+42>: call 0x401050 <std::basic_ostream<char, std::char_traits<char> >& std::operator<< <std::char_traits<char> >(std::basic_ostream<char, std::char_tra
its<char> >&, char const*)@plt>
0x00000000004011ff <+47>: mov rdi,rax
0x0000000000401202 <+50>: movabs rsi,0x401030
0x000000000040120c <+60>: call 0x401060 <std::ostream::operator<<(std::ostream& (*)(std::ostream&))@plt>
=> 0x0000000000401211 <+65>: movabs rdi,0x404080
0x000000000040121b <+75>: movabs rsi,0x402010
0x0000000000401225 <+85>: mov QWORD PTR [rbp-0x18],rax
0x0000000000401229 <+89>: call 0x401050 <std::basic_ostream<char, std::char_traits<char> >& std::operator<< <std::char_traits<char> >(std::basic_ostream<char, std::char_tra
its<char> >&, char const*)@plt>
0x000000000040122e <+94>: mov rdi,rax
0x0000000000401231 <+97>: movabs rsi,0x401030
0x000000000040123b <+107>: call 0x401060 <std::ostream::operator<<(std::ostream& (*)(std::ostream&))@plt>
0x0000000000401240 <+112>: xor ecx,ecx
0x0000000000401242 <+114>: mov QWORD PTR [rbp-0x20],rax
0x0000000000401246 <+118>: mov eax,ecx
0x0000000000401248 <+120>: add rsp,0x20
0x000000000040124c <+124>: pop rbp
0x000000000040124d <+125>: ret
End of assembler dump.
Fast Command: frame
#0 main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:6:109:beg:0x401211
6 std::cout << "bla-bla-bla2" << std::endl;
Result: #0 main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
/data/3/soft/devel/IDEs/upp/MyApps/ConsoleTest/ConsoleTest.cpp:6:109:beg:0x401211
6 std::cout << "bla-bla-bla2" << std::endl;
Fast Command: info threads
Id Target Id Frame
* 1 process 162236 "ConsoleTest" main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
Result: Id Target Id Frame
* 1 process 162236 "ConsoleTest" main (argc=1, argv=0x7fffffffd988) at ConsoleTest.cpp:6
Fast Command: print int
Attempt to use a type name as an expression
Result: Attempt to use a type name as an expression
Fast Command: print main
$1 = {int (int, const char **)} 0x4011d0 <main(int, char const**)>
Result: $1 = {int (int, const char **)} 0x4011d0 <main(int, char const**)>
Fast Command: print argc
$2 = 1
Result: $2 = 1
Fast Command: print const
A syntax error in expression, near `'.
Result: A syntax error in expression, near `'.
Fast Command: print char
Attempt to use a type name as an expression
Result: Attempt to use a type name as an expression
Fast Command: print argv
$3 = (const char **) 0x7fffffffd988
Result: $3 = (const char **) 0x7fffffffd988
Fast Command: print std
Attempt to use a type name as an expression
Result: Attempt to use a type name as an expression
Fast Command: print cout
No symbol "cout" in current context.
Result: No symbol "cout" in current context.
Fast Command: print endl
No symbol "endl" in current context.
Result: No symbol "endl" in current context.
Fast Command: print return
No symbol "return" in current context.
Result: No symbol "return" in current context.
Fast Command: print iostream
A syntax error in expression, near `'.
Result: A syntax error in expression, near `'.
Command: continue
Continuing.
[Inferior 1 (process 162236) exited normally]
Time of `continue` 6.999 ms
=========== Result:
Continuing.
[Inferior 1 (process 162236) exited normally]
===================
Fast Command: frame
No stack.
Result: No stack.
Well, it is sometimes unreliable (gdb?)
Mirek
|
|
|
 |
|
Cannot debug application on ubuntu linux
By: alex-t on Wed, 04 August 2021 22:58
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Wed, 04 August 2021 23:18
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 10:51
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 10:55
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Thu, 05 August 2021 11:15
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 11:48
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Thu, 05 August 2021 13:04
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 13:29
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 13:35
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Thu, 05 August 2021 14:09
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 14:35
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 14:50
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Thu, 05 August 2021 22:53
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 23:54
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Fri, 06 August 2021 00:02
|
 |
|
Re: Cannot debug application on ubuntu linux
By: mirek on Sat, 07 August 2021 09:36
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Mon, 09 August 2021 12:08
|
 |
|
Re: Cannot debug application on ubuntu linux
By: alex-t on Thu, 05 August 2021 10:33
|
Goto Forum:
Current Time: Mon Jul 07 16:13:49 CEST 2025
Total time taken to generate the page: 0.03624 seconds
|
|
|