liyujie
2025-08-28 d9927380ed7c8366f762049be9f3fee225860833
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
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
target_config = {
 
    # Configuration syntax:
    #
    #   Required keys: (Use one or more of these)
    #    * golem - specify a golem machine-type to build, e.g. android-armv8
    #              (uses art/tools/golem/build-target.sh)
    #    * make - specify a make target to build, e.g. build-art-host
    #    * run-test - runs the tests in art/test/ directory with testrunner.py,
    #                 specify a list of arguments to pass to testrunner.py
    #
    #   Optional keys: (Use any of these)
    #    * env - Add additional environment variable to the current environment.
    #
    # *** IMPORTANT ***:
    #    This configuration is used by the android build server. Targets must not be renamed
    #    or removed.
    #
 
    ##########################################
 
    # General ART configurations.
    # Calls make and testrunner both.
 
    'art-test' : {
        'make' : 'test-art-host-gtest',
        'run-test' : []
    },
 
    'art-test-javac' : {
        'run-test' : ['--jvm']
    },
 
    # ART run-test configurations
    # (calls testrunner which builds and then runs the test targets)
 
    'art-ndebug' : {
        'run-test' : ['--ndebug']
    },
    'art-interpreter' : {
        'run-test' : ['--interpreter']
    },
    'art-interpreter-cxx' : {
        'run-test' : ['--interpreter'],
        'env' : {
            'ART_USE_CXX_INTERPRETER' : 'true'
        }
    },
    'art-interpreter-access-checks' : {
        'run-test' : ['--interp-ac']
    },
    'art-jit' : {
        'run-test' : ['--jit', '--debuggable', '--ndebuggable']
    },
    'art-jit-on-first-use' : {
        'run-test' : ['--jit-on-first-use']
    },
    'art-pictest' : {
        # Deprecated config: All AOT-compiled code is PIC now.
        'run-test' : ['--optimizing']
    },
    'art-gcstress-gcverify': {
        # Do not exercise '--interpreter', '--optimizing', nor '--jit' in this
        # configuration, as they are covered by the
        # 'art-interpreter-gcstress-gcverify',
        # 'art-optimizing-gcstress-gcverify' and 'art-jit-gcstress-gcverify'
        # configurations below.
        'run-test': ['--interp-ac',
                     '--speed-profile',
                     '--gcstress',
                     '--gcverify']
    },
    'art-interpreter-gcstress-gcverify' : {
        'run-test' : ['--interpreter',
                      '--gcstress',
                      '--gcverify']
    },
    'art-optimizing-gcstress-gcverify' : {
        'run-test' : ['--optimizing',
                      '--gcstress',
                      '--gcverify']
    },
    'art-jit-gcstress-gcverify' : {
        'run-test' : ['--jit',
                      '--gcstress',
                      '--gcverify']
    },
    'art-jit-on-first-use-gcstress' : {
        'run-test' : ['--jit-on-first-use',
                      '--gcstress']
    },
    'art-read-barrier-heap-poisoning' : {
        'run-test': ['--interpreter',
                     '--optimizing'],
        'env' : {
            'ART_HEAP_POISONING' : 'true'
        }
    },
    'art-read-barrier-table-lookup' : {
        'run-test' : ['--interpreter',
                      '--optimizing'],
        'env' : {
            'ART_READ_BARRIER_TYPE' : 'TABLELOOKUP',
            'ART_HEAP_POISONING' : 'true'
        }
    },
    'art-debug-gc' : {
        'run-test' : ['--interpreter',
                      '--optimizing'],
        'env' : {
            'ART_TEST_DEBUG_GC' : 'true',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    # TODO: Consider removing this configuration when it is no longer used by
    # any continuous testing target (b/62611253), as the SS collector overlaps
    # with the CC collector, since both move objects.
    'art-ss-gc' : {
        'run-test' : ['--interpreter',
                      '--optimizing',
                      '--jit'],
        'env' : {
            'ART_DEFAULT_GC_TYPE' : 'SS',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    # TODO: Remove this configuration (b/62611253) when the GSS collector is removed (b/73295078).
    'art-gss-gc' : {
        'run-test' : ['--interpreter',
                      '--optimizing',
                      '--jit'],
        'env' : {
            'ART_DEFAULT_GC_TYPE' : 'GSS',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    # TODO: Consider removing this configuration when it is no longer used by
    # any continuous testing target (b/62611253), as the SS collector overlaps
    # with the CC collector, since both move objects.
    'art-ss-gc-tlab' : {
        'run-test' : ['--interpreter',
                      '--optimizing',
                      '--jit'],
        'env' : {
            'ART_DEFAULT_GC_TYPE' : 'SS',
            'ART_USE_TLAB' : 'true',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    # TODO: Remove this configuration (b/62611253) when the GSS collector is removed (b/73295078).
    'art-gss-gc-tlab' : {
        'run-test' : ['--interpreter',
                      '--optimizing',
                      '--jit'],
        'env' : {
            'ART_DEFAULT_GC_TYPE' : 'GSS',
            'ART_USE_TLAB' : 'true',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    'art-tracing' : {
        'run-test' : ['--trace']
    },
    'art-interpreter-tracing' : {
        'run-test' : ['--interpreter',
                      '--trace']
    },
    'art-forcecopy' : {
        'run-test' : ['--forcecopy']
    },
    'art-no-prebuild' : {
        'run-test' : ['--no-prebuild']
    },
    'art-no-image' : {
        'run-test' : ['--no-image']
    },
    'art-interpreter-no-image' : {
        'run-test' : ['--interpreter',
                      '--no-image']
    },
    'art-heap-poisoning' : {
        'run-test' : ['--interpreter',
                      '--optimizing',
                      '--cdex-none'],
        'env' : {
            'ART_USE_READ_BARRIER' : 'false',
            'ART_HEAP_POISONING' : 'true',
            # Disable compact dex to get coverage of standard dex file usage.
            'ART_DEFAULT_COMPACT_DEX_LEVEL' : 'none'
        }
    },
    'art-preopt' : {
        # This test configuration is intended to be representative of the case
        # of preopted apps, which are precompiled against an
        # unrelocated image, then used with a relocated image.
        'run-test' : ['--prebuild',
                      '--relocate',
                      '--jit']
    },
 
    # ART gtest configurations
    # (calls make 'target' which builds and then runs the gtests).
 
    'art-gtest' : {
        'make' :  'test-art-host-gtest'
    },
    'art-gtest-read-barrier': {
        'make' :  'test-art-host-gtest',
        'env' : {
            'ART_HEAP_POISONING' : 'true'
        }
    },
    'art-gtest-read-barrier-table-lookup': {
        'make' :  'test-art-host-gtest',
        'env': {
            'ART_READ_BARRIER_TYPE' : 'TABLELOOKUP',
            'ART_HEAP_POISONING' : 'true'
        }
    },
    # TODO: Consider removing this configuration when it is no longer used by
    # any continuous testing target (b/62611253), as the SS collector overlaps
    # with the CC collector, since both move objects.
    'art-gtest-ss-gc': {
        'make' :  'test-art-host-gtest',
        'env': {
            'ART_DEFAULT_GC_TYPE' : 'SS',
            'ART_USE_READ_BARRIER' : 'false',
            # Disable compact dex to get coverage of standard dex file usage.
            'ART_DEFAULT_COMPACT_DEX_LEVEL' : 'none'
        }
    },
    # TODO: Remove this configuration (b/62611253) when the GSS collector is removed (b/73295078).
    'art-gtest-gss-gc': {
        'make' :  'test-art-host-gtest',
        'env' : {
            'ART_DEFAULT_GC_TYPE' : 'GSS',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    # TODO: Consider removing this configuration when it is no longer used by
    # any continuous testing target (b/62611253), as the SS collector overlaps
    # with the CC collector, since both move objects.
    'art-gtest-ss-gc-tlab': {
        'make' :  'test-art-host-gtest',
        'env': {
            'ART_DEFAULT_GC_TYPE' : 'SS',
            'ART_USE_TLAB' : 'true',
            'ART_USE_READ_BARRIER' : 'false',
        }
    },
    # TODO: Remove this configuration (b/62611253) when the GSS collector is removed (b/73295078).
    'art-gtest-gss-gc-tlab': {
        'make' :  'test-art-host-gtest',
        'env': {
            'ART_DEFAULT_GC_TYPE' : 'GSS',
            'ART_USE_TLAB' : 'true',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    'art-gtest-debug-gc' : {
        'make' :  'test-art-host-gtest',
        'env' : {
            'ART_TEST_DEBUG_GC' : 'true',
            'ART_USE_READ_BARRIER' : 'false'
        }
    },
    'art-generational-cc': {
        'make' : 'test-art-host-gtest',
        'run-test' : [],
        'env' : {
            'ART_USE_GENERATIONAL_CC' : 'true'
        }
    },
 
    # ASAN (host) configurations.
 
    # These configurations need detect_leaks=0 to work in non-setup environments like build bots,
    # as our build tools leak. b/37751350
 
    'art-gtest-asan': {
        'make' : 'test-art-host-gtest',
        'env': {
            'SANITIZE_HOST' : 'address',
            'ASAN_OPTIONS' : 'detect_leaks=0'
        }
    },
    'art-asan': {
        'run-test' : ['--interpreter',
                      '--interp-ac',
                      '--optimizing',
                      '--jit',
                      '--speed-profile'],
        'env': {
            'SANITIZE_HOST' : 'address',
            'ASAN_OPTIONS' : 'detect_leaks=0'
        }
    },
    'art-gtest-heap-poisoning': {
        'make' : 'test-art-host-gtest',
        'env' : {
            'ART_HEAP_POISONING' : 'true',
            'ART_USE_READ_BARRIER' : 'false',
            'SANITIZE_HOST' : 'address',
            'ASAN_OPTIONS' : 'detect_leaks=0'
        }
    },
 
    # ART Golem build targets used by go/lem (continuous ART benchmarking),
    # (art-opt-cc is used by default since it mimics the default preopt config),
    #
    # calls golem/build-target.sh which builds a golem tarball of the target name,
    #     e.g. 'golem: android-armv7' produces an 'android-armv7.tar.gz' upon success.
 
    'art-golem-android-armv7': {
        'golem' : 'android-armv7'
    },
    'art-golem-android-armv8': {
        'golem' : 'android-armv8'
    },
    'art-golem-linux-armv7': {
        'golem' : 'linux-armv7'
    },
    'art-golem-linux-armv8': {
        'golem' : 'linux-armv8'
    },
    'art-golem-linux-ia32': {
        'golem' : 'linux-ia32'
    },
    'art-golem-linux-x64': {
        'golem' : 'linux-x64'
    },
    'art-linux-bionic-x64': {
        'build': '{ANDROID_BUILD_TOP}/art/tools/build_linux_bionic_tests.sh {MAKE_OPTIONS}',
        'run-test': ['--run-test-option=--bionic',
                     '--host',
                     '--64',
                     '--no-build-dependencies'],
    },
    'art-linux-bionic-x64-zipapex': {
        'build': '{ANDROID_BUILD_TOP}/art/tools/build_linux_bionic_tests.sh {MAKE_OPTIONS} com.android.runtime.host',
        'run-test': ['--run-test-option=--bionic',
                     "--runtime-zipapex={SOONG_OUT_DIR}/host/linux_bionic-x86/apex/com.android.runtime.host.zipapex",
                     '--host',
                     '--64',
                     '--no-build-dependencies'],
    },
}