faster splitter

Chris via Digitalmars-d digitalmars-d at puremagic.com
Wed May 25 03:28:47 PDT 2016


On Tuesday, 24 May 2016 at 22:01:17 UTC, qznc wrote:
> On Tuesday, 24 May 2016 at 19:47:52 UTC, qznc wrote:
>
> I discovered radare2. While it is actually a debugger (like 
> gdb), it includes a nice disassembler. Example view, which 
> shows the loop calling std.algorithm.find repeatedly:
>
>        |   0x00402e08,   0 |           nop [rax+rax+0x0]
>       .--> 0x00402e10,   0 |           mov rdx, [rbx]
>       ||   0x00402e13    0 |           mov rcx, [rbx+0x8]
>       ||   0x00402e17    0 |           mov rdi, r15
>       ||   0x00402e1a    0 |           mov rsi, r12
>       ||   0x00402e1d    0 |           call 0x409160  ; 4 = 
> sym._D3std9algorithm9searching34__T4fin
>       ||   0x00402e22    0 |           mov rcx, [rbx]
>       ||   0x00402e25    0 |           sub rcx, rax
>       ||   0x00402e28,   0 |           mov [rbx+0x20], rcx
>       ||   0x00402e2c,   0 |           dec ebp
>       `==< 0x00402e2e    0 |           jnz 0x402e10  ; 5 = 
> 0x00402e10
>        |   0x00402e30,   0 |           lea r15, [rsp]
>
> Note the ASCII arrow on the left! Objdump should do that. :)

Any suggestions how we can make find more efficient?


More information about the Digitalmars-d mailing list