profiler-md 0.1.2 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -88,30 +88,21 @@ declare const defaultIsThirdPartyEntry: (entry: ProfileEntry) => boolean;
88
88
  * It is assumed that {@link data} is a valid pprof (raw protobuf). The behavior
89
89
  * of this function is undefined for invalid profiles.
90
90
  *
91
- * pprof can be generated by many tools, including:
92
- * - Go's [`runtime/pprof`](https://pkg.go.dev/runtime/pprof) package
93
- * - Node.js's [`pprof`](https://www.npmjs.com/package/pprof) npm package
94
- * - Python's [`py-spy`](https://github.com/benfred/py-spy)
95
- * - Rust's [`pprof-rs`](https://github.com/tikv/pprof-rs)
96
- * - Java/Kotlin's [`async-profiler`](https://github.com/async-profiler/async-profiler)
97
- * - C/C++'s [`gperftools`](https://github.com/gperftools/gperftools) (via `pprof --proto`)
91
+ * See the [pprof docs](https://github.com/TomerAberbach/profiler-md/blob/main/docs/formats/pprof.md)
92
+ * for supported tools and generation instructions (`profiler-md --help pprof`).
98
93
  */
99
94
  declare const pprofToMd: (data: Uint8Array, options?: ProfileToMdOptions) => string;
100
95
  //#endregion
101
96
  //#region src/formats/speedscope/index.d.ts
102
97
  /**
103
- * Converts the given speedscope profile to Markdown.
98
+ * Converts the given Speedscope profile to Markdown.
104
99
  *
105
- * It is assumed that {@link data} is a valid speedscope JSON file. The behavior
100
+ * It is assumed that {@link data} is a valid Speedscope JSON file. The behavior
106
101
  * of this function is undefined for invalid profiles.
107
102
  *
108
- * Speedscope profiles can be generated by many tools, including:
109
- * - [speedscope](https://www.speedscope.app) (drag and drop any supported profile)
110
- * - [rbspy](https://rbspy.github.io) for Ruby
111
- * - [py-spy](https://github.com/benfred/py-spy) for Python (`--format speedscope`)
112
- * - [pprof-rs](https://github.com/tikv/pprof-rs) for Rust
113
- * - [async-profiler](https://github.com/async-profiler/async-profiler) for Java/Kotlin (`-o speedscope`)
114
- * - [phpspy](https://github.com/adsr/phpspy) for PHP (`--output-format=speedscope`)
103
+ * See the [Speedscope docs](https://github.com/TomerAberbach/profiler-md/blob/main/docs/formats/speedscope.md)
104
+ * for supported tools and generation instructions
105
+ * (`profiler-md --help speedscope`).
115
106
  */
116
107
  declare const speedscopeProfileToMd: (data: string | Uint8Array, options?: ProfileToMdOptions) => string;
117
108
  //#endregion
@@ -122,19 +113,9 @@ declare const speedscopeProfileToMd: (data: string | Uint8Array, options?: Profi
122
113
  * It is assumed that {@link data} is a valid profile. The behavior of this
123
114
  * function is undefined for invalid profiles.
124
115
  *
125
- * You can generate a V8 CPU profile in several ways:
126
- * - [`node --cpu-prof`](https://nodejs.org/api/cli.html#cpu-prof)
127
- * - [`deno run --cpu-prof`](https://docs.deno.com/runtime/fundamentals/debugging/#cpu-profiling)
128
- * - [`bun --cpu-prof`](https://bun.com/docs/project/benchmarking#cpu-profiling)
129
- * (NOTE: output was incorrect until
130
- * [v1.3.13](https://bun.com/blog/bun-v1.3.13#node-js-compatibility-improvements))
131
- * - [`node --inspect`](https://nodejs.org/api/debugger.html#v8-inspector-integration-for-nodejs),
132
- * [`deno run --inspect`](https://docs.deno.com/runtime/fundamentals/debugging/#--inspect),
133
- * or [`bun --inspect`](https://bun.com/docs/runtime/debugger#inspect) with
134
- * [Chrome DevTools](https://developer.chrome.com/docs/devtools/performance/nodejs)
135
- * - [Chrome DevTools directly](https://developer.chrome.com/docs/devtools/performance#record)
136
- *
137
- * Lower the sampling interval to capture more granular data.
116
+ * See the [V8 CPU profile docs](https://github.com/TomerAberbach/profiler-md/blob/main/docs/formats/v8-cpu-profile.md)
117
+ * for supported runtimes and generation instructions
118
+ * (`profiler-md --help v8-cpu-profile`).
138
119
  */
139
120
  declare const v8CpuProfileToMd: (data: string | Uint8Array, options?: ProfileToMdOptions) => string;
140
121
  //#endregion
@@ -145,16 +126,9 @@ declare const v8CpuProfileToMd: (data: string | Uint8Array, options?: ProfileToM
145
126
  * It is assumed that {@link data} is a valid profile. The behavior of this
146
127
  * function is undefined for invalid profiles.
147
128
  *
148
- * You can generate a V8 heap profile in several ways:
149
- * - [`node --heap-prof`](https://nodejs.org/api/cli.html#--heap-prof)
150
- * - [`node --inspect`](https://nodejs.org/api/debugger.html#v8-inspector-integration-for-nodejs),
151
- * [`deno run --inspect`](https://docs.deno.com/runtime/fundamentals/debugging/#--inspect),
152
- * or [`bun --inspect`](https://bun.com/docs/runtime/debugger#inspect) with
153
- * [Chrome DevTools](https://developer.chrome.com/docs/devtools/memory-problems/allocation-profiler)
154
- * - [Chrome DevTools directly](https://developer.chrome.com/docs/devtools/memory-problems/allocation-profiler)
155
- *
156
- * Note that [`bun --heap-prof`](https://bun.com/docs/project/benchmarking#heap-profiling)
157
- * generates a heap _snapshot_ on exit, not a heap _profile_.
129
+ * See the [V8 heap profile docs](https://github.com/TomerAberbach/profiler-md/blob/main/docs/formats/v8-heap-profile.md)
130
+ * for supported runtimes and generation instructions
131
+ * (`profiler-md --help v8-heap-profile`).
158
132
  */
159
133
  declare const v8HeapProfileToMd: (data: string | Uint8Array, options?: ProfileToMdOptions) => string;
160
134
  //#endregion
@@ -165,16 +139,9 @@ declare const v8HeapProfileToMd: (data: string | Uint8Array, options?: ProfileTo
165
139
  * It is assumed that {@link data} is a valid snapshot. The behavior of this
166
140
  * function is undefined for invalid snapshots.
167
141
  *
168
- * You can generate a V8 heap snapshot in several ways:
169
- * - [`node --heapsnapshot-near-heap-limit=1`](https://nodejs.org/api/cli.html#heapsnapshot-near-heap-limitmax-count)
170
- * - [`node --heapsnapshot-signal`](https://nodejs.org/api/cli.html#--heapsnapshot-signalsignal)
171
- * - [`bun --heap-prof`](https://bun.com/docs/project/benchmarking#heap-profiling)
172
- * - [`v8.writeHeapSnapshot()`](https://nodejs.org/api/v8.html#v8writeheapsnapshotfilename)
173
- * - [`node --inspect`](https://nodejs.org/api/debugger.html#v8-inspector-integration-for-nodejs),
174
- * [`deno run --inspect`](https://docs.deno.com/runtime/fundamentals/debugging/#--inspect),
175
- * or [`bun --inspect`](https://bun.com/docs/runtime/debugger#inspect) with
176
- * [Chrome DevTools](https://developer.chrome.com/docs/devtools/memory-problems/heap-snapshots)
177
- * - [Chrome DevTools directly](https://developer.chrome.com/docs/devtools/memory-problems/heap-snapshots)
142
+ * See the [V8 heap snapshot docs](https://github.com/TomerAberbach/profiler-md/blob/main/docs/formats/v8-heap-snapshot.md)
143
+ * for supported runtimes and generation instructions
144
+ * (`profiler-md --help v8-heap-snapshot`).
178
145
  */
179
146
  declare const v8HeapSnapshotToMd: (data: string | Uint8Array, options?: ProfileToMdOptions) => string;
180
147
  //#endregion