LLDB mainline
PluginManager.h
Go to the documentation of this file.
1//===-- PluginManager.h -----------------------------------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLDB_CORE_PLUGINMANAGER_H
10#define LLDB_CORE_PLUGINMANAGER_H
11
18#include "lldb/Utility/Status.h"
20#include "lldb/lldb-forward.h"
22#include "llvm/ADT/ArrayRef.h"
23#include "llvm/ADT/STLFunctionalExtras.h"
24#include "llvm/ADT/SmallVector.h"
25#include "llvm/ADT/StringRef.h"
26#include "llvm/Support/Error.h"
27#include "llvm/Support/JSON.h"
28
29#include <cstddef>
30#include <cstdint>
31#include <functional>
32#include <variant>
33#include <vector>
34
35// Match the PluginInitCallback and PluginTermCallback signature. The generated
36// initializer always succeeds.
37#define LLDB_PLUGIN_DEFINE_ADV(ClassName, PluginName) \
38 extern "C" { \
39 bool lldb_initialize_##PluginName() { \
40 ClassName::Initialize(); \
41 return true; \
42 } \
43 void lldb_terminate_##PluginName() { ClassName::Terminate(); } \
44 }
45
46#define LLDB_PLUGIN_DEFINE(PluginName) \
47 LLDB_PLUGIN_DEFINE_ADV(PluginName, PluginName)
48
49// FIXME: Generate me with CMake
50#define LLDB_PLUGIN_DECLARE(PluginName) \
51 extern "C" { \
52 extern bool lldb_initialize_##PluginName(); \
53 extern void lldb_terminate_##PluginName(); \
54 }
55
56#define LLDB_PLUGIN_INITIALIZE(PluginName) lldb_initialize_##PluginName()
57#define LLDB_PLUGIN_TERMINATE(PluginName) lldb_terminate_##PluginName()
58
59namespace lldb_private {
60class CommandInterpreter;
61class Debugger;
62class StringList;
63
65 llvm::StringRef name = "";
66 llvm::StringRef description = "";
67 bool enabled = false;
68};
69
70// Define some data structures to describe known plugin "namespaces".
71// The PluginManager is organized into a series of static functions
72// that operate on different types of plugins. For example SystemRuntime
73// and ObjectFile plugins.
74//
75// The namespace name is used a prefix when matching plugin names. For example,
76// if we have an "macosx" plugin in the "system-runtime" namespace then we will
77// match a plugin name pattern against the "system-runtime.macosx" name.
78//
79// The plugin namespace here is used so we can operate on all the plugins
80// of a given type so it is easy to enable or disable them as a group.
81using GetPluginInfo = std::function<llvm::SmallVector<RegisteredPluginInfo>()>;
82using SetPluginEnabledGlobalDomain = std::function<bool(llvm::StringRef, bool)>;
83using SetPluginEnabledAllDomains = std::function<llvm::Error(
84 llvm::StringRef, bool, Debugger &, lldb::PluginDomainKind)>;
86public:
87 static constexpr uint8_t kAllDomains = lldb::ePluginDomainKindGlobal |
90
91 /// Plugin that only supports enable/disable in the global domain
95 supported_domains(lldb::ePluginDomainKindGlobal),
96 set_enabled_fn(set_enabled) {}
97
98 /// Plugin that supports enable/disable in all domains.
103
104 std::optional<SetPluginEnabledGlobalDomain> GetSetEnabledGlobalFn() const {
106 return std::get<SetPluginEnabledGlobalDomain>(set_enabled_fn);
107 return std::nullopt;
108 }
109
110 std::optional<SetPluginEnabledAllDomains> GetSetEnabledAllDomainsFn() const {
112 return std::get<SetPluginEnabledAllDomains>(set_enabled_fn);
113 return std::nullopt;
114 }
115
117 assert(llvm::has_single_bit(static_cast<uint8_t>(domain)));
118 return supported_domains & domain;
119 }
120
122 assert(llvm::has_single_bit(static_cast<uint8_t>(domain)));
123 return supported_domains == domain;
124 }
125
126 llvm::StringRef name;
128
129private:
131 std::variant<SetPluginEnabledGlobalDomain, SetPluginEnabledAllDomains>
133};
134
139
145
152
158
163
168
174
175template <typename Callback> struct PluginInstance {
176 typedef Callback CallbackType;
177
178 PluginInstance() = default;
185
186 llvm::StringRef name;
187 llvm::StringRef description;
191};
192
208
210public:
211 static void Initialize();
212
213 static void Terminate();
214
215 // Support for enabling and disabling plugins.
216
217 // Return the plugins that can be enabled or disabled by the user.
218 static llvm::ArrayRef<PluginNamespace> GetPluginNamespaces();
219
220 // Generate a json object that describes the plugins that are available.
221 // This is a json representation of the plugin info returned by
222 // GetPluginNamespaces().
223 //
224 // {
225 // <plugin-namespace>: [
226 // {
227 // "enabled": <bool>,
228 // "name": <plugin-name>,
229 // },
230 // ...
231 // ],
232 // ...
233 // }
234 //
235 // If pattern is given it will be used to filter the plugins that are
236 // are returned. The pattern filters the plugin names using the
237 // PluginManager::MatchPluginName() function.
238 static llvm::json::Object GetJSON(llvm::StringRef pattern = "");
239
240 // Return true if the pattern matches the plugin name.
241 //
242 // The pattern matches the name if it is exactly equal to the namespace name
243 // or if it is equal to the qualified name, which is the namespace name
244 // followed by a dot and the plugin name (e.g. "system-runtime.foo").
245 //
246 // An empty pattern matches all plugins.
247 static bool MatchPluginName(llvm::StringRef pattern,
248 const PluginNamespace &plugin_ns,
250
251 // ABI
252 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
253 ABICreateInstance create_callback);
254
255 static bool UnregisterPlugin(ABICreateInstance create_callback);
256
257 static llvm::SmallVector<ABICreateInstance> GetABICreateCallbacks();
258
259 // Architecture
260 static void RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
261 ArchitectureCreateInstance create_callback);
262
263 static void UnregisterPlugin(ArchitectureCreateInstance create_callback);
264
265 static std::unique_ptr<Architecture>
267
268 // BugReporter
269 static void RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
270 BugReporterCreateInstance create_callback);
271
272 static void UnregisterPlugin(BugReporterCreateInstance create_callback);
273
274 static std::unique_ptr<BugReporter>
275 CreateBugReporterInstance(llvm::StringRef name = {});
276
277 // Disassembler
278 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
279 DisassemblerCreateInstance create_callback);
280
281 static bool UnregisterPlugin(DisassemblerCreateInstance create_callback);
282
283 static llvm::SmallVector<DisassemblerCreateInstance>
285
287 GetDisassemblerCreateCallbackForPluginName(llvm::StringRef name);
288
289 // DynamicLoader
290 static bool
291 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
292 DynamicLoaderCreateInstance create_callback,
293 DebuggerInitializeCallback debugger_init_callback = nullptr);
294
295 static bool UnregisterPlugin(DynamicLoaderCreateInstance create_callback);
296
297 static llvm::SmallVector<DynamicLoaderCreateInstance>
299
302
303 // JITLoader
304 static bool
305 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
306 JITLoaderCreateInstance create_callback,
307 DebuggerInitializeCallback debugger_init_callback = nullptr);
308
309 static bool UnregisterPlugin(JITLoaderCreateInstance create_callback);
310
311 static llvm::SmallVector<JITLoaderCreateInstance>
313
314 // EmulateInstruction
315 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
316 EmulateInstructionCreateInstance create_callback);
317
318 static bool
320
321 static llvm::SmallVector<EmulateInstructionCreateInstance>
323
326
327 // OperatingSystem
328 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
329 OperatingSystemCreateInstance create_callback,
330 DebuggerInitializeCallback debugger_init_callback);
331
332 static bool UnregisterPlugin(OperatingSystemCreateInstance create_callback);
333
334 static llvm::SmallVector<OperatingSystemCreateInstance>
336
339
340 // Language
341 static bool
342 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
343 LanguageCreateInstance create_callback,
344 DebuggerInitializeCallback debugger_init_callback = nullptr);
345
346 static bool UnregisterPlugin(LanguageCreateInstance create_callback);
347
348 /// Returns the instance of the enabled language plugin that supports
349 /// \p language, creating it on first use, or nullptr if there is none.
351
352 /// Returns GetLanguageInstance() for every language type that an enabled
353 /// language plugin supports, in language type order.
354 static std::vector<Language *> GetAllLanguageInstances();
355
356 // LanguageRuntime
357 static bool RegisterPlugin(
358 llvm::StringRef name, llvm::StringRef description,
359 LanguageRuntimeCreateInstance create_callback,
360 LanguageRuntimeGetCommandObject command_callback = nullptr,
361 LanguageRuntimeGetExceptionPrecondition precondition_callback = nullptr);
362
363 static bool UnregisterPlugin(LanguageRuntimeCreateInstance create_callback);
364
365 static llvm::SmallVector<LanguageRuntimeCallbacks>
367
368 // SystemRuntime
369 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
370 SystemRuntimeCreateInstance create_callback);
371
372 static bool UnregisterPlugin(SystemRuntimeCreateInstance create_callback);
373
374 static llvm::SmallVector<SystemRuntimeCreateInstance>
376
377 // ObjectFile
378 static bool
379 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
380 ObjectFileCreateInstance create_callback,
381 ObjectFileCreateMemoryInstance create_memory_callback,
382 ObjectFileGetModuleSpecifications get_module_specifications,
383 ObjectFileSaveCore save_core = nullptr,
384 DebuggerInitializeCallback debugger_init_callback = nullptr);
385
386 static bool UnregisterPlugin(ObjectFileCreateInstance create_callback);
387
388 static bool IsRegisteredObjectFilePluginName(llvm::StringRef name);
389
390 static llvm::SmallVector<ObjectFileCallbacks> GetObjectFileCallbacks();
391
394
395 static Status SaveCore(lldb_private::SaveCoreOptions &core_options);
396
397 static llvm::SmallVector<llvm::StringRef> GetSaveCorePluginNames();
398
399 // ObjectContainer
400 static bool RegisterPlugin(
401 llvm::StringRef name, llvm::StringRef description,
402 ObjectContainerCreateInstance create_callback,
403 ObjectFileGetModuleSpecifications get_module_specifications,
404 ObjectContainerCreateMemoryInstance create_memory_callback = nullptr);
405
406 static bool UnregisterPlugin(ObjectContainerCreateInstance create_callback);
407
408 static llvm::SmallVector<ObjectContainerCallbacks>
410
411 // Platform
412 static bool
413 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
414 PlatformCreateInstance create_callback,
415 DebuggerInitializeCallback debugger_init_callback = nullptr);
416
417 static bool UnregisterPlugin(PlatformCreateInstance create_callback);
418
419 static llvm::SmallVector<PlatformCreateInstance> GetPlatformCreateCallbacks();
420
422 GetPlatformCreateCallbackForPluginName(llvm::StringRef name);
423
424 static llvm::StringRef GetPlatformPluginNameAtIndex(uint32_t idx);
425
426 static llvm::StringRef GetPlatformPluginDescriptionAtIndex(uint32_t idx);
427
428 static void AutoCompletePlatformName(llvm::StringRef partial_name,
429 CompletionRequest &request);
430 // Process
431 static bool
432 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
433 ProcessCreateInstance create_callback,
434 DebuggerInitializeCallback debugger_init_callback = nullptr);
435
436 static bool UnregisterPlugin(ProcessCreateInstance create_callback);
437
438 static llvm::SmallVector<ProcessCreateInstance> GetProcessCreateCallbacks();
439
441 GetProcessCreateCallbackForPluginName(llvm::StringRef name);
442
443 static llvm::StringRef GetProcessPluginNameAtIndex(uint32_t idx);
444
445 static llvm::StringRef GetProcessPluginDescriptionAtIndex(uint32_t idx);
446
447 static void AutoCompleteProcessName(llvm::StringRef partial_name,
448 CompletionRequest &request);
449
450 // Protocol
451 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
452 ProtocolServerCreateInstance create_callback);
453
454 static bool UnregisterPlugin(ProtocolServerCreateInstance create_callback);
455
456 static llvm::StringRef GetProtocolServerPluginNameAtIndex(uint32_t idx);
457
459 GetProtocolCreateCallbackForPluginName(llvm::StringRef name);
460
461 // Register Type Provider
462 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
463 RegisterTypeBuilderCreateInstance create_callback);
464
465 static bool
467
469
470 // ScriptInterpreter
471 static bool
472 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
473 lldb::ScriptLanguage script_lang,
474 ScriptInterpreterCreateInstance create_callback,
475 ScriptInterpreterGetPath get_path_callback = nullptr);
476
477 static bool UnregisterPlugin(ScriptInterpreterCreateInstance create_callback);
478
479 static llvm::SmallVector<ScriptInterpreterCreateInstance>
481
484 Debugger &debugger);
485
486 /// Records why no script interpreter for \p script_lang could be
487 /// registered, for the fallback interpreter to report in its place. Success
488 /// clears the recorded error.
489 static void SetScriptInterpreterError(lldb::ScriptLanguage script_lang,
490 llvm::Error error);
491
492 /// Returns the error recorded for \p script_lang, or success.
493 static llvm::Error
495
496 static FileSpec
498
499 // SyntheticFrameProvider
500 static bool
501 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
502 SyntheticFrameProviderCreateInstance create_native_callback,
503 ScriptedFrameProviderCreateInstance create_scripted_callback);
504
505 static bool
507
508 static bool
510
513
514 static llvm::SmallVector<ScriptedFrameProviderCreateInstance>
516
517 // StructuredDataPlugin
518
519 /// Register a StructuredDataPlugin class along with optional
520 /// callbacks for debugger initialization and Process launch info
521 /// filtering and manipulation.
522 ///
523 /// \param[in] name
524 /// The name of the plugin.
525 ///
526 /// \param[in] description
527 /// A description string for the plugin.
528 ///
529 /// \param[in] create_callback
530 /// The callback that will be invoked to create an instance of
531 /// the callback. This may not be nullptr.
532 ///
533 /// \param[in] debugger_init_callback
534 /// An optional callback that will be made when a Debugger
535 /// instance is initialized.
536 ///
537 /// \param[in] filter_callback
538 /// An optional callback that will be invoked before LLDB
539 /// launches a process for debugging. The callback must
540 /// do the following:
541 /// 1. Only do something if the plugin's behavior is enabled.
542 /// 2. Only make changes for processes that are relevant to the
543 /// plugin. The callback gets a pointer to the Target, which
544 /// can be inspected as needed. The ProcessLaunchInfo is
545 /// provided in read-write mode, and may be modified by the
546 /// plugin if, for instance, additional environment variables
547 /// are needed to support the feature when enabled.
548 ///
549 /// \return
550 /// Returns true upon success; otherwise, false.
551 static bool
552 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
554 DebuggerInitializeCallback debugger_init_callback = nullptr,
555 StructuredDataFilterLaunchInfo filter_callback = nullptr);
556
557 static bool
559
560 static llvm::SmallVector<StructuredDataPluginCallbacks>
562
563 // SymbolFile
564 static bool
565 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
566 SymbolFileCreateInstance create_callback,
567 DebuggerInitializeCallback debugger_init_callback = nullptr);
568
569 static bool UnregisterPlugin(SymbolFileCreateInstance create_callback);
570
571 static llvm::SmallVector<SymbolFileCreateInstance>
573
574 // SymbolVendor
575 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
576 SymbolVendorCreateInstance create_callback);
577
578 static bool UnregisterPlugin(SymbolVendorCreateInstance create_callback);
579
580 static llvm::SmallVector<SymbolVendorCreateInstance>
582
583 // SymbolLocator
584 static bool RegisterPlugin(
585 llvm::StringRef name, llvm::StringRef description,
586 SymbolLocatorCreateInstance create_callback,
587 SymbolLocatorLocateExecutableObjectFile locate_executable_object_file =
588 nullptr,
589 SymbolLocatorLocateExecutableSymbolFile locate_executable_symbol_file =
590 nullptr,
591 SymbolLocatorDownloadObjectAndSymbolFile download_object_symbol_file =
592 nullptr,
593 SymbolLocatorFindSymbolFileInBundle find_symbol_file_in_bundle = nullptr,
594 DebuggerInitializeCallback debugger_init_callback = nullptr);
595
596 static bool UnregisterPlugin(SymbolLocatorCreateInstance create_callback);
597
598 static llvm::SmallVector<SymbolLocatorCreateInstance>
600
601 static ModuleSpec LocateExecutableObjectFile(const ModuleSpec &module_spec,
602 StatisticsMap &map);
603
604 static FileSpec
605 LocateExecutableSymbolFile(const ModuleSpec &module_spec,
606 const FileSpecList &default_search_paths,
607 StatisticsMap &map);
608
609 static bool DownloadObjectAndSymbolFile(ModuleSpec &module_spec,
610 Status &error,
611 bool force_lookup = true,
612 bool copy_executable = true);
613
614 static FileSpec FindSymbolFileInBundle(const FileSpec &dsym_bundle_fspec,
615 const UUID *uuid,
616 const ArchSpec *arch);
617
618 // Trace
619 static bool RegisterPlugin(
620 llvm::StringRef name, llvm::StringRef description,
621 TraceCreateInstanceFromBundle create_callback_from_bundle,
622 TraceCreateInstanceForLiveProcess create_callback_for_live_process,
623 llvm::StringRef schema,
624 DebuggerInitializeCallback debugger_init_callback);
625
626 static bool UnregisterPlugin(TraceCreateInstanceFromBundle create_callback);
627
629 GetTraceCreateCallback(llvm::StringRef plugin_name);
630
632 GetTraceCreateCallbackForLiveProcess(llvm::StringRef plugin_name);
633
634 /// Get the JSON schema for a trace bundle description file corresponding to
635 /// the given plugin.
636 ///
637 /// \param[in] plugin_name
638 /// The name of the plugin.
639 ///
640 /// \return
641 /// An empty \a StringRef if no plugin was found with that plugin name,
642 /// otherwise the actual schema is returned.
643 static llvm::StringRef GetTraceSchema(llvm::StringRef plugin_name);
644
645 /// Get the JSON schema for a trace bundle description file corresponding to
646 /// the plugin given by its index.
647 ///
648 /// \param[in] index
649 /// The index of the plugin to get the schema of.
650 ///
651 /// \return
652 /// An empty \a StringRef if the index is greater than or equal to the
653 /// number plugins, otherwise the actual schema is returned.
654 static llvm::StringRef GetTraceSchema(size_t index);
655
656 // TraceExporter
657
658 /// \param[in] create_thread_trace_export_command
659 /// This callback is used to create a CommandObject that will be listed
660 /// under "thread trace export". Can be \b null.
661 static bool RegisterPlugin(
662 llvm::StringRef name, llvm::StringRef description,
663 TraceExporterCreateInstance create_callback,
664 ThreadTraceExportCommandCreator create_thread_trace_export_command);
665
667 GetTraceExporterCreateCallback(llvm::StringRef plugin_name);
668
669 static bool UnregisterPlugin(TraceExporterCreateInstance create_callback);
670
671 static llvm::SmallVector<TraceExporterCallbacks> GetTraceExporterCallbacks();
672
673 // UnwindAssembly
674 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
675 UnwindAssemblyCreateInstance create_callback);
676
677 static bool UnregisterPlugin(UnwindAssemblyCreateInstance create_callback);
678
679 static llvm::SmallVector<UnwindAssemblyCreateInstance>
681
682 // MemoryHistory
683 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
684 MemoryHistoryCreateInstance create_callback);
685
686 static bool UnregisterPlugin(MemoryHistoryCreateInstance create_callback);
687
688 static llvm::SmallVector<MemoryHistoryCreateInstance>
690
691 // InstrumentationRuntime
692 static bool
693 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
695 InstrumentationRuntimeGetType get_type_callback);
696
697 static bool
699
700 static llvm::SmallVector<InstrumentationRuntimeCallbacks>
701 GetInstrumentationRuntimeCallbacks(bool enabled_only = true);
702
703 // TypeSystem
704 static bool
705 RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
706 TypeSystemCreateInstance create_callback,
707 LanguageSet supported_languages_for_types,
708 LanguageSet supported_languages_for_expressions,
709 DebuggerInitializeCallback debugger_init_callback = nullptr);
710
711 static bool UnregisterPlugin(TypeSystemCreateInstance create_callback);
712
713 static llvm::SmallVector<TypeSystemCreateInstance>
715
717
719
720 // Scripted Interface
721 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
722 ScriptedInterfaceCreateInstance create_callback,
723 lldb::ScriptedExtension extension,
724 lldb::ScriptLanguage language,
726
727 static bool UnregisterPlugin(ScriptedInterfaceCreateInstance create_callback);
728
729 static size_t GetNumScriptedInterfaces();
730
731 static llvm::StringRef GetScriptedInterfaceNameAtIndex(uint32_t idx);
732
733 static llvm::StringRef GetScriptedInterfaceDescriptionAtIndex(uint32_t idx);
734
737
739
742
743 /// Invoke \p callback once per registered scripted extension, passing the
744 /// first interface registered for it. An extension backed by several
745 /// languages is only reported once. When \p language is not
746 /// `eScriptLanguageUnknown`, only interfaces for that language count.
747 static void ForEachScriptedExtension(
748 llvm::function_ref<void(const ScriptedInterfaceInstance &)> callback,
750
752 llvm::StringRef partial_name, CompletionRequest &request,
754
755 // REPL
756 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
757 REPLCreateInstance create_callback,
758 LanguageSet supported_languages);
759
760 static bool UnregisterPlugin(REPLCreateInstance create_callback);
761
762 static llvm::SmallVector<REPLCallbacks> GetREPLCallbacks();
763
765
766 // Higlhighter
767 static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description,
768 HighlighterCreateInstance create_callback);
769
770 static bool UnregisterPlugin(HighlighterCreateInstance create_callback);
771
772 static llvm::SmallVector<HighlighterCreateInstance>
774
775 // Some plug-ins might register a DebuggerInitializeCallback callback when
776 // registering the plug-in. After a new Debugger instance is created, this
777 // DebuggerInitialize function will get called. This allows plug-ins to
778 // install Properties and do any other initialization that requires a
779 // debugger instance.
780 static void DebuggerInitialize(Debugger &debugger);
781
784 llvm::StringRef setting_name);
785
787 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
788 llvm::StringRef description, bool is_global_property);
789
791 GetSettingForPlatformPlugin(Debugger &debugger, llvm::StringRef setting_name);
792
794 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
795 llvm::StringRef description, bool is_global_property);
796
798 GetSettingForProcessPlugin(Debugger &debugger, llvm::StringRef setting_name);
799
801 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
802 llvm::StringRef description, bool is_global_property);
803
806 llvm::StringRef setting_name);
807
809 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
810 llvm::StringRef description, bool is_global_property);
811
812 static bool CreateSettingForTracePlugin(
813 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
814 llvm::StringRef description, bool is_global_property);
815
818 llvm::StringRef setting_name);
819
821 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
822 llvm::StringRef description, bool is_global_property);
823
826 llvm::StringRef setting_name);
827
829 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
830 llvm::StringRef description, bool is_global_property);
831
834 llvm::StringRef setting_name);
835
837 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
838 llvm::StringRef description, bool is_global_property);
839
842 llvm::StringRef setting_name);
843
845 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
846 llvm::StringRef description, bool is_global_property);
847
850 llvm::StringRef setting_name);
851
853 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
854 llvm::StringRef description, bool is_global_property);
855
858 llvm::StringRef setting_name);
859
861 Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp,
862 llvm::StringRef description, bool is_global_property);
863
864 //
865 // Plugin Info+Enable Declarations
866 //
867 static llvm::SmallVector<RegisteredPluginInfo> GetABIPluginInfo();
868 static bool SetABIPluginEnabled(llvm::StringRef name, bool enable);
869
870 static llvm::SmallVector<RegisteredPluginInfo> GetArchitecturePluginInfo();
871 static bool SetArchitecturePluginEnabled(llvm::StringRef name, bool enable);
872
873 static llvm::SmallVector<RegisteredPluginInfo> GetBugReporterPluginInfo();
874 static bool SetBugReporterPluginEnabled(llvm::StringRef name, bool enable);
875
876 static llvm::SmallVector<RegisteredPluginInfo> GetDisassemblerPluginInfo();
877 static bool SetDisassemblerPluginEnabled(llvm::StringRef name, bool enable);
878
879 static llvm::SmallVector<RegisteredPluginInfo> GetDynamicLoaderPluginInfo();
880 static bool SetDynamicLoaderPluginEnabled(llvm::StringRef name, bool enable);
881
882 static llvm::SmallVector<RegisteredPluginInfo>
884 static bool SetEmulateInstructionPluginEnabled(llvm::StringRef name,
885 bool enable);
886
887 static llvm::SmallVector<RegisteredPluginInfo>
889 static llvm::StringRef PluginDomainKindToStr(lldb::PluginDomainKind kind);
890 static llvm::Error
891 SetInstrumentationRuntimePluginEnabled(llvm::StringRef name, bool enable,
892 Debugger &requesting_debugger,
894
895 static llvm::SmallVector<RegisteredPluginInfo> GetJITLoaderPluginInfo();
896 static bool SetJITLoaderPluginEnabled(llvm::StringRef name, bool enable);
897
898 static llvm::SmallVector<RegisteredPluginInfo> GetLanguagePluginInfo();
899 static bool SetLanguagePluginEnabled(llvm::StringRef name, bool enable);
900
901 static llvm::SmallVector<RegisteredPluginInfo> GetLanguageRuntimePluginInfo();
902 static bool SetLanguageRuntimePluginEnabled(llvm::StringRef name,
903 bool enable);
904
905 static llvm::SmallVector<RegisteredPluginInfo> GetMemoryHistoryPluginInfo();
906 static bool SetMemoryHistoryPluginEnabled(llvm::StringRef name, bool enable);
907
908 static llvm::SmallVector<RegisteredPluginInfo> GetObjectContainerPluginInfo();
909 static bool SetObjectContainerPluginEnabled(llvm::StringRef name,
910 bool enable);
911
912 static llvm::SmallVector<RegisteredPluginInfo> GetObjectFilePluginInfo();
913 static bool SetObjectFilePluginEnabled(llvm::StringRef name, bool enable);
914
915 static llvm::SmallVector<RegisteredPluginInfo> GetOperatingSystemPluginInfo();
916 static bool SetOperatingSystemPluginEnabled(llvm::StringRef name,
917 bool enable);
918
919 static llvm::SmallVector<RegisteredPluginInfo> GetPlatformPluginInfo();
920 static bool SetPlatformPluginEnabled(llvm::StringRef name, bool enable);
921
922 static llvm::SmallVector<RegisteredPluginInfo> GetProcessPluginInfo();
923 static bool SetProcessPluginEnabled(llvm::StringRef name, bool enable);
924
925 static llvm::SmallVector<RegisteredPluginInfo> GetREPLPluginInfo();
926 static bool SetREPLPluginEnabled(llvm::StringRef name, bool enable);
927
928 static llvm::SmallVector<RegisteredPluginInfo>
930 static bool SetRegisterTypeBuilderPluginEnabled(llvm::StringRef name,
931 bool enable);
932
933 static llvm::SmallVector<RegisteredPluginInfo>
935 static bool SetScriptInterpreterPluginEnabled(llvm::StringRef name,
936 bool enable);
937
938 static llvm::SmallVector<RegisteredPluginInfo>
940 static bool SetScriptedInterfacePluginEnabled(llvm::StringRef name,
941 bool enable);
942
943 static llvm::SmallVector<RegisteredPluginInfo> GetStructuredDataPluginInfo();
944 static bool SetStructuredDataPluginEnabled(llvm::StringRef name, bool enable);
945
946 static llvm::SmallVector<RegisteredPluginInfo> GetSymbolFilePluginInfo();
947 static bool SetSymbolFilePluginEnabled(llvm::StringRef name, bool enable);
948
949 static llvm::SmallVector<RegisteredPluginInfo> GetSymbolLocatorPluginInfo();
950 static bool SetSymbolLocatorPluginEnabled(llvm::StringRef name, bool enable);
951
952 static llvm::SmallVector<RegisteredPluginInfo> GetSymbolVendorPluginInfo();
953 static bool SetSymbolVendorPluginEnabled(llvm::StringRef name, bool enable);
954
955 static llvm::SmallVector<RegisteredPluginInfo> GetSystemRuntimePluginInfo();
956 static bool SetSystemRuntimePluginEnabled(llvm::StringRef name, bool enable);
957
958 static llvm::SmallVector<RegisteredPluginInfo> GetTracePluginInfo();
959 static bool SetTracePluginEnabled(llvm::StringRef name, bool enable);
960
961 static llvm::SmallVector<RegisteredPluginInfo> GetTraceExporterPluginInfo();
962 static bool SetTraceExporterPluginEnabled(llvm::StringRef name, bool enable);
963
964 static llvm::SmallVector<RegisteredPluginInfo> GetTypeSystemPluginInfo();
965 static bool SetTypeSystemPluginEnabled(llvm::StringRef name, bool enable);
966
967 static llvm::SmallVector<RegisteredPluginInfo> GetUnwindAssemblyPluginInfo();
968 static bool SetUnwindAssemblyPluginEnabled(llvm::StringRef name, bool enable);
969
970 static void AutoCompletePluginName(llvm::StringRef partial_name,
971 CompletionRequest &request);
972};
973
974} // namespace lldb_private
975
976#endif // LLDB_CORE_PLUGINMANAGER_H
static llvm::raw_ostream & error(Stream &strm)
An architecture specification class.
Definition ArchSpec.h:32
"lldb/Utility/ArgCompletionRequest.h"
A class to manage flag bits.
Definition Debugger.h:106
A file collection class.
A file utility class.
Definition FileSpec.h:56
static bool SetArchitecturePluginEnabled(llvm::StringRef name, bool enable)
static llvm::StringRef GetPlatformPluginDescriptionAtIndex(uint32_t idx)
static bool SetPlatformPluginEnabled(llvm::StringRef name, bool enable)
static bool SetScriptInterpreterPluginEnabled(llvm::StringRef name, bool enable)
static bool MatchPluginName(llvm::StringRef pattern, const PluginNamespace &plugin_ns, const RegisteredPluginInfo &plugin)
static lldb::OptionValuePropertiesSP GetSettingForStructuredDataPlugin(Debugger &debugger, llvm::StringRef setting_name)
static bool SetMemoryHistoryPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetSystemRuntimePluginInfo()
static llvm::SmallVector< RegisteredPluginInfo > GetTypeSystemPluginInfo()
static void AutoCompleteScriptedExtension(llvm::StringRef partial_name, CompletionRequest &request, lldb::ScriptLanguage language=lldb::eScriptLanguageUnknown)
static bool CreateSettingForJITLoaderPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static bool SetRegisterTypeBuilderPluginEnabled(llvm::StringRef name, bool enable)
static llvm::StringRef PluginDomainKindToStr(lldb::PluginDomainKind kind)
static bool SetTraceExporterPluginEnabled(llvm::StringRef name, bool enable)
static Language * GetLanguageInstance(lldb::LanguageType language)
Returns the instance of the enabled language plugin that supports language, creating it on first use,...
static llvm::SmallVector< RegisteredPluginInfo > GetArchitecturePluginInfo()
static void ForEachScriptedExtension(llvm::function_ref< void(const ScriptedInterfaceInstance &)> callback, lldb::ScriptLanguage language=lldb::eScriptLanguageUnknown)
Invoke callback once per registered scripted extension, passing the first interface registered for it...
static LanguageSet GetAllTypeSystemSupportedLanguagesForExpressions()
static bool CreateSettingForOperatingSystemPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static llvm::SmallVector< UnwindAssemblyCreateInstance > GetUnwindAssemblyCreateCallbacks()
static lldb::OptionValuePropertiesSP GetSettingForObjectFilePlugin(Debugger &debugger, llvm::StringRef setting_name)
static llvm::SmallVector< RegisteredPluginInfo > GetEmulateInstructionPluginInfo()
static void AutoCompletePlatformName(llvm::StringRef partial_name, CompletionRequest &request)
static TraceExporterCreateInstance GetTraceExporterCreateCallback(llvm::StringRef plugin_name)
static bool SetDynamicLoaderPluginEnabled(llvm::StringRef name, bool enable)
static llvm::json::Object GetJSON(llvm::StringRef pattern="")
static bool CreateSettingForObjectFilePlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static bool SetScriptedInterfacePluginEnabled(llvm::StringRef name, bool enable)
static bool SetOperatingSystemPluginEnabled(llvm::StringRef name, bool enable)
static lldb::ScriptInterpreterSP GetScriptInterpreterForLanguage(lldb::ScriptLanguage script_lang, Debugger &debugger)
static llvm::SmallVector< ABICreateInstance > GetABICreateCallbacks()
static llvm::SmallVector< InstrumentationRuntimeCallbacks > GetInstrumentationRuntimeCallbacks(bool enabled_only=true)
static void AutoCompleteProcessName(llvm::StringRef partial_name, CompletionRequest &request)
static llvm::SmallVector< RegisteredPluginInfo > GetScriptInterpreterPluginInfo()
static bool SetBugReporterPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetABIPluginInfo()
static llvm::SmallVector< RegisteredPluginInfo > GetLanguagePluginInfo()
static LanguageSet GetREPLAllTypeSystemSupportedLanguages()
static llvm::SmallVector< OperatingSystemCreateInstance > GetOperatingSystemCreateCallbacks()
static bool CreateSettingForTracePlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static llvm::SmallVector< RegisteredPluginInfo > GetDynamicLoaderPluginInfo()
static lldb::OptionValuePropertiesSP GetSettingForOperatingSystemPlugin(Debugger &debugger, llvm::StringRef setting_name)
static llvm::Error SetInstrumentationRuntimePluginEnabled(llvm::StringRef name, bool enable, Debugger &requesting_debugger, lldb::PluginDomainKind domain)
static llvm::SmallVector< ProcessCreateInstance > GetProcessCreateCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetObjectContainerPluginInfo()
static bool DownloadObjectAndSymbolFile(ModuleSpec &module_spec, Status &error, bool force_lookup=true, bool copy_executable=true)
static llvm::SmallVector< RegisteredPluginInfo > GetDisassemblerPluginInfo()
static llvm::SmallVector< LanguageRuntimeCallbacks > GetLanguageRuntimeCallbacks()
static llvm::SmallVector< SymbolFileCreateInstance > GetSymbolFileCreateCallbacks()
static bool SetLanguageRuntimePluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetObjectFilePluginInfo()
static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description, ABICreateInstance create_callback)
static lldb::ScriptLanguage GetScriptedInterfaceLanguageAtIndex(uint32_t idx)
static void SetScriptInterpreterError(lldb::ScriptLanguage script_lang, llvm::Error error)
Records why no script interpreter for script_lang could be registered, for the fallback interpreter t...
static llvm::SmallVector< RegisteredPluginInfo > GetSymbolLocatorPluginInfo()
static llvm::StringRef GetTraceSchema(llvm::StringRef plugin_name)
Get the JSON schema for a trace bundle description file corresponding to the given plugin.
static llvm::SmallVector< SymbolVendorCreateInstance > GetSymbolVendorCreateCallbacks()
static bool SetUnwindAssemblyPluginEnabled(llvm::StringRef name, bool enable)
static lldb::OptionValuePropertiesSP GetSettingForCPlusPlusLanguagePlugin(Debugger &debugger, llvm::StringRef setting_name)
static bool SetDisassemblerPluginEnabled(llvm::StringRef name, bool enable)
static bool SetSystemRuntimePluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetTracePluginInfo()
static llvm::SmallVector< JITLoaderCreateInstance > GetJITLoaderCreateCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetProcessPluginInfo()
static TraceCreateInstanceForLiveProcess GetTraceCreateCallbackForLiveProcess(llvm::StringRef plugin_name)
static std::unique_ptr< Architecture > CreateArchitectureInstance(const ArchSpec &arch)
static llvm::SmallVector< DisassemblerCreateInstance > GetDisassemblerCreateCallbacks()
static lldb::OptionValuePropertiesSP GetSettingForSymbolLocatorPlugin(Debugger &debugger, llvm::StringRef setting_name)
static bool SetStructuredDataPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< ObjectFileCallbacks > GetObjectFileCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetLanguageRuntimePluginInfo()
static bool SetObjectContainerPluginEnabled(llvm::StringRef name, bool enable)
static bool CreateSettingForProcessPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static llvm::SmallVector< RegisteredPluginInfo > GetPlatformPluginInfo()
static llvm::SmallVector< RegisteredPluginInfo > GetMemoryHistoryPluginInfo()
static llvm::SmallVector< TypeSystemCreateInstance > GetTypeSystemCreateCallbacks()
static lldb::OptionValuePropertiesSP GetSettingForPlatformPlugin(Debugger &debugger, llvm::StringRef setting_name)
static llvm::SmallVector< RegisteredPluginInfo > GetSymbolFilePluginInfo()
static SyntheticFrameProviderCreateInstance GetSyntheticFrameProviderCreateCallbackForPluginName(llvm::StringRef name)
static llvm::SmallVector< SymbolLocatorCreateInstance > GetSymbolLocatorCreateCallbacks()
static llvm::ArrayRef< PluginNamespace > GetPluginNamespaces()
static bool SetTypeSystemPluginEnabled(llvm::StringRef name, bool enable)
static bool SetTracePluginEnabled(llvm::StringRef name, bool enable)
static Status SaveCore(lldb_private::SaveCoreOptions &core_options)
static llvm::SmallVector< RegisteredPluginInfo > GetTraceExporterPluginInfo()
static FileSpec LocateExecutableSymbolFile(const ModuleSpec &module_spec, const FileSpecList &default_search_paths, StatisticsMap &map)
static bool SetEmulateInstructionPluginEnabled(llvm::StringRef name, bool enable)
static lldb::OptionValuePropertiesSP GetSettingForJITLoaderPlugin(Debugger &debugger, llvm::StringRef setting_name)
static DisassemblerCreateInstance GetDisassemblerCreateCallbackForPluginName(llvm::StringRef name)
static bool SetJITLoaderPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetInstrumentationRuntimePluginInfo()
static llvm::SmallVector< REPLCallbacks > GetREPLCallbacks()
static bool CreateSettingForSymbolFilePlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static bool CreateSettingForPlatformPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static OperatingSystemCreateInstance GetOperatingSystemCreateCallbackForPluginName(llvm::StringRef name)
static std::vector< Language * > GetAllLanguageInstances()
Returns GetLanguageInstance() for every language type that an enabled language plugin supports,...
static bool SetSymbolFilePluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< ScriptInterpreterCreateInstance > GetScriptInterpreterCreateCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetRegisterTypeBuilderPluginInfo()
static EmulateInstructionCreateInstance GetEmulateInstructionCreateCallbackForPluginName(llvm::StringRef name)
static lldb::OptionValuePropertiesSP GetSettingForSymbolFilePlugin(Debugger &debugger, llvm::StringRef setting_name)
static bool CreateSettingForStructuredDataPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static size_t GetNumScriptedInterfaces()
static bool CreateSettingForCPlusPlusLanguagePlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static llvm::SmallVector< TraceExporterCallbacks > GetTraceExporterCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetSymbolVendorPluginInfo()
static llvm::SmallVector< RegisteredPluginInfo > GetBugReporterPluginInfo()
static DynamicLoaderCreateInstance GetDynamicLoaderCreateCallbackForPluginName(llvm::StringRef name)
static llvm::SmallVector< EmulateInstructionCreateInstance > GetEmulateInstructionCreateCallbacks()
static PlatformCreateInstance GetPlatformCreateCallbackForPluginName(llvm::StringRef name)
static bool SetProcessPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< llvm::StringRef > GetSaveCorePluginNames()
static llvm::SmallVector< RegisteredPluginInfo > GetOperatingSystemPluginInfo()
static llvm::SmallVector< ScriptedFrameProviderCreateInstance > GetScriptedFrameProviderCreateCallbacks()
static bool SetABIPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetScriptedInterfacePluginInfo()
static lldb::OptionValuePropertiesSP GetSettingForProcessPlugin(Debugger &debugger, llvm::StringRef setting_name)
static ProcessCreateInstance GetProcessCreateCallbackForPluginName(llvm::StringRef name)
static lldb::ScriptedExtension GetScriptedInterfaceExtensionAtIndex(uint32_t idx)
static void AutoCompletePluginName(llvm::StringRef partial_name, CompletionRequest &request)
static llvm::StringRef GetScriptedInterfaceDescriptionAtIndex(uint32_t idx)
static llvm::StringRef GetProcessPluginDescriptionAtIndex(uint32_t idx)
static llvm::StringRef GetProtocolServerPluginNameAtIndex(uint32_t idx)
static bool IsRegisteredObjectFilePluginName(llvm::StringRef name)
static lldb::OptionValuePropertiesSP GetSettingForDynamicLoaderPlugin(Debugger &debugger, llvm::StringRef setting_name)
static bool CreateSettingForDynamicLoaderPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static bool SetLanguagePluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< RegisteredPluginInfo > GetREPLPluginInfo()
static bool SetREPLPluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< HighlighterCreateInstance > GetHighlighterCreateCallbacks()
static llvm::SmallVector< RegisteredPluginInfo > GetUnwindAssemblyPluginInfo()
static llvm::StringRef GetPlatformPluginNameAtIndex(uint32_t idx)
static bool SetSymbolVendorPluginEnabled(llvm::StringRef name, bool enable)
static TraceCreateInstanceFromBundle GetTraceCreateCallback(llvm::StringRef plugin_name)
static void DebuggerInitialize(Debugger &debugger)
static llvm::StringRef GetScriptedInterfaceNameAtIndex(uint32_t idx)
static llvm::SmallVector< ObjectContainerCallbacks > GetObjectContainerCallbacks()
static llvm::StringRef GetProcessPluginNameAtIndex(uint32_t idx)
static ModuleSpec LocateExecutableObjectFile(const ModuleSpec &module_spec, StatisticsMap &map)
static llvm::SmallVector< StructuredDataPluginCallbacks > GetStructuredDataPluginCallbacks()
static LanguageSet GetAllTypeSystemSupportedLanguagesForTypes()
static llvm::Error GetScriptInterpreterError(lldb::ScriptLanguage script_lang)
Returns the error recorded for script_lang, or success.
static llvm::SmallVector< SystemRuntimeCreateInstance > GetSystemRuntimeCreateCallbacks()
static FileSpec GetScriptInterpreterLibraryPath(lldb::ScriptLanguage script_lang)
static bool UnregisterPlugin(ABICreateInstance create_callback)
static FileSpec FindSymbolFileInBundle(const FileSpec &dsym_bundle_fspec, const UUID *uuid, const ArchSpec *arch)
static llvm::SmallVector< RegisteredPluginInfo > GetStructuredDataPluginInfo()
static bool SetSymbolLocatorPluginEnabled(llvm::StringRef name, bool enable)
static ProtocolServerCreateInstance GetProtocolCreateCallbackForPluginName(llvm::StringRef name)
static std::unique_ptr< BugReporter > CreateBugReporterInstance(llvm::StringRef name={})
static llvm::SmallVector< DynamicLoaderCreateInstance > GetDynamicLoaderCreateCallbacks()
static lldb::RegisterTypeBuilderSP GetRegisterTypeBuilder(Target &target)
static llvm::SmallVector< MemoryHistoryCreateInstance > GetMemoryHistoryCreateCallbacks()
static ScriptedInterfaceUsages GetScriptedInterfaceUsagesAtIndex(uint32_t idx)
static ObjectFileCreateMemoryInstance GetObjectFileCreateMemoryCallbackForPluginName(llvm::StringRef name)
static bool CreateSettingForSymbolLocatorPlugin(Debugger &debugger, const lldb::OptionValuePropertiesSP &properties_sp, llvm::StringRef description, bool is_global_property)
static llvm::SmallVector< RegisteredPluginInfo > GetJITLoaderPluginInfo()
static bool SetObjectFilePluginEnabled(llvm::StringRef name, bool enable)
static llvm::SmallVector< PlatformCreateInstance > GetPlatformCreateCallbacks()
PluginNamespace(llvm::StringRef name, GetPluginInfo get_info, SetPluginEnabledAllDomains set_enabled)
Plugin that supports enable/disable in all domains.
std::optional< SetPluginEnabledGlobalDomain > GetSetEnabledGlobalFn() const
std::variant< SetPluginEnabledGlobalDomain, SetPluginEnabledAllDomains > set_enabled_fn
PluginNamespace(llvm::StringRef name, GetPluginInfo get_info, SetPluginEnabledGlobalDomain set_enabled)
Plugin that only supports enable/disable in the global domain.
std::optional< SetPluginEnabledAllDomains > GetSetEnabledAllDomainsFn() const
bool SupportsOnlyDomain(lldb::PluginDomainKind domain) const
static constexpr uint8_t kAllDomains
bool SupportsDomain(lldb::PluginDomainKind domain) const
A class to count time for plugins.
Definition Statistics.h:94
An error handling class.
Definition Status.h:118
Represents UUID's of various sizes.
Definition UUID.h:27
A class that represents a running process on the host machine.
SymbolVendor *(* SymbolVendorCreateInstance)(const lldb::ModuleSP &module_sp, lldb_private::Stream *feedback_strm)
bool(* ObjectFileSaveCore)(const lldb::ProcessSP &process_sp, lldb_private::SaveCoreOptions &options, Status &error)
llvm::Expected< lldb::TraceSP >(* TraceCreateInstanceForLiveProcess)(Process &process)
FileSpec(* ScriptInterpreterGetPath)()
lldb::ScriptInterpreterSP(* ScriptInterpreterCreateInstance)(Debugger &debugger, lldb::ScriptLanguage language)
lldb::RegisterTypeBuilderSP(* RegisterTypeBuilderCreateInstance)(Target &target)
std::function< llvm::SmallVector< RegisteredPluginInfo >()> GetPluginInfo
lldb::ProtocolServerUP(* ProtocolServerCreateInstance)()
LanguageRuntime *(* LanguageRuntimeCreateInstance)(Process *process, lldb::LanguageType language)
lldb::InstrumentationRuntimeType(* InstrumentationRuntimeGetType)()
llvm::Expected< lldb::TraceSP >(* TraceCreateInstanceFromBundle)(const llvm::json::Value &trace_bundle_description, llvm::StringRef session_file_dir, lldb_private::Debugger &debugger)
Trace.
lldb::DisassemblerSP(* DisassemblerCreateInstance)(const ArchSpec &arch, const char *flavor, const char *cpu, const char *features)
std::optional< FileSpec >(* SymbolLocatorLocateExecutableSymbolFile)(const ModuleSpec &module_spec, const FileSpecList &default_search_paths)
std::function< bool(llvm::StringRef, bool)> SetPluginEnabledGlobalDomain
EmulateInstruction *(* EmulateInstructionCreateInstance)(const ArchSpec &arch, InstructionType inst_type)
ObjectContainer *(* ObjectContainerCreateMemoryInstance)(const lldb::ModuleSP &module_sp, lldb::WritableDataBufferSP data_sp, const lldb::ProcessSP &process_sp, lldb::addr_t offset)
void(* DebuggerInitializeCallback)(Debugger &debugger)
std::unique_ptr< Architecture >(* ArchitectureCreateInstance)(const ArchSpec &arch)
lldb::PlatformSP(* PlatformCreateInstance)(bool force, const ArchSpec *arch)
bool(* ScriptedInterfaceCreateInstance)(lldb::ScriptLanguage language, ScriptedInterfaceUsages usages)
SystemRuntime *(* SystemRuntimeCreateInstance)(Process *process)
lldb::ProcessSP(* ProcessCreateInstance)(lldb::TargetSP target_sp, lldb::ListenerSP listener_sp, const FileSpec *crash_file_path, bool can_connect)
UnwindAssembly *(* UnwindAssemblyCreateInstance)(const ArchSpec &arch)
lldb::TypeSystemSP(* TypeSystemCreateInstance)(lldb::LanguageType language, Module *module, Target *target)
lldb::BreakpointPreconditionSP(* LanguageRuntimeGetExceptionPrecondition)(lldb::LanguageType language, bool throw_bp)
ObjectContainer *(* ObjectContainerCreateInstance)(const lldb::ModuleSP &module_sp, lldb::DataBufferSP &data_sp, lldb::offset_t data_offset, const FileSpec *file, lldb::offset_t offset, lldb::offset_t length)
lldb::MemoryHistorySP(* MemoryHistoryCreateInstance)(const lldb::ProcessSP &process_sp)
ObjectFile *(* ObjectFileCreateMemoryInstance)(const lldb::ModuleSP &module_sp, lldb::WritableDataBufferSP data_sp, const lldb::ProcessSP &process_sp, lldb::addr_t offset)
SymbolLocator *(* SymbolLocatorCreateInstance)()
std::unique_ptr< BugReporter >(* BugReporterCreateInstance)()
std::optional< ModuleSpec >(* SymbolLocatorLocateExecutableObjectFile)(const ModuleSpec &module_spec)
lldb::CommandObjectSP(* LanguageRuntimeGetCommandObject)(CommandInterpreter &interpreter)
DynamicLoader *(* DynamicLoaderCreateInstance)(Process *process, bool force)
lldb::StructuredDataPluginSP(* StructuredDataPluginCreateInstance)(Process &process)
lldb::JITLoaderSP(* JITLoaderCreateInstance)(Process *process, bool force)
llvm::Expected< lldb::SyntheticFrameProviderSP >(* SyntheticFrameProviderCreateInstance)(lldb::StackFrameListSP input_frames, const std::vector< lldb_private::ThreadSpec > &thread_specs)
OperatingSystem *(* OperatingSystemCreateInstance)(Process *process, bool force)
lldb::REPLSP(* REPLCreateInstance)(Status &error, lldb::LanguageType language, Debugger *debugger, Target *target, const char *repl_options)
SymbolFile *(* SymbolFileCreateInstance)(lldb::ObjectFileSP objfile_sp)
llvm::Expected< lldb::TraceExporterUP >(* TraceExporterCreateInstance)()
Highlighter *(* HighlighterCreateInstance)(lldb::LanguageType language)
std::optional< FileSpec >(* SymbolLocatorFindSymbolFileInBundle)(const FileSpec &dsym_bundle_fspec, const UUID *uuid, const ArchSpec *arch)
bool(* SymbolLocatorDownloadObjectAndSymbolFile)(ModuleSpec &module_spec, Status &error, bool force_lookup, bool copy_executable)
Language *(* LanguageCreateInstance)(lldb::LanguageType language)
Status(* StructuredDataFilterLaunchInfo)(ProcessLaunchInfo &launch_info, Target *target)
ObjectFile *(* ObjectFileCreateInstance)(const lldb::ModuleSP &module_sp, lldb::DataExtractorSP extractor_sp, lldb::offset_t data_offset, const FileSpec *file, lldb::offset_t file_offset, lldb::offset_t length)
ModuleSpecList(* ObjectFileGetModuleSpecifications)(const FileSpec &file, lldb::DataExtractorSP &extractor_sp, lldb::offset_t file_offset, lldb::offset_t length)
lldb::ABISP(* ABICreateInstance)(lldb::ProcessSP process_sp, const ArchSpec &arch)
llvm::Expected< lldb::SyntheticFrameProviderSP >(* ScriptedFrameProviderCreateInstance)(lldb::StackFrameListSP input_frames, const lldb_private::ScriptedFrameProviderDescriptor &descriptor)
lldb::CommandObjectSP(* ThreadTraceExportCommandCreator)(CommandInterpreter &interpreter)
std::function< llvm::Error( llvm::StringRef, bool, Debugger &, lldb::PluginDomainKind)> SetPluginEnabledAllDomains
lldb::InstrumentationRuntimeSP(* InstrumentationRuntimeCreateInstance)(const lldb::ProcessSP &process_sp)
ScriptLanguage
Script interpreter types.
@ eScriptLanguageUnknown
std::shared_ptr< lldb_private::OptionValueProperties > OptionValuePropertiesSP
ScriptedExtension
Scripting extension types.
std::shared_ptr< lldb_private::ScriptInterpreter > ScriptInterpreterSP
@ ePluginDomainKindTarget
@ ePluginDomainKindGlobal
@ ePluginDomainKindDebugger
std::shared_ptr< lldb_private::RegisterTypeBuilder > RegisterTypeBuilderSP
LanguageType
Programming language type.
InstrumentationRuntimeGetType get_type_callback
InstrumentationRuntimeCreateInstance create_callback
LanguageRuntimeGetExceptionPrecondition precondition_callback
LanguageRuntimeGetCommandObject command_callback
LanguageRuntimeCreateInstance create_callback
A SmallBitVector that represents a set of source languages (lldb::LanguageType).
ObjectContainerCreateMemoryInstance create_memory_callback
ObjectContainerCreateInstance create_callback
ObjectFileGetModuleSpecifications get_module_specifications
ObjectFileCreateMemoryInstance create_memory_callback
ObjectFileCreateInstance create_callback
ObjectFileGetModuleSpecifications get_module_specifications
PluginInstance(llvm::StringRef name, llvm::StringRef description, Callback create_callback, DebuggerInitializeCallback debugger_init_callback=nullptr)
REPLCreateInstance create_callback
ScriptedInterfaceInstance(llvm::StringRef name, llvm::StringRef description, ScriptedInterfaceCreateInstance create_callback, lldb::ScriptedExtension extension, lldb::ScriptLanguage language, ScriptedInterfaceUsages usages)
StructuredDataFilterLaunchInfo filter_callback
StructuredDataPluginCreateInstance create_callback
ThreadTraceExportCommandCreator create_thread_trace_export_command
TraceExporterCreateInstance create_callback