Skip to content

Instantly share code, notes, and snippets.

@sanxiyn
Created August 1, 2016 13:58
Show Gist options
  • Save sanxiyn/30ae39a3a0f520e1abcf75b774a02075 to your computer and use it in GitHub Desktop.
Save sanxiyn/30ae39a3a0f520e1abcf75b774a02075 to your computer and use it in GitHub Desktop.
Dump of assembler code for function rustc_trans::back::write::diagnostic_handler:
0x00007ffff576c3b0 <+0>: push %rbp
0x00007ffff576c3b1 <+1>: mov %rsp,%rbp
0x00007ffff576c3b4 <+4>: sub $0x390,%rsp
0x00007ffff576c3bb <+11>: mov %rdi,-0x8(%rbp)
0x00007ffff576c3bf <+15>: mov %rsi,-0x10(%rbp)
0x00007ffff576c3c3 <+19>: lea -0xf8(%rbp),%rdi
0x00007ffff576c3ca <+26>: movb $0x0,-0x239(%rbp)
0x00007ffff576c3d1 <+33>: mov -0x8(%rbp),%rax
0x00007ffff576c3d5 <+37>: mov %rax,-0x18(%rbp)
0x00007ffff576c3d9 <+41>: mov -0x10(%rbp),%rax
0x00007ffff576c3dd <+45>: mov %rax,-0x20(%rbp)
0x00007ffff576c3e1 <+49>: mov -0x20(%rbp),%rax
0x00007ffff576c3e5 <+53>: mov (%rax),%rcx
0x00007ffff576c3e8 <+56>: mov %rcx,-0x28(%rbp)
0x00007ffff576c3ec <+60>: mov 0x8(%rax),%rax
0x00007ffff576c3f0 <+64>: mov %rax,-0x30(%rbp)
0x00007ffff576c3f4 <+68>: mov -0x18(%rbp),%rsi
0x00007ffff576c3f8 <+72>: callq 0x7ffff56d87c0 <_ZN10rustc_llvm10diagnostic10Diagnostic6unpack17ha2ee207ee605eb0bE@plt>
0x00007ffff576c3fd <+77>: mov -0xf8(%rbp),%rax
0x00007ffff576c404 <+84>: test %rax,%rax
0x00007ffff576c407 <+87>: mov %rax,-0x2a0(%rbp)
0x00007ffff576c40e <+94>: je 0x7ffff576c447 <rustc_trans::back::write::diagnostic_handler+151>
0x00007ffff576c410 <+96>: jmp 0x7ffff576c412 <rustc_trans::back::write::diagnostic_handler+98>
0x00007ffff576c412 <+98>: mov -0x2a0(%rbp),%rax
0x00007ffff576c419 <+105>: sub $0x1,%rax
0x00007ffff576c41d <+109>: mov %rax,-0x2a8(%rbp)
0x00007ffff576c424 <+116>: je 0x7ffff576c481 <rustc_trans::back::write::diagnostic_handler+209>
0x00007ffff576c426 <+118>: jmp 0x7ffff576c428 <rustc_trans::back::write::diagnostic_handler+120>
0x00007ffff576c428 <+120>: mov -0x2a0(%rbp),%rax
0x00007ffff576c42f <+127>: sub $0x2,%rax
0x00007ffff576c433 <+131>: mov %rax,-0x2b0(%rbp)
0x00007ffff576c43a <+138>: jne 0x7ffff576ca03 <rustc_trans::back::write::diagnostic_handler+1619>
0x00007ffff576c440 <+144>: jmp 0x7ffff576c442 <rustc_trans::back::write::diagnostic_handler+146>
0x00007ffff576c442 <+146>: jmpq 0x7ffff576c9d4 <rustc_trans::back::write::diagnostic_handler+1572>
0x00007ffff576c447 <+151>: mov $0x28,%eax
0x00007ffff576c44c <+156>: mov %eax,%edx
0x00007ffff576c44e <+158>: lea -0x70(%rbp),%rcx
0x00007ffff576c452 <+162>: lea -0xf8(%rbp),%rsi
0x00007ffff576c459 <+169>: add $0x8,%rsi
0x00007ffff576c45d <+173>: mov %rcx,%rdi
0x00007ffff576c460 <+176>: callq 0x7ffff56dad70 <memcpy@plt>
0x00007ffff576c465 <+181>: mov -0x68(%rbp),%rdi
0x00007ffff576c469 <+185>: callq 0x7ffff56dda80 <_ZN3std3ffi5c_str4CStr8from_ptr17h30ad47d7a0bec464E@plt>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment