不懂ARM汇编,有一个函数,有50行的汇编代码,我想还原成C语言,可惜不懂ARM汇编指令。
如果您在深圳,或者方便去东莞或者去惠州淡水,一定请你去HAPPY,绝不食言 :)
0044d6f8 <get_cust_id>:
44d6f8: e92d41ff push {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr}
44d6fc: e1a08000 mov r8, r0
44d700: e3a00010 mov r0, #16 ; 0x10
44d704: ebff4a6a bl 4200b4 <malloc>
44d708: e2504000 subs r4, r0, #0 ; 0x0
44d70c: 0a000005 beq 44d728 <get_cust_id+0x30>
44d710: e3a00010 mov r0, #16 ; 0x10
44d714: ebff4a66 bl 4200b4 <malloc>
44d718: e2505000 subs r5, r0, #0 ; 0x0
44d71c: 1a000004 bne 44d734 <get_cust_id+0x3c>
44d720: e1a00004 mov r0, r4
44d724: ebff491f bl 41fba8 <free>
44d728: e59f0098 ldr r0, [pc, #152] ; 44d7c8 <get_cust_id+0xd0>
44d72c: ebff3c74 bl 41c904 <debug_stmt>
44d730: ea000021 b 44d7bc <get_cust_id+0xc4>
44d734: e3a01000 mov r1, #0 ; 0x0
44d738: e3a02010 mov r2, #16 ; 0x10
44d73c: ebff0db4 bl 410e14 <memset>
44d740: e59f1084 ldr r1, [pc, #132] ; 44d7cc <get_cust_id+0xd4>
44d744: e3a02010 mov r2, #16 ; 0x10
44d748: e1a00004 mov r0, r4
44d74c: ebff0dab bl 410e00 <memcpy>
44d750: e28d6008 add r6, sp, #8 ; 0x8
44d754: e3a03000 mov r3, #0 ; 0x0
44d758: e1a00003 mov r0, r3
44d75c: e59f106c ldr r1, [pc, #108] ; 44d7d0 <get_cust_id+0xd8>
44d760: e1a02006 mov r2, r6
44d764: e58d300c str r3, [sp, #12]
44d768: ebfffdde bl 44cee8 <_encrypt_open_km>
44d76c: e3500000 cmp r0, #0 ; 0x0
44d770: e58d000c str r0, [sp, #12]
44d774: 0a00000c beq 44d7ac <get_cust_id+0xb4>