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) |
| 17 | |
| 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 |
| 29 | art_run_tests_dir := $(call intermediates-dir-for,PACKAGING,art-run-tests)/DATA |
| 30 | |
| 31 | # A generated list of prerequisites that call 'run-test --build-only', the actual prerequisite is |
| 32 | # an empty file touched in the intermediate directory. |
| 33 | TEST_ART_RUN_TEST_BUILD_RULES := |
| 34 | |
| 35 | # Helper to create individual build targets for tests. Must be called with $(eval). |
| 36 | # $(1): the test number |
| 37 | define define-build-art-run-test |
| 38 | dmart_target := $(art_run_tests_dir)/art-run-tests/$(1)/touch |
Andreas Gampe | 8fda9f2 | 2014-10-03 16:15:37 -0700 | [diff] [blame] | 39 | $$(dmart_target): $(DX) $(HOST_OUT_EXECUTABLES)/jasmin $(HOST_OUT_EXECUTABLES)/smali $(HOST_OUT_EXECUTABLES)/dexmerger |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 40 | $(hide) rm -rf $$(dir $$@) && mkdir -p $$(dir $$@) |
| 41 | $(hide) DX=$(abspath $(DX)) JASMIN=$(abspath $(HOST_OUT_EXECUTABLES)/jasmin) \ |
Andreas Gampe | 8fda9f2 | 2014-10-03 16:15:37 -0700 | [diff] [blame] | 42 | SMALI=$(abspath $(HOST_OUT_EXECUTABLES)/smali) \ |
| 43 | DXMERGER=$(abspath $(HOST_OUT_EXECUTABLES)/dexmerger) \ |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 44 | $(LOCAL_PATH)/run-test --build-only --output-path $$(abspath $$(dir $$@)) $(1) |
| 45 | $(hide) touch $$@ |
| 46 | |
| 47 | TEST_ART_RUN_TEST_BUILD_RULES += $$(dmart_target) |
| 48 | dmart_target := |
| 49 | endef |
Ian Rogers | bf66bce | 2014-06-24 23:15:34 -0700 | [diff] [blame] | 50 | $(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] | 51 | |
| 52 | include $(CLEAR_VARS) |
| 53 | LOCAL_MODULE_TAGS := tests |
| 54 | LOCAL_MODULE := art-run-tests |
Ian Rogers | abbf242 | 2014-10-15 11:57:01 -0700 | [diff] [blame] | 55 | LOCAL_ADDITIONAL_DEPENDENCIES := $(TEST_ART_RUN_TEST_BUILD_RULES) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 56 | # The build system use this flag to pick up files generated by declare-make-art-run-test. |
| 57 | LOCAL_PICKUP_FILES := $(art_run_tests_dir) |
| 58 | |
| 59 | include $(BUILD_PHONY_PACKAGE) |
| 60 | |
| 61 | # Clear temp vars. |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 62 | art_run_tests_dir := |
| 63 | define-build-art-run-test := |
Ian Rogers | 8a14b75 | 2014-07-18 15:06:53 -0700 | [diff] [blame] | 64 | TEST_ART_RUN_TEST_BUILD_RULES := |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 65 | |
| 66 | ######################################################################## |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 67 | # General rules to build and run a run-test. |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 68 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 69 | TARGET_TYPES := host target |
Nicolas Geoffray | 41bb331 | 2014-10-24 13:49:08 +0100 | [diff] [blame] | 70 | PREBUILD_TYPES := |
| 71 | ifeq ($(ART_TEST_RUN_TEST_PREBUILD),true) |
| 72 | PREBUILD_TYPES += prebuild |
| 73 | endif |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 74 | ifeq ($(ART_TEST_RUN_TEST_NO_PREBUILD),true) |
| 75 | PREBUILD_TYPES += no-prebuild |
| 76 | endif |
| 77 | ifeq ($(ART_TEST_RUN_TEST_NO_DEX2OAT),true) |
| 78 | PREBUILD_TYPES += no-dex2oat |
| 79 | endif |
| 80 | COMPILER_TYPES := |
| 81 | ifeq ($(ART_TEST_DEFAULT_COMPILER),true) |
| 82 | COMPILER_TYPES += default |
| 83 | endif |
| 84 | ifeq ($(ART_TEST_INTERPRETER),true) |
| 85 | COMPILER_TYPES += interpreter |
| 86 | endif |
| 87 | ifeq ($(ART_TEST_OPTIMIZING),true) |
| 88 | COMPILER_TYPES += optimizing |
| 89 | endif |
| 90 | RELOCATE_TYPES := relocate |
| 91 | ifeq ($(ART_TEST_RUN_TEST_NO_RELOCATE),true) |
| 92 | RELOCATE_TYPES += no-relocate |
| 93 | endif |
| 94 | ifeq ($(ART_TEST_RUN_TEST_RELOCATE_NO_PATCHOAT),true) |
| 95 | RELOCATE_TYPES := relocate-no-patchoat |
| 96 | endif |
| 97 | TRACE_TYPES := no-trace |
| 98 | ifeq ($(ART_TEST_TRACE),true) |
| 99 | TRACE_TYPES += trace |
| 100 | endif |
| 101 | GC_TYPES := cms |
Alex Light | 992f1e7 | 2014-08-27 16:08:57 -0700 | [diff] [blame] | 102 | ifeq ($(ART_TEST_GC_STRESS),true) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 103 | GC_TYPES += gcstress |
| 104 | endif |
Alex Light | 992f1e7 | 2014-08-27 16:08:57 -0700 | [diff] [blame] | 105 | ifeq ($(ART_TEST_GC_VERIFY),true) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 106 | GC_TYPES += gcverify |
| 107 | endif |
| 108 | JNI_TYPES := checkjni |
| 109 | ifeq ($(ART_TEST_JNI_FORCECOPY),true) |
| 110 | JNI_TYPES += forcecopy |
| 111 | endif |
| 112 | IMAGE_TYPES := image |
| 113 | ifeq ($(ART_TEST_RUN_TEST_NO_IMAGE),true) |
| 114 | IMAGE_TYPES += no-image |
| 115 | endif |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 116 | ifeq ($(ART_TEST_PIC_IMAGE),true) |
| 117 | IMAGE_TYPES += picimage |
| 118 | endif |
| 119 | PICTEST_TYPES := nopictest |
| 120 | ifeq ($(ART_TEST_PIC_TEST),true) |
| 121 | PICTEST_TYPES += pictest |
| 122 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 123 | RUN_TYPES := |
| 124 | ifeq ($(ART_TEST_RUN_TEST_DEBUG),true) |
| 125 | RUN_TYPES += debug |
| 126 | endif |
| 127 | ifeq ($(ART_TEST_RUN_TEST_NDEBUG),true) |
| 128 | RUN_TYPES += ndebug |
| 129 | endif |
Nicolas Geoffray | 41bb331 | 2014-10-24 13:49:08 +0100 | [diff] [blame] | 130 | ADDRESS_SIZES_TARGET := $(ART_PHONY_TEST_TARGET_SUFFIX) |
| 131 | ADDRESS_SIZES_HOST := $(ART_PHONY_TEST_HOST_SUFFIX) |
| 132 | ifeq ($(ART_TEST_RUN_TEST_2ND_ARCH),true) |
| 133 | ADDRESS_SIZES_TARGET += $(2ND_ART_PHONY_TEST_TARGET_SUFFIX) |
| 134 | ADDRESS_SIZES_HOST += $(2ND_ART_PHONY_TEST_HOST_SUFFIX) |
| 135 | endif |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 136 | ALL_ADDRESS_SIZES := 64 32 |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 137 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 138 | # List all run test names with number arguments agreeing with the comment above. |
| 139 | define all-run-test-names |
| 140 | $(foreach target, $(1), \ |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 141 | $(foreach run-type, $(2), \ |
| 142 | $(foreach prebuild, $(3), \ |
| 143 | $(foreach compiler, $(4), \ |
| 144 | $(foreach relocate, $(5), \ |
| 145 | $(foreach trace, $(6), \ |
| 146 | $(foreach gc, $(7), \ |
| 147 | $(foreach jni, $(8), \ |
| 148 | $(foreach image, $(9), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 149 | $(foreach pictest, $(10), \ |
| 150 | $(foreach test, $(11), \ |
| 151 | $(foreach address_size, $(12), \ |
| 152 | test-art-$(target)-run-test-$(run-type)-$(prebuild)-$(compiler)-$(relocate)-$(trace)-$(gc)-$(jni)-$(image)-$(pictest)-$(test)$(address_size) \ |
| 153 | )))))))))))) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 154 | endef # all-run-test-names |
| 155 | |
| 156 | # To generate a full list or tests: |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 157 | # $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES),$(COMPILER_TYPES), \ |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 158 | # $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
| 159 | # $(TEST_ART_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 160 | |
| 161 | # Convert's a rule name to the form used in variables, e.g. no-relocate to NO_RELOCATE |
| 162 | define name-to-var |
| 163 | $(shell echo $(1) | tr '[:lower:]' '[:upper:]' | tr '-' '_') |
| 164 | endef # name-to-var |
| 165 | |
| 166 | # Tests that are timing sensitive and flaky on heavily loaded systems. |
| 167 | TEST_ART_TIMING_SENSITIVE_RUN_TESTS := \ |
| 168 | 053-wait-some \ |
| 169 | 055-enum-performance |
| 170 | |
| 171 | # disable timing sensitive tests on "dist" builds. |
| 172 | ifdef dist_goal |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 173 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 174 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 175 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_TIMING_SENSITIVE_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 176 | endif |
| 177 | |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 178 | TEST_ART_TIMING_SENSITIVE_RUN_TESTS := |
| 179 | |
Nicolas Geoffray | 3d56be8 | 2014-09-30 15:05:13 +0100 | [diff] [blame] | 180 | TEST_ART_BROKEN_RUN_TESTS := \ |
| 181 | 004-ThreadStress |
| 182 | |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 183 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Nicolas Geoffray | 3d56be8 | 2014-09-30 15:05:13 +0100 | [diff] [blame] | 184 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 185 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_BROKEN_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
Nicolas Geoffray | 3d56be8 | 2014-09-30 15:05:13 +0100 | [diff] [blame] | 186 | |
| 187 | TEST_ART_BROKEN_RUN_TESTS := |
| 188 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 189 | # Note 116-nodex2oat is not broken per-se it just doesn't (and isn't meant to) work with --prebuild. |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 190 | TEST_ART_BROKEN_PREBUILD_RUN_TESTS := \ |
| 191 | 116-nodex2oat |
| 192 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 193 | ifneq (,$(filter prebuild,$(PREBUILD_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 194 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),prebuild, \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 195 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 196 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_BROKEN_PREBUILD_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 197 | endif |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 198 | |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 199 | TEST_ART_BROKEN_PREBUILD_RUN_TESTS := |
| 200 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 201 | TEST_ART_BROKEN_NO_PREBUILD_TESTS := \ |
| 202 | 117-nopatchoat |
| 203 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 204 | ifneq (,$(filter no-prebuild,$(PREBUILD_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 205 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),no-prebuild, \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 206 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 207 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_BROKEN_NO_PREBUILD_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 208 | endif |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 209 | |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 210 | TEST_ART_BROKEN_NO_PREBUILD_TESTS := |
| 211 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 212 | # Note 117-nopatchoat is not broken per-se it just doesn't work (and isn't meant to) without |
| 213 | # --prebuild --relocate |
| 214 | TEST_ART_BROKEN_NO_RELOCATE_TESTS := \ |
| 215 | 117-nopatchoat |
| 216 | |
| 217 | ifneq (,$(filter no-relocate,$(RELOCATE_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 218 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 219 | $(COMPILER_TYPES), no-relocate,$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 220 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_BROKEN_NO_RELOCATE_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 221 | endif |
| 222 | |
| 223 | TEST_ART_BROKEN_NO_RELOCATE_TESTS := |
| 224 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 225 | # Tests that are broken with GC stress. |
| 226 | TEST_ART_BROKEN_GCSTRESS_RUN_TESTS := \ |
Ian Rogers | 58920cc | 2014-10-10 12:39:31 -0700 | [diff] [blame] | 227 | 004-SignalTest \ |
| 228 | 114-ParallelGC |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 229 | |
| 230 | ifneq (,$(filter gcstress,$(GC_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 231 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 232 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),gcstress,$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 233 | $(IMAGE_TYPES), $(PICTEST_TYPES), $(TEST_ART_BROKEN_GCSTRESS_RUN_TESTS), $(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 234 | endif |
| 235 | |
| 236 | TEST_ART_BROKEN_GCSTRESS_RUN_TESTS := |
| 237 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 238 | # 115-native-bridge setup is complicated. Need to implement it correctly for the target. |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 239 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES),$(COMPILER_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 240 | $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES),$(PICTEST_TYPES),115-native-bridge, \ |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 241 | $(ALL_ADDRESS_SIZES)) |
| 242 | |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 243 | # All these tests check that we have sane behavior if we don't have a patchoat or dex2oat. |
| 244 | # Therefore we shouldn't run them in situations where we actually don't have these since they |
| 245 | # explicitly test for them. These all also assume we have an image. |
| 246 | TEST_ART_BROKEN_FALLBACK_RUN_TESTS := \ |
| 247 | 116-nodex2oat \ |
| 248 | 117-nopatchoat \ |
| 249 | 118-noimage-dex2oat \ |
| 250 | 119-noimage-patchoat |
| 251 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 252 | ifneq (,$(filter no-dex2oat,$(PREBUILD_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 253 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),no-dex2oat, \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 254 | $(COMPILER_TYPES),$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 255 | $(PICTEST_TYPES),$(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 256 | endif |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 257 | |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 258 | |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 259 | ifneq (,$(filter no-image,$(IMAGE_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 260 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 261 | $(COMPILER_TYPES), $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),no-image, \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 262 | $(PICTEST_TYPES), $(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 263 | endif |
| 264 | |
| 265 | ifneq (,$(filter relocate-no-patchoat,$(RELOCATE_TYPES))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 266 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 267 | $(COMPILER_TYPES), relocate-no-patchoat,$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 268 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(TEST_ART_BROKEN_FALLBACK_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
Ian Rogers | 40e1912 | 2014-09-02 15:59:28 -0700 | [diff] [blame] | 269 | endif |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 270 | |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 271 | TEST_ART_BROKEN_FALLBACK_RUN_TESTS := |
| 272 | |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 273 | # The following tests use libarttest.so, which is linked against libartd.so, so will |
| 274 | # not work when libart.so is the one loaded. |
| 275 | # TODO: Find a way to run these tests in ndebug mode. |
| 276 | TEST_ART_BROKEN_NDEBUG_TESTS := \ |
| 277 | 004-JniTest \ |
| 278 | 004-ReferenceMap \ |
| 279 | 004-SignalTest \ |
| 280 | 004-StackWalk \ |
| 281 | 004-UnsafeTest \ |
Nicolas Geoffray | 64dea7e | 2014-11-07 14:32:42 +0000 | [diff] [blame^] | 282 | 051-thread \ |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 283 | 115-native-bridge \ |
| 284 | 116-nodex2oat \ |
| 285 | 117-nopatchoat \ |
| 286 | 118-noimage-dex2oat \ |
| 287 | 119-noimage-patchoat \ |
| 288 | |
| 289 | ifneq (,$(filter ndebug,$(RUN_TYPES))) |
| 290 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),ndebug,$(PREBUILD_TYPES), \ |
| 291 | $(COMPILER_TYPES), $(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES),$(IMAGE_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 292 | $(PICTEST_TYPES),$(TEST_ART_BROKEN_NDEBUG_TESTS),$(ALL_ADDRESS_SIZES)) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 293 | endif |
| 294 | |
| 295 | TEST_ART_BROKEN_NDEBUG_TESTS := |
| 296 | |
Nicolas Geoffray | a3d05a4 | 2014-10-20 17:41:32 +0100 | [diff] [blame] | 297 | # Known broken tests for the default compiler (Quick). |
| 298 | TEST_ART_BROKEN_DEFAULT_RUN_TESTS := \ |
| 299 | 412-new-array |
| 300 | |
| 301 | ifneq (,$(filter default,$(COMPILER_TYPES))) |
| 302 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
Nicolas Geoffray | 83cae42 | 2014-10-22 15:08:03 +0100 | [diff] [blame] | 303 | default,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 304 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(TEST_ART_BROKEN_DEFAULT_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
Nicolas Geoffray | a3d05a4 | 2014-10-20 17:41:32 +0100 | [diff] [blame] | 305 | endif |
| 306 | |
| 307 | TEST_ART_BROKEN_DEFAULT_RUN_TESTS := |
| 308 | |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 309 | # Known broken tests for the arm64 optimizing compiler backend. |
| 310 | TEST_ART_BROKEN_OPTIMIZING_ARM64_RUN_TESTS := \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 311 | 001-HelloWorld \ |
Roland Levillain | ed9b195 | 2014-11-06 11:10:17 +0000 | [diff] [blame] | 312 | 002-sleep \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 313 | 003-omnibus-opcodes \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 314 | 004-InterfaceTest \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 315 | 004-JniTest \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 316 | 004-ReferenceMap \ |
| 317 | 004-SignalTest \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 318 | 004-StackWalk \ |
Nicolas Geoffray | 03e68d5 | 2014-11-04 11:49:17 +0000 | [diff] [blame] | 319 | 004-UnsafeTest \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 320 | 005-annotations \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 321 | 006-args \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 322 | 007-count10 \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 323 | 008-exceptions \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 324 | 011-array-copy \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 325 | 013-math2 \ |
| 326 | 016-intern \ |
| 327 | 017-float \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 328 | 018-stack-overflow \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 329 | 019-wrong-array-type \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 330 | 020-string \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 331 | 021-string2 \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 332 | 022-interface \ |
| 333 | 023-many-interfaces \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 334 | 024-illegal-access \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 335 | 026-access \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 336 | 028-array-write \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 337 | 029-assert \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 338 | 030-bad-finalizer \ |
| 339 | 031-class-attributes \ |
| 340 | 032-concrete-sub \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 341 | 033-class-init-deadlock \ |
| 342 | 035-enum \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 343 | 036-finalizer \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 344 | 037-inherit \ |
| 345 | 038-inner-null \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 346 | 039-join-main \ |
| 347 | 040-miranda \ |
| 348 | 042-new-instance \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 349 | 043-privates \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 350 | 044-proxy \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 351 | 045-reflect-array \ |
| 352 | 046-reflect \ |
| 353 | 047-returns \ |
| 354 | 049-show-object \ |
| 355 | 050-sync-test \ |
| 356 | 051-thread \ |
| 357 | 052-verifier-fun \ |
| 358 | 054-uncaught \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 359 | 055-enum-performance \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 360 | 056-const-string-jumbo \ |
| 361 | 061-out-of-memory \ |
| 362 | 063-process-manager \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 363 | 064-field-access \ |
| 364 | 065-mismatched-implements \ |
| 365 | 066-mismatched-super \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 366 | 067-preemptive-unpark \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 367 | 068-classloader \ |
| 368 | 069-field-type \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 369 | 070-nio-buffer \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 370 | 071-dexfile \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 371 | 072-precise-gc \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 372 | 074-gc-thrash \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 373 | 075-verification-error \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 374 | 076-boolean-put \ |
| 375 | 077-method-override \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 376 | 078-polymorphic-virtual \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 377 | 079-phantom \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 378 | 080-oom-throw \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 379 | 081-hot-exceptions \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 380 | 082-inline-execute \ |
| 381 | 083-compiler-regressions \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 382 | 084-class-init \ |
| 383 | 085-old-style-inner-class \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 384 | 086-null-super \ |
| 385 | 087-gc-after-link \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 386 | 088-monitor-verification \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 387 | 090-loop-formation \ |
| 388 | 092-locale \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 389 | 093-serialization \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 390 | 094-pattern \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 391 | 096-array-copy-concurrent-gc \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 392 | 097-duplicate-method \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 393 | 098-ddmc \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 394 | 100-reflect2 \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 395 | 101-fibonacci \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 396 | 102-concurrent-gc \ |
| 397 | 103-string-append \ |
| 398 | 105-invoke \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 399 | 106-exceptions2 \ |
| 400 | 107-int-math2 \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 401 | 109-suspend-check \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 402 | 110-field-access \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 403 | 111-unresolvable-exception \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 404 | 112-double-math \ |
| 405 | 113-multidex \ |
| 406 | 117-nopatchoat \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 407 | 118-noimage-dex2oat \ |
| 408 | 119-noimage-patchoat \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 409 | 121-modifiers \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 410 | 121-simple-suspend-check \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 411 | 122-npe \ |
| 412 | 123-compiler-regressions-mt \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 413 | 124-missing-classes \ |
| 414 | 125-gc-and-classloading \ |
Nicolas Geoffray | 4b420e7 | 2014-11-04 09:15:35 +0000 | [diff] [blame] | 415 | 126-miranda-multidex \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 416 | 201-built-in-exception-detail-messages \ |
| 417 | 202-thread-oome \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 418 | 300-package-override \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 419 | 301-abstract-protected \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 420 | 303-verification-stress \ |
| 421 | 401-optimizing-compiler \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 422 | 402-optimizing-control-flow \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 423 | 403-optimizing-long \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 424 | 404-optimizing-allocator \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 425 | 405-optimizing-long-allocator \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 426 | 406-fields \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 427 | 407-arrays \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 428 | 409-materialized-condition \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 429 | 410-floats \ |
| 430 | 411-optimizing-arith \ |
| 431 | 412-new-array \ |
| 432 | 413-regalloc-regression \ |
Calin Juravle | 096cc02 | 2014-10-23 17:01:13 +0100 | [diff] [blame] | 433 | 414-optimizing-arith-sub \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 434 | 414-static-fields \ |
Roland Levillain | 66ce173 | 2014-10-23 16:38:33 +0100 | [diff] [blame] | 435 | 415-optimizing-arith-neg \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 436 | 416-optimizing-arith-not \ |
Calin Juravle | 7c4954d | 2014-10-28 16:57:40 +0000 | [diff] [blame] | 437 | 417-optimizing-arith-div \ |
Nicolas Geoffray | b5f62b3 | 2014-10-30 10:58:41 +0000 | [diff] [blame] | 438 | 418-const-string \ |
Nicolas Geoffray | 020ac03 | 2014-10-30 17:33:03 +0000 | [diff] [blame] | 439 | 419-long-parameter \ |
Nicolas Geoffray | 424f676 | 2014-11-03 14:51:25 +0000 | [diff] [blame] | 440 | 420-const-class \ |
Nicolas Geoffray | de58ab2 | 2014-11-05 12:46:03 +0000 | [diff] [blame] | 441 | 421-exceptions \ |
Nicolas Geoffray | 0deac2f | 2014-11-06 17:37:50 +0000 | [diff] [blame] | 442 | 421-large-frame \ |
Roland Levillain | dff1f28 | 2014-11-05 14:15:05 +0000 | [diff] [blame] | 443 | 422-type-conversion \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 444 | 700-LoadArgRegs \ |
Nicolas Geoffray | 53c42b6 | 2014-10-31 15:07:56 +0000 | [diff] [blame] | 445 | 701-easy-div-rem \ |
Nicolas Geoffray | 32607a1 | 2014-10-30 10:54:03 +0000 | [diff] [blame] | 446 | 702-LargeBranchOffset \ |
Nicolas Geoffray | 6fb4ef5 | 2014-11-06 09:33:43 +0000 | [diff] [blame] | 447 | 703-floating-point-div \ |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 448 | 800-smali |
| 449 | |
| 450 | ifneq (,$(filter optimizing,$(COMPILER_TYPES))) |
| 451 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,target,$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 452 | optimizing,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 453 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(TEST_ART_BROKEN_OPTIMIZING_ARM64_RUN_TESTS),64) |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 454 | endif |
| 455 | |
| 456 | TEST_ART_BROKEN_OPTIMIZING_ARM64_RUN_TESTS := |
| 457 | |
Nicolas Geoffray | 19a19cf | 2014-10-22 16:07:05 +0100 | [diff] [blame] | 458 | # Known broken tests for the optimizing compiler. |
| 459 | TEST_ART_BROKEN_OPTIMIZING_RUN_TESTS := \ |
| 460 | 099-vmdebug \ # b/18098594 |
| 461 | |
| 462 | ifneq (,$(filter optimizing,$(COMPILER_TYPES))) |
| 463 | ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ |
| 464 | optimizing,$(RELOCATE_TYPES),$(TRACE_TYPES),$(GC_TYPES),$(JNI_TYPES), \ |
| 465 | $(IMAGE_TYPES),$(PICTEST_TYPES),$(TEST_ART_BROKEN_OPTIMIZING_RUN_TESTS),$(ALL_ADDRESS_SIZES)) |
| 466 | endif |
| 467 | |
| 468 | TEST_ART_BROKEN_OPTIMIZING_RUN_TESTS := |
| 469 | |
Alexandre Rames | 5319def | 2014-10-23 10:03:10 +0100 | [diff] [blame] | 470 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 471 | # Clear variables ahead of appending to them when defining tests. |
| 472 | $(foreach target, $(TARGET_TYPES), $(eval ART_RUN_TEST_$(call name-to-var,$(target))_RULES :=)) |
| 473 | $(foreach target, $(TARGET_TYPES), \ |
| 474 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 475 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(prebuild))_RULES :=))) |
| 476 | $(foreach target, $(TARGET_TYPES), \ |
| 477 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 478 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(compiler))_RULES :=))) |
| 479 | $(foreach target, $(TARGET_TYPES), \ |
| 480 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 481 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(relocate))_RULES :=))) |
| 482 | $(foreach target, $(TARGET_TYPES), \ |
| 483 | $(foreach trace, $(TRACE_TYPES), \ |
| 484 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(trace))_RULES :=))) |
| 485 | $(foreach target, $(TARGET_TYPES), \ |
| 486 | $(foreach gc, $(GC_TYPES), \ |
| 487 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(gc))_RULES :=))) |
| 488 | $(foreach target, $(TARGET_TYPES), \ |
| 489 | $(foreach jni, $(JNI_TYPES), \ |
| 490 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(jni))_RULES :=))) |
| 491 | $(foreach target, $(TARGET_TYPES), \ |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 492 | $(foreach image, $(IMAGE_TYPES), \ |
| 493 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(image))_RULES :=))) |
| 494 | $(foreach target, $(TARGET_TYPES), \ |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 495 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
| 496 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(test))_RULES :=))) |
| 497 | $(foreach target, $(TARGET_TYPES), \ |
| 498 | $(foreach address_size, $(ALL_ADDRESS_SIZES), \ |
| 499 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(address_size))_RULES :=))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 500 | $(foreach target, $(TARGET_TYPES), \ |
| 501 | $(foreach run_type, $(RUN_TYPES), \ |
| 502 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(run_type))_RULES :=))) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 503 | |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 504 | # We need dex2oat and dalvikvm on the target as well as the core images (all images as we sync |
| 505 | # only once). |
| 506 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_EXECUTABLES) $(TARGET_CORE_IMG_OUTS) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 507 | |
Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 508 | # Also need libarttest. |
| 509 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_TEST_OUT)/$(TARGET_ARCH)/libarttest.so |
| 510 | ifdef TARGET_2ND_ARCH |
| 511 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_TEST_OUT)/$(TARGET_2ND_ARCH)/libarttest.so |
| 512 | endif |
| 513 | |
Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 514 | # Also need libnativebridgetest. |
| 515 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_TEST_OUT)/$(TARGET_ARCH)/libnativebridgetest.so |
| 516 | ifdef TARGET_2ND_ARCH |
| 517 | TEST_ART_TARGET_SYNC_DEPS += $(ART_TARGET_TEST_OUT)/$(TARGET_2ND_ARCH)/libnativebridgetest.so |
| 518 | endif |
| 519 | |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 520 | # All tests require the host executables. The tests also depend on the core images, but on |
| 521 | # specific version depending on the compiler. |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 522 | ART_TEST_HOST_RUN_TEST_DEPENDENCIES := \ |
| 523 | $(ART_HOST_EXECUTABLES) \ |
Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 524 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libarttest$(ART_HOST_SHLIB_EXTENSION) \ |
Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 525 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libnativebridgetest$(ART_HOST_SHLIB_EXTENSION) \ |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 526 | $(ART_HOST_OUT_SHARED_LIBRARIES)/libjavacore$(ART_HOST_SHLIB_EXTENSION) |
Ian Rogers | 665de8a | 2014-06-24 21:34:09 -0700 | [diff] [blame] | 527 | |
| 528 | ifneq ($(HOST_PREFER_32_BIT),true) |
| 529 | ART_TEST_HOST_RUN_TEST_DEPENDENCIES += \ |
Andreas Gampe | 1c83cbc | 2014-07-22 18:52:29 -0700 | [diff] [blame] | 530 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libarttest$(ART_HOST_SHLIB_EXTENSION) \ |
Andreas Gampe | 855564b | 2014-07-25 02:32:19 -0700 | [diff] [blame] | 531 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libnativebridgetest$(ART_HOST_SHLIB_EXTENSION) \ |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 532 | $(2ND_ART_HOST_OUT_SHARED_LIBRARIES)/libjavacore$(ART_HOST_SHLIB_EXTENSION) |
Ian Rogers | 665de8a | 2014-06-24 21:34:09 -0700 | [diff] [blame] | 533 | endif |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 534 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 535 | # Create a rule to build and run a tests following the form: |
Calin Juravle | 9228b2a | 2014-10-22 15:54:34 +0100 | [diff] [blame] | 536 | # test-art-{1: host or target}-run-test-{2: debug ndebug}-{3: prebuild no-prebuild no-dex2oat}- |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 537 | # {4: interpreter default optimizing}-{5: relocate no-relocate relocate-no-patchoat}- |
| 538 | # {6: trace or no-trace}-{7: gcstress gcverify cms}-{8: forcecopy checkjni jni}- |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 539 | # {9: no-image image picimage}-{10: pictest nopictest}-{11: test name}{12: 32 or 64} |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 540 | define define-test-art-run-test |
Nicolas Geoffray | 611e1db | 2014-10-09 17:34:45 +0100 | [diff] [blame] | 541 | run_test_options := |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 542 | prereq_rule := |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 543 | test_groups := |
| 544 | uc_host_or_target := |
Alex Light | bfac14a | 2014-07-30 09:41:21 -0700 | [diff] [blame] | 545 | ifeq ($(ART_TEST_RUN_TEST_ALWAYS_CLEAN),true) |
| 546 | run_test_options += --always-clean |
| 547 | endif |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 548 | ifeq ($(1),host) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 549 | uc_host_or_target := HOST |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 550 | test_groups := ART_RUN_TEST_HOST_RULES |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 551 | run_test_options += --host |
| 552 | prereq_rule := $(ART_TEST_HOST_RUN_TEST_DEPENDENCIES) |
| 553 | else |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 554 | ifeq ($(1),target) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 555 | uc_host_or_target := TARGET |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 556 | test_groups := ART_RUN_TEST_TARGET_RULES |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 557 | prereq_rule := test-art-target-sync |
| 558 | else |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 559 | $$(error found $(1) expected $(TARGET_TYPES)) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 560 | endif |
| 561 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 562 | ifeq ($(2),debug) |
| 563 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_DEBUG_RULES |
| 564 | else |
| 565 | ifeq ($(2),ndebug) |
| 566 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELEASE_RULES |
| 567 | run_test_options += -O |
| 568 | else |
| 569 | $$(error found $(2) expected $(RUN_TYPES)) |
| 570 | endif |
| 571 | endif |
| 572 | ifeq ($(3),prebuild) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 573 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_PREBUILD_RULES |
| 574 | run_test_options += --prebuild |
Alex Light | a59dd80 | 2014-07-02 16:28:08 -0700 | [diff] [blame] | 575 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 576 | ifeq ($(3),no-prebuild) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 577 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_PREBUILD_RULES |
| 578 | run_test_options += --no-prebuild |
Alex Light | a59dd80 | 2014-07-02 16:28:08 -0700 | [diff] [blame] | 579 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 580 | ifeq ($(3),no-dex2oat) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 581 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_DEX2OAT_RULES |
| 582 | run_test_options += --no-prebuild --no-dex2oat |
| 583 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 584 | $$(error found $(3) expected $(PREBUILD_TYPES)) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 585 | endif |
Alex Light | a59dd80 | 2014-07-02 16:28:08 -0700 | [diff] [blame] | 586 | endif |
| 587 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 588 | ifeq ($(4),optimizing) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 589 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_OPTIMIZING_RULES |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 590 | run_test_options += --optimizing |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 591 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 592 | ifeq ($(4),interpreter) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 593 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_INTERPRETER_RULES |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 594 | run_test_options += --interpreter |
| 595 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 596 | ifeq ($(4),default) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 597 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_DEFAULT_RULES |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 598 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 599 | $$(error found $(4) expected $(COMPILER_TYPES)) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 600 | endif |
| 601 | endif |
| 602 | endif |
Andreas Gampe | 63fc30e | 2014-10-24 21:58:16 -0700 | [diff] [blame] | 603 | |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 604 | ifeq ($(5),relocate) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 605 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELOCATE_RULES |
| 606 | run_test_options += --relocate |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 607 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 608 | ifeq ($(5),no-relocate) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 609 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_RELOCATE_RULES |
| 610 | run_test_options += --no-relocate |
| 611 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 612 | ifeq ($(5),relocate-no-patchoat) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 613 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_RELOCATE_NO_PATCHOAT_RULES |
| 614 | run_test_options += --relocate --no-patchoat |
| 615 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 616 | $$(error found $(5) expected $(RELOCATE_TYPES)) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 617 | endif |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 618 | endif |
| 619 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 620 | ifeq ($(6),trace) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 621 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_TRACE_RULES |
Ian Rogers | 716e4f8 | 2014-07-16 11:18:03 -0700 | [diff] [blame] | 622 | run_test_options += --trace |
Ian Rogers | 716e4f8 | 2014-07-16 11:18:03 -0700 | [diff] [blame] | 623 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 624 | ifeq ($(6),no-trace) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 625 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_TRACE_RULES |
Ian Rogers | 701aa64 | 2014-07-18 11:38:13 -0700 | [diff] [blame] | 626 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 627 | $$(error found $(6) expected $(TRACE_TYPES)) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 628 | endif |
| 629 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 630 | ifeq ($(7),gcverify) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 631 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_GCVERIFY_RULES |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 632 | run_test_options += --gcverify |
| 633 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 634 | ifeq ($(7),gcstress) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 635 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_GCSTRESS_RULES |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 636 | run_test_options += --gcstress |
| 637 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 638 | ifeq ($(7),cms) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 639 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_CMS_RULES |
Ian Rogers | 8a14b75 | 2014-07-18 15:06:53 -0700 | [diff] [blame] | 640 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 641 | $$(error found $(7) expected $(GC_TYPES)) |
Ian Rogers | 701aa64 | 2014-07-18 11:38:13 -0700 | [diff] [blame] | 642 | endif |
Ian Rogers | 716e4f8 | 2014-07-16 11:18:03 -0700 | [diff] [blame] | 643 | endif |
| 644 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 645 | ifeq ($(8),forcecopy) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 646 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_FORCECOPY_RULES |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 647 | run_test_options += --runtime-option -Xjniopts:forcecopy |
| 648 | ifneq ($$(ART_TEST_JNI_FORCECOPY),true) |
| 649 | skip_test := true |
| 650 | endif |
| 651 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 652 | ifeq ($(8),checkjni) |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 653 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_CHECKJNI_RULES |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 654 | run_test_options += --runtime-option -Xcheck:jni |
| 655 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 656 | ifeq ($(8),jni) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 657 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_JNI_RULES |
| 658 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 659 | $$(error found $(8) expected $(JNI_TYPES)) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 660 | endif |
| 661 | endif |
| 662 | endif |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 663 | ifeq ($(9),no-image) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 664 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_NO_IMAGE_RULES |
| 665 | run_test_options += --no-image |
Andreas Gampe | bf03e84 | 2014-10-29 20:46:17 -0700 | [diff] [blame] | 666 | # Add the core dependency. This is required for pre-building. |
| 667 | ifeq ($(1),host) |
| 668 | prereq_rule += $(HOST_CORE_IMAGE_$(4)_no-pic_$(12)) |
| 669 | else |
| 670 | prereq_rule += $(TARGET_CORE_IMAGE_$(4)_no-pic_$(12)) |
| 671 | endif |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 672 | else |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 673 | ifeq ($(9),image) |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 674 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_IMAGE_RULES |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 675 | # Add the core dependency. |
| 676 | ifeq ($(1),host) |
| 677 | prereq_rule += $(HOST_CORE_IMAGE_$(4)_no-pic_$(12)) |
| 678 | else |
| 679 | prereq_rule += $(TARGET_CORE_IMAGE_$(4)_no-pic_$(12)) |
| 680 | endif |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 681 | else |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 682 | ifeq ($(9),picimage) |
| 683 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_PICIMAGE_RULES |
| 684 | run_test_options += --pic-image |
| 685 | ifeq ($(1),host) |
| 686 | prereq_rule += $(HOST_CORE_IMAGE_$(4)_pic_$(12)) |
| 687 | else |
| 688 | prereq_rule += $(TARGET_CORE_IMAGE_$(4)_pic_$(12)) |
| 689 | endif |
| 690 | else |
| 691 | $$(error found $(9) expected $(IMAGE_TYPES)) |
| 692 | endif |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 693 | endif |
| 694 | endif |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 695 | ifeq ($(10),pictest) |
| 696 | run_test_options += --pic-test |
| 697 | else |
| 698 | ifeq ($(10),nopictest) |
| 699 | # Nothing to be done. |
| 700 | else |
| 701 | $$(error found $(10) expected $(PICTEST_TYPES)) |
| 702 | endif |
| 703 | endif |
| 704 | # $(11) is the test name |
| 705 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_$(call name-to-var,$(11))_RULES |
| 706 | ifeq ($(12),64) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 707 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_64_RULES |
| 708 | run_test_options += --64 |
| 709 | else |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 710 | ifeq ($(12),32) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 711 | test_groups += ART_RUN_TEST_$$(uc_host_or_target)_32_RULES |
| 712 | else |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 713 | $$(error found $(12) expected $(ALL_ADDRESS_SIZES)) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 714 | endif |
| 715 | endif |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 716 | run_test_rule_name := test-art-$(1)-run-test-$(2)-$(3)-$(4)-$(5)-$(6)-$(7)-$(8)-$(9)-$(10)-$(11)$(12) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 717 | run_test_options := --output-path $(ART_HOST_TEST_DIR)/run-test-output/$$(run_test_rule_name) \ |
Ian Rogers | 5242c0a | 2014-07-18 11:02:19 -0700 | [diff] [blame] | 718 | $$(run_test_options) |
Nicolas Geoffray | c8f23fc | 2014-10-28 17:59:47 +0000 | [diff] [blame] | 719 | ifneq ($(ART_TEST_ANDROID_ROOT),) |
| 720 | run_test_options := --android-root $(ART_TEST_ANDROID_ROOT) $$(run_test_options) |
| 721 | endif |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 722 | $$(run_test_rule_name): PRIVATE_RUN_TEST_OPTIONS := $$(run_test_options) |
| 723 | .PHONY: $$(run_test_rule_name) |
Andreas Gampe | 8fda9f2 | 2014-10-03 16:15:37 -0700 | [diff] [blame] | 724 | $$(run_test_rule_name): $(DX) $(HOST_OUT_EXECUTABLES)/jasmin $(HOST_OUT_EXECUTABLES)/smali $(HOST_OUT_EXECUTABLES)/dexmerger $$(prereq_rule) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 725 | $(hide) $$(call ART_TEST_SKIP,$$@) && \ |
| 726 | DX=$(abspath $(DX)) JASMIN=$(abspath $(HOST_OUT_EXECUTABLES)/jasmin) \ |
Andreas Gampe | 8fda9f2 | 2014-10-03 16:15:37 -0700 | [diff] [blame] | 727 | SMALI=$(abspath $(HOST_OUT_EXECUTABLES)/smali) \ |
| 728 | DXMERGER=$(abspath $(HOST_OUT_EXECUTABLES)/dexmerger) \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 729 | art/test/run-test $$(PRIVATE_RUN_TEST_OPTIONS) $(11) \ |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 730 | && $$(call ART_TEST_PASSED,$$@) || $$(call ART_TEST_FAILED,$$@) |
| 731 | $$(hide) (echo $(MAKECMDGOALS) | grep -q $$@ && \ |
| 732 | echo "run-test run as top-level target, removing test directory $(ART_HOST_TEST_DIR)" && \ |
| 733 | rm -r $(ART_HOST_TEST_DIR)) || true |
| 734 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 735 | $$(foreach test_group,$$(test_groups), $$(eval $$(value test_group) += $$(run_test_rule_name))) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 736 | |
| 737 | # Clear locally defined variables. |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 738 | uc_host_or_target := |
| 739 | test_groups := |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 740 | run_test_options := |
| 741 | run_test_rule_name := |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 742 | prereq_rule := |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 743 | endef # define-test-art-run-test |
| 744 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 745 | $(foreach target, $(TARGET_TYPES), \ |
| 746 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 747 | $(foreach run_type, $(RUN_TYPES), \ |
| 748 | $(foreach address_size, $(ADDRESS_SIZES_$(call name-to-var,$(target))), \ |
| 749 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 750 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 751 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 752 | $(foreach trace, $(TRACE_TYPES), \ |
| 753 | $(foreach gc, $(GC_TYPES), \ |
| 754 | $(foreach jni, $(JNI_TYPES), \ |
| 755 | $(foreach image, $(IMAGE_TYPES), \ |
Andreas Gampe | c23c9c9 | 2014-10-28 14:47:25 -0700 | [diff] [blame] | 756 | $(foreach pictest, $(PICTEST_TYPES), \ |
| 757 | $(eval $(call define-test-art-run-test,$(target),$(run_type),$(prebuild),$(compiler),$(relocate),$(trace),$(gc),$(jni),$(image),$(pictest),$(test),$(address_size))) \ |
| 758 | )))))))))))) |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 759 | define-test-art-run-test := |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 760 | |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 761 | # Define a phony rule whose purpose is to test its prerequisites. |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 762 | # $(1): host or target |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 763 | # $(2): list of prerequisites |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 764 | define define-test-art-run-test-group |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 765 | .PHONY: $(1) |
| 766 | $(1): $(2) |
| 767 | $(hide) $$(call ART_TEST_PREREQ_FINISHED,$$@) |
| 768 | |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 769 | endef # define-test-art-run-test-group |
| 770 | |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 771 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 772 | $(foreach target, $(TARGET_TYPES), $(eval \ |
| 773 | $(call define-test-art-run-test-group,test-art-$(target)-run-test,$(ART_RUN_TEST_$(call name-to-var,$(target))_RULES)))) |
| 774 | $(foreach target, $(TARGET_TYPES), \ |
| 775 | $(foreach prebuild, $(PREBUILD_TYPES), $(eval \ |
| 776 | $(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))))) |
| 777 | $(foreach target, $(TARGET_TYPES), \ |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 778 | $(foreach run-type, $(RUN_TYPES), $(eval \ |
| 779 | $(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))))) |
| 780 | $(foreach target, $(TARGET_TYPES), \ |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 781 | $(foreach compiler, $(COMPILER_TYPES), $(eval \ |
| 782 | $(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))))) |
| 783 | $(foreach target, $(TARGET_TYPES), \ |
| 784 | $(foreach relocate, $(RELOCATE_TYPES), $(eval \ |
| 785 | $(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))))) |
| 786 | $(foreach target, $(TARGET_TYPES), \ |
| 787 | $(foreach trace, $(TRACE_TYPES), $(eval \ |
| 788 | $(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))))) |
| 789 | $(foreach target, $(TARGET_TYPES), \ |
| 790 | $(foreach gc, $(GC_TYPES), $(eval \ |
| 791 | $(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))))) |
| 792 | $(foreach target, $(TARGET_TYPES), \ |
| 793 | $(foreach jni, $(JNI_TYPES), $(eval \ |
| 794 | $(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))))) |
| 795 | $(foreach target, $(TARGET_TYPES), \ |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 796 | $(foreach image, $(IMAGE_TYPES), $(eval \ |
| 797 | $(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))))) |
| 798 | $(foreach target, $(TARGET_TYPES), \ |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 799 | $(foreach test, $(TEST_ART_RUN_TESTS), $(eval \ |
| 800 | $(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))))) |
| 801 | $(foreach target, $(TARGET_TYPES), \ |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 802 | $(foreach address_size, $(ADDRESS_SIZES_$(call name-to-var,$(target))), $(eval \ |
Ian Rogers | a3cf6ce | 2014-10-02 16:35:52 -0700 | [diff] [blame] | 803 | $(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))))) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 804 | |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 805 | # Clear variables now we're finished with them. |
| 806 | $(foreach target, $(TARGET_TYPES), $(eval ART_RUN_TEST_$(call name-to-var,$(target))_RULES :=)) |
| 807 | $(foreach target, $(TARGET_TYPES), \ |
| 808 | $(foreach prebuild, $(PREBUILD_TYPES), \ |
| 809 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(prebuild))_RULES :=))) |
| 810 | $(foreach target, $(TARGET_TYPES), \ |
| 811 | $(foreach compiler, $(COMPILER_TYPES), \ |
| 812 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(compiler))_RULES :=))) |
| 813 | $(foreach target, $(TARGET_TYPES), \ |
| 814 | $(foreach relocate, $(RELOCATE_TYPES), \ |
| 815 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(relocate))_RULES :=))) |
| 816 | $(foreach target, $(TARGET_TYPES), \ |
| 817 | $(foreach trace, $(TRACE_TYPES), \ |
| 818 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(trace))_RULES :=))) |
| 819 | $(foreach target, $(TARGET_TYPES), \ |
| 820 | $(foreach gc, $(GC_TYPES), \ |
| 821 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(gc))_RULES :=))) |
| 822 | $(foreach target, $(TARGET_TYPES), \ |
| 823 | $(foreach jni, $(JNI_TYPES), \ |
| 824 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(jni))_RULES :=))) |
| 825 | $(foreach target, $(TARGET_TYPES), \ |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 826 | $(foreach image, $(IMAGE_TYPES), \ |
| 827 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(image))_RULES :=))) |
| 828 | $(foreach target, $(TARGET_TYPES), \ |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 829 | $(foreach test, $(TEST_ART_RUN_TESTS), \ |
| 830 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(test))_RULES :=))) |
| 831 | $(foreach target, $(TARGET_TYPES), \ |
| 832 | $(foreach address_size, $(ALL_ADDRESS_SIZES), \ |
| 833 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(address_size))_RULES :=))) |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 834 | $(foreach target, $(TARGET_TYPES), \ |
| 835 | $(foreach run_type, $(RUN_TYPES), \ |
| 836 | $(eval ART_RUN_TEST_$(call name-to-var,$(target))_$(call name-to-var,$(run_type))_RULES :=))) |
Ian Rogers | afd9acc | 2014-06-17 08:21:54 -0700 | [diff] [blame] | 837 | define-test-art-run-test-group := |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 838 | TARGET_TYPES := |
| 839 | PREBUILD_TYPES := |
| 840 | COMPILER_TYPES := |
| 841 | RELOCATE_TYPES := |
| 842 | TRACE_TYPES := |
| 843 | GC_TYPES := |
| 844 | JNI_TYPES := |
Alex Light | 03a112d | 2014-08-25 13:25:56 -0700 | [diff] [blame] | 845 | IMAGE_TYPES := |
Ian Rogers | 86df3ac | 2014-08-27 10:54:11 -0700 | [diff] [blame] | 846 | ADDRESS_SIZES_TARGET := |
| 847 | ADDRESS_SIZES_HOST := |
Ian Rogers | f5c44b3 | 2014-08-19 16:52:36 -0700 | [diff] [blame] | 848 | ALL_ADDRESS_SIZES := |
Nicolas Geoffray | bd2c63c | 2014-10-16 18:04:12 +0100 | [diff] [blame] | 849 | RUN_TYPES := |
Ian Rogers | 9fcaa4b | 2014-08-26 19:59:52 -0700 | [diff] [blame] | 850 | |
| 851 | include $(LOCAL_PATH)/Android.libarttest.mk |
| 852 | include art/test/Android.libnativebridgetest.mk |