| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 1 | # Copyright (C) 2011 The Android Open Source Project |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | # |
| 15 | |
| 16 | LOCAL_PATH := $(call my-dir) |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 17 | |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 18 | include art/build/Android.common_test.mk |
| 19 | |
| 20 | # List of all tests of the form 003-omnibus-opcodes. |
| 21 | TEST_ART_RUN_TESTS := $(wildcard $(LOCAL_PATH)/[0-9]*) |
| 22 | TEST_ART_RUN_TESTS := $(subst $(LOCAL_PATH)/,, $(TEST_ART_RUN_TESTS)) |
| 23 | |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 24 | ######################################################################## |
| 25 | # The art-run-tests module, used to build all run-tests into an image. |
| Alex Light | 9dcc457 | 2014-08-14 14:16:26 -0700 | [diff] [blame] | 26 | |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 27 | # The path where build only targets will be output, e.g. |
| 28 | # out/target/product/generic_x86_64/obj/PACKAGING/art-run-tests_intermediates/DATA |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 29 | art_run_tests_build_dir := $(call intermediates-dir-for,JAVA_LIBRARIES,art-run-tests)/DATA |
| 30 | art_run_tests_install_dir := $(call intermediates-dir-for,PACKAGING,art-run-tests)/DATA |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 31 | |
| 32 | # A generated list of prerequisites that call 'run-test --build-only', the actual prerequisite is |
| 33 | # an empty file touched in the intermediate directory. |
| 34 | TEST_ART_RUN_TEST_BUILD_RULES := |
| 35 | |
| Nicolas Geoffray | 07f2bc1 | 2015-05-29 13:40:25 +0100 | [diff] [blame] | 36 | # Dependencies for actually running a run-test. |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 37 | TEST_ART_RUN_TEST_DEPENDENCIES := \ |
| 38 | $(DX) \ |
| 39 | $(HOST_OUT_EXECUTABLES)/jasmin \ |
| 40 | $(HOST_OUT_EXECUTABLES)/smali \ |
| Sebastien Hertz | 2b763c3 | 2016-03-31 09:22:50 +0200 | [diff] [blame] | 41 | $(HOST_OUT_EXECUTABLES)/dexmerger \ |
| 42 | $(JACK) |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 43 | |
| Sebastien Hertz | 2b763c3 | 2016-03-31 09:22:50 +0200 | [diff] [blame] | 44 | TEST_ART_RUN_TEST_ORDERONLY_DEPENDENCIES := setup-jack-server |
| Nicolas Geoffray | 07f2bc1 | 2015-05-29 13:40:25 +0100 | [diff] [blame] | 45 | |
| Hiroshi Yamauchi | 093f1b4 | 2015-07-14 12:20:30 -0700 | [diff] [blame] | 46 | ifeq ($(ART_TEST_DEBUG_GC),true) |
| 47 | ART_TEST_WITH_STRACE := true |
| 48 | endif |
| 49 | |
| Wojciech Staszkiewicz | d7a819a | 2016-09-01 14:43:39 -0700 | [diff] [blame] | 50 | ifeq ($(ART_TEST_BISECTION),true) |
| 51 | # Need to keep rebuilding the test to bisection search it. |
| 52 | ART_TEST_RUN_TEST_NO_PREBUILD := true |
| 53 | ART_TEST_RUN_TEST_PREBUILD := false |
| 54 | # Bisection search writes to standard output. |
| 55 | ART_TEST_QUIET := false |
| 56 | endif |
| 57 | |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 58 | # Helper to create individual build targets for tests. Must be called with $(eval). |
| 59 | # $(1): the test number |
| 60 | define define-build-art-run-test |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 61 | dmart_target := $(art_run_tests_build_dir)/art-run-tests/$(1)/touch |
| 62 | dmart_install_target := $(art_run_tests_install_dir)/art-run-tests/$(1)/touch |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 63 | run_test_options = --build-only |
| Alex Light | 91de25f | 2015-10-28 17:00:06 -0700 | [diff] [blame] | 64 | ifeq ($(ART_TEST_QUIET),true) |
| 65 | run_test_options += --quiet |
| 66 | endif |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 67 | $$(dmart_target): PRIVATE_RUN_TEST_OPTIONS := $$(run_test_options) |
| Yohann Roussel | 05b9125 | 2015-12-09 12:02:46 +0100 | [diff] [blame] | 68 | $$(dmart_target): $(TEST_ART_RUN_TEST_DEPENDENCIES) $(TARGET_JACK_CLASSPATH_DEPENDENCIES) | $(TEST_ART_RUN_TEST_ORDERONLY_DEPENDENCIES) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 69 | $(hide) rm -rf $$(dir $$@) && mkdir -p $$(dir $$@) |
| 70 | $(hide) DX=$(abspath $(DX)) JASMIN=$(abspath $(HOST_OUT_EXECUTABLES)/jasmin) \ |
| Andreas Gampe | 8fda9f2 | 2014-10-03 16:15:37 -0700 | [diff] [blame] | 71 | SMALI=$(abspath $(HOST_OUT_EXECUTABLES)/smali) \ |
| 72 | DXMERGER=$(abspath $(HOST_OUT_EXECUTABLES)/dexmerger) \ |
| Yohann Roussel | cc6bb93 | 2016-01-19 23:29:29 +0100 | [diff] [blame] | 73 | JACK_VERSION=$(JACK_DEFAULT_VERSION) \ |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 74 | JACK=$(abspath $(JACK)) \ |
| Yohann Roussel | aaa779a | 2016-01-19 17:07:18 +0100 | [diff] [blame] | 75 | JACK_VERSION=$(JACK_DEFAULT_VERSION) \ |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 76 | JACK_CLASSPATH=$(TARGET_JACK_CLASSPATH) \ |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 77 | $(LOCAL_PATH)/run-test $$(PRIVATE_RUN_TEST_OPTIONS) --output-path $$(abspath $$(dir $$@)) $(1) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 78 | $(hide) touch $$@ |
| 79 | |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 80 | $$(dmart_install_target): $$(dmart_target) |
| 81 | $(hide) rm -rf $$(dir $$@) && mkdir -p $$(dir $$@) |
| 82 | $(hide) cp $$(dir $$<)/* $$(dir $$@)/ |
| 83 | |
| 84 | TEST_ART_RUN_TEST_BUILD_RULES += $$(dmart_install_target) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 85 | dmart_target := |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 86 | dmart_install_target := |
| Sebastien Hertz | 19ac027 | 2015-02-24 17:39:50 +0100 | [diff] [blame] | 87 | run_test_options := |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 88 | endef |
| Ian Rogers | bf66bce | 2014-06-24 23:15:34 -0700 | [diff] [blame] | 89 | $(foreach test, $(TEST_ART_RUN_TESTS), $(eval $(call define-build-art-run-test,$(test)))) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 90 | |
| 91 | include $(CLEAR_VARS) |
| 92 | LOCAL_MODULE_TAGS := tests |
| 93 | LOCAL_MODULE := art-run-tests |
| Ian Rogers | abbf242 | 2014-10-15 11:57:01 -0700 | [diff] [blame] | 94 | LOCAL_ADDITIONAL_DEPENDENCIES := $(TEST_ART_RUN_TEST_BUILD_RULES) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 95 | # The build system use this flag to pick up files generated by declare-make-art-run-test. |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 96 | LOCAL_PICKUP_FILES := $(art_run_tests_install_dir) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 97 | |
| 98 | include $(BUILD_PHONY_PACKAGE) |
| 99 | |
| 100 | # Clear temp vars. |
| Dan Willemsen | 7fb2c2c | 2016-08-01 22:58:31 -0700 | [diff] [blame] | 101 | art_run_tests_build_dir := |
| 102 | art_run_tests_install_dir := |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 103 | define-build-art-run-test := |
| Ian Rogers | 8a14b75 | 2014-07-18 15:06:53 -0700 | [diff] [blame] | 104 | TEST_ART_RUN_TEST_BUILD_RULES := |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 105 | |
| 106 | ######################################################################## |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 107 | # General rules to build and run a run-test. |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 108 | |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 109 | TARGET_TYPES := host target |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 110 | PREBUILD_TYPES := |
| 111 | ifeq ($(ART_TEST_RUN_TEST_PREBUILD),true) |
| 112 | PREBUILD_TYPES += prebuild |
| 113 | endif |
| 114 | ifeq ($(ART_TEST_RUN_TEST_NO_PREBUILD),true) |
| 115 | PREBUILD_TYPES += no-prebuild |
| 116 | endif |
| 117 | ifeq ($(ART_TEST_RUN_TEST_NO_DEX2OAT),true) |
| 118 | PREBUILD_TYPES += no-dex2oat |
| 119 | endif |
| 120 | COMPILER_TYPES := |
| 121 | ifeq ($(ART_TEST_INTERPRETER_ACCESS_CHECKS),true) |
| 122 | COMPILER_TYPES += interp-ac |
| 123 | endif |
| 124 | ifeq ($(ART_TEST_INTERPRETER),true) |
| 125 | COMPILER_TYPES += interpreter |
| 126 | endif |
| 127 | ifeq ($(ART_TEST_JIT),true) |
| 128 | COMPILER_TYPES += jit |
| 129 | endif |
| 130 | OPTIMIZING_COMPILER_TYPES := |
| 131 | ifeq ($(ART_TEST_OPTIMIZING),true) |
| 132 | COMPILER_TYPES += optimizing |
| 133 | OPTIMIZING_COMPILER_TYPES += optimizing |
| 134 | endif |
| 135 | ifeq ($(ART_TEST_OPTIMIZING_GRAPH_COLOR),true) |
| 136 | COMPILER_TYPES += regalloc_gc |
| 137 | OPTIMIZING_COMPILER_TYPES += regalloc_gc |
| 138 | endif |
| 139 | RELOCATE_TYPES := no-relocate |
| 140 | ifeq ($(ART_TEST_RUN_TEST_RELOCATE),true) |
| 141 | RELOCATE_TYPES += relocate |
| 142 | endif |
| 143 | ifeq ($(ART_TEST_RUN_TEST_RELOCATE_NO_PATCHOAT),true) |
| 144 | RELOCATE_TYPES += relocate-npatchoat |
| 145 | endif |
| Mathieu Chartier | 1445dd3 | 2015-03-20 14:29:51 -0700 | [diff] [blame] | 146 | TRACE_TYPES := ntrace |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 147 | ifeq ($(ART_TEST_TRACE),true) |
| 148 | TRACE_TYPES += trace |
| 149 | endif |
| 150 | ifeq ($(ART_TEST_TRACE_STREAM),true) |
| 151 | TRACE_TYPES += stream |
| 152 | endif |
| Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 153 | GC_TYPES := cms |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 154 | ifeq ($(ART_TEST_GC_STRESS),true) |
| 155 | GC_TYPES += gcstress |
| 156 | endif |
| 157 | ifeq ($(ART_TEST_GC_VERIFY),true) |
| 158 | GC_TYPES += gcverify |
| 159 | endif |
| Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 160 | JNI_TYPES := checkjni |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 161 | ifeq ($(ART_TEST_JNI_FORCECOPY),true) |
| 162 | JNI_TYPES += forcecopy |
| 163 | endif |
| 164 | ifeq ($(ART_TEST_RUN_TEST_IMAGE),true) |
| Nicolas Geoffray | b76bc78 | 2016-09-14 12:33:34 +0000 | [diff] [blame] | 165 | IMAGE_TYPES := picimage |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 166 | endif |
| 167 | ifeq ($(ART_TEST_RUN_TEST_NO_IMAGE),true) |
| 168 | IMAGE_TYPES += no-image |
| 169 | endif |
| 170 | ifeq ($(ART_TEST_RUN_TEST_MULTI_IMAGE),true) |
| 171 | IMAGE_TYPES := multipicimage |
| 172 | endif |
| 173 | ifeq ($(ART_TEST_NPIC_IMAGE),true) |
| 174 | IMAGE_TYPES += npicimage |
| 175 | ifeq ($(ART_TEST_RUN_TEST_MULTI_IMAGE),true) |
| 176 | IMAGE_TYPES := multinpicimage |
| 177 | endif |
| 178 | endif |
| Mathieu Chartier | 1445dd3 | 2015-03-20 14:29:51 -0700 | [diff] [blame] | 179 | PICTEST_TYPES := npictest |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 180 | ifeq ($(ART_TEST_PIC_TEST),true) |
| 181 | PICTEST_TYPES += pictest |
| 182 | endif |
| 183 | RUN_TYPES := |
| 184 | ifeq ($(ART_TEST_RUN_TEST_DEBUG),true) |
| 185 | RUN_TYPES += debug |
| 186 | endif |
| 187 | ifeq ($(ART_TEST_RUN_TEST_NDEBUG),true) |
| 188 | RUN_TYPES += ndebug |
| 189 | endif |
| Mathieu Chartier | 1445dd3 | 2015-03-20 14:29:51 -0700 | [diff] [blame] | 190 | DEBUGGABLE_TYPES := ndebuggable |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 191 | ifeq ($(ART_TEST_RUN_TEST_DEBUGGABLE),true) |
| Nicolas Geoffray | 43c162f | 2015-03-09 12:21:26 +0000 | [diff] [blame] | 192 | DEBUGGABLE_TYPES += debuggable |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 193 | endif |
| 194 | ADDRESS_SIZES_TARGET := $(ART_PHONY_TEST_TARGET_SUFFIX) |
| 195 | ADDRESS_SIZES_HOST := $(ART_PHONY_TEST_HOST_SUFFIX) |
| 196 | ifeq ($(ART_TEST_RUN_TEST_2ND_ARCH),true) |
| 197 | ADDRESS_SIZES_TARGET += $(2ND_ART_PHONY_TEST_TARGET_SUFFIX) |
| 198 | ADDRESS_SIZES_HOST += $(2ND_ART_PHONY_TEST_HOST_SUFFIX) |
| 199 | endif |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 200 | ALL_ADDRESS_SIZES := 64 32 |
| Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 201 | |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 202 | # List all run test names with number arguments agreeing with the comment above. |
| 203 | define all-run-test-names |
| 204 | $(foreach target, $(1), \ |
| 205 | $(foreach run-type, $(2), \ |
| 206 | $(foreach prebuild, $(3), \ |
| 207 | $(foreach compiler, $(4), \ |
| 208 | $(foreach relocate, $(5), \ |
| 209 | $(foreach trace, $(6), \ |
| 210 | $(foreach gc, $(7), \ |
| 211 | $(foreach jni, $(8), \ |
| 212 | $(foreach image, $(9), \ |
| 213 | $(foreach pictest, $(10), \ |
| 214 | $(foreach debuggable, $(11), \ |
| 215 | $(foreach test, $(12), \ |
| 216 | $(foreach address_size, $(13), \ |
| 217 | test-art-$(target)-run-test-$(run-type)-$(prebuild)-$(compiler)-$(relocate)-$(trace)-$(gc)-$(jni)-$(image)-$(pictest)-$(debuggable)-$(test)$(address_size) \ |
| 218 | ))))))))))))) |
| 219 | endef # all-run-test-names |
| 220 | |
| 221 | # To generate a full list or tests: |
| 222 | # $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES),$(COMPILER_TYPES), \ |
| 223 | # $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 224 | # $(PICTEST_TYPES),$(DEBUGGABLE_TYPES),$(TEST_ART_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 225 | |
| 226 | # Convert's a rule name to the form used in variables, e.g. no-relocate to NO_RELOCATE |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 227 | define name-to-var |
| 228 | $(shell echo $(1) | tr '[:lower:]' '[:upper:]' | tr '-' '_') |
| 229 | endef # name-to-var |
| 230 | |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 231 | # Disable 153-reference-stress temporarily until a fix arrives. b/33389022. |
| 232 | # Disable 080-oom-fragmentation due to flakes. b/33795328 |
| 233 | # Disable 497-inlining-and-class-loader and 542-unresolved-access-check until |
| 234 | # they are rewritten. These tests use a broken class loader that tries to |
| 235 | # register a dex file that's already registered with a different loader. |
| 236 | # b/34193123 |
| 237 | ART_TEST_RUN_TEST_SKIP += \ |
| 238 | 153-reference-stress \ |
| 239 | 080-oom-fragmentation \ |
| 240 | 497-inlining-and-class-loader \ |
| 241 | 542-unresolved-access-check |
| 242 | |
| 243 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 244 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 245 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(ART_TEST_RUN_TEST_SKIP), $(ALL_ADDRESS_SIZES)) |
| 246 | |
| 247 | |
| 248 | # Disable 149-suspend-all-stress, its output is flaky (b/28988206). |
| 249 | # Disable 577-profile-foreign-dex (b/27454772). |
| 250 | TEST_ART_BROKEN_ALL_TARGET_TESTS := \ |
| 251 | 149-suspend-all-stress \ |
| 252 | 577-profile-foreign-dex \ |
| 253 | |
| 254 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 255 | $(COMPILER_TYPES), $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 256 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_ALL_TARGET_TESTS), \ |
| 257 | $(ALL_ADDRESS_SIZES)) |
| 258 | |
| 259 | TEST_ART_BROKEN_ALL_TARGET_TESTS := |
| 260 | |
| 261 | # Tests that are timing sensitive and flaky on heavily loaded systems. |
| 262 | TEST_ART_TIMING_SENSITIVE_RUN_TESTS := \ |
| 263 | 002-sleep \ |
| 264 | 053-wait-some \ |
| 265 | 055-enum-performance \ |
| 266 | 133-static-invoke-super |
| 267 | |
| 268 | # disable timing sensitive tests on "dist" builds. |
| 269 | ifdef dist_goal |
| 270 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 271 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 272 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_TIMING_SENSITIVE_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
| 273 | endif |
| 274 | |
| 275 | # 147-stripped-dex-fallback isn't supported on device because --strip-dex |
| 276 | # requires the zip command. |
| 277 | # 569-checker-pattern-replacement tests behaviour present only on host. |
| 278 | TEST_ART_BROKEN_TARGET_TESTS := \ |
| 279 | 147-stripped-dex-fallback \ |
| 280 | 569-checker-pattern-replacement |
| 281 | |
| 282 | ifneq (,$(filter target,$(TARGET_TYPES))) |
| 283 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 284 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 285 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_TARGET_TESTS), $(ALL_ADDRESS_SIZES)) |
| 286 | endif |
| 287 | |
| 288 | TEST_ART_BROKEN_TARGET_TESTS := |
| 289 | |
| 290 | # Tests that require python3. |
| 291 | TEST_ART_PYTHON3_DEPENDENCY_RUN_TESTS := \ |
| 292 | 960-default-smali \ |
| 293 | 961-default-iface-resolution-gen \ |
| 294 | 964-default-iface-init-gen \ |
| 295 | 968-default-partial-compile-gen \ |
| 296 | 969-iface-super \ |
| 297 | 970-iface-super-resolution-gen \ |
| 298 | 971-iface-super |
| 299 | |
| 300 | # Check if we have python3 to run our tests. |
| 301 | ifeq ($(wildcard /usr/bin/python3),) |
| 302 | $(warning "No python3 found. Disabling tests: $(TEST_ART_PYTHON3_DEPENDENCY_RUN_TESTS)") |
| 303 | |
| 304 | # Currently disable tests requiring python3 when it is not installed. |
| 305 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 306 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 307 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_PYTHON3_DEPENDENCY_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
| 308 | endif |
| 309 | |
| 310 | TEST_ART_TIMING_SENSITIVE_RUN_TESTS := |
| 311 | |
| 312 | # Note 116-nodex2oat is not broken per-se it just doesn't (and isn't meant to) work with --prebuild. |
| 313 | TEST_ART_BROKEN_PREBUILD_RUN_TESTS := \ |
| 314 | 116-nodex2oat \ |
| 315 | 118-noimage-dex2oat \ |
| 316 | 134-nodex2oat-nofallback |
| 317 | |
| 318 | ifneq (,$(filter prebuild,$(PREBUILD_TYPES))) |
| 319 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),prebuild, \ |
| 320 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 321 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_PREBUILD_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
| 322 | endif |
| 323 | |
| 324 | TEST_ART_BROKEN_PREBUILD_RUN_TESTS := |
| 325 | |
| 326 | # 554-jit-profile-file is disabled because it needs a primary oat file to know what it should save. |
| 327 | # 529 and 555: b/27784033 |
| 328 | TEST_ART_BROKEN_NO_PREBUILD_TESTS := \ |
| 329 | 117-nopatchoat \ |
| 330 | 147-stripped-dex-fallback \ |
| 331 | 554-jit-profile-file \ |
| 332 | 529-checker-unresolved \ |
| 333 | 555-checker-regression-x86const \ |
| 334 | 608-checker-unresolved-lse |
| 335 | |
| 336 | ifneq (,$(filter no-prebuild,$(PREBUILD_TYPES))) |
| 337 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),no-prebuild, \ |
| 338 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 339 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_NO_PREBUILD_TESTS), $(ALL_ADDRESS_SIZES)) |
| 340 | endif |
| 341 | |
| 342 | TEST_ART_BROKEN_NO_PREBUILD_TESTS := |
| 343 | |
| 344 | # Note 117-nopatchoat is not broken per-se it just doesn't work (and isn't meant to) without |
| 345 | # --prebuild --relocate |
| 346 | TEST_ART_BROKEN_NO_RELOCATE_TESTS := \ |
| 347 | 117-nopatchoat \ |
| 348 | 118-noimage-dex2oat \ |
| 349 | 119-noimage-patchoat \ |
| 350 | 554-jit-profile-file |
| 351 | |
| 352 | ifneq (,$(filter no-relocate,$(RELOCATE_TYPES))) |
| 353 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 354 | $(COMPILER_TYPES), no-relocate,$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 355 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_NO_RELOCATE_TESTS), $(ALL_ADDRESS_SIZES)) |
| 356 | endif |
| 357 | |
| 358 | TEST_ART_BROKEN_NO_RELOCATE_TESTS := |
| 359 | |
| 360 | # Temporarily disable some broken tests when forcing access checks in interpreter b/22414682 |
| 361 | # 629 requires compilation. |
| 362 | TEST_ART_BROKEN_INTERPRETER_ACCESS_CHECK_TESTS := \ |
| 363 | 137-cfi \ |
| 364 | 629-vdex-speed |
| 365 | |
| 366 | ifneq (,$(filter interp-ac,$(COMPILER_TYPES))) |
| 367 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 368 | interp-ac,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 369 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_INTERPRETER_ACCESS_CHECK_TESTS), $(ALL_ADDRESS_SIZES)) |
| 370 | endif |
| 371 | |
| 372 | TEST_ART_BROKEN_INTERPRETER_ACCESS_CHECK_TESTS := |
| 373 | |
| 374 | # Tests that are broken with GC stress. |
| 375 | # * 137-cfi needs to unwind a second forked process. We're using a primitive sleep to wait till we |
| 376 | # hope the second process got into the expected state. The slowness of gcstress makes this bad. |
| 377 | # * 908-gc-start-finish expects GCs only to be run at clear points. The reduced heap size makes |
| 378 | # this non-deterministic. Same for 913. |
| 379 | # * 961-default-iface-resolution-gen and 964-default-iface-init-genare very long tests that often |
| 380 | # will take more than the timeout to run when gcstress is enabled. This is because gcstress |
| 381 | # slows down allocations significantly which these tests do a lot. |
| 382 | TEST_ART_BROKEN_GCSTRESS_RUN_TESTS := \ |
| 383 | 137-cfi \ |
| 384 | 154-gc-loop \ |
| 385 | 908-gc-start-finish \ |
| 386 | 913-heaps \ |
| 387 | 961-default-iface-resolution-gen \ |
| 388 | 964-default-iface-init-gen |
| 389 | |
| 390 | ifneq (,$(filter gcstress,$(GC_TYPES))) |
| 391 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 392 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),gcstress,$(JNI_TYPES), \ |
| 393 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_GCSTRESS_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
| 394 | endif |
| 395 | |
| 396 | TEST_ART_BROKEN_GCSTRESS_RUN_TESTS := |
| 397 | |
| 398 | # 115-native-bridge setup is complicated. Need to implement it correctly for the target. |
| 399 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES),$(COMPILER_TYPES), \ |
| 400 | $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), 115-native-bridge, \ |
| 401 | $(ALL_ADDRESS_SIZES)) |
| 402 | |
| 403 | # 130-hprof dumps the heap and runs hprof-conv to check whether the file is somewhat readable. This |
| 404 | # is only possible on the host. |
| 405 | # TODO: Turn off all the other combinations, this is more about testing actual ART code. A gtest is |
| 406 | # very hard to write here, as (for a complete test) JDWP must be set up. |
| 407 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 408 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 409 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES),130-hprof,$(ALL_ADDRESS_SIZES)) |
| 410 | |
| 411 | # 131 is an old test. The functionality has been implemented at an earlier stage and is checked |
| 412 | # in tests 138. Blacklisted for debug builds since these builds have duplicate classes checks which |
| 413 | # punt to interpreter. |
| 414 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),debug,$(PREBUILD_TYPES), \ |
| 415 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 416 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES),131-structural-change,$(ALL_ADDRESS_SIZES)) |
| 417 | |
| 418 | # 138-duplicate-classes-check. Turned on for debug builds since debug builds have duplicate classes |
| 419 | # checks enabled, b/2133391. |
| 420 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),ndebug,$(PREBUILD_TYPES), \ |
| 421 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 422 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES),138-duplicate-classes-check,$(ALL_ADDRESS_SIZES)) |
| 423 | |
| 424 | # All these tests check that we have sane behavior if we don't have a patchoat or dex2oat. |
| 425 | # Therefore we shouldn't run them in situations where we actually don't have these since they |
| 426 | # explicitly test for them. These all also assume we have an image. |
| 427 | # 147-stripped-dex-fallback is disabled because it requires --prebuild. |
| 428 | # 554-jit-profile-file is disabled because it needs a primary oat file to know what it should save. |
| 429 | # 629-vdex-speed requires compiled code. |
| 430 | TEST_ART_BROKEN_FALLBACK_RUN_TESTS := \ |
| 431 | 116-nodex2oat \ |
| 432 | 117-nopatchoat \ |
| 433 | 118-noimage-dex2oat \ |
| 434 | 119-noimage-patchoat \ |
| 435 | 137-cfi \ |
| 436 | 138-duplicate-classes-check2 \ |
| 437 | 147-stripped-dex-fallback \ |
| 438 | 554-jit-profile-file \ |
| 439 | 629-vdex-speed |
| 440 | |
| 441 | # This test fails without an image. |
| 442 | # 018, 961, 964, 968 often time out. b/34369284 |
| 443 | TEST_ART_BROKEN_NO_IMAGE_RUN_TESTS := \ |
| 444 | 137-cfi \ |
| 445 | 138-duplicate-classes-check \ |
| 446 | 018-stack-overflow \ |
| 447 | 961-default-iface-resolution-gen \ |
| 448 | 964-default-iface-init \ |
| 449 | 968-default-partial-compile-gen \ |
| 450 | |
| 451 | ifneq (,$(filter no-dex2oat,$(PREBUILD_TYPES))) |
| 452 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),no-dex2oat, \ |
| 453 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 454 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 455 | endif |
| 456 | |
| 457 | |
| 458 | ifneq (,$(filter no-image,$(IMAGE_TYPES))) |
| 459 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 460 | $(COMPILER_TYPES), $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),no-image, \ |
| 461 | $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 462 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 463 | $(COMPILER_TYPES), $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),no-image, \ |
| 464 | $(PICTEST_TYPES), $(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_NO_IMAGE_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 465 | endif |
| 466 | |
| 467 | ifneq (,$(filter relocate-npatchoat,$(RELOCATE_TYPES))) |
| 468 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 469 | $(COMPILER_TYPES), relocate-npatchoat,$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 470 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 471 | endif |
| 472 | |
| 473 | TEST_ART_BROKEN_FALLBACK_RUN_TESTS := |
| 474 | |
| 475 | # 137: |
| 476 | # This test unrolls and expects managed frames, but tracing means we run the interpreter. |
| 477 | # 802 and 570-checker-osr: |
| 478 | # This test dynamically enables tracing to force a deoptimization. This makes the test meaningless |
| 479 | # when already tracing, and writes an error message that we do not want to check for. |
| 480 | # 130 occasional timeout b/32383962. |
| 481 | # 629 requires compilation. |
| 482 | TEST_ART_BROKEN_TRACING_RUN_TESTS := \ |
| 483 | 087-gc-after-link \ |
| 484 | 130-hprof \ |
| 485 | 137-cfi \ |
| 486 | 141-class-unload \ |
| 487 | 570-checker-osr \ |
| 488 | 629-vdex-speed \ |
| 489 | 802-deoptimization |
| 490 | |
| 491 | ifneq (,$(filter trace stream,$(TRACE_TYPES))) |
| 492 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 493 | $(COMPILER_TYPES),$(RELOCATE_TYPES),trace stream,$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 494 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_TRACING_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 495 | endif |
| 496 | |
| 497 | TEST_ART_BROKEN_TRACING_RUN_TESTS := |
| 498 | |
| 499 | # These tests expect JIT compilation, which is suppressed when tracing. |
| 500 | TEST_ART_BROKEN_JIT_TRACING_RUN_TESTS := \ |
| 501 | 604-hot-static-interface \ |
| 502 | 612-jit-dex-cache \ |
| 503 | 613-inlining-dex-cache \ |
| 504 | 616-cha \ |
| 505 | 626-set-resolved-string \ |
| 506 | |
| 507 | ifneq (,$(filter trace stream,$(TRACE_TYPES))) |
| 508 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 509 | jit,$(RELOCATE_TYPES),trace stream,$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 510 | $(PICTEST_TYPES),$(DEBUGGABLE_TYPES), $(TEST_ART_BROKEN_JIT_TRACING_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 511 | endif |
| 512 | |
| 513 | TEST_ART_BROKEN_JIT_TRACING_RUN_TESTS := |
| 514 | |
| 515 | # Known broken tests for the interpreter. |
| 516 | # CFI unwinding expects managed frames. |
| 517 | # 629 requires compilation. |
| 518 | TEST_ART_BROKEN_INTERPRETER_RUN_TESTS := \ |
| 519 | 137-cfi \ |
| 520 | 554-jit-profile-file \ |
| 521 | 629-vdex-speed |
| 522 | |
| 523 | ifneq (,$(filter interpreter,$(COMPILER_TYPES))) |
| 524 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 525 | interpreter,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 526 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES),$(TEST_ART_BROKEN_INTERPRETER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 527 | endif |
| 528 | |
| 529 | TEST_ART_BROKEN_INTERPRETER_RUN_TESTS := |
| 530 | |
| 531 | # Known broken tests for the JIT. |
| 532 | # CFI unwinding expects managed frames, and the test does not iterate enough to even compile. JIT |
| 533 | # also uses Generic JNI instead of the JNI compiler. |
| 534 | # Test 906 iterates the heap filtering with different options. No instances should be created |
| 535 | # between those runs to be able to have precise checks. |
| 536 | # Test 902 hits races with the JIT compiler. b/32821077 |
| 537 | # Test 629 requires compilation. |
| 538 | # Test 914, 915, 917, & 919 are very sensitive to the exact state of the stack, |
| 539 | # including the jit-inserted runtime frames. This causes them to be somewhat |
| 540 | # flaky as JIT tests. This should be fixed once b/33630159 or b/33616143 are |
| 541 | # resolved but until then just disable them. Test 916 already checks this |
| 542 | # feature for JIT use cases in a way that is resilient to the jit frames. |
| 543 | # 912: b/34655682 |
| 544 | TEST_ART_BROKEN_JIT_RUN_TESTS := \ |
| 545 | 137-cfi \ |
| 546 | 629-vdex-speed \ |
| 547 | 902-hello-transformation \ |
| 548 | 904-object-allocation \ |
| 549 | 906-iterate-heap \ |
| 550 | 912-classes \ |
| 551 | 914-hello-obsolescence \ |
| 552 | 915-obsolete-2 \ |
| 553 | 917-fields-transformation \ |
| 554 | 919-obsolete-fields \ |
| 555 | 926-multi-obsolescence \ |
| 556 | |
| 557 | ifneq (,$(filter jit,$(COMPILER_TYPES))) |
| 558 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 559 | jit,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 560 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES),$(TEST_ART_BROKEN_JIT_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 561 | endif |
| 562 | |
| 563 | TEST_ART_BROKEN_JIT_RUN_TESTS := |
| 564 | |
| 565 | # Known broken tests for the graph coloring register allocator. |
| 566 | # These tests were based on the linear scan allocator, which makes different decisions than |
| 567 | # the graph coloring allocator. (These attempt to test for code quality, not correctness.) |
| 568 | TEST_ART_BROKEN_OPTIMIZING_GRAPH_COLOR := \ |
| 569 | 570-checker-select \ |
| 570 | 484-checker-register-hints |
| 571 | |
| 572 | ifneq (,$(filter regalloc_gc,$(COMPILER_TYPES))) |
| 573 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 574 | regalloc_gc,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 575 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 576 | $(TEST_ART_BROKEN_OPTIMIZING_GRAPH_COLOR),$(ALL_ADDRESS_SIZES)) |
| 577 | endif |
| 578 | |
| 579 | # Known broken tests for the mips32 optimizing compiler backend. |
| 580 | TEST_ART_BROKEN_OPTIMIZING_MIPS_RUN_TESTS := \ |
| 581 | |
| 582 | ifeq (mips,$(TARGET_ARCH)) |
| 583 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 584 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 585 | $(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 586 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 587 | $(TEST_ART_BROKEN_OPTIMIZING_MIPS_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 588 | endif |
| 589 | endif |
| 590 | |
| 591 | TEST_ART_BROKEN_OPTIMIZING_MIPS_RUN_TESTS := |
| 592 | |
| 593 | # Known broken tests for the mips64 optimizing compiler backend. |
| 594 | TEST_ART_BROKEN_OPTIMIZING_MIPS64_RUN_TESTS := \ |
| 595 | |
| 596 | ifeq (mips64,$(TARGET_ARCH)) |
| 597 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 598 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 599 | $(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 600 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 601 | $(TEST_ART_BROKEN_OPTIMIZING_MIPS64_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 602 | endif |
| 603 | endif |
| 604 | |
| 605 | TEST_ART_BROKEN_OPTIMIZING_MIPS64_RUN_TESTS := |
| 606 | |
| 607 | # Tests that should fail when the optimizing compiler compiles them non-debuggable. |
| 608 | TEST_ART_BROKEN_OPTIMIZING_NONDEBUGGABLE_RUN_TESTS := \ |
| 609 | 454-get-vreg \ |
| 610 | 457-regs \ |
| 611 | 602-deoptimizeable |
| 612 | |
| 613 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 614 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 615 | $(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 616 | $(IMAGE_TYPES),$(PICTEST_TYPES),ndebuggable,$(TEST_ART_BROKEN_OPTIMIZING_NONDEBUGGABLE_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 617 | endif |
| 618 | |
| 619 | TEST_ART_BROKEN_OPTIMIZING_NONDEBUGGABLE_RUN_TESTS := |
| 620 | |
| 621 | # Tests that should fail when the optimizing compiler compiles them debuggable. |
| 622 | TEST_ART_BROKEN_OPTIMIZING_DEBUGGABLE_RUN_TESTS := \ |
| 623 | |
| 624 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 625 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 626 | $(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 627 | $(IMAGE_TYPES),$(PICTEST_TYPES),debuggable,$(TEST_ART_BROKEN_OPTIMIZING_DEBUGGABLE_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 628 | endif |
| 629 | |
| 630 | TEST_ART_BROKEN_OPTIMIZING_DEBUGGABLE_RUN_TESTS := |
| 631 | |
| 632 | # Tests that should fail in the read barrier configuration with the interpreter. |
| 633 | TEST_ART_BROKEN_INTERPRETER_READ_BARRIER_RUN_TESTS := |
| 634 | |
| 635 | # Tests that should fail in the read barrier configuration with the Optimizing compiler (AOT). |
| 636 | TEST_ART_BROKEN_OPTIMIZING_READ_BARRIER_RUN_TESTS := |
| 637 | |
| 638 | # Tests that should fail in the read barrier configuration with JIT (Optimizing compiler). |
| 639 | TEST_ART_BROKEN_JIT_READ_BARRIER_RUN_TESTS := |
| 640 | |
| 641 | # Tests failing in non-Baker read barrier configurations with the Optimizing compiler (AOT). |
| 642 | # 537: Expects an array copy to be intrinsified, but calling-on-slowpath intrinsics are not yet |
| 643 | # handled in non-Baker read barrier configurations. |
| 644 | TEST_ART_BROKEN_OPTIMIZING_NON_BAKER_READ_BARRIER_RUN_TESTS := \ |
| 645 | 537-checker-arraycopy |
| 646 | |
| 647 | # Tests failing in non-Baker read barrier configurations with JIT (Optimizing compiler). |
| 648 | # 537: Expects an array copy to be intrinsified, but calling-on-slowpath intrinsics are not yet |
| 649 | # handled in non-Baker read barrier configurations. |
| 650 | TEST_ART_BROKEN_JIT_NON_BAKER_READ_BARRIER_RUN_TESTS := \ |
| 651 | 537-checker-arraycopy |
| 652 | |
| 653 | ifeq ($(ART_USE_READ_BARRIER),true) |
| 654 | ifneq (,$(filter interpreter,$(COMPILER_TYPES))) |
| 655 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 656 | $(PREBUILD_TYPES),interpreter,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES), \ |
| 657 | $(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 658 | $(TEST_ART_BROKEN_INTERPRETER_READ_BARRIER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 659 | endif |
| 660 | |
| 661 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 662 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 663 | $(PREBUILD_TYPES),$(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES), \ |
| 664 | $(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 665 | $(TEST_ART_BROKEN_OPTIMIZING_READ_BARRIER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 666 | ifneq ($(ART_READ_BARRIER_TYPE),BAKER) |
| 667 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 668 | $(PREBUILD_TYPES),$(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES), \ |
| 669 | $(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 670 | $(TEST_ART_BROKEN_OPTIMIZING_NON_BAKER_READ_BARRIER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 671 | endif |
| 672 | endif |
| 673 | |
| 674 | ifneq (,$(filter jit,$(COMPILER_TYPES))) |
| 675 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 676 | $(PREBUILD_TYPES),jit,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES), \ |
| 677 | $(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 678 | $(TEST_ART_BROKEN_JIT_READ_BARRIER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 679 | ifneq ($(ART_READ_BARRIER_TYPE),BAKER) |
| 680 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 681 | $(PREBUILD_TYPES),jit,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES), \ |
| 682 | $(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 683 | $(TEST_ART_BROKEN_JIT_NON_BAKER_READ_BARRIER_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 684 | endif |
| 685 | endif |
| 686 | endif |
| 687 | |
| 688 | TEST_ART_BROKEN_OPTIMIZING_READ_BARRIER_RUN_TESTS := |
| 689 | TEST_ART_BROKEN_JIT_READ_BARRIER_RUN_TESTS := |
| 690 | |
| 691 | TEST_ART_BROKEN_NPIC_RUN_TESTS := 596-app-images |
| 692 | ifneq (,$(filter npictest,$(PICTEST_TYPES))) |
| 693 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 694 | ${COMPILER_TYPES},$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 695 | $(IMAGE_TYPES),npictest,$(DEBUGGABLE_TYPES),$(TEST_ART_BROKEN_NPIC_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 696 | endif |
| 697 | |
| 698 | # Tests that should fail in the heap poisoning configuration with the Optimizing compiler. |
| 699 | # 055: Exceeds run time limits due to heap poisoning instrumentation (on ARM and ARM64 devices). |
| 700 | TEST_ART_BROKEN_OPTIMIZING_HEAP_POISONING_RUN_TESTS := \ |
| 701 | 055-enum-performance |
| 702 | |
| 703 | ifeq ($(ART_HEAP_POISONING),true) |
| 704 | ifneq (,$(filter $(OPTIMIZING_COMPILER_TYPES),$(COMPILER_TYPES))) |
| 705 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 706 | $(PREBUILD_TYPES),$(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 707 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 708 | $(TEST_ART_BROKEN_OPTIMIZING_HEAP_POISONING_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 709 | endif |
| 710 | endif |
| 711 | |
| 712 | TEST_ART_BROKEN_OPTIMIZING_HEAP_POISONING_RUN_TESTS := |
| 713 | |
| 714 | # 909: Tests that check semantics for a non-debuggable app. |
| 715 | # 137: relies on AOT code and debuggable makes us JIT always. |
| 716 | TEST_ART_BROKEN_DEBUGGABLE_RUN_TESTS := \ |
| 717 | 137-cfi \ |
| 718 | 909-attach-agent \ |
| 719 | |
| 720 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 721 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 722 | $(IMAGE_TYPES),$(PICTEST_TYPES),debuggable,$(TEST_ART_BROKEN_DEBUGGABLE_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 723 | |
| 724 | TEST_ART_BROKEN_DEBUGGABLE_RUN_TESTS := |
| 725 | |
| 726 | # Tests incompatible with bisection bug search. Sorted by incompatibility reason. |
| 727 | # 000 through 595 do not compile anything. 089 tests a build failure. 018 through 137 |
| 728 | # run dalvikvm more than once. 115 and 088 assume they are always compiled. |
| 729 | # 055 tests performance which is degraded during bisecting. |
| 730 | TEST_ART_INCOMPATIBLE_BISECTION_SEARCH_RUN_TESTS := \ |
| 731 | 000-nop \ |
| 732 | 134-nodex2oat-nofallback \ |
| 733 | 147-stripped-dex-fallback \ |
| 734 | 595-profile-saving \ |
| 735 | \ |
| 736 | 089-many-methods \ |
| 737 | \ |
| 738 | 018-stack-overflow \ |
| 739 | 116-nodex2oat \ |
| 740 | 117-nopatchoat \ |
| 741 | 118-noimage-dex2oat \ |
| 742 | 119-noimage-patchoat \ |
| 743 | 126-miranda-multidex \ |
| 744 | 137-cfi \ |
| 745 | \ |
| 746 | 115-native-bridge \ |
| 747 | 088-monitor-verification \ |
| 748 | \ |
| 749 | 055-enum-performance |
| 750 | |
| 751 | ifeq ($(ART_TEST_BISECTION),true) |
| 752 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES), \ |
| 753 | $(PREBUILD_TYPES),$(OPTIMIZING_COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 754 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(DEBUGGABLE_TYPES), \ |
| 755 | $(TEST_ART_INCOMPATIBLE_BISECTION_SEARCH_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 756 | endif |
| 757 | |
| 758 | # Clear variables ahead of appending to them when defining tests. |
| 759 | $(foreach target, $(TARGET_TYPES), $(eval ART_RUN_TEST_$(call name-to-var,$(target))_RULES :=)) |
| 760 | $(foreach target, $(TARGET_TYPES), \ |
| 761 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 762 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(prebuild))_RULES :=))) |
| 763 | $(foreach target, $(TARGET_TYPES), \ |
| 764 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 765 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(compiler))_RULES :=))) |
| 766 | $(foreach target, $(TARGET_TYPES), \ |
| 767 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 768 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(relocate))_RULES :=))) |
| 769 | $(foreach target, $(TARGET_TYPES), \ |
| 770 | $(foreach trace, $(TRACE_TYPES), \ |
| 771 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(trace))_RULES :=))) |
| 772 | $(foreach target, $(TARGET_TYPES), \ |
| 773 | $(foreach gc, $(GC_TYPES), \ |
| 774 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(gc))_RULES :=))) |
| 775 | $(foreach target, $(TARGET_TYPES), \ |
| 776 | $(foreach jni, $(JNI_TYPES), \ |
| 777 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(jni))_RULES :=))) |
| 778 | $(foreach target, $(TARGET_TYPES), \ |
| 779 | $(foreach image, $(IMAGE_TYPES), \ |
| 780 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(image))_RULES :=))) |
| 781 | $(foreach target, $(TARGET_TYPES), \ |
| 782 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
| 783 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(test))_RULES :=))) |
| 784 | $(foreach target, $(TARGET_TYPES), \ |
| 785 | $(foreach address_size, $(ALL_ADDRESS_SIZES), \ |
| 786 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(address_size))_RULES :=))) |
| 787 | $(foreach target, $(TARGET_TYPES), \ |
| 788 | $(foreach run_type, $(RUN_TYPES), \ |
| 789 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(run_type))_RULES :=))) |
| 790 | $(foreach target, $(TARGET_TYPES), \ |
| 791 | $(foreach debuggable_type, $(DEBUGGABLE_TYPES), \ |
| 792 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(debuggable_type))_RULES :=))) |
| 793 | |
| Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 794 | # We need dex2oat and dalvikvm on the target as well as the core images (all images as we sync |
| 795 | # only once). |
| 796 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_EXECUTABLES) $(TARGET_CORE_IMG_OUTS) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 797 | |
| Alex Light | 7233c7e | 2016-07-28 10:07:45 -0700 | [diff] [blame] | 798 | # Also need libartagent. |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 799 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libartagent) |
| 800 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libartagentd) |
| Alex Light | 7233c7e | 2016-07-28 10:07:45 -0700 | [diff] [blame] | 801 | ifdef TARGET_2ND_ARCH |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 802 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libartagent) |
| 803 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libartagentd) |
| Alex Light | 7233c7e | 2016-07-28 10:07:45 -0700 | [diff] [blame] | 804 | endif |
| 805 | |
| Alex Light | 49948e9 | 2016-08-11 15:35:28 -0700 | [diff] [blame] | 806 | # Also need libtiagent. |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 807 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libtiagent) |
| 808 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libtiagentd) |
| Alex Light | 49948e9 | 2016-08-11 15:35:28 -0700 | [diff] [blame] | 809 | ifdef TARGET_2ND_ARCH |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 810 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libtiagent) |
| 811 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libtiagentd) |
| Alex Light | 49948e9 | 2016-08-11 15:35:28 -0700 | [diff] [blame] | 812 | endif |
| 813 | |
| Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 814 | # Also need libarttest. |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 815 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libarttest) |
| 816 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libarttestd) |
| Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 817 | ifdef TARGET_2ND_ARCH |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 818 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libarttest) |
| 819 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libarttestd) |
| Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 820 | endif |
| 821 | |
| Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 822 | # Also need libnativebridgetest. |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 823 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_ARCH)_libnativebridgetest) |
| Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 824 | ifdef TARGET_2ND_ARCH |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 825 | TEST_ART_TARGET_SYNC_DEPS += $(OUT_DIR)/$(ART_TEST_LIST_device_$(TARGET_2ND_ARCH)_libnativebridgetest) |
| Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 826 | endif |
| 827 | |
| Nicolas Geoffray | d026ee5 | 2016-11-23 10:47:02 +0000 | [diff] [blame] | 828 | # Also need libopenjdkjvmti. |
| Nicolas Geoffray | ae02d2e | 2016-11-23 16:25:15 +0000 | [diff] [blame] | 829 | TEST_ART_TARGET_SYNC_DEPS += libopenjdkjvmti |
| 830 | TEST_ART_TARGET_SYNC_DEPS += libopenjdkjvmtid |
| Nicolas Geoffray | d026ee5 | 2016-11-23 10:47:02 +0000 | [diff] [blame] | 831 | |
| Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 832 | # All tests require the host executables. The tests also depend on the core images, but on |
| 833 | # specific version depending on the compiler. |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 834 | ART_TEST_HOST_RUN_TEST_DEPENDENCIES := \ |
| 835 | $(ART_HOST_EXECUTABLES) \ |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 836 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libtiagent) \ |
| 837 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libtiagentd) \ |
| 838 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libartagent) \ |
| 839 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libartagentd) \ |
| 840 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libarttest) \ |
| 841 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libarttestd) \ |
| 842 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(ART_HOST_ARCH)_libnativebridgetest) \ |
| Narayan Kamath | 67ef2c9 | 2015-11-16 10:17:35 +0000 | [diff] [blame] | 843 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libjavacore$(ART_HOST_SHLIB_EXTENSION) \ |
| Andreas Gampe | 10edbb1 | 2016-01-06 17:59:49 -0800 | [diff] [blame] | 844 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdk$(ART_HOST_SHLIB_EXTENSION) \ |
| Andreas Gampe | f2c5dbd | 2016-11-17 22:50:33 -0800 | [diff] [blame] | 845 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkd$(ART_HOST_SHLIB_EXTENSION) \ |
| 846 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkjvmti$(ART_HOST_SHLIB_EXTENSION) \ |
| 847 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkjvmtid$(ART_HOST_SHLIB_EXTENSION) \ |
| Ian Rogers | 665de8a | 2014-06-24 21:34:09 -0700 | [diff] [blame] | 848 | |
| 849 | ifneq ($(HOST_PREFER_32_BIT),true) |
| 850 | ART_TEST_HOST_RUN_TEST_DEPENDENCIES += \ |
| Colin Cross | afd3c9e | 2016-09-16 13:47:21 -0700 | [diff] [blame] | 851 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libtiagent) \ |
| 852 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libtiagentd) \ |
| 853 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libartagent) \ |
| 854 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libartagentd) \ |
| 855 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libarttest) \ |
| 856 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libarttestd) \ |
| 857 | $(OUT_DIR)/$(ART_TEST_LIST_host_$(2ND_ART_HOST_ARCH)_libnativebridgetest) \ |
| Narayan Kamath | 67ef2c9 | 2015-11-16 10:17:35 +0000 | [diff] [blame] | 858 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libjavacore$(ART_HOST_SHLIB_EXTENSION) \ |
| Andreas Gampe | 10edbb1 | 2016-01-06 17:59:49 -0800 | [diff] [blame] | 859 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdk$(ART_HOST_SHLIB_EXTENSION) \ |
| Andreas Gampe | f2c5dbd | 2016-11-17 22:50:33 -0800 | [diff] [blame] | 860 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkd$(ART_HOST_SHLIB_EXTENSION) \ |
| 861 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkjvmti$(ART_HOST_SHLIB_EXTENSION) \ |
| 862 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libopenjdkjvmtid$(ART_HOST_SHLIB_EXTENSION) \ |
| 863 | |
| Ian Rogers | 665de8a | 2014-06-24 21:34:09 -0700 | [diff] [blame] | 864 | endif |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 865 | |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 866 | # Create a rule to build and run a tests following the form: |
| 867 | # test-art-{1: host or target}-run-test-{2: debug ndebug}-{3: prebuild no-prebuild no-dex2oat}- |
| 868 | # {4: interpreter optimizing jit interp-ac}- |
| 869 | # {5: relocate nrelocate relocate-npatchoat}- |
| 870 | # {6: trace or ntrace}-{7: gcstress gcverify cms}-{8: forcecopy checkjni jni}- |
| 871 | # {9: no-image image picimage}-{10: pictest npictest}- |
| 872 | # {11: ndebuggable debuggable}-{12: test name}{13: 32 or 64} |
| 873 | define define-test-art-run-test |
| 874 | run_test_options := |
| 875 | prereq_rule := |
| 876 | test_groups := |
| 877 | uc_host_or_target := |
| 878 | jack_classpath := |
| 879 | ifeq ($(ART_TEST_WITH_STRACE),true) |
| 880 | run_test_options += --strace |
| 881 | endif |
| 882 | ifeq ($(ART_TEST_RUN_TEST_ALWAYS_CLEAN),true) |
| 883 | run_test_options += --always-clean |
| 884 | endif |
| 885 | ifeq ($(ART_TEST_BISECTION),true) |
| 886 | run_test_options += --bisection-search |
| 887 | endif |
| 888 | ifeq ($(1),host) |
| 889 | uc_host_or_target := HOST |
| 890 | test_groups := ART_RUN_TEST_HOST_RULES |
| 891 | run_test_options += --host |
| 892 | prereq_rule := $(ART_TEST_HOST_RUN_TEST_DEPENDENCIES) $(HOST_JACK_CLASSPATH_DEPENDENCIES) |
| 893 | jack_classpath := $(HOST_JACK_CLASSPATH) |
| Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 894 | else |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 895 | ifeq ($(1),target) |
| 896 | uc_host_or_target := TARGET |
| 897 | test_groups := ART_RUN_TEST_TARGET_RULES |
| 898 | prereq_rule := test-art-target-sync $(TARGET_JACK_CLASSPATH_DEPENDENCIES) |
| 899 | jack_classpath := $(TARGET_JACK_CLASSPATH) |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 900 | else |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 901 | $$(error found $(1) expected $(TARGET_TYPES)) |
| 902 | endif |
| 903 | endif |
| 904 | ifeq ($(2),debug) |
| 905 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_DEBUG_RULES |
| 906 | else |
| 907 | ifeq ($(2),ndebug) |
| 908 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELEASE_RULES |
| 909 | run_test_options += -O |
| 910 | else |
| 911 | $$(error found $(2) expected $(RUN_TYPES)) |
| 912 | endif |
| 913 | endif |
| 914 | ifeq ($(3),prebuild) |
| 915 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_PREBUILD_RULES |
| 916 | run_test_options += --prebuild |
| 917 | else |
| 918 | ifeq ($(3),no-prebuild) |
| 919 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_PREBUILD_RULES |
| 920 | run_test_options += --no-prebuild |
| 921 | else |
| 922 | ifeq ($(3),no-dex2oat) |
| 923 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_DEX2OAT_RULES |
| 924 | run_test_options += --no-prebuild --no-dex2oat |
| Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 925 | else |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 926 | $$(error found $(3) expected $(PREBUILD_TYPES)) |
| 927 | endif |
| 928 | endif |
| 929 | endif |
| 930 | ifeq ($(4),optimizing) |
| 931 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_OPTIMIZING_RULES |
| 932 | run_test_options += --optimizing |
| 933 | else ifeq ($(4),regalloc_gc) |
| 934 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_OPTIMIZING_GRAPH_COLOR_RULES |
| 935 | run_test_options += --optimizing -Xcompiler-option --register-allocation-strategy=graph-color |
| 936 | else |
| 937 | ifeq ($(4),interpreter) |
| 938 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_INTERPRETER_RULES |
| 939 | run_test_options += --interpreter |
| 940 | else ifeq ($(4),interp-ac) |
| 941 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_INTERPRETER_ACCESS_CHECKS_RULES |
| 942 | run_test_options += --interpreter --verify-soft-fail |
| 943 | else |
| 944 | ifeq ($(4),jit) |
| 945 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_JIT_RULES |
| 946 | run_test_options += --jit |
| 947 | else |
| 948 | $$(error found $(4) expected $(COMPILER_TYPES)) |
| 949 | endif |
| 950 | endif |
| 951 | endif |
| 952 | |
| 953 | ifeq ($(5),relocate) |
| 954 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELOCATE_RULES |
| 955 | run_test_options += --relocate |
| 956 | else |
| 957 | ifeq ($(5),no-relocate) |
| 958 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_RELOCATE_RULES |
| 959 | run_test_options += --no-relocate |
| 960 | else |
| 961 | ifeq ($(5),relocate-npatchoat) |
| 962 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELOCATE_NO_PATCHOAT_RULES |
| 963 | run_test_options += --relocate --no-patchoat |
| 964 | else |
| 965 | $$(error found $(5) expected $(RELOCATE_TYPES)) |
| 966 | endif |
| 967 | endif |
| 968 | endif |
| 969 | ifeq ($(6),trace) |
| 970 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_TRACE_RULES |
| 971 | run_test_options += --trace |
| 972 | else |
| 973 | ifeq ($(6),ntrace) |
| 974 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_TRACE_RULES |
| 975 | else |
| 976 | ifeq ($(6),stream) |
| 977 | # Group streaming under normal tracing rules. |
| 978 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_TRACE_RULES |
| 979 | run_test_options += --trace --stream |
| 980 | else |
| 981 | $$(error found $(6) expected $(TRACE_TYPES)) |
| 982 | endif |
| 983 | endif |
| 984 | endif |
| 985 | ifeq ($(7),gcverify) |
| 986 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_GCVERIFY_RULES |
| 987 | run_test_options += --gcverify |
| 988 | else |
| 989 | ifeq ($(7),gcstress) |
| 990 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_GCSTRESS_RULES |
| 991 | run_test_options += --gcstress |
| 992 | else |
| 993 | ifeq ($(7),cms) |
| 994 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_CMS_RULES |
| 995 | else |
| 996 | $$(error found $(7) expected $(GC_TYPES)) |
| 997 | endif |
| 998 | endif |
| 999 | endif |
| 1000 | ifeq ($(8),forcecopy) |
| 1001 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_FORCECOPY_RULES |
| 1002 | run_test_options += --runtime-option -Xjniopts:forcecopy |
| 1003 | ifneq ($$(ART_TEST_JNI_FORCECOPY),true) |
| 1004 | skip_test := true |
| 1005 | endif |
| 1006 | else |
| 1007 | ifeq ($(8),checkjni) |
| 1008 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_CHECKJNI_RULES |
| 1009 | run_test_options += --runtime-option -Xcheck:jni |
| 1010 | else |
| 1011 | ifeq ($(8),jni) |
| 1012 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_JNI_RULES |
| 1013 | else |
| 1014 | $$(error found $(8) expected $(JNI_TYPES)) |
| 1015 | endif |
| 1016 | endif |
| 1017 | endif |
| 1018 | image_suffix := $(4) |
| 1019 | ifeq ($(4),regalloc_gc) |
| 1020 | # Graph coloring tests share the image_suffix with optimizing tests. |
| 1021 | image_suffix := optimizing |
| 1022 | else |
| 1023 | ifeq ($(4),jit) |
| 1024 | # JIT tests share the image_suffix with interpreter tests. |
| 1025 | image_suffix := interpreter |
| 1026 | endif |
| 1027 | endif |
| 1028 | ifeq ($(9),no-image) |
| 1029 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_IMAGE_RULES |
| 1030 | run_test_options += --no-image |
| 1031 | # Add the core dependency. This is required for pre-building. |
| 1032 | # Use the PIC image, as it is the default in run-test, to match dependencies. |
| 1033 | ifeq ($(1),host) |
| 1034 | prereq_rule += $$(HOST_CORE_IMAGE_$$(image_suffix)_pic_$(13)) |
| 1035 | else |
| 1036 | prereq_rule += $$(TARGET_CORE_IMAGE_$$(image_suffix)_pic_$(13)) |
| 1037 | endif |
| 1038 | else |
| 1039 | ifeq ($(9),npicimage) |
| 1040 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_IMAGE_RULES |
| 1041 | run_test_options += --npic-image |
| 1042 | # Add the core dependency. |
| 1043 | ifeq ($(1),host) |
| 1044 | prereq_rule += $$(HOST_CORE_IMAGE_$$(image_suffix)_no-pic_$(13)) |
| 1045 | else |
| 1046 | prereq_rule += $$(TARGET_CORE_IMAGE_$$(image_suffix)_no-pic_$(13)) |
| 1047 | endif |
| 1048 | else |
| 1049 | ifeq ($(9),picimage) |
| 1050 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_PICIMAGE_RULES |
| 1051 | ifeq ($(1),host) |
| 1052 | prereq_rule += $$(HOST_CORE_IMAGE_$$(image_suffix)_pic_$(13)) |
| Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 1053 | else |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1054 | prereq_rule += $$(TARGET_CORE_IMAGE_$$(image_suffix)_pic_$(13)) |
| 1055 | endif |
| 1056 | else |
| 1057 | ifeq ($(9),multinpicimage) |
| 1058 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_IMAGE_RULES |
| 1059 | run_test_options += --npic-image --multi-image |
| 1060 | ifeq ($(1),host) |
| 1061 | prereq_rule += $$(HOST_CORE_IMAGE_$$(image_suffix)_no-pic_multi_$(13)) |
| 1062 | else |
| 1063 | prereq_rule += $$(TARGET_CORE_IMAGE_$$(image_suffix)_no-pic_multi_$(13)) |
| 1064 | endif |
| 1065 | else |
| 1066 | ifeq ($(9),multipicimage) |
| 1067 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_PICIMAGE_RULES |
| 1068 | run_test_options += --multi-image |
| 1069 | ifeq ($(1),host) |
| 1070 | prereq_rule += $$(HOST_CORE_IMAGE_$$(image_suffix)_pic_multi_$(13)) |
| 1071 | else |
| 1072 | prereq_rule += $$(TARGET_CORE_IMAGE_$$(image_suffix)_pic_multi_$(13)) |
| 1073 | endif |
| 1074 | else |
| 1075 | $$(error found $(9) expected $(IMAGE_TYPES)) |
| Jeff Hao | dcdc85b | 2015-12-04 14:06:18 -0800 | [diff] [blame] | 1076 | endif |
| 1077 | endif |
| Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 1078 | endif |
| Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 1079 | endif |
| 1080 | endif |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1081 | ifeq ($(10),pictest) |
| 1082 | run_test_options += --pic-test |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1083 | else |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1084 | ifeq ($(10),npictest) |
| 1085 | # Nothing to be done. |
| 1086 | else |
| 1087 | $$(error found $(10) expected $(PICTEST_TYPES)) |
| 1088 | endif |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1089 | endif |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1090 | ifeq ($(11),debuggable) |
| 1091 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_DEBUGGABLE_RULES |
| 1092 | run_test_options += --debuggable |
| 1093 | else |
| 1094 | ifeq ($(11),ndebuggable) |
| 1095 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NONDEBUGGABLE_RULES |
| 1096 | # Nothing to be done. |
| 1097 | else |
| 1098 | $$(error found $(11) expected $(DEBUGGABLE_TYPES)) |
| 1099 | endif |
| 1100 | endif |
| 1101 | # $(12) is the test name. |
| 1102 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_$(call name-to-var,$(12))_RULES |
| 1103 | ifeq ($(13),64) |
| 1104 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_64_RULES |
| 1105 | run_test_options += --64 |
| 1106 | else |
| 1107 | ifeq ($(13),32) |
| 1108 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_32_RULES |
| 1109 | else |
| 1110 | $$(error found $(13) expected $(ALL_ADDRESS_SIZES)) |
| 1111 | endif |
| 1112 | endif |
| 1113 | # Override of host instruction-set-features. Required to test advanced x86 intrinsics. The |
| 1114 | # conditionals aren't really correct, they will fail to do the right thing on a 32-bit only |
| 1115 | # host. However, this isn't common enough to worry here and make the conditions complicated. |
| 1116 | ifneq ($(DEX2OAT_HOST_INSTRUCTION_SET_FEATURES),) |
| 1117 | ifeq ($(13),64) |
| 1118 | run_test_options += --instruction-set-features $(DEX2OAT_HOST_INSTRUCTION_SET_FEATURES) |
| 1119 | endif |
| 1120 | endif |
| 1121 | ifneq ($($(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES),) |
| 1122 | ifeq ($(13),32) |
| 1123 | run_test_options += --instruction-set-features $($(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES) |
| 1124 | endif |
| 1125 | endif |
| 1126 | run_test_rule_name := test-art-$(1)-run-test-$(2)-$(3)-$(4)-$(5)-$(6)-$(7)-$(8)-$(9)-$(10)-$(11)-$(12)$(13) |
| 1127 | run_test_options := --output-path $(ART_HOST_TEST_DIR)/run-test-output/$$(run_test_rule_name) \ |
| 1128 | $$(run_test_options) |
| 1129 | ifneq ($(ART_TEST_ANDROID_ROOT),) |
| 1130 | run_test_options := --android-root $(ART_TEST_ANDROID_ROOT) $$(run_test_options) |
| 1131 | endif |
| 1132 | ifeq ($(ART_TEST_QUIET),true) |
| 1133 | run_test_options += --quiet |
| 1134 | endif |
| 1135 | $$(run_test_rule_name): PRIVATE_RUN_TEST_OPTIONS := $$(run_test_options) |
| 1136 | $$(run_test_rule_name): PRIVATE_JACK_CLASSPATH := $$(jack_classpath) |
| 1137 | .PHONY: $$(run_test_rule_name) |
| 1138 | $$(run_test_rule_name): $(TEST_ART_RUN_TEST_DEPENDENCIES) $(HOST_OUT_EXECUTABLES)/hprof-conv $$(prereq_rule) | $(TEST_ART_RUN_TEST_ORDERONLY_DEPENDENCIES) |
| 1139 | $(hide) $$(call ART_TEST_SKIP,$$@) && \ |
| 1140 | DX=$(abspath $(DX)) \ |
| 1141 | JASMIN=$(abspath $(HOST_OUT_EXECUTABLES)/jasmin) \ |
| 1142 | SMALI=$(abspath $(HOST_OUT_EXECUTABLES)/smali) \ |
| 1143 | DXMERGER=$(abspath $(HOST_OUT_EXECUTABLES)/dexmerger) \ |
| 1144 | JACK_VERSION=$(JACK_DEFAULT_VERSION) \ |
| 1145 | JACK=$(abspath $(JACK)) \ |
| 1146 | JACK_VERSION=$(JACK_DEFAULT_VERSION) \ |
| 1147 | JACK_CLASSPATH=$$(PRIVATE_JACK_CLASSPATH) \ |
| 1148 | art/test/run-test $$(PRIVATE_RUN_TEST_OPTIONS) $(12) \ |
| 1149 | && $$(call ART_TEST_PASSED,$$@) || $$(call ART_TEST_FAILED,$$@) |
| 1150 | $$(hide) (echo $(MAKECMDGOALS) | grep -q $$@ && \ |
| 1151 | echo "run-test run as top-level target, removing test directory $(ART_HOST_TEST_DIR)" && \ |
| 1152 | rm -r $(ART_HOST_TEST_DIR)) || true |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1153 | |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1154 | $$(foreach test_group,$$(test_groups), $$(eval $$(value test_group) += $$(run_test_rule_name))) |
| 1155 | |
| 1156 | # Clear locally defined variables. |
| 1157 | uc_host_or_target := |
| 1158 | test_groups := |
| 1159 | run_test_options := |
| 1160 | run_test_rule_name := |
| 1161 | prereq_rule := |
| 1162 | jack_classpath := |
| 1163 | endef # define-test-art-run-test |
| 1164 | |
| 1165 | $(foreach target, $(TARGET_TYPES), \ |
| 1166 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
| 1167 | $(foreach run_type, $(RUN_TYPES), \ |
| 1168 | $(foreach address_size, $(ADDRESS_SIZES_$(call name-to-var,$(target))), \ |
| 1169 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 1170 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 1171 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 1172 | $(foreach trace, $(TRACE_TYPES), \ |
| 1173 | $(foreach gc, $(GC_TYPES), \ |
| 1174 | $(foreach jni, $(JNI_TYPES), \ |
| 1175 | $(foreach image, $(IMAGE_TYPES), \ |
| 1176 | $(foreach pictest, $(PICTEST_TYPES), \ |
| 1177 | $(foreach debuggable, $(DEBUGGABLE_TYPES), \ |
| 1178 | $(eval $(call define-test-art-run-test,$(target),$(run_type),$(prebuild),$(compiler),$(relocate),$(trace),$(gc),$(jni),$(image),$(pictest),$(debuggable),$(test),$(address_size))) \ |
| 1179 | ))))))))))))) |
| 1180 | define-test-art-run-test := |
| 1181 | |
| 1182 | # Define a phony rule whose purpose is to test its prerequisites. |
| 1183 | # $(1): host or target |
| 1184 | # $(2): list of prerequisites |
| 1185 | define define-test-art-run-test-group |
| 1186 | .PHONY: $(1) |
| 1187 | $(1): $(2) |
| 1188 | $(hide) $$(call ART_TEST_PREREQ_FINISHED,$$@) |
| 1189 | |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1190 | endef # define-test-art-run-test-group |
| 1191 | |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1192 | |
| 1193 | $(foreach target, $(TARGET_TYPES), $(eval \ |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1194 | $(call define-test-art-run-test-group,test-art-$(target)-run-test,$(ART_RUN_TEST_$(call name-to-var,$(target))_RULES)))) |
| 1195 | $(foreach target, $(TARGET_TYPES), \ |
| 1196 | $(foreach prebuild, $(PREBUILD_TYPES), $(eval \ |
| 1197 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(prebuild),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(prebuild))_RULES))))) |
| 1198 | $(foreach target, $(TARGET_TYPES), \ |
| 1199 | $(foreach run-type, $(RUN_TYPES), $(eval \ |
| 1200 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(run-type),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(run-type))_RULES))))) |
| 1201 | $(foreach target, $(TARGET_TYPES), \ |
| 1202 | $(foreach compiler, $(COMPILER_TYPES), $(eval \ |
| 1203 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(compiler),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(compiler))_RULES))))) |
| 1204 | $(foreach target, $(TARGET_TYPES), \ |
| 1205 | $(foreach relocate, $(RELOCATE_TYPES), $(eval \ |
| 1206 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(relocate),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(relocate))_RULES))))) |
| 1207 | $(foreach target, $(TARGET_TYPES), \ |
| 1208 | $(foreach trace, $(TRACE_TYPES), $(eval \ |
| 1209 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(trace),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(trace))_RULES))))) |
| 1210 | $(foreach target, $(TARGET_TYPES), \ |
| 1211 | $(foreach gc, $(GC_TYPES), $(eval \ |
| 1212 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(gc),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(gc))_RULES))))) |
| 1213 | $(foreach target, $(TARGET_TYPES), \ |
| 1214 | $(foreach jni, $(JNI_TYPES), $(eval \ |
| 1215 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(jni),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(jni))_RULES))))) |
| 1216 | $(foreach target, $(TARGET_TYPES), \ |
| 1217 | $(foreach debuggable, $(DEBUGGABLE_TYPES), $(eval \ |
| 1218 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(debuggable),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(debuggable))_RULES))))) |
| 1219 | $(foreach target, $(TARGET_TYPES), \ |
| 1220 | $(foreach image, $(IMAGE_TYPES), $(eval \ |
| 1221 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(image),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(image))_RULES))))) |
| 1222 | $(foreach target, $(TARGET_TYPES), \ |
| 1223 | $(foreach test, $(TEST_ART_RUN_TESTS), $(eval \ |
| 1224 | $(call define-test-art-run-test-group,test-art-$(target)-run-test-$(test),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(test))_RULES))))) |
| 1225 | $(foreach target, $(TARGET_TYPES), \ |
| 1226 | $(foreach address_size, $(ADDRESS_SIZES_$(call name-to-var,$(target))), $(eval \ |
| 1227 | $(call define-test-art-run-test-group,test-art-$(target)-run-test$(address_size),$(ART_RUN_TEST_$(call name-to-var,$(target))_$(address_size)_RULES))))) |
| Shubham Ajmera | b5a77b9 | 2016-12-07 19:39:29 +0000 | [diff] [blame] | 1228 | |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1229 | # Clear variables now we're finished with them. |
| 1230 | $(foreach target, $(TARGET_TYPES), $(eval ART_RUN_TEST_$(call name-to-var,$(target))_RULES :=)) |
| 1231 | $(foreach target, $(TARGET_TYPES), \ |
| 1232 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 1233 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(prebuild))_RULES :=))) |
| 1234 | $(foreach target, $(TARGET_TYPES), \ |
| 1235 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 1236 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(compiler))_RULES :=))) |
| 1237 | $(foreach target, $(TARGET_TYPES), \ |
| 1238 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 1239 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(relocate))_RULES :=))) |
| 1240 | $(foreach target, $(TARGET_TYPES), \ |
| 1241 | $(foreach trace, $(TRACE_TYPES), \ |
| 1242 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(trace))_RULES :=))) |
| 1243 | $(foreach target, $(TARGET_TYPES), \ |
| 1244 | $(foreach gc, $(GC_TYPES), \ |
| 1245 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(gc))_RULES :=))) |
| 1246 | $(foreach target, $(TARGET_TYPES), \ |
| 1247 | $(foreach jni, $(JNI_TYPES), \ |
| 1248 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(jni))_RULES :=))) |
| 1249 | $(foreach target, $(TARGET_TYPES), \ |
| 1250 | $(foreach debuggable, $(DEBUGGABLE_TYPES), \ |
| 1251 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(debuggable))_RULES :=))) |
| 1252 | $(foreach target, $(TARGET_TYPES), \ |
| 1253 | $(foreach image, $(IMAGE_TYPES), \ |
| 1254 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(image))_RULES :=))) |
| 1255 | $(foreach target, $(TARGET_TYPES), \ |
| 1256 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
| 1257 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(test))_RULES :=))) |
| 1258 | $(foreach target, $(TARGET_TYPES), \ |
| 1259 | $(foreach address_size, $(ALL_ADDRESS_SIZES), \ |
| 1260 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(address_size))_RULES :=))) |
| 1261 | $(foreach target, $(TARGET_TYPES), \ |
| 1262 | $(foreach run_type, $(RUN_TYPES), \ |
| 1263 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(run_type))_RULES :=))) |
| 1264 | define-test-art-run-test-group := |
| Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 1265 | TARGET_TYPES := |
| 1266 | PREBUILD_TYPES := |
| 1267 | COMPILER_TYPES := |
| 1268 | RELOCATE_TYPES := |
| 1269 | TRACE_TYPES := |
| 1270 | GC_TYPES := |
| 1271 | JNI_TYPES := |
| Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 1272 | IMAGE_TYPES := |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1273 | ADDRESS_SIZES_TARGET := |
| 1274 | ADDRESS_SIZES_HOST := |
| 1275 | ALL_ADDRESS_SIZES := |
| Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 1276 | RUN_TYPES := |
| Nicolas Geoffray | 43c162f | 2015-03-09 12:21:26 +0000 | [diff] [blame] | 1277 | DEBUGGABLE_TYPES := |
| Shubham Ajmera | 6f3d590 | 2017-02-06 06:39:11 +0000 | [diff] [blame^] | 1278 | |
| Alex Light | 7233c7e | 2016-07-28 10:07:45 -0700 | [diff] [blame] | 1279 | LOCAL_PATH := |