Commit graph

55 commits

Author SHA1 Message Date
Zach Anderson d0510501d2 [build] Add -a kbc for interpreter
This CL adds support to build.py and test.py for building/testing
a VM with the interpreter on x64, e.g.:

$ ./tools/gn.py -m release -a x64 --bytecode
$ ./tools/build.py -m release -a x64 --bytecode runtime
$ ./tools/test.py -m release -a x64 -r vm -c dartkb language_2

Change-Id: I956d23790636609d4a2e71129481fcbd7afef9a0
Reviewed-on: https://dart-review.googlesource.com/65206
Commit-Queue: Zach Anderson <zra@google.com>
Reviewed-by: Régis Crelier <regis@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-07-17 21:51:41 +00:00
Ben Konyi e35ed9c749 [ VM / Build ] Added '--no-include-kernel-service' to build.py. By default, the kernel service is now included in all build modes, including product mode. Providing '--no-include-kernel-service' will build the specified configuration without the kernel service.
Change-Id: I682cd7c2895a9bcb215948615f2bdc627abe8d08
Reviewed-on: https://dart-review.googlesource.com/56286
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Zach Anderson <zra@google.com>
2018-05-23 20:35:53 +00:00
Zach Anderson d2b7787186 [infra] Use downloaded sysroots by default
Change-Id: I6bd6e369775182acb4aa5933360282af47024018
Reviewed-on: https://dart-review.googlesource.com/45762
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-03-09 09:02:05 +00:00
Zach Anderson 8240134d66 [infra] Roll boringssl forward. Use clang for arm on Linux.
fixes: #32363
Change-Id: I68c3ea314b320e51e0dcbdc98b71cf3150800837
Reviewed-on: https://dart-review.googlesource.com/45742
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-03-08 18:09:28 +00:00
Zach Anderson 6810d4604b [infra] Roll toolchain.
related #32364, #32363, #32362

Change-Id: Ia8ac3af0317fc67efb2a38e506b2924780473b8f
Reviewed-on: https://dart-review.googlesource.com/44400
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-03-01 20:09:29 +00:00
Zach Anderson 98a42402cc Revert "[infra] Use wheezy sysroot for local builds on linux."
This reverts commit 4678cdaa24.

Reason for revert: This broke gcc arm builds.

Original change's description:
> [infra] Use wheezy sysroot for local builds on linux.
> 
> I had though that this is how things already worked, but it wasn't.
> 
> Change-Id: Iaa6b4e7d9e791f3fad29431c5715fcb19df8a76b
> Reviewed-on: https://dart-review.googlesource.com/40840
> Reviewed-by: Siva Annamalai <asiva@google.com>
> Commit-Queue: Zach Anderson <zra@google.com>

TBR=rmacnak@google.com,zra@google.com,asiva@google.com

Change-Id: I013fe2d3736acdcb8ce7d1ec959419f20aa0aa54
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/41340
Reviewed-by: Zach Anderson <zra@google.com>
2018-02-14 16:41:45 +00:00
Zach Anderson 3b2e4076d3 Revert "[infra] Fix asan build"
This reverts commit 41eef1cbb5.

Reason for revert: Backing out to revert:
[infra] Use wheezy sysroot for local builds on linux.

Original change's description:
> [infra] Fix asan build
> 
> Change-Id: Ib5b1efbf12bdf7455e2c9d32c37ce5a06ed3195b
> Reviewed-on: https://dart-review.googlesource.com/41000
> Reviewed-by: Zach Anderson <zra@google.com>
> Reviewed-by: Ryan Macnak <rmacnak@google.com>
> Commit-Queue: Zach Anderson <zra@google.com>

TBR=rmacnak@google.com,zra@google.com

Change-Id: Ica54f78a98784aa7e1b40f8c7e113298606255c9
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/41341
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-02-14 16:41:29 +00:00
Zach Anderson 41eef1cbb5 [infra] Fix asan build
Change-Id: Ib5b1efbf12bdf7455e2c9d32c37ce5a06ed3195b
Reviewed-on: https://dart-review.googlesource.com/41000
Reviewed-by: Zach Anderson <zra@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-02-13 21:10:24 +00:00
Zach Anderson 4678cdaa24 [infra] Use wheezy sysroot for local builds on linux.
I had though that this is how things already worked, but it wasn't.

