Skip to content
Permalink
Browse files

Add mozjs feature for profiling.

  • Loading branch information...
jdm committed Mar 22, 2019
1 parent f45bea7 commit 896aae1c1410256fcfa46a7f11cf38f6b766359a
Showing with 16 additions and 12 deletions.
  1. +7 −7 Cargo.lock
  2. +2 −1 components/script/Cargo.toml
  3. +1 −0 components/servo/Cargo.toml
  4. +1 −0 ports/servo/Cargo.toml
  5. +5 −4 python/servo/build_commands.py

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -14,6 +14,7 @@ path = "lib.rs"

[features]
debugmozjs = ['js/debugmozjs']
profilemozjs = ['js/profilemozjs']
unstable = []
unrooted_must_root_lint = ["script_plugins/unrooted_must_root_lint"]
default = ["unrooted_must_root_lint"]
@@ -63,7 +64,7 @@ indexmap = "1.0.2"
ipc-channel = "0.11"
itertools = "0.8"
jstraceable_derive = {path = "../jstraceable_derive"}
js = {package = "mozjs", version = "0.10.0"}
js = {package = "mozjs", version = "0.10.1"}
keyboard-types = "0.4.4"
lazy_static = "1"
libc = "0.2"
@@ -16,6 +16,7 @@ max_log_level = ["log/release_max_level_info"]
webdriver = ["webdriver_server"]
energy-profiling = ["profile_traits/energy-profiling"]
debugmozjs = ["script/debugmozjs"]
profilemozjs = ["script/profilemozjs"]
googlevr = ["webvr/googlevr"]
js_backtrace = ["script/js_backtrace"]
native-bluetooth = ["bluetooth/native-bluetooth"]
@@ -34,6 +34,7 @@ max_log_level = ["log/release_max_level_info"]
webdriver = ["libservo/webdriver"]
energy-profiling = ["libservo/energy-profiling"]
debugmozjs = ["libservo/debugmozjs"]
profilemozjs = ["libservo/profilemozjs"]
unstable = ["libservo/unstable"]
webgl_backtrace = ["libservo/webgl_backtrace"]
webrender_debugger = ["libservo/webrender_debugger"]
@@ -283,6 +283,7 @@ def build(self, target=None, release=False, dev=False, jobs=None,

opts += ["--target", target]

env = self.build_env(target=target, is_build=True)
self.ensure_bootstrapped(target=target)
self.ensure_clobbered()

@@ -291,6 +292,10 @@ def build(self, target=None, release=False, dev=False, jobs=None,
if debug_mozjs:
features += ["debugmozjs"]

if with_frame_pointer:
env['RUSTFLAGS'] = env.get('RUSTFLAGS', "") + " -C force-frame-pointers=yes"
features += ["profilemozjs"]

if self.config["build"]["webgl-backtrace"]:
features += ["webgl-backtrace"]
if self.config["build"]["dom-backtrace"]:
@@ -300,15 +305,11 @@ def build(self, target=None, release=False, dev=False, jobs=None,
opts += ["--features", "%s" % ' '.join(features)]

build_start = time()
env = self.build_env(target=target, is_build=True)
env["CARGO_TARGET_DIR"] = target_path

if with_debug_assertions:
env['RUSTFLAGS'] = env.get('RUSTFLAGS', "") + " -C debug_assertions"

if with_frame_pointer:
env['RUSTFLAGS'] = env.get('RUSTFLAGS', "") + " -C force-frame-pointers=yes"

if android:
if "ANDROID_NDK" not in env:
print("Please set the ANDROID_NDK environment variable.")

1 comment on commit 896aae1

@taskcluster

This comment has been minimized.

Copy link

commented on 896aae1 Mar 25, 2019

Submitting the task to Taskcluster failed. Details

Internal Server Error, incidentId 97893581-9b79-4bd3-b1e8-d7a0094f129b.


  • method: createTask
  • errorCode: InternalServerError
  • statusCode: 500
  • time: 2019-03-25T20:16:32.546Z
Please sign in to comment.
You can’t perform that action at this time.