0
라이브러리 함수 open 및 fcntl에 대한 호출을 포함하는 iPhone 어셈블리 함수를 연구 중입니다. 어셈블리 언어에 익숙하지 않은 나는 일반적으로 프로그램 실행을 이해하는 데 어려움이 있습니다. 내가 알고 싶은 것은 open 및 fcntl 함수의 매개 변수입니다. 이 기능이하는 다른 설명도 가장 환영받습니다.iPhone 미스터리 어셈블리
코드 :
당신은 가서 ARM ABI 설명서를 잡기 위해 필요-[Utilities openFileAsset]:
00000a94 b590 push {r4, r7, lr}
00000a96 af01 add r7, sp, #4
00000a98 b088 sub sp, #32
00000a9a ab01 add r3, sp, #4
00000a9c 6018 str r0, [r3, #0]
00000a9e 466b mov r3, sp
00000aa0 6019 str r1, [r3, #0]
00000aa2 ab01 add r3, sp, #4
00000aa4 681a ldr r2, [r3, #0]
00000aa6 4b4a ldr r3, [pc, #296] (0xbd0)
00000aa8 447b add r3, pc
00000aaa 681b ldr r3, [r3, #0]
00000aac 1c10 adds r0, r2, #0
00000aae 1c19 adds r1, r3, #0
00000ab0 f001ee46 blx 0x2740 ; symbol stub for: _objc_msgSend
00000ab4 1c03 adds r3, r0, #0
00000ab6 b2db uxtb r3, r3
00000ab8 2b00 cmp r3, #0
00000aba d100 bne.n 0xabe
00000abc e086 b.n 0xbcc
00000abe 4b45 ldr r3, [pc, #276] (0xbd4)
00000ac0 447b add r3, pc
00000ac2 681b ldr r3, [r3, #0]
00000ac4 681b ldr r3, [r3, #0]
00000ac6 1c1a adds r2, r3, #0
00000ac8 4b43 ldr r3, [pc, #268] (0xbd8)
00000aca 447b add r3, pc
00000acc 681b ldr r3, [r3, #0]
00000ace 1c10 adds r0, r2, #0
00000ad0 1c19 adds r1, r3, #0
00000ad2 2201 movs r2, #1
00000ad4 f001ee34 blx 0x2740 ; symbol stub for: _objc_msgSend
00000ad8 1c02 adds r2, r0, #0
00000ada 23f0 movs r3, #240
00000adc 005b lsls r3, r3, #1
00000ade 1c10 adds r0, r2, #0
00000ae0 2102 movs r1, #2
00000ae2 1c1a adds r2, r3, #0
00000ae4 f001ee84 blx 0x27f0 ; symbol stub for: _open
00000ae8 1c02 adds r2, r0, #0
00000aea 4b3c ldr r3, [pc, #240] (0xbdc)
00000aec 447b add r3, pc
00000aee 681b ldr r3, [r3, #0]
00000af0 601a str r2, [r3, #0]
00000af2 4b3b ldr r3, [pc, #236] (0xbe0)
00000af4 447b add r3, pc
00000af6 681b ldr r3, [r3, #0]
00000af8 681b ldr r3, [r3, #0]
00000afa 1c18 adds r0, r3, #0
00000afc 2104 movs r1, #4
00000afe 2204 movs r2, #4
00000b00 f001ee0e blx 0x2720 ; symbol stub for: _fcntl
어 대기, 다른 사람의 소스 코드를 원하는 (스포일러는 처음 세 개의 인수가 R0, R1, R2는 .... 더 많거나 적은있다)! 아니면 출처를 떠난 곳을 잊어 버렸습니까? – JustSid
왜이 정보가 필요합니까? 더 쉬운 방법이 있을까요? http://pubs.opengroup.org/onlinepubs/009695399/functions/fcntl.html – madmik3