Change-Id: Iaa6b4e7d9e791f3fad29431c5715fcb19df8a76b
Reviewed-on: https://dart-review.googlesource.com/40840
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-02-13 19:11:24 +00:00
Zachary Anderson e625b39414 [infra] Add env var for extra GN args
Change-Id: Ifcc61f8c242c7e69e963187b9bae379f7d5b7f0f
Reviewed-on: https://dart-review.googlesource.com/33480
Commit-Queue: Zach Anderson <zra@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2018-01-09 19:26:58 +00:00
Zachary Anderson d9eb629ffa [infra] Use Clang for ia32 and arm64. Use the dl'd sysroots by default.
This CL switches the ia32 and arm64 builds to use clang by default.
The arm build can't be switched at least until we roll clang to
pick up the fix for https://reviews.llvm.org/D34691.

This CL also changes to use the sysroots from wheezy (and jessie
for arm64) by default so that we can be building/testing locally with
the same setup as we are shipping in the SDK.

Change-Id: I09a1907ee7f78c3f4bb8d56ffdbbd6107ed054d9
Reviewed-on: https://dart-review.googlesource.com/25160
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2017-12-02 06:19:33 +00:00
Alexander Aprelev 1d50f112dc Flutter and Fuchsia build stripped down [platform] version of dart sdk, so make it default(while standalone builds full dart sdk)
Both Flutter and Fuchsia expect stripped dart in standard out directory, so make that default too(while standalone build puts stripped into exe.stripped/).

BUG=
R=zra@google.com

Review-Url: https://codereview.chromium.org/2998503002 .
2017-08-08 14:42:11 -07:00
Ryan Macnak be95b916dd GN: Change the default meaning of dart_target_arch from current_cpu to target_cpu.
Update args.gn for the simulator builds to compensate.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2980023002 .
2017-07-13 14:59:35 -07:00
Zachary Anderson 1a8174b08d Exclude Observatory assets from PRODUCT build dart, dart_precompiled_runtime
This CL also removes some compiler flags that increase space somewhat
that help the profiler find symbols, which isn't included in a PRODUCT
build.

Before:
zra@zach:~/dart/sdk$ ls -la out/ProductX64/exe.stripped/
-rwxr-x--- 1 zra eng  9693064 Jun 29 14:52 dart
-rwxr-x--- 1 zra eng  7391080 Jun 29 14:52 dart_precompiled_runtime

R=askesc@google.com, rmacnak@google.com

After:
-rwxr-x--- 1 zra eng  6809424 Jun 29 15:11 dart
-rwxr-x--- 1 zra eng  3299120 Jun 29 15:11 dart_precompiled_runtime
Review-Url: https://codereview.chromium.org/2964133002 .
2017-06-30 08:09:37 -07:00
Alexander Aprelev 501688de4c Drop custom dart_host_sdk used for Flutter.
Instead have Flutter fetch prebuilt host sdk into same location where standalone dart expects it.

BUG=
R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2963053002 .
2017-06-29 13:18:43 -07:00
Zachary Anderson ac16656161 Remove MIPS support
R=asiva@google.com

Review-Url: https://codereview.chromium.org/2858623002 .
2017-06-22 08:49:22 -07:00
Ryan Macnak 76df24b076 CoreJIT snapshots without training.
Only include OSR and field guards in the features descriptor for JIT code to avoid gen_snapshot and dart having different default values.

Disabled since core snapshots with code break tests with non-default flags for type checks, assertions, strict errors, OSR, or field guards.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2902313004 .
2017-05-31 13:49:12 -07:00
Zachary Anderson 467dad857e Adds deprecation messages for MIPS cross-builds
fixes #29678

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2899803002 .
2017-05-22 13:35:23 -07:00
Zachary Anderson 34f601a8db Fix ARMv6 Linux cross-build
related #29676

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2892413002 .
2017-05-22 13:15:33 -07:00
Zachary Anderson 81e428fd39 [infra] Assembles the SDK using GN rather than create_sdk.py
This has a few advantages:
- We can track dependencies more precisely
- ninja can assemble things in parallel as they're ready rather than
  sequentially all at once.
- It is easier to customize SDKs depending on target platform, e.g.
  Fuchsia.

This CL also has a number of cleanups:
- Defining is_fuchsia and is_fuchsia host so we don't always have to check
- Piping through toolchain overrides in more places
- Fixing bugs in copy_tree.py, not using list_files.py, which is broken on Windows

related #29558

R=whesse@google.com

Review-Url: https://codereview.chromium.org/2848943003 .
2017-05-20 23:30:09 -07:00
Zachary Anderson 6225b1f4b1 [infra] Ignore wheezy sysroot for Linux ARM cross-builds
Fixes Linux SDK buildbot

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2870963002 .
2017-05-09 10:22:15 -07:00
Ryan Macnak 98d31056a7 Change build.py to be like ninja.py and only use a single GN/Ninja invocation to cross-build the SDK. This step alone would fix #29580. This breaks cross-building the SDK with GYP.
Remove hack in bin/snapshot_utils.cc that avoided building a true app-jit snapshot for ARM, ARM64 and MIPS because of the multiple invocations above.

