• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright (C) 2023 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//      http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15import {SqlTableDescription} from './table';
16
17const sliceTable: SqlTableDescription = {
18  imports: ['slices.slices'],
19  name: '_slice_with_thread_and_process_info',
20  displayName: 'slice',
21  columns: [
22    {
23      name: 'id',
24      title: 'ID',
25      display: {
26        type: 'slice_id',
27        ts: 'ts',
28        dur: 'dur',
29        trackId: 'track_id',
30      },
31    },
32    {
33      name: 'ts',
34      title: 'Timestamp',
35      display: {
36        type: 'timestamp',
37      },
38    },
39    {
40      name: 'dur',
41      title: 'Duration',
42      display: {
43        type: 'duration',
44      },
45    },
46    {
47      name: 'thread_dur',
48      title: 'Thread duration',
49      display: {
50        type: 'thread_duration',
51      },
52    },
53    {
54      name: 'category',
55      title: 'Category',
56    },
57    {
58      name: 'name',
59      title: 'Name',
60    },
61    {
62      name: 'track_id',
63      title: 'Track ID',
64      startsHidden: true,
65    },
66    {
67      name: 'track_name',
68      title: 'Track name',
69      startsHidden: true,
70    },
71    {
72      name: 'thread_name',
73      title: 'Thread name',
74    },
75    {
76      name: 'utid',
77      startsHidden: true,
78    },
79    {
80      name: 'tid',
81    },
82    {
83      name: 'process_name',
84      title: 'Process name',
85    },
86    {
87      name: 'upid',
88      startsHidden: true,
89    },
90    {
91      name: 'pid',
92    },
93    {
94      name: 'depth',
95      title: 'Depth',
96      startsHidden: true,
97    },
98    {
99      name: 'parent_id',
100      title: 'Parent slice ID',
101      startsHidden: true,
102    },
103    {
104      name: 'arg_set_id',
105      title: 'Arg',
106      type: 'arg_set_id',
107    },
108  ],
109};
110
111export class SqlTables {
112  static readonly slice = sliceTable;
113}
114