ContainerHelpers.smali
3.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
.class Landroidx/collection/ContainerHelpers;
.super Ljava/lang/Object;
.source "ContainerHelpers.java"
# static fields
.field static final EMPTY_INTS:[I
.field static final EMPTY_LONGS:[J
.field static final EMPTY_OBJECTS:[Ljava/lang/Object;
# direct methods
.method static constructor <clinit>()V
.locals 2
const/4 v0, 0x0
.line 20
new-array v1, v0, [I
sput-object v1, Landroidx/collection/ContainerHelpers;->EMPTY_INTS:[I
.line 21
new-array v1, v0, [J
sput-object v1, Landroidx/collection/ContainerHelpers;->EMPTY_LONGS:[J
.line 22
new-array v0, v0, [Ljava/lang/Object;
sput-object v0, Landroidx/collection/ContainerHelpers;->EMPTY_OBJECTS:[Ljava/lang/Object;
return-void
.end method
.method private constructor <init>()V
.locals 0
.line 83
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method static binarySearch([III)I
.locals 3
add-int/lit8 p1, p1, -0x1
const/4 v0, 0x0
:goto_0
if-gt v0, p1, :cond_2
add-int v1, v0, p1
ushr-int/lit8 v1, v1, 0x1
.line 51
aget v2, p0, v1
if-ge v2, p2, :cond_0
add-int/lit8 v1, v1, 0x1
move v0, v1
goto :goto_0
:cond_0
if-le v2, p2, :cond_1
add-int/lit8 v1, v1, -0x1
move p1, v1
goto :goto_0
:cond_1
return v1
:cond_2
not-int p0, v0
return p0
.end method
.method static binarySearch([JIJ)I
.locals 4
add-int/lit8 p1, p1, -0x1
const/4 v0, 0x0
:goto_0
if-gt v0, p1, :cond_2
add-int v1, v0, p1
ushr-int/lit8 v1, v1, 0x1
.line 70
aget-wide v2, p0, v1
cmp-long v2, v2, p2
if-gez v2, :cond_0
add-int/lit8 v1, v1, 0x1
move v0, v1
goto :goto_0
:cond_0
if-lez v2, :cond_1
add-int/lit8 v1, v1, -0x1
move p1, v1
goto :goto_0
:cond_1
return v1
:cond_2
not-int p0, v0
return p0
.end method
.method public static equal(Ljava/lang/Object;Ljava/lang/Object;)Z
.locals 0
if-eq p0, p1, :cond_1
if-eqz p0, :cond_0
.line 41
invoke-virtual {p0, p1}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result p0
if-eqz p0, :cond_0
goto :goto_0
:cond_0
const/4 p0, 0x0
goto :goto_1
:cond_1
:goto_0
const/4 p0, 0x1
:goto_1
return p0
.end method
.method public static idealByteArraySize(I)I
.locals 2
const/4 v0, 0x4
:goto_0
const/16 v1, 0x20
if-ge v0, v1, :cond_1
const/4 v1, 0x1
shl-int/2addr v1, v0
add-int/lit8 v1, v1, -0xc
if-gt p0, v1, :cond_0
return v1
:cond_0
add-int/lit8 v0, v0, 0x1
goto :goto_0
:cond_1
return p0
.end method
.method public static idealIntArraySize(I)I
.locals 0
mul-int/lit8 p0, p0, 0x4
.line 25
invoke-static {p0}, Landroidx/collection/ContainerHelpers;->idealByteArraySize(I)I
move-result p0
div-int/lit8 p0, p0, 0x4
return p0
.end method
.method public static idealLongArraySize(I)I
.locals 0
mul-int/lit8 p0, p0, 0x8
.line 29
invoke-static {p0}, Landroidx/collection/ContainerHelpers;->idealByteArraySize(I)I
move-result p0
div-int/lit8 p0, p0, 0x8
return p0
.end method