1fe6060f1SDimitry Andric //===-- TraceIntelPTConstants.h ---------------------------------*- C++ -*-===// 2fe6060f1SDimitry Andric // 3fe6060f1SDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4fe6060f1SDimitry Andric // See https://llvm.org/LICENSE.txt for license information. 5fe6060f1SDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6fe6060f1SDimitry Andric // 7fe6060f1SDimitry Andric //===----------------------------------------------------------------------===// 8fe6060f1SDimitry Andric 9fe6060f1SDimitry Andric #ifndef LLDB_SOURCE_PLUGINS_TRACE_INTEL_PT_CONSTANTS_H 10fe6060f1SDimitry Andric #define LLDB_SOURCE_PLUGINS_TRACE_INTEL_PT_CONSTANTS_H 11fe6060f1SDimitry Andric 12*bdd1243dSDimitry Andric #include "lldb/lldb-types.h" 13fe6060f1SDimitry Andric #include <cstddef> 14*bdd1243dSDimitry Andric #include <optional> 15fe6060f1SDimitry Andric 16fe6060f1SDimitry Andric namespace lldb_private { 17fe6060f1SDimitry Andric namespace trace_intel_pt { 18fe6060f1SDimitry Andric 1981ad6265SDimitry Andric const size_t kDefaultIptTraceSize = 4 * 1024; // 4KB 20fe6060f1SDimitry Andric const size_t kDefaultProcessBufferSizeLimit = 5 * 1024 * 1024; // 500MB 21fe6060f1SDimitry Andric const bool kDefaultEnableTscValue = false; 22*bdd1243dSDimitry Andric const std::optional<size_t> kDefaultPsbPeriod; 2381ad6265SDimitry Andric const bool kDefaultPerCpuTracing = false; 24753f127fSDimitry Andric const bool kDefaultDisableCgroupFiltering = false; 25fe6060f1SDimitry Andric 26*bdd1243dSDimitry Andric // Physical address where the kernel is loaded in x86 architecture. Refer to 27*bdd1243dSDimitry Andric // https://github.com/torvalds/linux/blob/master/Documentation/x86/x86_64/mm.rst 28*bdd1243dSDimitry Andric // for the start address of kernel text section. 29*bdd1243dSDimitry Andric // The kernel entry point is 0x1000000 by default when KASLR is disabled. 30*bdd1243dSDimitry Andric const lldb::addr_t kDefaultKernelLoadAddress = 0xffffffff81000000; 31*bdd1243dSDimitry Andric const lldb::pid_t kDefaultKernelProcessID = 1; 32*bdd1243dSDimitry Andric 33fe6060f1SDimitry Andric } // namespace trace_intel_pt 34fe6060f1SDimitry Andric } // namespace lldb_private 35fe6060f1SDimitry Andric 36fe6060f1SDimitry Andric #endif // LLDB_SOURCE_PLUGINS_TRACE_INTEL_PT_CONSTANTS_H 37