-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
Some functions return two separate values, in R0 and R1. To handle this case support needs to be added to translation, transmission, and the function summary. For the function summary, this may require creating a new post-condition attribute to indicate the extra return value.
Example: 752084:10958
The function __aeabi_uidivmod has two return values:
--------------------------------------------------------------------------------
0x109cc [ -16 ] MOV R1, #0x3c R1 := 0x3c (C: 0x3c)
0x109d0 [ -16 ] MOV R0, R5 R0 := t (C: t)
0x109d4 [ -16 ] BL 0x9bb4 call __aeabi_uidiv(t, 0x3c) (C: (t, 0x3c))
0x109d8 [ -16 ] MOV R1, #0x3c R1 := 0x3c (C: 0x3c)
0x109dc [ -16 ] BL 0x9a88 call `__aeabi_uidivmod`(rtn___aeabi_uidiv, 0x3c) (C: (rtn___aeabi_uidiv, 0x3c))
0x109e0 [ -16 ] SUBS R2, R1, #0 R2 := (R1 - 0x0) (= R1) (C: R1)
0x109e4 [ -16 ] BEQ 0x109f8 if (R1 == 0x0) then goto 0x109f8
--------------------------------------------------------------------------------
Currently R1 is abstracted away, as it is assumed clobbered by the call.
Metadata
Metadata
Assignees
Labels
No labels