📄 util.cod
字号:
; 160 : while ( dsize-- )
0002c e1b02820 movs r2, r0, lsr #16
00030 1afffff7 bne |$L36176|
; 162 : }
00034 e8bd4010 ldmia sp!, {r4, lr}
00038 e12fff1e bx lr
0003c |$M36294|
ENDP ; |pc_memfill|
EXPORT |swap_hi_low_byte|
00000 AREA |.text| { |swap_hi_low_byte| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$swap_hi_low_byte|, PDATA, SELECTION=5, ASSOC=|.text| { |swap_hi_low_byte| } ; comdat associative
|$T36303| DCD |swap_hi_low_byte|
DCD 0x40000b01
; Function compile flags: /Ogsy
00000 AREA |.text| { |swap_hi_low_byte| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |swap_hi_low_byte| PROC
; 167 : {
00000 e92d4010 stmdb sp!, {r4, lr}
00004 |$M36301|
00004 e1a04000 mov r4, r0
; 168 : UINT16 tmpWord;
; 169 :
; 170 : tmpWord = inword;
; 171 : inword <<= 8;
; 172 : tmpWord = (tmpWord >> 8) | inword;
; 173 :
; 174 : return (tmpWord);
00008 e1a00804 mov r0, r4, lsl #16
0000c e1a01820 mov r1, r0, lsr #16
00010 e1a02401 mov r2, r1, lsl #8
00014 e1a00802 mov r0, r2, lsl #16
00018 e1a03820 mov r3, r0, lsr #16
0001c e1a01804 mov r1, r4, lsl #16
00020 e1830c21 orr r0, r3, r1, lsr #24
; 175 : }
00024 e8bd4010 ldmia sp!, {r4, lr}
00028 e12fff1e bx lr
0002c |$M36302|
ENDP ; |swap_hi_low_byte|
EXPORT |pc_strcat|
00000 AREA |.text| { |pc_strcat| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$pc_strcat|, PDATA, SELECTION=5, ASSOC=|.text| { |pc_strcat| } ; comdat associative
|$T36317| DCD |pc_strcat|
DCD 0x40000f00
; Function compile flags: /Ogsy
00000 AREA |.text| { |pc_strcat| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |pc_strcat| PROC
; 195 : {
00000 |$M36315|
00000 e1a02000 mov r2, r0
; 196 : while ( *to )
00004 e5d20000 ldrb r0, [r2]
00008 ea000000 b |$L36313|
0000c |$L36188|
0000c e5f20001 ldrb r0, [r2, #1]!
00010 |$L36313|
00010 e31000ff tst r0, #0xFF
00014 1afffffc bne |$L36188|
; 197 : to++;
; 198 :
; 199 : while ( *from )
00018 e5d10000 ldrb r0, [r1]
0001c ea000001 b |$L36314|
00020 |$L36191|
; 200 : *to++ = *from++;
00020 e4c20001 strb r0, [r2], #1
00024 e5f10001 ldrb r0, [r1, #1]!
00028 |$L36314|
; 197 : to++;
; 198 :
; 199 : while ( *from )
00028 e31000ff tst r0, #0xFF
0002c 1afffffb bne |$L36191|
; 201 : *to = 0;
00030 e3a00000 mov r0, #0
00034 e5c20000 strb r0, [r2]
; 202 : }
00038 e12fff1e bx lr
0003c |$M36316|
ENDP ; |pc_strcat|
EXPORT |to_DWORD|
00000 AREA |.text| { |to_DWORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$to_DWORD|, PDATA, SELECTION=5, ASSOC=|.text| { |to_DWORD| } ; comdat associative
|$T36325| DCD |to_DWORD|
DCD 0x40000200
; Function compile flags: /Ogsy
00000 AREA |.text| { |to_DWORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |to_DWORD| PROC
; 262 : {
00000 |$M36323|
; 263 : ULONG res;
; 264 : #if (LITTLE_ENDIAN)
; 265 : res = ((ULONG) *((ULONG *)from));
; 266 : #else
; 267 : ULONG t;
; 268 : t = ((ULONG) *(from + 3)) & 0x00FF;
; 269 : res = (t << 24);
; 270 : t = ((ULONG) *(from + 2)) & 0x00FF;
; 271 : res |= (t << 16);
; 272 : t = ((ULONG) *(from + 1)) & 0x00FF;
; 273 : res |= (t << 8);
; 274 : t = ((ULONG) *from) & 0x00FF;
; 275 : res |= t;
; 276 : #endif
; 277 : return (res);
00000 e5900000 ldr r0, [r0]
; 278 : }
00004 e12fff1e bx lr
00008 |$M36324|
ENDP ; |to_DWORD|
EXPORT |to_WORD|
00000 AREA |.text| { |to_WORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$to_WORD|, PDATA, SELECTION=5, ASSOC=|.text| { |to_WORD| } ; comdat associative
|$T36333| DCD |to_WORD|
DCD 0x40000200
; Function compile flags: /Ogsy
00000 AREA |.text| { |to_WORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |to_WORD| PROC
; 295 : {
00000 |$M36331|
; 296 : UINT16 nres;
; 297 :
; 298 : #if (LITTLE_ENDIAN)
; 299 : nres = ((UINT16) *((UINT16 *)from));
; 300 : #else
; 301 : UINT16 t;
; 302 : t = (UINT16) (((UINT16) *(from + 1)) & 0x00FF);
; 303 : nres = (UINT16) (t << 8);
; 304 : t = (UINT16) (((UINT16) *from) & 0x00FF);
; 305 : nres |= t;
; 306 : #endif
; 307 : return (nres);
00000 e1d000b0 ldrh r0, [r0]
; 308 : }
00004 e12fff1e bx lr
00008 |$M36332|
ENDP ; |to_WORD|
EXPORT |fr_WORD|
00000 AREA |.text| { |fr_WORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$fr_WORD|, PDATA, SELECTION=5, ASSOC=|.text| { |fr_WORD| } ; comdat associative
|$T36341| DCD |fr_WORD|
DCD 0x40000200
; Function compile flags: /Ogsy
00000 AREA |.text| { |fr_WORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |fr_WORD| PROC
; 327 : {
00000 |$M36339|
; 328 : #if (LITTLE_ENDIAN)
; 329 : *((UINT16 *)to) = from;
00000 e1c010b0 strh r1, [r0]
; 330 : #else
; 331 : UINT16 *tptr;
; 332 : UINT16 t1, t2;
; 333 :
; 334 :
; 335 : tptr = (UINT16 *)to;
; 336 :
; 337 : if ( (ULONG)tptr & 0x01 )
; 338 : {
; 339 : t1 = (from & 0xFF);
; 340 : t2 = (from & 0xFF00);
; 341 :
; 342 : tptr = (UINT16 *)(to-1);
; 343 : *tptr &= 0xFF00;
; 344 : *tptr |= t1;
; 345 : tptr++;
; 346 : *tptr &= 0x00FF;
; 347 : *tptr |= t2;
; 348 : }
; 349 : else
; 350 : {
; 351 : t1 = (from << 8);
; 352 : t2 = ((from >> 8) & 0x00FF);
; 353 : *tptr = (t1 | t2);
; 354 : }
; 355 : #endif
; 356 : }
00004 e12fff1e bx lr
00008 |$M36340|
ENDP ; |fr_WORD|
EXPORT |fr_DWORD|
00000 AREA |.text| { |fr_DWORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$fr_DWORD|, PDATA, SELECTION=5, ASSOC=|.text| { |fr_DWORD| } ; comdat associative
|$T36349| DCD |fr_DWORD|
DCD 0x40000200
; Function compile flags: /Ogsy
00000 AREA |.text| { |fr_DWORD| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |fr_DWORD| PROC
; 373 : {
00000 |$M36347|
; 374 : #if (LITTLE_ENDIAN)
; 375 : *((UINT32 *)to) = from;
00000 e5801000 str r1, [r0]
; 376 : #else
; 377 : UINT16 tt;
; 378 :
; 379 : tt = (UINT16)(from & 0xFFFF);
; 380 : fr_WORD((UCHAR *)&to[0], tt);
; 381 :
; 382 : tt = (UINT16)(from >> 16);
; 383 : fr_WORD((UCHAR *)&to[2], tt);
; 384 :
; 385 : #endif
; 386 : }
00004 e12fff1e bx lr
00008 |$M36348|
ENDP ; |fr_DWORD|
END
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -