xref: /llvm-project/llvm/test/tools/llvm-xray/X86/graph-color-simple-case.yaml (revision f0cb13d704c87843d083a3eb646e36007e7a6a7f)
1#RUN: llvm-xray graph %s -o - -m %S/Inputs/simple-instrmap.yaml -e sum -c sum \
2#RUN:    | FileCheck %s -check-prefix=EDGE
3#RUN: llvm-xray graph %s -o - -m %S/Inputs/simple-instrmap.yaml -v sum -b sum \
4#RUN:    | FileCheck %s -check-prefix=VERTEX
5---
6header:
7  version: 1
8  type: 0
9  constant-tsc: true
10  nonstop-tsc: true
11  cycle-frequency: 1
12records:
13  - { type: 0, func-id: 1, cpu: 1, thread: 111, kind: function-enter, tsc: 10000 }
14  - { type: 0, func-id: 1, cpu: 1, thread: 111, kind: function-exit,  tsc: 10010 }
15  - { type: 0, func-id: 2, cpu: 1, thread: 111, kind: function-enter, tsc: 10100 }
16  - { type: 0, func-id: 2, cpu: 1, thread: 111, kind: function-exit,  tsc: 10120 }
17  - { type: 0, func-id: 3, cpu: 1, thread: 111, kind: function-enter, tsc: 10200 }
18  - { type: 0, func-id: 3, cpu: 1, thread: 111, kind: function-exit,  tsc: 10230 }
19  - { type: 0, func-id: 4, cpu: 1, thread: 111, kind: function-enter, tsc: 10300 }
20  - { type: 0, func-id: 4, cpu: 1, thread: 111, kind: function-exit,  tsc: 10340 }
21  - { type: 0, func-id: 5, cpu: 1, thread: 111, kind: function-enter, tsc: 10400 }
22  - { type: 0, func-id: 5, cpu: 1, thread: 111, kind: function-exit,  tsc: 10450 }
23  - { type: 0, func-id: 6, cpu: 1, thread: 111, kind: function-enter, tsc: 10500 }
24  - { type: 0, func-id: 6, cpu: 1, thread: 111, kind: function-exit,  tsc: 10560 }
25  - { type: 0, func-id: 7, cpu: 1, thread: 111, kind: function-enter, tsc: 10600 }
26  - { type: 0, func-id: 7, cpu: 1, thread: 111, kind: function-exit,  tsc: 10670 }
27  - { type: 0, func-id: 8, cpu: 1, thread: 111, kind: function-enter, tsc: 10700 }
28  - { type: 0, func-id: 8, cpu: 1, thread: 111, kind: function-exit,  tsc: 10780 }
29  - { type: 0, func-id: 9, cpu: 1, thread: 111, kind: function-enter, tsc: 10800 }
30  - { type: 0, func-id: 9, cpu: 1, thread: 111, kind: function-exit,  tsc: 10890 }
31---
32
33
34#EDGE:     digraph xray {
35#EDGE-DAG: F0 -> F7 [label="7.{{[0-9]*}}e+01" color="#B00000"];
36#EDGE-DAG: F0 -> F2 [label="2.{{[0-9]*}}e+01" color="#FC9963"];
37#EDGE-DAG: F0 -> F9 [label="9.{{[0-9]*}}e+01" color="#7F0000"];
38#EDGE-DAG: F0 -> F4 [label="4.{{[0-9]*}}e+01" color="#E75339"];
39#EDGE-DAG: F0 -> F6 [label="6.{{[0-9]*}}e+01" color="#C4150D"];
40#EDGE-DAG: F0 -> F1 [label="1.{{[0-9]*}}e+01" color="#FDC48D"];
41#EDGE-DAG: F0 -> F8 [label="8.{{[0-9]*}}e+01" color="#970000"];
42#EDGE-DAG: F0 -> F3 [label="3.{{[0-9]*}}e+01" color="#F4744E"];
43#EDGE-DAG: F0 -> F5 [label="5.{{[0-9]*}}e+01" color="#D83220"];
44#EDGE-DAG: F7 [label="@(7)"];
45#EDGE-DAG: F2 [label="@(2)"];
46#EDGE-DAG: F9 [label="@(9)"];
47#EDGE-DAG: F4 [label="@(4)"];
48#EDGE-DAG: F6 [label="@(6)"];
49#EDGE-DAG: F1 [label="@(1)"];
50#EDGE-DAG: F8 [label="@(8)"];
51#EDGE-DAG: F3 [label="@(3)"];
52#EDGE-DAG: F5 [label="@(5)"];
53#EDGE-NEXT:     }
54#
55#VERTEX:     digraph xray {
56#VERTEX-DAG: node [shape=record];
57#VERTEX-DAG: F0 -> F7 [label=""];
58#VERTEX-DAG: F0 -> F2 [label=""];
59#VERTEX-DAG: F0 -> F9 [label=""];
60#VERTEX-DAG: F0 -> F4 [label=""];
61#VERTEX-DAG: F0 -> F6 [label=""];
62#VERTEX-DAG: F0 -> F1 [label=""];
63#VERTEX-DAG: F0 -> F8 [label=""];
64#VERTEX-DAG: F0 -> F3 [label=""];
65#VERTEX-DAG: F0 -> F5 [label=""];
66#VERTEX-DAG: F7 [label="{@(7)|7.{{[0-9]*}}e+01}" color="#B00000"];
67#VERTEX-DAG: F2 [label="{@(2)|2.{{[0-9]*}}e+01}" color="#FC9963"];
68#VERTEX-DAG: F9 [label="{@(9)|9.{{[0-9]*}}e+01}" color="#7F0000"];
69#VERTEX-DAG: F4 [label="{@(4)|4.{{[0-9]*}}e+01}" color="#E75339"];
70#VERTEX-DAG: F6 [label="{@(6)|6.{{[0-9]*}}e+01}" color="#C4150D"];
71#VERTEX-DAG: F1 [label="{@(1)|1.{{[0-9]*}}e+01}" color="#FDC48D"];
72#VERTEX-DAG: F8 [label="{@(8)|8.{{[0-9]*}}e+01}" color="#970000"];
73#VERTEX-DAG: F3 [label="{@(3)|3.{{[0-9]*}}e+01}" color="#F4744E"];
74#VERTEX-DAG: F5 [label="{@(5)|5.{{[0-9]*}}e+01}" color="#D83220"];
75#VERTEX-NEXT: }
76