This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug gdb/17992] New: "set demangle none" doesn't work


https://sourceware.org/bugzilla/show_bug.cgi?id=17992

            Bug ID: 17992
           Summary: "set demangle none" doesn't work
           Product: gdb
           Version: unknown
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gdb
          Assignee: unassigned at sourceware dot org
          Reporter: hjl.tools at gmail dot com

[hjl@gnu-6 tmp]$ cat f.cc
int
foo (int x)
{
  return x;
}
[hjl@gnu-6 tmp]$ gcc -fpic -g f.cc -shared   
[hjl@gnu-6 tmp]$ gdb a.out 
GNU gdb (GDB) Fedora 7.7.1-21.fc20
Copyright (C) 2014 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-redhat-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 a.out...done.
(gdb) disass foo
Dump of assembler code for function foo(int):
   0x0000000000000605 <+0>:    push   %rbp
   0x0000000000000606 <+1>:    mov    %rsp,%rbp
   0x0000000000000609 <+4>:    mov    %edi,-0x4(%rbp)
   0x000000000000060c <+7>:    mov    -0x4(%rbp),%eax
   0x000000000000060f <+10>:    pop    %rbp
   0x0000000000000610 <+11>:    retq   
End of assembler dump.
(gdb) set demangle none
(gdb) show demangle
The current C++ demangling style is "none".
(gdb) disass foo
Dump of assembler code for function foo(int):
   0x0000000000000605 <+0>:    push   %rbp
   0x0000000000000606 <+1>:    mov    %rsp,%rbp
   0x0000000000000609 <+4>:    mov    %edi,-0x4(%rbp)
   0x000000000000060c <+7>:    mov    -0x4(%rbp),%eax
   0x000000000000060f <+10>:    pop    %rbp
   0x0000000000000610 <+11>:    retq   
End of assembler dump.
(gdb) 

I am expecting

Dump of assembler code for function _Z3fooi:

instead of

Dump of assembler code for function foo(int):

"objdump -d" handles it properly.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]