aboutsummaryrefslogtreecommitdiff
path: root/docs/DEVELOPER_README
diff options
context:
space:
mode:
Diffstat (limited to 'docs/DEVELOPER_README')
-rw-r--r--docs/DEVELOPER_README89
1 files changed, 43 insertions, 46 deletions
diff --git a/docs/DEVELOPER_README b/docs/DEVELOPER_README
index 9a2fffdf..fe140954 100644
--- a/docs/DEVELOPER_README
+++ b/docs/DEVELOPER_README
@@ -737,26 +737,6 @@ an implementation based on Joni, the regular expression engine used by
the JRuby project. The default value for this flag is "joni"
-SYSTEM PROPERTY: -Dnashorn.time
-
-This enables timers for various phases of script compilation. The timers
-will be dumped when the Nashorn process exits. We see a percentage value
-of how much time was spent not executing bytecode (i.e. compilation and
-internal tasks) at the end of the report.
-
-Here is an example:
-
-[JavaScript Parsing] 61 ms
-[Constant Folding] 11 ms
-[Control Flow Lowering] 26 ms
-[Type Attribution] 81 ms
-[Range Analysis] 0 ms
-[Code Splitting] 29 ms
-[Type Finalization] 19 ms
-[Bytecode Generation] 189 ms
-[Code Installation] 7 ms
-Total runtime: 508 ms (Non-runtime: 423 ms [83%])
-
===============
2. The loggers.
===============
@@ -887,6 +867,34 @@ etc. It will also show the internal representation of respective field
(Object in the normal case, unless running with the dual field
representation)
+* time
+
+This enables timers for various phases of script compilation. The timers
+will be dumped when the Nashorn process exits. We see a percentage value
+of how much time was spent not executing bytecode (i.e. compilation and
+internal tasks) at the end of the report.
+
+A finer level than "info" will show individual compilation timings as they
+happen.
+
+Here is an example:
+
+[time] Accumulated complation phase Timings:
+[time]
+[time] 'JavaScript Parsing' 1076 ms
+[time] 'Constant Folding' 159 ms
+[time] 'Control Flow Lowering' 303 ms
+[time] 'Program Point Calculation' 282 ms
+[time] 'Builtin Replacement' 71 ms
+[time] 'Code Splitting' 670 ms
+[time] 'Symbol Assignment' 474 ms
+[time] 'Scope Depth Computation' 249 ms
+[time] 'Optimistic Type Assignment' 186 ms
+[time] 'Local Variable Type Calculation' 526 ms
+[time] 'Bytecode Generation' 5177 ms
+[time] 'Class Installation' 1854 ms
+[time]
+[time] Total runtime: 11994 ms (Non-runtime: 11027 ms [91%])
=======================
3. Undocumented options
@@ -914,11 +922,10 @@ A short summary follows:
-cp, -classpath (-cp path. Specify where to find user class files.)
- -co, --compile-only (Compile script without running. Exit after compilation)
+ -co, --compile-only (Compile without running.)
param: [true|false] default: false
- -d, --dump-debug-dir (specify a destination directory to dump class files.
- This must be combined with the --compile-only option to work)
+ -d, --dump-debug-dir (specify a destination directory to dump class files.)
param: <path>
--debug-lines (Generate line number table in .class files.)
@@ -954,10 +961,6 @@ A short summary follows:
-h, -help (Print help for command line flags.)
param: [true|false] default: false
- --lazy-compilation (EXPERIMENTAL: Use lazy code generation strategies - do not compile
- the entire script at once.)
- param: [true|false] default: false
-
--loader-per-compile (Create a new class loader per compile.)
param: [true|false] default: true
@@ -965,16 +968,16 @@ A short summary follows:
param: <locale> default: en-US
--log (Enable logging of a given level for a given number of sub systems.
- [for example: --log=fields:finest,codegen:info])
+ [for example: --log=fields:finest,codegen:info].)
param: <module:level>,*
- -nj, --no-java (No Java support)
+ -nj, --no-java (Disable Java support.)
param: [true|false] default: false
- -nse, --no-syntax-extensions (No non-standard syntax extensions)
+ -nse, --no-syntax-extensions (Disallow non-standard syntax extensions.)
param: [true|false] default: false
- -nta, --no-typed-arrays (No Typed arrays support)
+ -nta, --no-typed-arrays (Disable typed arrays support.)
param: [true|false] default: false
--parse-only (Parse without compiling.)
@@ -983,13 +986,15 @@ A short summary follows:
--print-ast (Print abstract syntax tree.)
param: [true|false] default: false
- --print-code (Print bytecode.)
- param: [true|false] default: false
+ -pc, --print-code (Print generated bytecode. If a directory is specified, nothing will
+ be dumped to stderr. Also, in that case, .dot files will be generated
+ for all functions or for the function with the specified name only.)
+ param: [dir:<output-dir>,function:<name>]
--print-lower-ast (Print lowered abstract syntax tree.)
param: [true|false] default: false
- --print-lower-parse (Print the parse tree after lowering.)
+ -plp, --print-lower-parse (Print the parse tree after lowering.)
param: [true|false] default: false
--print-mem-usage (Print memory usage of IR after each compile stage.)
@@ -998,7 +1003,7 @@ A short summary follows:
--print-no-newline (Print function will not print new line char.)
param: [true|false] default: false
- --print-parse (Print the parse tree.)
+ -pp, --print-parse (Print the parse tree.)
param: [true|false] default: false
--print-symbols (Print the symbol table.)
@@ -1007,21 +1012,13 @@ A short summary follows:
-pcs, --profile-callsites (Dump callsite profile data.)
param: [true|false] default: false
- --range-analysis (EXPERIMENTAL: Do range analysis using known compile time types,
- and try to narrow number types)
- param: [true|false] default: false
-
-scripting (Enable scripting features.)
param: [true|false] default: false
- --specialize-calls (EXPERIMENTAL: Specialize all or a set of method according
- to callsite parameter types)
- param: [=function_1,...,function_n]
-
- --stderr (Redirect stderr to a filename or to another tty, e.g. stdout)
+ --stderr (Redirect stderr to a filename or to another tty, e.g. stdout.)
param: <output console>
- --stdout (Redirect stdout to a filename or to another tty, e.g. stderr)
+ --stdout (Redirect stdout to a filename or to another tty, e.g. stderr.)
param: <output console>
-strict (Run scripts in strict mode.)
@@ -1031,7 +1028,7 @@ A short summary follows:
param: <timezone> default: Europe/Stockholm
-tcs, --trace-callsites (Enable callsite trace mode. Options are: miss [trace callsite misses]
- enterexit [trace callsite enter/exit], objects [print object properties])
+ enterexit [trace callsite enter/exit], objects [print object properties].)
param: [=[option,]*]
--verify-code (Verify byte code before running.)