https://github.com/agontarek created https://github.com/llvm/llvm-project/pull/158334
- Introduced a new method `IsNVPTX()` in `ArchSpec` to check for NVPTX architecture. - Implemented the corresponding method in `ArchSpec.cpp` to utilize the existing triple architecture checks. >From 0751dd1fee9237590773d2f2f4e1e0fd8d88cab9 Mon Sep 17 00:00:00 2001 From: Andrew Gontarek <agonta...@nvidia.com> Date: Wed, 10 Sep 2025 12:40:28 -0500 Subject: [PATCH] [LLDB][NVIDIA] Add NVPTX architecture support - Introduced a new method `IsNVPTX()` in `ArchSpec` to check for NVPTX architecture. - Implemented the corresponding method in `ArchSpec.cpp` to utilize the existing triple architecture checks. --- lldb/include/lldb/Utility/ArchSpec.h | 5 +++++ lldb/source/Utility/ArchSpec.cpp | 2 ++ 2 files changed, 7 insertions(+) diff --git a/lldb/include/lldb/Utility/ArchSpec.h b/lldb/include/lldb/Utility/ArchSpec.h index 96bd5e3597b68..361108fd8f0e7 100644 --- a/lldb/include/lldb/Utility/ArchSpec.h +++ b/lldb/include/lldb/Utility/ArchSpec.h @@ -327,6 +327,11 @@ class ArchSpec { /// \return a boolean value. bool IsMIPS() const; + /// If NVPTX architecture return true. + /// + /// \return a boolean value. + bool IsNVPTX() const; + /// Returns a string representing current architecture as a target CPU for /// tools like compiler, disassembler etc. /// diff --git a/lldb/source/Utility/ArchSpec.cpp b/lldb/source/Utility/ArchSpec.cpp index 1b8dae39735df..2a87cc6bf7de9 100644 --- a/lldb/source/Utility/ArchSpec.cpp +++ b/lldb/source/Utility/ArchSpec.cpp @@ -545,6 +545,8 @@ const char *ArchSpec::GetArchitectureName() const { bool ArchSpec::IsMIPS() const { return GetTriple().isMIPS(); } +bool ArchSpec::IsNVPTX() const { return GetTriple().isNVPTX(); } + std::string ArchSpec::GetTargetABI() const { std::string abi; _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits