blob: 6a57763ece26ee5fda59d0e04dde25e80a8f0926 [file] [log] [blame]
Ben Murdoch3ef787d2012-04-12 10:51:47 +01001# Copyright 2012 the V8 project authors. All rights reserved.
Ben Murdochb0fe1622011-05-05 13:52:32 +01002# 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{
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000029 'variables': {
Ben Murdochb8a8cc12014-11-26 15:28:44 +000030 'v8_code': 1,
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000031 'generated_file': '<(SHARED_INTERMEDIATE_DIR)/resources.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010032 },
Ben Murdochb8a8cc12014-11-26 15:28:44 +000033 'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
Ben Murdochb0fe1622011-05-05 13:52:32 +010034 'targets': [
35 {
36 'target_name': 'cctest',
37 'type': 'executable',
38 'dependencies': [
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000039 'resources',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000040 '../../tools/gyp/v8.gyp:v8_libplatform',
Ben Murdochb0fe1622011-05-05 13:52:32 +010041 ],
42 'include_dirs': [
Ben Murdochb8a8cc12014-11-26 15:28:44 +000043 '../..',
Ben Murdochb0fe1622011-05-05 13:52:32 +010044 ],
Ben Murdochb8a8cc12014-11-26 15:28:44 +000045 'sources': [ ### gcmole(all) ###
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000046 '<(generated_file)',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000047 'compiler/c-signature.h',
48 'compiler/codegen-tester.cc',
49 'compiler/codegen-tester.h',
50 'compiler/function-tester.h',
51 'compiler/graph-builder-tester.cc',
52 'compiler/graph-builder-tester.h',
53 'compiler/graph-tester.h',
54 'compiler/simplified-graph-builder.cc',
55 'compiler/simplified-graph-builder.h',
56 'compiler/test-branch-combine.cc',
57 'compiler/test-changes-lowering.cc',
58 'compiler/test-codegen-deopt.cc',
59 'compiler/test-gap-resolver.cc',
60 'compiler/test-graph-reducer.cc',
61 'compiler/test-instruction.cc',
62 'compiler/test-js-context-specialization.cc',
63 'compiler/test-js-constant-cache.cc',
64 'compiler/test-js-typed-lowering.cc',
65 'compiler/test-linkage.cc',
66 'compiler/test-machine-operator-reducer.cc',
67 'compiler/test-node-algorithm.cc',
68 'compiler/test-node-cache.cc',
69 'compiler/test-node.cc',
70 'compiler/test-operator.cc',
71 'compiler/test-phi-reducer.cc',
72 'compiler/test-pipeline.cc',
73 'compiler/test-representation-change.cc',
74 'compiler/test-run-deopt.cc',
75 'compiler/test-run-inlining.cc',
76 'compiler/test-run-intrinsics.cc',
77 'compiler/test-run-jsbranches.cc',
78 'compiler/test-run-jscalls.cc',
79 'compiler/test-run-jsexceptions.cc',
80 'compiler/test-run-jsops.cc',
81 'compiler/test-run-machops.cc',
82 'compiler/test-run-properties.cc',
83 'compiler/test-run-variables.cc',
84 'compiler/test-schedule.cc',
85 'compiler/test-scheduler.cc',
86 'compiler/test-simplified-lowering.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010087 'cctest.cc',
88 'gay-fixed.cc',
89 'gay-precision.cc',
90 'gay-shortest.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000091 'print-extension.cc',
92 'profiler-extension.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010093 'test-accessors.cc',
94 'test-alloc.cc',
95 'test-api.cc',
96 'test-ast.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000097 'test-atomicops.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010098 'test-bignum.cc',
99 'test-bignum-dtoa.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000100 'test-checks.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100101 'test-circular-queue.cc',
102 'test-compiler.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000103 'test-constantpool.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100104 'test-conversions.cc',
105 'test-cpu-profiler.cc',
106 'test-dataflow.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100107 'test-date.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100108 'test-debug.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000109 'test-declarative-accessors.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100110 'test-decls.cc',
111 'test-deoptimization.cc',
Ben Murdoch69a99ed2011-11-30 16:03:39 +0000112 'test-dictionary.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100113 'test-diy-fp.cc',
114 'test-double.cc',
115 'test-dtoa.cc',
116 'test-fast-dtoa.cc',
117 'test-fixed-dtoa.cc',
118 'test-flags.cc',
119 'test-func-name-inference.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000120 'test-gc-tracer.cc',
121 'test-global-handles.cc',
122 'test-global-object.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100123 'test-hashing.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100124 'test-hashmap.cc',
125 'test-heap.cc',
126 'test-heap-profiler.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000127 'test-hydrogen-types.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100128 'test-list.cc',
129 'test-liveedit.cc',
Ben Murdoch257744e2011-11-30 15:57:28 +0000130 'test-lockers.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100131 'test-log.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000132 'test-microtask-delivery.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100133 'test-mark-compact.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000134 'test-mementos.cc',
135 'test-object-observe.cc',
136 'test-ordered-hash-table.cc',
137 'test-ostreams.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100138 'test-parsing.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000139 'test-platform.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100140 'test-profile-generator.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000141 'test-random-number-generator.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100142 'test-regexp.cc',
143 'test-reloc-info.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000144 'test-representation.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100145 'test-serialize.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100146 'test-spaces.cc',
147 'test-strings.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000148 'test-symbols.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100149 'test-strtod.cc',
150 'test-thread-termination.cc',
151 'test-threads.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000152 'test-types.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100153 'test-unbound-queue.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000154 'test-unique.cc',
155 'test-unscopables-hidden-prototype.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100156 'test-utils.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100157 'test-version.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000158 'test-weakmaps.cc',
159 'test-weaksets.cc',
160 'test-weaktypedarrays.cc',
161 'trace-extension.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100162 ],
163 'conditions': [
164 ['v8_target_arch=="ia32"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000165 'sources': [ ### gcmole(arch:ia32) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100166 'test-assembler-ia32.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000167 'test-code-stubs.cc',
168 'test-code-stubs-ia32.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100169 'test-disasm-ia32.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000170 'test-macro-assembler-ia32.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100171 'test-log-stack-tracer.cc'
172 ],
173 }],
174 ['v8_target_arch=="x64"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000175 'sources': [ ### gcmole(arch:x64) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100176 'test-assembler-x64.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000177 'test-code-stubs.cc',
178 'test-code-stubs-x64.cc',
179 'test-disasm-x64.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100180 'test-macro-assembler-x64.cc',
181 'test-log-stack-tracer.cc'
182 ],
183 }],
184 ['v8_target_arch=="arm"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000185 'sources': [ ### gcmole(arch:arm) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100186 'test-assembler-arm.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000187 'test-code-stubs.cc',
188 'test-code-stubs-arm.cc',
189 'test-disasm-arm.cc',
190 'test-macro-assembler-arm.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100191 ],
192 }],
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000193 ['v8_target_arch=="arm64"', {
194 'sources': [ ### gcmole(arch:arm64) ###
195 'test-utils-arm64.cc',
196 'test-assembler-arm64.cc',
197 'test-code-stubs.cc',
198 'test-code-stubs-arm64.cc',
199 'test-disasm-arm64.cc',
200 'test-fuzz-arm64.cc',
201 'test-javascript-arm64.cc',
202 'test-js-arm64-variables.cc'
203 ],
204 }],
205 ['v8_target_arch=="mipsel"', {
206 'sources': [ ### gcmole(arch:mipsel) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100207 'test-assembler-mips.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000208 'test-code-stubs.cc',
209 'test-code-stubs-mips.cc',
Ben Murdoch257744e2011-11-30 15:57:28 +0000210 'test-disasm-mips.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000211 'test-macro-assembler-mips.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100212 ],
213 }],
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000214 ['v8_target_arch=="mips64el"', {
215 'sources': [
216 'test-assembler-mips64.cc',
217 'test-code-stubs.cc',
218 'test-code-stubs-mips64.cc',
219 'test-disasm-mips64.cc',
220 'test-macro-assembler-mips64.cc'
221 ],
222 }],
223 ['v8_target_arch=="x87"', {
224 'sources': [ ### gcmole(arch:x87) ###
225 'test-assembler-x87.cc',
226 'test-code-stubs.cc',
227 'test-code-stubs-x87.cc',
228 'test-disasm-x87.cc',
229 'test-macro-assembler-x87.cc',
230 'test-log-stack-tracer.cc'
231 ],
232 }],
233 [ 'OS=="linux" or OS=="qnx"', {
Ben Murdochb0fe1622011-05-05 13:52:32 +0100234 'sources': [
235 'test-platform-linux.cc',
236 ],
237 }],
Ben Murdochb0fe1622011-05-05 13:52:32 +0100238 [ 'OS=="win"', {
239 'sources': [
240 'test-platform-win32.cc',
241 ],
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100242 'msvs_settings': {
243 'VCCLCompilerTool': {
244 # MSVS wants this for gay-{precision,shortest}.cc.
245 'AdditionalOptions': ['/bigobj'],
246 },
247 },
Ben Murdochb0fe1622011-05-05 13:52:32 +0100248 }],
Ben Murdoch589d6972011-11-30 16:04:58 +0000249 ['component=="shared_library"', {
250 # cctest can't be built against a shared library, so we need to
251 # depend on the underlying static target in that case.
252 'conditions': [
253 ['v8_use_snapshot=="true"', {
254 'dependencies': ['../../tools/gyp/v8.gyp:v8_snapshot'],
255 },
256 {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000257 'dependencies': [
258 '../../tools/gyp/v8.gyp:v8_nosnapshot',
259 ],
Ben Murdoch589d6972011-11-30 16:04:58 +0000260 }],
261 ],
262 }, {
263 'dependencies': ['../../tools/gyp/v8.gyp:v8'],
264 }],
Ben Murdochb0fe1622011-05-05 13:52:32 +0100265 ],
266 },
Ben Murdoch3fb3ca82011-12-02 17:19:32 +0000267 {
268 'target_name': 'resources',
269 'type': 'none',
270 'variables': {
271 'file_list': [
272 '../../tools/splaytree.js',
273 '../../tools/codemap.js',
274 '../../tools/csvparser.js',
275 '../../tools/consarray.js',
276 '../../tools/profile.js',
277 '../../tools/profile_view.js',
278 '../../tools/logreader.js',
279 'log-eq-of-logging-and-traversal.js',
280 ],
281 },
282 'actions': [
283 {
284 'action_name': 'js2c',
285 'inputs': [
286 '../../tools/js2c.py',
287 '<@(file_list)',
288 ],
289 'outputs': [
290 '<(generated_file)',
291 ],
292 'action': [
293 'python',
294 '../../tools/js2c.py',
295 '<@(_outputs)',
296 'TEST', # type
297 'off', # compression
298 '<@(file_list)',
299 ],
300 }
301 ],
302 },
Ben Murdochb0fe1622011-05-05 13:52:32 +0100303 ],
304}