1# Copyright 2012 the V8 project authors. All rights reserved. 2# Redistribution and use in source and binary forms, with or without 3# modification, are permitted provided that the following conditions are 4# met: 5# 6# * Redistributions of source code must retain the above copyright 7# notice, this list of conditions and the following disclaimer. 8# * Redistributions in binary form must reproduce the above 9# copyright notice, this list of conditions and the following 10# disclaimer in the documentation and/or other materials provided 11# with the distribution. 12# * Neither the name of Google Inc. nor the names of its 13# contributors may be used to endorse or promote products derived 14# from this software without specific prior written permission. 15# 16# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 17# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 18# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 19# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 20# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 21# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 22# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 24# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 25# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 26# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 28# Please keep this file in sync with BUILD.gn. 29 30{ 31 'variables': { 32 'v8_code': 1, 33 'generated_file': '<(SHARED_INTERMEDIATE_DIR)/resources.cc', 34 }, 35 'includes': ['../../gypfiles/toolchain.gypi', '../../gypfiles/features.gypi'], 36 'targets': [ 37 { 38 'target_name': 'cctest', 39 'type': 'executable', 40 'dependencies': [ 41 'resources', 42 '../../src/v8.gyp:v8_libplatform', 43 ], 44 'include_dirs': [ 45 '../..', 46 ], 47 'sources': [ ### gcmole(all) ### 48 '<(generated_file)', 49 'compiler/c-signature.h', 50 'compiler/codegen-tester.cc', 51 'compiler/codegen-tester.h', 52 'compiler/code-assembler-tester.h', 53 'compiler/function-tester.h', 54 'compiler/graph-builder-tester.h', 55 'compiler/test-basic-block-profiler.cc', 56 'compiler/test-branch-combine.cc', 57 'compiler/test-gap-resolver.cc', 58 'compiler/test-graph-visualizer.cc', 59 'compiler/test-code-assembler.cc', 60 'compiler/test-instruction.cc', 61 'compiler/test-js-context-specialization.cc', 62 'compiler/test-js-constant-cache.cc', 63 'compiler/test-js-typed-lowering.cc', 64 'compiler/test-jump-threading.cc', 65 'compiler/test-linkage.cc', 66 'compiler/test-loop-assignment-analysis.cc', 67 'compiler/test-loop-analysis.cc', 68 'compiler/test-machine-operator-reducer.cc', 69 'compiler/test-multiple-return.cc', 70 'compiler/test-node.cc', 71 'compiler/test-operator.cc', 72 'compiler/test-osr.cc', 73 'compiler/test-representation-change.cc', 74 'compiler/test-run-bytecode-graph-builder.cc', 75 'compiler/test-run-calls-to-external-references.cc', 76 'compiler/test-run-deopt.cc', 77 'compiler/test-run-inlining.cc', 78 'compiler/test-run-intrinsics.cc', 79 'compiler/test-run-jsbranches.cc', 80 'compiler/test-run-jscalls.cc', 81 'compiler/test-run-jsexceptions.cc', 82 'compiler/test-run-jsobjects.cc', 83 'compiler/test-run-jsops.cc', 84 'compiler/test-run-load-store.cc', 85 'compiler/test-run-machops.cc', 86 'compiler/test-run-native-calls.cc', 87 'compiler/test-run-stackcheck.cc', 88 'compiler/test-run-stubs.cc', 89 'compiler/test-run-variables.cc', 90 'compiler/test-run-wasm-machops.cc', 91 'compiler/test-simplified-lowering.cc', 92 'cctest.cc', 93 'expression-type-collector.cc', 94 'expression-type-collector.h', 95 'interpreter/interpreter-tester.cc', 96 'interpreter/source-position-matcher.cc', 97 'interpreter/source-position-matcher.h', 98 'interpreter/test-bytecode-generator.cc', 99 'interpreter/test-interpreter.cc', 100 'interpreter/test-interpreter-intrinsics.cc', 101 'interpreter/test-source-positions.cc', 102 'interpreter/bytecode-expectations-printer.cc', 103 'interpreter/bytecode-expectations-printer.h', 104 'gay-fixed.cc', 105 'gay-precision.cc', 106 'gay-shortest.cc', 107 'heap/heap-tester.h', 108 'heap/heap-utils.cc', 109 'heap/heap-utils.h', 110 'heap/test-alloc.cc', 111 'heap/test-array-buffer-tracker.cc', 112 'heap/test-compaction.cc', 113 'heap/test-heap.cc', 114 'heap/test-incremental-marking.cc', 115 'heap/test-lab.cc', 116 'heap/test-mark-compact.cc', 117 'heap/test-page-promotion.cc', 118 'heap/test-spaces.cc', 119 'libsampler/test-sampler.cc', 120 'print-extension.cc', 121 'profiler-extension.cc', 122 'test-access-checks.cc', 123 'test-accessors.cc', 124 'test-api.cc', 125 'test-api.h', 126 'test-api-accessors.cc', 127 'test-api-interceptors.cc', 128 'test-api-fast-accessor-builder.cc', 129 'test-array-list.cc', 130 'test-ast.cc', 131 'test-ast-expression-visitor.cc', 132 'test-asm-validator.cc', 133 'test-atomicops.cc', 134 'test-bignum.cc', 135 'test-bignum-dtoa.cc', 136 'test-bit-vector.cc', 137 'test-circular-queue.cc', 138 'test-code-cache.cc', 139 'test-code-layout.cc', 140 'test-code-stub-assembler.cc', 141 'test-compiler.cc', 142 'test-constantpool.cc', 143 'test-conversions.cc', 144 'test-cpu-profiler.cc', 145 'test-date.cc', 146 'test-debug.cc', 147 'test-decls.cc', 148 'test-deoptimization.cc', 149 'test-dictionary.cc', 150 'test-diy-fp.cc', 151 'test-double.cc', 152 'test-dtoa.cc', 153 'test-elements-kind.cc', 154 'test-eh-frame-hdr.cc', 155 'test-fast-dtoa.cc', 156 'test-feedback-vector.cc', 157 'test-field-type-tracking.cc', 158 'test-fixed-dtoa.cc', 159 'test-flags.cc', 160 'test-func-name-inference.cc', 161 'test-global-handles.cc', 162 'test-global-object.cc', 163 'test-hashing.cc', 164 'test-hashmap.cc', 165 'test-heap-profiler.cc', 166 'test-hydrogen-types.cc', 167 'test-identity-map.cc', 168 'test-inobject-slack-tracking.cc', 169 'test-list.cc', 170 'test-liveedit.cc', 171 'test-lockers.cc', 172 'test-log.cc', 173 'test-mementos.cc', 174 'test-parsing.cc', 175 'test-platform.cc', 176 'test-profile-generator.cc', 177 'test-random-number-generator.cc', 178 'test-receiver-check-hidden-prototype.cc', 179 'test-regexp.cc', 180 'test-reloc-info.cc', 181 'test-representation.cc', 182 'test-sampler-api.cc', 183 'test-serialize.cc', 184 'test-simd.cc', 185 'test-strings.cc', 186 'test-symbols.cc', 187 'test-strtod.cc', 188 'test-thread-termination.cc', 189 'test-threads.cc', 190 'test-trace-event.cc', 191 'test-transitions.cc', 192 'test-typedarrays.cc', 193 'test-types.cc', 194 'test-unbound-queue.cc', 195 'test-unboxed-doubles.cc', 196 'test-unique.cc', 197 'test-unscopables-hidden-prototype.cc', 198 'test-usecounters.cc', 199 'test-utils.cc', 200 'test-version.cc', 201 'test-weakmaps.cc', 202 'test-weaksets.cc', 203 'trace-extension.cc', 204 'wasm/test-run-wasm.cc', 205 'wasm/test-run-wasm-64.cc', 206 'wasm/test-run-wasm-asmjs.cc', 207 'wasm/test-run-wasm-interpreter.cc', 208 'wasm/test-run-wasm-js.cc', 209 'wasm/test-run-wasm-module.cc', 210 'wasm/test-signatures.h', 211 'wasm/test-wasm-function-name-table.cc', 212 'wasm/test-run-wasm-relocation.cc', 213 'wasm/test-wasm-stack.cc', 214 'wasm/test-wasm-trap-position.cc', 215 'wasm/wasm-run-utils.h', 216 ], 217 'conditions': [ 218 ['v8_target_arch=="ia32"', { 219 'sources': [ ### gcmole(arch:ia32) ### 220 'test-assembler-ia32.cc', 221 'test-code-stubs.cc', 222 'test-code-stubs-ia32.cc', 223 'test-disasm-ia32.cc', 224 'test-macro-assembler-ia32.cc', 225 'test-log-stack-tracer.cc', 226 'test-run-wasm-relocation-ia32.cc' 227 ], 228 }], 229 ['v8_target_arch=="x64"', { 230 'sources': [ ### gcmole(arch:x64) ### 231 'test-assembler-x64.cc', 232 'test-code-stubs.cc', 233 'test-code-stubs-x64.cc', 234 'test-disasm-x64.cc', 235 'test-macro-assembler-x64.cc', 236 'test-log-stack-tracer.cc', 237 'test-run-wasm-relocation-x64.cc' 238 ], 239 }], 240 ['v8_target_arch=="arm"', { 241 'sources': [ ### gcmole(arch:arm) ### 242 'test-assembler-arm.cc', 243 'test-code-stubs.cc', 244 'test-code-stubs-arm.cc', 245 'test-disasm-arm.cc', 246 'test-macro-assembler-arm.cc', 247 'test-run-wasm-relocation-arm.cc' 248 ], 249 }], 250 ['v8_target_arch=="arm64"', { 251 'sources': [ ### gcmole(arch:arm64) ### 252 'test-utils-arm64.cc', 253 'test-assembler-arm64.cc', 254 'test-code-stubs.cc', 255 'test-code-stubs-arm64.cc', 256 'test-disasm-arm64.cc', 257 'test-fuzz-arm64.cc', 258 'test-javascript-arm64.cc', 259 'test-js-arm64-variables.cc', 260 'test-run-wasm-relocation-arm64.cc' 261 ], 262 }], 263 ['v8_target_arch=="s390"', { 264 'sources': [ ### gcmole(arch:s390) ### 265 'test-assembler-s390.cc', 266 'test-code-stubs.cc', 267 'test-disasm-s390.cc' 268 ], 269 }], 270 ['v8_target_arch=="s390x"', { 271 'sources': [ ### gcmole(arch:s390x) ### 272 'test-assembler-s390.cc', 273 'test-code-stubs.cc', 274 'test-disasm-s390.cc' 275 ], 276 }], 277 ['v8_target_arch=="ppc"', { 278 'sources': [ ### gcmole(arch:ppc) ### 279 'test-assembler-ppc.cc', 280 'test-code-stubs.cc', 281 'test-disasm-ppc.cc' 282 ], 283 }], 284 ['v8_target_arch=="ppc64"', { 285 'sources': [ ### gcmole(arch:ppc64) ### 286 'test-assembler-ppc.cc', 287 'test-code-stubs.cc', 288 'test-disasm-ppc.cc' 289 ], 290 }], 291 ['v8_target_arch=="mips"', { 292 'sources': [ ### gcmole(arch:mips) ### 293 'test-assembler-mips.cc', 294 'test-code-stubs.cc', 295 'test-code-stubs-mips.cc', 296 'test-disasm-mips.cc', 297 'test-macro-assembler-mips.cc' 298 ], 299 }], 300 ['v8_target_arch=="mipsel"', { 301 'sources': [ ### gcmole(arch:mipsel) ### 302 'test-assembler-mips.cc', 303 'test-code-stubs.cc', 304 'test-code-stubs-mips.cc', 305 'test-disasm-mips.cc', 306 'test-macro-assembler-mips.cc' 307 ], 308 }], 309 ['v8_target_arch=="mips64"', { 310 'sources': [ ### gcmole(arch:mips64) ### 311 'test-assembler-mips64.cc', 312 'test-code-stubs.cc', 313 'test-code-stubs-mips64.cc', 314 'test-disasm-mips64.cc', 315 'test-macro-assembler-mips64.cc' 316 ], 317 }], 318 ['v8_target_arch=="mips64el"', { 319 'sources': [ ### gcmole(arch:mips64el) ### 320 'test-assembler-mips64.cc', 321 'test-code-stubs.cc', 322 'test-code-stubs-mips64.cc', 323 'test-disasm-mips64.cc', 324 'test-macro-assembler-mips64.cc' 325 ], 326 }], 327 ['v8_target_arch=="x87"', { 328 'sources': [ ### gcmole(arch:x87) ### 329 'test-assembler-x87.cc', 330 'test-code-stubs.cc', 331 'test-code-stubs-x87.cc', 332 'test-disasm-x87.cc', 333 'test-macro-assembler-x87.cc', 334 'test-log-stack-tracer.cc', 335 'test-run-wasm-relocation-x87.cc' 336 ], 337 }], 338 [ 'OS=="linux" or OS=="qnx"', { 339 'sources': [ 340 'test-platform-linux.cc', 341 ], 342 }], 343 [ 'OS=="win"', { 344 'sources': [ 345 'test-platform-win32.cc', 346 ], 347 'msvs_settings': { 348 'VCCLCompilerTool': { 349 # MSVS wants this for gay-{precision,shortest}.cc. 350 'AdditionalOptions': ['/bigobj'], 351 }, 352 }, 353 }], 354 ['v8_target_arch=="ppc" or v8_target_arch=="ppc64" \ 355 or v8_target_arch=="arm" or v8_target_arch=="arm64" \ 356 or v8_target_arch=="s390" or v8_target_arch=="s390x"', { 357 # disable fmadd/fmsub so that expected results match generated code in 358 # RunFloat64MulAndFloat64Add1 and friends. 359 'cflags': ['-ffp-contract=off'], 360 }], 361 ['OS=="aix"', { 362 'ldflags': [ '-Wl,-bbigtoc' ], 363 }], 364 ['component=="shared_library"', { 365 # cctest can't be built against a shared library, so we need to 366 # depend on the underlying static target in that case. 367 'dependencies': ['../../src/v8.gyp:v8_maybe_snapshot'], 368 }, { 369 'dependencies': ['../../src/v8.gyp:v8'], 370 }], 371 ], 372 }, 373 { 374 'target_name': 'resources', 375 'type': 'none', 376 'variables': { 377 'file_list': [ 378 '../../tools/splaytree.js', 379 '../../tools/codemap.js', 380 '../../tools/csvparser.js', 381 '../../tools/consarray.js', 382 '../../tools/profile.js', 383 '../../tools/profile_view.js', 384 '../../tools/logreader.js', 385 'log-eq-of-logging-and-traversal.js', 386 ], 387 }, 388 'actions': [ 389 { 390 'action_name': 'js2c', 391 'inputs': [ 392 '../../tools/js2c.py', 393 '<@(file_list)', 394 ], 395 'outputs': [ 396 '<(generated_file)', 397 ], 398 'action': [ 399 'python', 400 '../../tools/js2c.py', 401 '<@(_outputs)', 402 'TEST', # type 403 '<@(file_list)', 404 ], 405 } 406 ], 407 }, 408 { 409 'target_name': 'generate-bytecode-expectations', 410 'type': 'executable', 411 'dependencies': [ 412 '../../src/v8.gyp:v8_libplatform', 413 ], 414 'conditions': [ 415 ['component=="shared_library"', { 416 # Same as cctest, we need to depend on the underlying static target. 417 'dependencies': ['../../src/v8.gyp:v8_maybe_snapshot'], 418 }, { 419 'dependencies': ['../../src/v8.gyp:v8'], 420 }], 421 ], 422 'include_dirs+': [ 423 '../..', 424 ], 425 'sources': [ 426 'interpreter/bytecode-expectations-printer.cc', 427 'interpreter/bytecode-expectations-printer.h', 428 'interpreter/generate-bytecode-expectations.cc', 429 ], 430 }, 431 ], 432 'conditions': [ 433 ['test_isolation_mode != "noop"', { 434 'targets': [ 435 { 436 'target_name': 'cctest_exe_run', 437 'type': 'none', 438 'dependencies': [ 439 'cctest', 440 ], 441 'includes': [ 442 '../../gypfiles/isolate.gypi', 443 ], 444 'sources': [ 445 'cctest_exe.isolate', 446 ], 447 }, 448 { 449 'target_name': 'cctest_run', 450 'type': 'none', 451 'dependencies': [ 452 'cctest_exe_run', 453 ], 454 'includes': [ 455 '../../gypfiles/isolate.gypi', 456 ], 457 'sources': [ 458 'cctest.isolate', 459 ], 460 }, 461 ], 462 }], 463 ], 464} 465