Skip to content

Commit 137519a

Browse files
authored
gh-135953: Add flamegraph reporter to sampling profiler (#138715)
1 parent 6bc65c3 commit 137519a

File tree

14 files changed

+1446
-6
lines changed

14 files changed

+1446
-6
lines changed

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,3 +103,4 @@ Python/stdlib_module_names.h generated
103103
Tools/peg_generator/pegen/grammar_parser.py generated
104104
aclocal.m4 generated
105105
configure generated
106+
*.min.js generated

Doc/license.rst

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1169,3 +1169,33 @@ contributors. The pyzstd code is distributed under the 3-Clause BSD License::
11691169
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
11701170
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
11711171
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1172+
1173+
1174+
Profiling module
1175+
----------------
1176+
1177+
The :mod:`!profiling` module includes vendored third-party libraries in
1178+
:file:`Lib/profiling/sampling/_vendor/` with the following licenses:
1179+
1180+
**d3-flamegraph**
1181+
1182+
The d3-flamegraph library is distributed under the Apache License, Version 2.0.
1183+
See the OpenSSL section above for the full text of the Apache License Version 2.0.
1184+
1185+
**d3.js**
1186+
1187+
The d3.js library contains the following notice::
1188+
1189+
Copyright 2010-2021 Mike Bostock
1190+
1191+
Permission to use, copy, modify, and/or distribute this software for any purpose
1192+
with or without fee is hereby granted, provided that the above copyright notice
1193+
and this permission notice appear in all copies.
1194+
1195+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
1196+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
1197+
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
1198+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
1199+
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
1200+
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
1201+
THIS SOFTWARE.
20.2 KB
Loading

Lib/profiling/sampling/_vendor/d3-flame-graph/4.1.3/d3-flamegraph-tooltip.min.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
.d3-flame-graph rect {
2+
stroke: #EEEEEE;
3+
fill-opacity: .8;
4+
}
5+
6+
.d3-flame-graph rect:hover {
7+
stroke: #474747;
8+
stroke-width: 0.5;
9+
cursor: pointer;
10+
}
11+
12+
.d3-flame-graph-label {
13+
pointer-events: none;
14+
white-space: nowrap;
15+
text-overflow: ellipsis;
16+
overflow: hidden;
17+
font-size: 12px;
18+
font-family: Verdana;
19+
margin-left: 4px;
20+
margin-right: 4px;
21+
line-height: 1.5;
22+
padding: 0 0 0;
23+
font-weight: 400;
24+
color: black;
25+
text-align: left;
26+
}
27+
28+
.d3-flame-graph .fade {
29+
opacity: 0.6 !important;
30+
}
31+
32+
.d3-flame-graph .title {
33+
font-size: 20px;
34+
font-family: Verdana;
35+
}
36+
37+
.d3-flame-graph-tip {
38+
background-color: black;
39+
border: none;
40+
border-radius: 3px;
41+
padding: 5px 10px 5px 10px;
42+
min-width: 250px;
43+
text-align: left;
44+
color: white;
45+
z-index: 10;
46+
}

Lib/profiling/sampling/_vendor/d3-flame-graph/4.1.3/d3-flamegraph.min.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Lib/profiling/sampling/_vendor/d3/7.8.5/d3.min.js

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)