1-- 2-- Copyright 2024 The Android Open Source Project 3-- 4-- Licensed under the Apache License, Version 2.0 (the "License"); 5-- you may not use this file except in compliance with the License. 6-- You may obtain a copy of the License at 7-- 8-- https://www.apache.org/licenses/LICENSE-2.0 9-- 10-- Unless required by applicable law or agreed to in writing, software 11-- distributed under the License is distributed on an "AS IS" BASIS, 12-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13-- See the License for the specific language governing permissions and 14-- limitations under the License. 15 16-- Represents a jitted code snippet. 17-- TODO(carlscab): Make public 18CREATE PERFETTO VIEW _jit_code ( 19 -- Unique jit code id. 20 jit_code_id LONG, 21 -- Time this code was created / allocated. 22 create_ts TIMESTAMP, 23 -- Time this code was destroyed / deallocated. This is a upper bound, as we 24 -- can only detect deletions indirectly when new code is allocated overlapping 25 -- existing one. 26 estimated_delete_ts TIMESTAMP, 27 -- Thread that generated the code. 28 utid JOINID(thread.id), 29 -- Start address for the generated code. 30 start_address LONG, 31 -- Size in bytes of the generated code. 32 size LONG, 33 -- Function name. 34 function_name STRING, 35 -- Jitted code (binary data). 36 native_code BYTES 37) AS 38SELECT 39 id AS jit_code_id, 40 create_ts, 41 estimated_delete_ts, 42 utid, 43 start_address, 44 size, 45 function_name, 46 base64_decode(native_code_base64) AS native_code 47FROM __intrinsic_jit_code; 48 49-- Represents a jitted frame. 50-- TODO(carlscab): Make public 51CREATE PERFETTO VIEW _jit_frame ( 52 -- Jitted code snipped the frame is in (joins with _jit_code.jit_code_id). 53 jit_code_id LONG, 54 -- Jitted frame (joins with stack_profile_frame.id). 55 frame_id LONG 56) AS 57SELECT 58 jit_code_id, 59 frame_id 60FROM __intrinsic_jit_frame; 61