Commit 9c51dfb9 authored by Sumnima Joshi's avatar Sumnima Joshi
Browse files

Assign temporary register to the size of an array.

Temporary register was added so that the value of existing registers
could remain the same.

Test: Dexfuzz was run.

Before
000144: 1300 0800                  |0000: const/16 v0, #int 8 // #8
000148: 2300 0300                  |0002: new-array v0, v0, [I // type@0003
00014c: 2600 0400 0000             |0004: fill-array-data v0, 00000008 // +00000004
000152: 1100                       |0007: return-object v0

After
000144: 0900 0100 0200             |0000: move-object/16 v1, v2
00014a: 1300 1052                  |0003: const/16 v0, #int 21008 // #5210
00014e: 1302 1800                  |0005: const/16 v2, #int 24 // #18
000152: 2320 0300                  |0007: new-array v0, v2, [I // type@0003
000156: 2600 0500 0000             |0009: fill-array-data v0, 0000000e // +00000005
00015c: 1102                       |000c: return-object v2

Change-Id: I0d8380ab3facd6256bc46931929d32763bad4476
parent 8fe41cf9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment