[LLVM][NVPTX] Add support for griddepcontrol instruction (#123511)
[llvm-project.git] / lldb / source / Plugins / Platform / MacOSX / PlatformMacOSX.h
blobbe844856ef923e6e3e0a25dfc7e2ab48cf66882b
1 //===-- PlatformMacOSX.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 //===----------------------------------------------------------------------===//
9 #ifndef LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMMACOSX_H
10 #define LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMMACOSX_H
12 #include "PlatformDarwinDevice.h"
13 #include "lldb/Target/Platform.h"
14 #include "lldb/Utility/ConstString.h"
15 #include "lldb/Utility/Status.h"
16 #include "lldb/Utility/XcodeSDK.h"
17 #include "lldb/lldb-forward.h"
18 #include "llvm/ADT/SmallVector.h"
19 #include "llvm/ADT/StringRef.h"
21 #include <vector>
23 namespace lldb_private {
24 class ArchSpec;
25 class FileSpec;
26 class FileSpecList;
27 class ModuleSpec;
28 class Process;
29 class Target;
31 class PlatformMacOSX : public PlatformDarwinDevice {
32 public:
33 PlatformMacOSX();
35 static lldb::PlatformSP CreateInstance(bool force, const ArchSpec *arch);
37 static void Initialize();
39 static void Terminate();
41 static llvm::StringRef GetPluginNameStatic() {
42 return Platform::GetHostPlatformName();
45 static llvm::StringRef GetDescriptionStatic();
47 llvm::StringRef GetPluginName() override { return GetPluginNameStatic(); }
49 Status GetSharedModule(const ModuleSpec &module_spec, Process *process,
50 lldb::ModuleSP &module_sp,
51 const FileSpecList *module_search_paths_ptr,
52 llvm::SmallVectorImpl<lldb::ModuleSP> *old_modules,
53 bool *did_create_ptr) override;
55 llvm::StringRef GetDescription() override { return GetDescriptionStatic(); }
57 Status GetFile(const FileSpec &source, const FileSpec &destination) override {
58 return PlatformDarwin::GetFile(source, destination);
61 std::vector<ArchSpec>
62 GetSupportedArchitectures(const ArchSpec &process_host_arch) override;
64 ConstString GetSDKDirectory(Target &target) override;
66 void
67 AddClangModuleCompilationOptions(Target *target,
68 std::vector<std::string> &options) override {
69 return PlatformDarwin::AddClangModuleCompilationOptionsForSDKType(
70 target, options, XcodeSDK::Type::MacOSX);
73 protected:
74 llvm::StringRef GetDeviceSupportDirectoryName() override;
75 llvm::StringRef GetPlatformName() override;
78 } // namespace lldb_private
80 #endif // LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMMACOSX_H