| Index: BUILD.gn
|
| diff --git a/BUILD.gn b/BUILD.gn
|
| index 30b5d5a57451790e53718e671926d677fd681daf..532ed2e3efa45eade0f79ff7bfcd2413df2e3658 100644
|
| --- a/BUILD.gn
|
| +++ b/BUILD.gn
|
| @@ -69,6 +69,13 @@ declare_args() {
|
|
|
| # Similar to the ARM hard float ABI but on MIPS.
|
| v8_use_mips_abi_hardfloat = true
|
| +
|
| + # Build with -pg option for gprof or uftrace
|
| + v8_pg_build = false
|
| +
|
| + # Build with -finstrument-functions option for uftrace or general function
|
| + # instrumentation
|
| + v8_finstrument_build = false
|
| }
|
|
|
| # Set project-specific defaults for some args if not provided in args.gn. The
|
| @@ -371,6 +378,20 @@ config("toolchain") {
|
| ]
|
| }
|
|
|
| + if (v8_pg_build) {
|
| + cflags += [
|
| + "-pg",
|
| + "-fno-omit-frame-pointer",
|
| + ]
|
| + }
|
| +
|
| + if (v8_finstrument_build) {
|
| + cflags += [
|
| + "-finstrument-functions",
|
| + "-fno-omit-frame-pointer",
|
| + ]
|
| + }
|
| +
|
| if (is_clang) {
|
| cflags += [
|
| "-Wsign-compare",
|
|
|