Add GN flags to choose to build script snapshots instead of app-jit snapshots, avoiding a slow training run inside a simulator.

Fixes #29580.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2871713002 .
2017-05-08 13:06:09 -07:00
Zachary Anderson 0d0d97d7a0 [infra] Cleanup buildfile generation scripts a bit
R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2871683002 .
2017-05-08 12:31:43 -07:00
Vyacheslav Egorov c162e0f011 GN: On Linux still fallback to GCC for ARM64 build.
We don't have clang arm64 toolchain.

BUG=
R=kustermann@google.com, sortie@google.com

Review-Url: https://codereview.chromium.org/2867733002 .
2017-05-08 11:30:32 +02:00
Zach Anderson 726732dd6b [infra] Roll clang to match the version used by Flutter
Flutter uses the same clang toolchain as Fuchsia. This CL puts Dart
on that toolchain, as well. This roll should entail no changes to
glibc version requirements on Linux.

The Fuchsia buildtools distribute clang-format with the toolchain
rather than separately, so this CL introduces forwarding scripts
that are copied to the right place under //buildtools.

This CL sets the default for the number of workers in //tools/gn.py
to 1, as the newer GN version fails occasionally when run
concurrently with other invocations.

As Flutter does, this CL uses the clang toolchain to build for
Android. Thus, it is now possible to build for Android on MacOS.

This change is a prerequisite for assembling the SDK in GN
rather than with a python script:

https://codereview.chromium.org/2848943003/

and will be nicer for making prebuilt SDKs for Fuchsia.

Resubmitting this with the following fixes:
1. Rolls further forward to get past a GN bug
2. Fixes the Android build.
3. Style cleanups in gn.py

Review-Url: https://codereview.chromium.org/2858873005 .
2017-05-06 21:45:00 -07:00
Zachary Anderson ab422ad194 Revert "[infra] Roll clang to match the version used by Flutter"
This reverts commit 6bf2c800fd.

There is still some strangeness with the new GN binary not wanting
to do an incremental build on top of a build that used an old GN
binary.

Review-Url: https://codereview.chromium.org/2861903002 .
2017-05-03 15:56:21 -07:00
Zachary Anderson 6bf2c800fd Reland: [infra] Roll clang to match the version used by Flutter
Flutter uses the same clang toolchain as Fuchsia. This CL puts Dart
on that toolchain, as well. This roll should entail no changes to
glibc version requirements on Linux.

The Fuchsia buildtools distribute clang-format with the toolchain
rather than separately, so this CL introduces forwarding scripts
that are copied to the right place under //buildtools.

This CL sets the default for the number of workers in //tools/gn.py
to 1, as the newer GN version fails occasionally when run
concurrently with other invocations.

As Flutter does, this CL uses the clang toolchain to build for
Android. Thus, it is now possible to build for Android on MacOS.

This change is a prerequisite for assembling the SDK in GN
rather than with a python script:

https://codereview.chromium.org/2848943003/

and will be nicer for making prebuilt SDKs for Fuchsia.

Review-Url: https://codereview.chromium.org/2855283002 .
2017-05-03 15:42:46 -07:00
Zachary Anderson c94667420a [infra] Prepare gn.py for update to GN binary
First part in attempt to reland https://codereview.chromium.org/2854583002/
in two parts. If the second part fails, this part does not need to be
reverted.

Review-Url: https://codereview.chromium.org/2859833003 .
2017-05-03 15:23:40 -07:00
Zachary Anderson 958c25c1db Revert "[infra] Roll clang to match the version used by Flutter"
This reverts commit cc968ca45b.

This CL will have to be relanded in two pieces so that the
update to tools/gn.py lands before the unmodified version
can invoke the updated GN binary.

Review-Url: https://codereview.chromium.org/2855973006 .
2017-05-03 15:16:21 -07:00
Zachary Anderson cc968ca45b [infra] Roll clang to match the version used by Flutter
Flutter uses the same clang toolchain as Fuchsia. This CL puts Dart
on that toolchain, as well. This roll should entail no changes to
glibc version requirements on Linux.

The Fuchsia buildtools distribute clang-format with the toolchain
rather than separately, so this CL introduces forwarding scripts
that are copied to the right place under //buildtools.

This CL sets the default for the number of workers in //tools/gn.py
to 1, as the newer GN version fails occasionally when run
concurrently with other invocations.

As Flutter does, this CL uses the clang toolchain to build for
Android. Thus, it is now possible to build for Android on MacOS.

This change is a prerequisite for assembling the SDK in GN
rather than with a python script:

https://codereview.chromium.org/2848943003/

and will be nicer for making prebuilt SDKs for Fuchsia.

