Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Jun 4th, 2012  |  syntax: None  |  size: 1.01 KB  |  hits: 12  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. What could make GDB refuse to break?
  2. void cerror_at (struct lex *lex, struct token *tok, const char *fmt, ...)
  3.        
  4. 0x0000000000403053 <+46>:   test   %al,%al
  5. 0x0000000000403055 <+48>:   je     0x403077 <cerror_at+82>
  6.        
  7. (gdb) disassemble dive
  8. Dump of assembler code for function dive:
  9.    0x0000000000400504 <+0>: push   %rbp
  10.    0x0000000000400505 <+1>: mov    %rsp,%rbp
  11.    0x0000000000400508 <+4>: sub    $0x10,%rsp
  12.    0x000000000040050c <+8>: mov    %edi,-0x4(%rbp)
  13.    0x000000000040050f <+11>:    mov    -0x4(%rbp),%eax
  14.    0x0000000000400512 <+14>:    add    $0x1,%eax
  15.    0x0000000000400515 <+17>:    mov    %eax,%edi
  16.    0x0000000000400517 <+19>:    callq  0x400504 <dive>
  17.    0x000000000040051c <+24>:    leaveq
  18.    0x000000000040051d <+25>:    retq  
  19. End of assembler dump.
  20.        
  21. (gdb) x/5i $p
  22. => 0x400539 <main+27>:  mov    $0x1,%esi
  23.    0x40053e <main+32>:  mov    %rax,%rdi
  24.    0x400541 <main+35>:  callq  0x400408 <fwrite@plt>
  25.    0x400546 <main+40>:  mov    $0x1,%edi
  26. -->0x40054b <main+45>:  callq  0x400504 <dive> <------