R=whesse@google.com

Review-Url: https://codereview.chromium.org/2854583002 .
2017-05-03 14:50:59 -07:00
Martin Kustermann 4e34234c28 Add support for configurable -OX optimization levels for debug builds
Can be used via -dX or --debug-opt-level=X, e.g.

  tools/gn.py --mode=debug --arch=x64 -d0

R=vegorov@google.com, zra@google.com

Review-Url: https://codereview.chromium.org/2645323002 .
2017-01-24 17:36:37 +01:00
Ryan Macnak 4f598c584d GN: Fix cross ARM64 and cross MIPS builds.
R=zra@google.com

Review-Url: https://codereview.chromium.org/2643583002 .
2017-01-20 15:44:24 -08:00
Zachary Anderson 0962a0f6f5 GN: Add environment variables for sysroot, toolchain
Also accept a map instead of a single path for each so
the toolchain/sysroot can be set per-arch.

R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2625503002 .
2017-01-09 15:53:21 -08:00
Zachary Anderson 375322d3ab GN: Add option to build with TSAN
fixes #28216

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2614493002 .
2017-01-03 14:37:27 -08:00
Zachary Anderson 566ed7ff55 GN: Fix armsimdbc target. Add armsimdbc64
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2596333002 .
2016-12-22 10:24:24 -08:00
Zachary Anderson 2644362215 GN: Reset default for fallback root certs to false.
R=johnmccutchan@google.com, rmacnak@google.com

Review URL: https://codereview.chromium.org/2536273002 .
2016-11-29 12:24:48 -08:00
Ryan Macnak 8d57e3d540 Enable SecureSocket on Fuchsia using BoringSSL and compiled-in certificates from dart-sdk/root_certificates.
Implement OS::CurrentTimeMicros in terms of gettimeofday.

R=asiva@google.com

Review URL: https://codereview.chromium.org/2519133005 .
2016-11-23 10:48:18 -08:00
Zachary Anderson f765e1498f GN: Make sure we use clang when ASAN is specificed for ia32 Linux
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2496383002 .
2016-11-14 13:29:30 -08:00
Zachary Anderson 43a506bcc8 Adds some error handling to the socket implementation.
I'm starting to try to track down the hang in socket_test in
a call to read() on Mac. We weren't checking that the calls
to set fds non-blocking were successful, so I'll start with
adding code to do that.

This CL also fixes the GN arm android build.

R=asiva@google.com

Review URL: https://codereview.chromium.org/2495003003 .
2016-11-11 21:15:16 -08:00
Zachary Anderson 7b86880b01 GN: Add an option to build against the Debian wheezy sysroot
Set the environment variable DART_USE_WHEEZY to build against
the wheezy sysroot on Linux.

R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2476343004 .
2016-11-07 13:09:45 -08:00
Zachary Anderson 02cb4a0003 GN: Take asan default from an environment variable
If DART_USE_ASAN is defined, then the GN build will have ASAN
enabled after a 'gclient runhooks'

R=whesse@google.com

Review URL: https://codereview.chromium.org/2480333002 .
2016-11-07 09:01:14 -08:00
Zachary Anderson f7799da7c5 GN: Fall back on dart_bootstrap where appropriate.
Review URL: https://codereview.chromium.org/2464153003 .
2016-11-01 12:59:36 -07:00
Zachary Anderson c1313a5ec7 Format GN files and add a presubmit check that GN is properly formatted
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2451613005 .
2016-10-26 08:50:54 -07:00
Zachary Anderson 1ed9dc3ac0 GN: Fix arm cross build to match gyp build
R=vegorov@google.com

Review URL: https://codereview.chromium.org/2456463003 .
2016-10-26 07:58:42 -07:00
Zachary Anderson 3066d28c0d GN: Add commands to bot scripts
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2412163002 .
2016-10-12 09:42:37 -07:00
Zachary Anderson 81ad8d5655 GN: Disable clang for simulators hosted on ia32
Also silence a warning in tcmalloc.

R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2405513002 .
2016-10-07 09:55:58 -07:00
Zachary Anderson f688cef70d GN: Use gcc for ia32 Linux
Clang doesn't compile tcmalloc's ia32 inline assembly correctly.

R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2390783007 .
2016-10-06 11:28:38 -07:00
Zach Anderson bb1ba21bf7 Have GN generate ide files
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2394063002 .
2016-10-05 15:36:46 -07:00
Zachary Anderson 4ab6c33d9a Enable GN ASAN builds for Linux
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2392403002 .
2016-10-05 13:43:29 -07:00
Zachary Anderson ff7ad2a4e1 Run GN from build.py if the output directory doesn't exist
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org/2397623003 .
2016-10-05 09:16:17 -07:00