[Lldb-commits] [lldb] 7dd76cc - [LLDB] Skip TestExitDuringExpression on aarch64/linux buildbot
Author: Muhammad Omair Javaid Date: 2021-03-19T15:30:10+05:00 New Revision: 7dd76a02ee59588647f2d97f1b554c48f580 URL: https://github.com/llvm/llvm-project/commit/7dd76a02ee59588647f2d97f1b554c48f580 DIFF: https://github.com/llvm/llvm-project/commit/7dd76a02ee59588647f2d97f1b554c48f580.diff LOG: [LLDB] Skip TestExitDuringExpression on aarch64/linux buildbot TestExitDuringExpression test_exit_before_one_thread_unwind fails sporadically on both Arm and AArch64 linux buildbots. This seems like a thread timing issue. I am marking it skip for now. Added: Modified: lldb/test/API/functionalities/thread/exit_during_expression/TestExitDuringExpression.py Removed: diff --git a/lldb/test/API/functionalities/thread/exit_during_expression/TestExitDuringExpression.py b/lldb/test/API/functionalities/thread/exit_during_expression/TestExitDuringExpression.py index 4ee65c85e8f1..dafc0a967605 100644 --- a/lldb/test/API/functionalities/thread/exit_during_expression/TestExitDuringExpression.py +++ b/lldb/test/API/functionalities/thread/exit_during_expression/TestExitDuringExpression.py @@ -15,7 +15,7 @@ class TestExitDuringExpression(TestBase): NO_DEBUG_INFO_TESTCASE = True @skipIfWindows -@skipIf(oslist=["linux"], archs=["arm"], bugnumber="llvm.org/pr48414") +@skipIf(oslist=["linux"], archs=["arm", "aarch64"], bugnumber="llvm.org/pr48414") @expectedFailureAll(oslist=["freebsd"], bugnumber="llvm.org/pr48414") @expectedFailureNetBSD def test_exit_before_one_thread_unwind(self): ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5367831 - Support GDB remote g packet partial read
Author: Muhammad Omair Javaid Date: 2021-03-02T17:21:48+05:00 New Revision: 536783170f0843838b2d521f8a0331f174f60e3c URL: https://github.com/llvm/llvm-project/commit/536783170f0843838b2d521f8a0331f174f60e3c DIFF: https://github.com/llvm/llvm-project/commit/536783170f0843838b2d521f8a0331f174f60e3c.diff LOG: Support GDB remote g packet partial read GDB remote protocol does not specify length of g packet for register read. It depends on remote to include all or exclude certain registers from g packet. In case a register or set of registers is not included as part of g packet then we should fall back to p packet for reading all registers excluded from g packet by remote. This patch adds support for above feature and adds a test-case for the same. Reviewed By: labath Differential Revision: https://reviews.llvm.org/D97498 Added: lldb/test/API/functionalities/gdb_remote_client/TestPartialGPacket.py Modified: lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h Removed: diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp index b607b156d7b4..1f50194e82f4 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp @@ -36,7 +36,7 @@ GDBRemoteRegisterContext::GDBRemoteRegisterContext( : RegisterContext(thread, concrete_frame_idx), m_reg_info_sp(std::move(reg_info_sp)), m_reg_valid(), m_reg_data(), m_read_all_at_once(read_all_at_once), - m_write_all_at_once(write_all_at_once) { + m_write_all_at_once(write_all_at_once), m_gpacket_cached(false) { // Resize our vector of bools to contain one bool for every register. We will // use these boolean values to know when a register value is valid in // m_reg_data. @@ -57,6 +57,7 @@ void GDBRemoteRegisterContext::InvalidateAllRegisters() { } void GDBRemoteRegisterContext::SetAllRegisterValid(bool b) { + m_gpacket_cached = b; std::vector::iterator pos, end = m_reg_valid.end(); for (pos = m_reg_valid.begin(); pos != end; ++pos) *pos = b; @@ -200,7 +201,7 @@ bool GDBRemoteRegisterContext::ReadRegisterBytes(const RegisterInfo *reg_info, const uint32_t reg = reg_info->kinds[eRegisterKindLLDB]; if (!GetRegisterIsValid(reg)) { -if (m_read_all_at_once) { +if (m_read_all_at_once && !m_gpacket_cached) { if (DataBufferSP buffer_sp = gdb_comm.ReadAllRegisters(m_thread.GetProtocolID())) { memcpy(const_cast(m_reg_data.GetDataStart()), @@ -221,7 +222,10 @@ bool GDBRemoteRegisterContext::ReadRegisterBytes(const RegisterInfo *reg_info, m_reg_valid[i] = false; } } - return true; + + m_gpacket_cached = true; + if (GetRegisterIsValid(reg)) +return true; } else { Log *log(ProcessGDBRemoteLog::GetLogIfAnyCategoryIsSet(GDBR_LOG_THREAD | GDBR_LOG_PACKETS)); @@ -233,9 +237,9 @@ bool GDBRemoteRegisterContext::ReadRegisterBytes(const RegisterInfo *reg_info, " bytes " "but only got %" PRId64 " bytes.", m_reg_data.GetByteSize(), buffer_sp->GetByteSize()); + return false; } } - return false; } if (reg_info->value_regs) { // Process this composite register request by delegating to the diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h index 252d7b359ee8..18fcb73b9815 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h @@ -118,6 +118,7 @@ class GDBRemoteRegisterContext : public RegisterContext { DataExtractor m_reg_data; bool m_read_all_at_once; bool m_write_all_at_once; + bool m_gpacket_cached; private: // Helper function for ReadRegisterBytes(). diff --git a/lldb/test/API/functionalities/gdb_remote_client/TestPartialGPacket.py b/lldb/test/API/functionalities/gdb_remote_client/TestPartialGPacket.py new file mode 100644 index ..14614875811d --- /dev/null +++ b/lldb/test/API/functionalities/gdb_remote_client/TestPartialGPacket.py @@ -0,0 +1,106 @@ +from __future__ import print_function +import lldb +from lldbsuite.test.lldbtest import * +from lldbsuite.test.decorators import * +from gdbclientutils import * + + +class TestPartialGPacket(GDBRemoteTestBase): + +@skipIfXmlSupportMissing +@skipIfRemote +def test(self): +""" +Test GDB remote fallback to 'p' packet when 'g' packet does not include all registers. +
[Lldb-commits] [lldb] 428b17c - [LLDB] Fix buildbots breakage due to TestGuessLanguage.py
Author: Muhammad Omair Javaid Date: 2021-04-12T15:10:46+05:00 New Revision: 428b17ce70523b1c54cb89095fed39e84f5ca8fc URL: https://github.com/llvm/llvm-project/commit/428b17ce70523b1c54cb89095fed39e84f5ca8fc DIFF: https://github.com/llvm/llvm-project/commit/428b17ce70523b1c54cb89095fed39e84f5ca8fc.diff LOG: [LLDB] Fix buildbots breakage due to TestGuessLanguage.py Fix LLDB buidbot breakage due to D99250. Differential Revision: https://reviews.llvm.org/D99250 Added: Modified: lldb/test/API/commands/frame/language/TestGuessLanguage.py Removed: diff --git a/lldb/test/API/commands/frame/language/TestGuessLanguage.py b/lldb/test/API/commands/frame/language/TestGuessLanguage.py index 7b3515715e3bc..0974a0e1f858b 100644 --- a/lldb/test/API/commands/frame/language/TestGuessLanguage.py +++ b/lldb/test/API/commands/frame/language/TestGuessLanguage.py @@ -70,7 +70,7 @@ def do_test(self): thread = threads[0] c_frame_language = lldb.eLanguageTypeC99 -cxx_frame_language = lldb.eLanguageTypeC_plus_plus_11 +cxx_frame_language = lldb.eLanguageTypeC_plus_plus # gcc emits DW_LANG_C89 even if -std=c99 was specified if "gcc" in self.getCompiler(): c_frame_language = lldb.eLanguageTypeC89 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] c2123a8 - [LLDB] Skip TestMultipleTargets.py on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2021-02-16T01:28:16+05:00 New Revision: c2123a82cd0076c548d2b8c2acc14408681d7f89 URL: https://github.com/llvm/llvm-project/commit/c2123a82cd0076c548d2b8c2acc14408681d7f89 DIFF: https://github.com/llvm/llvm-project/commit/c2123a82cd0076c548d2b8c2acc14408681d7f89.diff LOG: [LLDB] Skip TestMultipleTargets.py on Arm/AArch64 Linux TestMultipleTargets.py fails randomly on Arm/AArch64 Linux buildbot with no reasonable clues. I am marking it skipped for avoiding LLDB buildbot failures due to this test. Added: Modified: lldb/test/API/api/multiple-targets/TestMultipleTargets.py Removed: diff --git a/lldb/test/API/api/multiple-targets/TestMultipleTargets.py b/lldb/test/API/api/multiple-targets/TestMultipleTargets.py index 7931cc4be050..94b09c71ce2f 100644 --- a/lldb/test/API/api/multiple-targets/TestMultipleTargets.py +++ b/lldb/test/API/api/multiple-targets/TestMultipleTargets.py @@ -16,6 +16,7 @@ class TestMultipleTargets(TestBase): mydir = TestBase.compute_mydir(__file__) NO_DEBUG_INFO_TESTCASE = True +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) @skipIfNoSBHeaders @skipIfHostIncompatibleWithRemote @expectedFailureAll( ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] d7e2e97 - [LLDB] Remove typos from NativeRegisterContextLinux_arm*
Author: Muhammad Omair Javaid Date: 2021-08-25T02:55:38+05:00 New Revision: d7e2e9794a3e353e60a956140dcab93980a2a989 URL: https://github.com/llvm/llvm-project/commit/d7e2e9794a3e353e60a956140dcab93980a2a989 DIFF: https://github.com/llvm/llvm-project/commit/d7e2e9794a3e353e60a956140dcab93980a2a989.diff LOG: [LLDB] Remove typos from NativeRegisterContextLinux_arm* This patch removed some typos from NativeRegisterContextLinux_arm and NativeRegisterContextLinux_arm64. Some of the log/error messages were being reported as x86_64. Added: Modified: lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp Removed: diff --git a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp index 91f88280145d2..dcd68ddd279dd 100644 --- a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp @@ -236,14 +236,14 @@ Status NativeRegisterContextLinux_arm::WriteAllRegisterValues( if (!data_sp) { error.SetErrorStringWithFormat( -"NativeRegisterContextLinux_x86_64::%s invalid data_sp provided", +"NativeRegisterContextLinux_arm::%s invalid data_sp provided", __FUNCTION__); return error; } if (data_sp->GetByteSize() != REG_CONTEXT_SIZE) { error.SetErrorStringWithFormat( -"NativeRegisterContextLinux_x86_64::%s data_sp contained mismatched " +"NativeRegisterContextLinux_arm::%s data_sp contained mismatched " "data size, expected %" PRIu64 ", actual %" PRIu64, __FUNCTION__, (uint64_t)REG_CONTEXT_SIZE, data_sp->GetByteSize()); return error; @@ -251,7 +251,7 @@ Status NativeRegisterContextLinux_arm::WriteAllRegisterValues( uint8_t *src = data_sp->GetBytes(); if (src == nullptr) { -error.SetErrorStringWithFormat("NativeRegisterContextLinux_x86_64::%s " +error.SetErrorStringWithFormat("NativeRegisterContextLinux_arm::%s " "DataBuffer::GetBytes() returned a null " "pointer", __FUNCTION__); @@ -401,7 +401,7 @@ Status NativeRegisterContextLinux_arm::GetHardwareBreakHitIndex( uint32_t _index, lldb::addr_t trap_addr) { Log *log(ProcessPOSIXLog::GetLogIfAllCategoriesSet(POSIX_LOG_BREAKPOINTS)); - LLDB_LOGF(log, "NativeRegisterContextLinux_arm64::%s()", __FUNCTION__); + LLDB_LOGF(log, "NativeRegisterContextLinux_arm::%s()", __FUNCTION__); lldb::addr_t break_addr; diff --git a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp index 34a520edb6937..ebde0a499acf7 100644 --- a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp @@ -478,14 +478,14 @@ Status NativeRegisterContextLinux_arm64::WriteAllRegisterValues( if (!data_sp) { error.SetErrorStringWithFormat( -"NativeRegisterContextLinux_x86_64::%s invalid data_sp provided", +"NativeRegisterContextLinux_arm64::%s invalid data_sp provided", __FUNCTION__); return error; } if (data_sp->GetByteSize() != REG_CONTEXT_SIZE) { error.SetErrorStringWithFormat( -"NativeRegisterContextLinux_x86_64::%s data_sp contained mismatched " +"NativeRegisterContextLinux_arm64::%s data_sp contained mismatched " "data size, expected %" PRIu64 ", actual %" PRIu64, __FUNCTION__, REG_CONTEXT_SIZE, data_sp->GetByteSize()); return error; @@ -493,7 +493,7 @@ Status NativeRegisterContextLinux_arm64::WriteAllRegisterValues( uint8_t *src = data_sp->GetBytes(); if (src == nullptr) { -error.SetErrorStringWithFormat("NativeRegisterContextLinux_x86_64::%s " +error.SetErrorStringWithFormat("NativeRegisterContextLinux_arm64::%s " "DataBuffer::GetBytes() returned a null " "pointer", __FUNCTION__); ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 8901f8b - AArch64 SVE restore SVE registers after expression
Author: Muhammad Omair Javaid Date: 2021-09-09T16:06:48+05:00 New Revision: 8901f8beea3a70f92be8c0b80313260502f03727 URL: https://github.com/llvm/llvm-project/commit/8901f8beea3a70f92be8c0b80313260502f03727 DIFF: https://github.com/llvm/llvm-project/commit/8901f8beea3a70f92be8c0b80313260502f03727.diff LOG: AArch64 SVE restore SVE registers after expression This patch fixes register save/restore on expression call to also include SVE registers. This will fix expression calls like: re re p1 p re re p1 In above example register P1 should remain the same before and after the expression evaluation. Reviewed By: DavidSpickett Differential Revision: https://reviews.llvm.org/D108739 Added: Modified: lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.h lldb/source/Plugins/Process/Utility/RegisterInfoPOSIX_arm64.h lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_static_config/TestSVERegisters.py lldb/test/API/commands/register/register/aarch64_sve_registers/rw_access_static_config/main.c Removed: diff --git a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp index ebde0a499acf7..f28bddcb9a99b 100644 --- a/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp @@ -46,8 +46,6 @@ #define HWCAP_PACA (1 << 30) #define HWCAP2_MTE (1 << 18) -#define REG_CONTEXT_SIZE (GetGPRSize() + GetFPRSize()) - using namespace lldb; using namespace lldb_private; using namespace lldb_private::process_linux; @@ -452,30 +450,73 @@ Status NativeRegisterContextLinux_arm64::WriteRegister( Status NativeRegisterContextLinux_arm64::ReadAllRegisterValues( lldb::DataBufferSP _sp) { - Status error; + // AArch64 register data must contain GPRs, either FPR or SVE registers + // and optional MTE register. Pointer Authentication (PAC) registers are + // read-only and will be skiped. - data_sp.reset(new DataBufferHeap(REG_CONTEXT_SIZE, 0)); + // In order to create register data checkpoint we first read all register + // values if not done already and calculate total size of register set data. + // We store all register values in data_sp by copying full PTrace data that + // corresponds to register sets enabled by current register context. + Status error; + uint32_t reg_data_byte_size = GetGPRBufferSize(); error = ReadGPR(); if (error.Fail()) return error; - error = ReadFPR(); + // If SVE is enabled we need not copy FPR separately. + if (GetRegisterInfo().IsSVEEnabled()) { +reg_data_byte_size += GetSVEBufferSize(); +error = ReadAllSVE(); + } else { +reg_data_byte_size += GetFPRSize(); +error = ReadFPR(); + } if (error.Fail()) return error; + if (GetRegisterInfo().IsMTEEnabled()) { +reg_data_byte_size += GetMTEControlSize(); +error = ReadMTEControl(); +if (error.Fail()) + return error; + } + + data_sp.reset(new DataBufferHeap(reg_data_byte_size, 0)); uint8_t *dst = data_sp->GetBytes(); - ::memcpy(dst, GetGPRBuffer(), GetGPRSize()); - dst += GetGPRSize(); - ::memcpy(dst, GetFPRBuffer(), GetFPRSize()); + + ::memcpy(dst, GetGPRBuffer(), GetGPRBufferSize()); + dst += GetGPRBufferSize(); + + if (GetRegisterInfo().IsSVEEnabled()) { +::memcpy(dst, GetSVEBuffer(), GetSVEBufferSize()); +dst += GetSVEBufferSize(); + } else { +::memcpy(dst, GetFPRBuffer(), GetFPRSize()); +dst += GetFPRSize(); + } + + if (GetRegisterInfo().IsMTEEnabled()) +::memcpy(dst, GetMTEControl(), GetMTEControlSize()); return error; } Status NativeRegisterContextLinux_arm64::WriteAllRegisterValues( const lldb::DataBufferSP _sp) { - Status error; + // AArch64 register data must contain GPRs, either FPR or SVE registers + // and optional MTE register. Pointer Authentication (PAC) registers are + // read-only and will be skiped. + + // We store all register values in data_sp by copying full PTrace data that + // corresponds to register sets enabled by current register context. In order + // to restore from register data checkpoint we will first restore GPRs, based + // on size of remaining register data either SVE or FPRs should be restored + // next. SVE is not enabled if we have register data size less than or equal + // to size of GPR + FPR + MTE. + Status error; if (!data_sp) { error.SetErrorStringWithFormat( "NativeRegisterContextLinux_arm64::%s invalid data_sp provided", @@ -483,14 +524,6 @@ Status NativeRegisterContextLinux_arm64::WriteAllRegisterValues( return error; } - if (data_sp->GetByteSize() != REG_CONTEXT_SIZE) { -error.SetErrorStringWithFormat( -
[Lldb-commits] [lldb] c55e021 - [LLDB] Skip TestDyldLaunchLinux.py on Arm/Linux
Author: Muhammad Omair Javaid Date: 2021-09-11T16:18:22+05:00 New Revision: c55e021de40a87c0472593601780aa4c2fea2fc4 URL: https://github.com/llvm/llvm-project/commit/c55e021de40a87c0472593601780aa4c2fea2fc4 DIFF: https://github.com/llvm/llvm-project/commit/c55e021de40a87c0472593601780aa4c2fea2fc4.diff LOG: [LLDB] Skip TestDyldLaunchLinux.py on Arm/Linux TestDyldLaunchLinux.py has been recently added and is failing on LLDB Arm/Linux buildbot. I am marking it skip till I come back and look at it in more detail. Added: Modified: lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py Removed: diff --git a/lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py b/lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py index bf475890035a..9abe7f9e5e6b 100644 --- a/lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py +++ b/lldb/test/API/functionalities/dyld-launch-linux/TestDyldLaunchLinux.py @@ -13,6 +13,7 @@ class TestLinux64LaunchingViaDynamicLoader(TestBase): @skipIf(oslist=no_match(['linux'])) @no_debug_info_test +@skipIf(oslist=["linux"], archs=["arm"]) def test(self): self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 8813bc0 - [LLDB] Skip random fails on Arm/AArch64 Linux buildbot
Author: Muhammad Omair Javaid Date: 2021-08-09T13:53:48+05:00 New Revision: 8813bc02b40c90eeca0b30ec46aa898bd49e1522 URL: https://github.com/llvm/llvm-project/commit/8813bc02b40c90eeca0b30ec46aa898bd49e1522 DIFF: https://github.com/llvm/llvm-project/commit/8813bc02b40c90eeca0b30ec46aa898bd49e1522.diff LOG: [LLDB] Skip random fails on Arm/AArch64 Linux buildbot Following tests fail on Arm/AArch64 randomly with timeouts: TestMultilineNavigation.py TestBatchMode.py TestUnicode.py TestGdbRemote_vContThreads.py I am marking them as skipped until we find a away make to pass reliably. Added: Modified: lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py lldb/test/API/driver/batch_mode/TestBatchMode.py lldb/test/API/iohandler/unicode/TestUnicode.py lldb/test/API/tools/lldb-server/vCont-threads/TestGdbRemote_vContThreads.py Removed: diff --git a/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py b/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py index 0cd0a5d447b56..369ae3fb57a4a 100644 --- a/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py +++ b/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py @@ -19,7 +19,7 @@ class TestCase(PExpectTest): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr48316') -@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot def test_nav_arrow_up(self): """Tests that we can navigate back to the previous line with the up arrow""" self.launch() @@ -43,6 +43,7 @@ def test_nav_arrow_up(self): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr48316') +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot def test_nav_arrow_down(self): """Tests that we can navigate to the next line with the down arrow""" self.launch() @@ -74,6 +75,7 @@ def test_nav_arrow_down(self): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr48316') +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot def test_nav_arrow_up_empty_pr49845(self): """Tests that navigating with the up arrow doesn't crash.""" self.launch() diff --git a/lldb/test/API/driver/batch_mode/TestBatchMode.py b/lldb/test/API/driver/batch_mode/TestBatchMode.py index e5364a460f9ce..d9d75f71de21a 100644 --- a/lldb/test/API/driver/batch_mode/TestBatchMode.py +++ b/lldb/test/API/driver/batch_mode/TestBatchMode.py @@ -16,6 +16,7 @@ class DriverBatchModeTest(PExpectTest): mydir = TestBase.compute_mydir(__file__) source = 'main.c' +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot @expectedFlakeyFreeBSD("llvm.org/pr25172 fails rarely on the buildbot") def test_batch_mode_run_crash(self): """Test that the lldb driver's batch mode works correctly.""" @@ -46,6 +47,7 @@ def test_batch_mode_run_crash(self): self.expect_prompt() self.expect("frame variable touch_me_not", substrs=['(char *) touch_me_not']) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot @expectedFlakeyFreeBSD("llvm.org/pr25172 fails rarely on the buildbot") def test_batch_mode_run_exit(self): """Test that the lldb driver's batch mode works correctly.""" @@ -75,6 +77,7 @@ def test_batch_mode_run_exit(self): import pexpect child.expect(pexpect.EOF) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot @expectedFlakeyFreeBSD("llvm.org/pr25172 fails rarely on the buildbot") def test_batch_mode_launch_stop_at_entry(self): """Test that the lldb driver's batch mode works correctly for process launch.""" @@ -109,6 +112,7 @@ def closeVictim(self): self.victim.close() self.victim = None +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot @expectedFlakeyFreeBSD("llvm.org/pr25172 fails rarely on the buildbot") @expectedFailureNetBSD def test_batch_mode_attach_exit(self): diff --git a/lldb/test/API/iohandler/unicode/TestUnicode.py b/lldb/test/API/iohandler/unicode/TestUnicode.py index c8ff9a6ab32dd..7d239341d59c9 100644 --- a/lldb/test/API/iohandler/unicode/TestUnicode.py +++ b/lldb/test/API/iohandler/unicode/TestUnicode.py @@ -17,6 +17,7 @@ class TestCase(PExpectTest): # PExpect uses many timeouts internally and doesn't play well # under ASAN on a loaded machine.. @skipIfAsan +
[Lldb-commits] [lldb] fd18f0e - Revert "[LLDB][GUI] Expand selected thread tree item by default"
Author: Muhammad Omair Javaid Date: 2021-07-30T13:40:05+05:00 New Revision: fd18f0e84cca023df6cb19e88c07c0e2059f659b URL: https://github.com/llvm/llvm-project/commit/fd18f0e84cca023df6cb19e88c07c0e2059f659b DIFF: https://github.com/llvm/llvm-project/commit/fd18f0e84cca023df6cb19e88c07c0e2059f659b.diff LOG: Revert "[LLDB][GUI] Expand selected thread tree item by default" This reverts commit fed25ddc1c3de59aa1de27e95b349f86896ccb79. There has been sporadic failures in LLDB AArch64/Arm 32 buildbots since this commit. I am temporarily reverting it see if it fixes the issue. Differential Revision: https://reviews.llvm.org/D100243 Added: Modified: lldb/source/Core/IOHandlerCursesGUI.cpp Removed: lldb/test/API/commands/gui/expand-threads-tree/Makefile lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py lldb/test/API/commands/gui/expand-threads-tree/main.c diff --git a/lldb/source/Core/IOHandlerCursesGUI.cpp b/lldb/source/Core/IOHandlerCursesGUI.cpp index 010f9300aa2e5..e824f702aba21 100644 --- a/lldb/source/Core/IOHandlerCursesGUI.cpp +++ b/lldb/source/Core/IOHandlerCursesGUI.cpp @@ -3768,13 +3768,8 @@ class TreeDelegate { virtual void TreeDelegateDrawTreeItem(TreeItem , Window ) = 0; virtual void TreeDelegateGenerateChildren(TreeItem ) = 0; - virtual void TreeDelegateUpdateSelection(TreeItem , int _index, - TreeItem *_item) { -return; - } virtual bool TreeDelegateItemSelected( TreeItem ) = 0; // Return true if we need to update views - virtual bool TreeDelegateExpandRootByDefault() { return false; } }; typedef std::shared_ptr TreeDelegateSP; @@ -3784,10 +3779,7 @@ class TreeItem { TreeItem(TreeItem *parent, TreeDelegate , bool might_have_children) : m_parent(parent), m_delegate(delegate), m_user_data(nullptr), m_identifier(0), m_row_idx(-1), m_children(), -m_might_have_children(might_have_children), m_is_expanded(false) { -if (m_parent == nullptr) - m_is_expanded = m_delegate.TreeDelegateExpandRootByDefault(); - } +m_might_have_children(might_have_children), m_is_expanded(false) {} TreeItem =(const TreeItem ) { if (this != ) { @@ -4016,8 +4008,6 @@ class TreeWindowDelegate : public WindowDelegate { const int num_visible_rows = NumVisibleRows(); m_num_rows = 0; m_root.CalculateRowIndexes(m_num_rows); - m_delegate_sp->TreeDelegateUpdateSelection(m_root, m_selected_row_idx, - m_selected_item); // If we unexpanded while having something selected our total number of // rows is less than the num visible rows, then make sure we show all the @@ -4319,7 +4309,7 @@ class ThreadsTreeDelegate : public TreeDelegate { public: ThreadsTreeDelegate(Debugger ) : TreeDelegate(), m_thread_delegate_sp(), m_debugger(debugger), -m_stop_id(UINT32_MAX), m_update_selection(false) { +m_stop_id(UINT32_MAX) { FormatEntity::Parse("process ${process.id}{, name = ${process.name}}", m_format); } @@ -4347,7 +4337,6 @@ class ThreadsTreeDelegate : public TreeDelegate { void TreeDelegateGenerateChildren(TreeItem ) override { ProcessSP process_sp = GetProcess(); -m_update_selection = false; if (process_sp && process_sp->IsAlive()) { StateType state = process_sp->GetState(); if (StateIsStoppedState(state, true)) { @@ -4356,7 +4345,6 @@ class ThreadsTreeDelegate : public TreeDelegate { return; // Children are already up to date m_stop_id = stop_id; -m_update_selection = true; if (!m_thread_delegate_sp) { // Always expand the thread item the first time we show it @@ -4368,15 +4356,11 @@ class ThreadsTreeDelegate : public TreeDelegate { TreeItem t(, *m_thread_delegate_sp, false); ThreadList = process_sp->GetThreadList(); std::lock_guard guard(threads.GetMutex()); -ThreadSP selected_thread = threads.GetSelectedThread(); size_t num_threads = threads.GetSize(); item.Resize(num_threads, t); for (size_t i = 0; i < num_threads; ++i) { - ThreadSP thread = threads.GetThreadAtIndex(i); - item[i].SetIdentifier(thread->GetID()); + item[i].SetIdentifier(threads.GetThreadAtIndex(i)->GetID()); item[i].SetMightHaveChildren(true); - if (selected_thread->GetID() == thread->GetID()) -item[i].Expand(); } return; } @@ -4384,42 +4368,12 @@ class ThreadsTreeDelegate : public TreeDelegate { item.ClearChildren(); } - void TreeDelegateUpdateSelection(TreeItem , int _index, - TreeItem *_item) override { -if (!m_update_selection) - return; - -ProcessSP process_sp = GetProcess(); -
[Lldb-commits] [lldb] 4b88a94 - Revert "[trace] Introduce Hierarchical Trace Representation (HTR) and add command for Intel PT trace visualization"
Author: Muhammad Omair Javaid Date: 2021-07-29T01:34:24+05:00 New Revision: 4b88a94ebe08054ad88435cc89aaa3b84e41b938 URL: https://github.com/llvm/llvm-project/commit/4b88a94ebe08054ad88435cc89aaa3b84e41b938 DIFF: https://github.com/llvm/llvm-project/commit/4b88a94ebe08054ad88435cc89aaa3b84e41b938.diff LOG: Revert "[trace] Introduce Hierarchical Trace Representation (HTR) and add command for Intel PT trace visualization" This reverts commit aad17c55a8116cd3831d4392d909139702019d65. Breaks LLDB build on 32 bit Arm/Linux bot: https://lab.llvm.org/buildbot/#/builders/17/builds/9497 Differential Revision: https://reviews.llvm.org/D105741 Added: Modified: lldb/source/Plugins/TraceExporter/CMakeLists.txt lldb/source/Plugins/TraceExporter/ctf/CMakeLists.txt lldb/source/Plugins/TraceExporter/ctf/CommandObjectThreadTraceExportCTF.cpp lldb/source/Plugins/TraceExporter/ctf/CommandObjectThreadTraceExportCTF.h lldb/source/Plugins/TraceExporter/ctf/TraceExporterCTFOptions.td Removed: lldb/docs/htr.rst lldb/source/Plugins/TraceExporter/common/CMakeLists.txt lldb/source/Plugins/TraceExporter/common/TraceHTR.cpp lldb/source/Plugins/TraceExporter/common/TraceHTR.h lldb/test/API/commands/trace/TestTraceExport.py lldb/test/API/commands/trace/intelpt-trace/export_ctf_test_program.cpp lldb/test/API/commands/trace/intelpt-trace/export_ctf_test_program.out diff --git a/lldb/docs/htr.rst b/lldb/docs/htr.rst deleted file mode 100644 index fccf385914402..0 --- a/lldb/docs/htr.rst +++ /dev/null @@ -1,47 +0,0 @@ -Hierarchical Trace Representation (HTR) -== -The humongous amount of data processor traces like the ones obtained with Intel PT contain is not digestible to humans in its raw form. Given this, it is useful to summarize these massive traces by extracting useful information. Hierarchical Trace Representation (HTR) is the way lldb represents a summarized trace internally. HTR efficiently stores trace data and allows the trace data to be transformed in a way akin to compiler passes. - -Concepts - -**Block:** One or more contiguous units of the trace. At minimum, the unit of a trace is the load address of an instruction. - -**Block Metadata:** Metadata associated with each *block*. For processor traces, some metadata examples are the number of instructions in the block or information on what functions are called in the block. - -**Layer:** The representation of trace data between passes. For Intel PT there are two types of layers: - - **Instruction Layer:** Composed of the oad addresses of the instructions in the trace. In an effort to save space, - metadata is only stored for instructions that are of interest, not every instruction in the trace. HTR contains a - single instruction layer. - - **Block Layer:** Composed of blocks - a block in *layer n* refers to a sequence of blocks in *layer n - 1*. A block in - *layer 1* refers to a sequence of instructions in *layer 0* (the instruction layer). Metadata is stored for each block in - a block layer. HTR contains one or more block layers. - -**Pass:** A transformation applied to a *layer* that generates a new *layer* that is a more summarized, consolidated representation of the trace data. -A pass merges instructions/blocks based on its specific purpose - for example, a pass designed to summarize a processor trace by function calls would merge all the blocks of a function into a single block representing the entire function.l - -The image below illusrates the transformation of a trace's representation (HTR) - -.. image:: media/htr-example.png - -Passes --- -A *pass* is applied to a *layer* to extract useful information (summarization) and compress the trace representation into a new *layer*. The idea is to have a series of passes where each pass specializes in extracting certain information about the trace. Some examples of potential passes include: identifying functions, identifying loops, or a more general purpose such as identifying long sequences of instructions that are repeated (i.e. Basic Super Block). Below you will find a description of each pass currently implemented in lldb. - -**Basic Super Block Reduction** - -A “basic super block” is the longest sequence of blocks that always occur in the same order. (The concept is akin to “Basic Block'' in compiler theory, but refers to dynamic occurrences rather than CFG nodes). - -The image below shows the "basic super blocks" of the sequence. Each unique "basic super block" is marked with a diff erent color - -.. image:: media/basic_super_block_pass.png - -*Procedure to find all super blocks:* - -- For each block, compute the number of distinct predecessor and successor blocks. - - - **Predecessor** - the block that occurs directly before (to the left of) the current block - - **Successor**
[Lldb-commits] [lldb] a94fbb2 - Revert "Revert "[LLDB][GUI] Expand selected thread tree item by default""
Author: Muhammad Omair Javaid Date: 2021-08-02T05:29:32+05:00 New Revision: a94fbb25de5fef6f20027f5ec9466fec821ba92f URL: https://github.com/llvm/llvm-project/commit/a94fbb25de5fef6f20027f5ec9466fec821ba92f DIFF: https://github.com/llvm/llvm-project/commit/a94fbb25de5fef6f20027f5ec9466fec821ba92f.diff LOG: Revert "Revert "[LLDB][GUI] Expand selected thread tree item by default"" This reverts commit fd18f0e84cca023df6cb19e88c07c0e2059f659b. I reverted this change to see its effect on failing GUI tests on LLDB Arm/AArch64 Linux buildbots. I could not find any evidence against this particular change so reverting it back. Differential Revision: https://reviews.llvm.org/D100243 Added: lldb/test/API/commands/gui/expand-threads-tree/Makefile lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py lldb/test/API/commands/gui/expand-threads-tree/main.c Modified: lldb/source/Core/IOHandlerCursesGUI.cpp Removed: diff --git a/lldb/source/Core/IOHandlerCursesGUI.cpp b/lldb/source/Core/IOHandlerCursesGUI.cpp index e824f702aba21..010f9300aa2e5 100644 --- a/lldb/source/Core/IOHandlerCursesGUI.cpp +++ b/lldb/source/Core/IOHandlerCursesGUI.cpp @@ -3768,8 +3768,13 @@ class TreeDelegate { virtual void TreeDelegateDrawTreeItem(TreeItem , Window ) = 0; virtual void TreeDelegateGenerateChildren(TreeItem ) = 0; + virtual void TreeDelegateUpdateSelection(TreeItem , int _index, + TreeItem *_item) { +return; + } virtual bool TreeDelegateItemSelected( TreeItem ) = 0; // Return true if we need to update views + virtual bool TreeDelegateExpandRootByDefault() { return false; } }; typedef std::shared_ptr TreeDelegateSP; @@ -3779,7 +3784,10 @@ class TreeItem { TreeItem(TreeItem *parent, TreeDelegate , bool might_have_children) : m_parent(parent), m_delegate(delegate), m_user_data(nullptr), m_identifier(0), m_row_idx(-1), m_children(), -m_might_have_children(might_have_children), m_is_expanded(false) {} +m_might_have_children(might_have_children), m_is_expanded(false) { +if (m_parent == nullptr) + m_is_expanded = m_delegate.TreeDelegateExpandRootByDefault(); + } TreeItem =(const TreeItem ) { if (this != ) { @@ -4008,6 +4016,8 @@ class TreeWindowDelegate : public WindowDelegate { const int num_visible_rows = NumVisibleRows(); m_num_rows = 0; m_root.CalculateRowIndexes(m_num_rows); + m_delegate_sp->TreeDelegateUpdateSelection(m_root, m_selected_row_idx, + m_selected_item); // If we unexpanded while having something selected our total number of // rows is less than the num visible rows, then make sure we show all the @@ -4309,7 +4319,7 @@ class ThreadsTreeDelegate : public TreeDelegate { public: ThreadsTreeDelegate(Debugger ) : TreeDelegate(), m_thread_delegate_sp(), m_debugger(debugger), -m_stop_id(UINT32_MAX) { +m_stop_id(UINT32_MAX), m_update_selection(false) { FormatEntity::Parse("process ${process.id}{, name = ${process.name}}", m_format); } @@ -4337,6 +4347,7 @@ class ThreadsTreeDelegate : public TreeDelegate { void TreeDelegateGenerateChildren(TreeItem ) override { ProcessSP process_sp = GetProcess(); +m_update_selection = false; if (process_sp && process_sp->IsAlive()) { StateType state = process_sp->GetState(); if (StateIsStoppedState(state, true)) { @@ -4345,6 +4356,7 @@ class ThreadsTreeDelegate : public TreeDelegate { return; // Children are already up to date m_stop_id = stop_id; +m_update_selection = true; if (!m_thread_delegate_sp) { // Always expand the thread item the first time we show it @@ -4356,11 +4368,15 @@ class ThreadsTreeDelegate : public TreeDelegate { TreeItem t(, *m_thread_delegate_sp, false); ThreadList = process_sp->GetThreadList(); std::lock_guard guard(threads.GetMutex()); +ThreadSP selected_thread = threads.GetSelectedThread(); size_t num_threads = threads.GetSize(); item.Resize(num_threads, t); for (size_t i = 0; i < num_threads; ++i) { - item[i].SetIdentifier(threads.GetThreadAtIndex(i)->GetID()); + ThreadSP thread = threads.GetThreadAtIndex(i); + item[i].SetIdentifier(thread->GetID()); item[i].SetMightHaveChildren(true); + if (selected_thread->GetID() == thread->GetID()) +item[i].Expand(); } return; } @@ -4368,12 +4384,42 @@ class ThreadsTreeDelegate : public TreeDelegate { item.ClearChildren(); } + void TreeDelegateUpdateSelection(TreeItem , int _index, + TreeItem *_item) override { +if (!m_update_selection) +
[Lldb-commits] [lldb] 8f30db8 - [LLDB] Skip random failing tests on Arm/AArch64 Linux bots
Author: Muhammad Omair Javaid Date: 2021-08-02T05:24:05+05:00 New Revision: 8f30db8794125db2a768fbb3b20b0b1511ea211c URL: https://github.com/llvm/llvm-project/commit/8f30db8794125db2a768fbb3b20b0b1511ea211c DIFF: https://github.com/llvm/llvm-project/commit/8f30db8794125db2a768fbb3b20b0b1511ea211c.diff LOG: [LLDB] Skip random failing tests on Arm/AArch64 Linux bots Following tests have been failing randomly on LLDB Arm and AArch64 Linux builtbots: TestMultilineNavigation.py TestMultilineCompletion.py TestIOHandlerCompletion.py TestGuiBasic.py I have increased allocated CPU resources to these bots but it has not improved situation to an acceptable level. This patch marks them as skipped on Arm/AArch64 for now. Added: Modified: lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py lldb/test/API/commands/gui/basic/TestGuiBasic.py lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py Removed: diff --git a/lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py b/lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py index 0d6f19f7c6cba..d580d936dc4a2 100644 --- a/lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py +++ b/lldb/test/API/commands/expression/multiline-completion/TestMultilineCompletion.py @@ -31,6 +31,7 @@ def exit_expression_editor(self): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr49408') +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_basic_completion(self): """Test that we can complete a simple multiline expression""" self.build() diff --git a/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py b/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py index 95ad2c8857088..0cd0a5d447b56 100644 --- a/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py +++ b/lldb/test/API/commands/expression/multiline-navigation/TestMultilineNavigation.py @@ -19,6 +19,7 @@ class TestCase(PExpectTest): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr48316') +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_nav_arrow_up(self): """Tests that we can navigate back to the previous line with the up arrow""" self.launch() diff --git a/lldb/test/API/commands/gui/basic/TestGuiBasic.py b/lldb/test/API/commands/gui/basic/TestGuiBasic.py index d501b266cc12c..4e1a0f990a683 100644 --- a/lldb/test/API/commands/gui/basic/TestGuiBasic.py +++ b/lldb/test/API/commands/gui/basic/TestGuiBasic.py @@ -15,6 +15,7 @@ class BasicGuiCommandTest(PExpectTest): # under ASAN on a loaded machine.. @skipIfAsan @skipIfCursesSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_gui(self): self.build() diff --git a/lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py b/lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py index 183143c28cb87..2f49b810fb4c2 100644 --- a/lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py +++ b/lldb/test/API/iohandler/completion/TestIOHandlerCompletion.py @@ -18,6 +18,7 @@ class IOHandlerCompletionTest(PExpectTest): @skipIfAsan @skipIfEditlineSupportMissing @expectedFailureAll(oslist=['freebsd'], bugnumber='llvm.org/pr49408') +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_completion(self): self.launch(dimensions=(100,500)) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 97c6ef4 - [LLDB] Change pexpect timeout to 30 to 60
Author: Muhammad Omair Javaid Date: 2021-08-02T06:34:11+05:00 New Revision: 97c6ef4ea678ef9a69e1feaf9d77a0880bca09ba URL: https://github.com/llvm/llvm-project/commit/97c6ef4ea678ef9a69e1feaf9d77a0880bca09ba DIFF: https://github.com/llvm/llvm-project/commit/97c6ef4ea678ef9a69e1feaf9d77a0880bca09ba.diff LOG: [LLDB] Change pexpect timeout to 30 to 60 Test dependent on pexpect fail randomly with timeouts on Arm/AArch64 Linux buildbots. I am setting pexpect timeout from 30 to 60. I will revert this back if this doesnt improve random failures. Added: Modified: lldb/packages/Python/lldbsuite/test/lldbpexpect.py lldb/third_party/Python/module/pexpect-4.6/pexpect/spawnbase.py Removed: diff --git a/lldb/packages/Python/lldbsuite/test/lldbpexpect.py b/lldb/packages/Python/lldbsuite/test/lldbpexpect.py index 388e91892888e..f7c0e490105af 100644 --- a/lldb/packages/Python/lldbsuite/test/lldbpexpect.py +++ b/lldb/packages/Python/lldbsuite/test/lldbpexpect.py @@ -23,7 +23,7 @@ class PExpectTest(TestBase): def expect_prompt(self): self.child.expect_exact(self.PROMPT) -def launch(self, executable=None, extra_args=None, timeout=30, dimensions=None): +def launch(self, executable=None, extra_args=None, timeout=60, dimensions=None): logfile = getattr(sys.stdout, 'buffer', sys.stdout) if self.TraceOn() else None diff --git a/lldb/third_party/Python/module/pexpect-4.6/pexpect/spawnbase.py b/lldb/third_party/Python/module/pexpect-4.6/pexpect/spawnbase.py index 4bebe1158478c..589d5ec924656 100644 --- a/lldb/third_party/Python/module/pexpect-4.6/pexpect/spawnbase.py +++ b/lldb/third_party/Python/module/pexpect-4.6/pexpect/spawnbase.py @@ -30,7 +30,7 @@ class SpawnBase(object): pid = None flag_eof = False -def __init__(self, timeout=30, maxread=2000, searchwindowsize=None, +def __init__(self, timeout=60, maxread=2000, searchwindowsize=None, logfile=None, encoding=None, codec_errors='strict'): self.stdin = sys.stdin self.stdout = sys.stdout ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] f2128ab - [LLDB] Skip flaky tests on Arm/AArch64 Linux bots
Author: Muhammad Omair Javaid Date: 2021-08-04T16:57:36+05:00 New Revision: f2128abec2030f6534d46f877e3ab2bcc3b5af4c URL: https://github.com/llvm/llvm-project/commit/f2128abec2030f6534d46f877e3ab2bcc3b5af4c DIFF: https://github.com/llvm/llvm-project/commit/f2128abec2030f6534d46f877e3ab2bcc3b5af4c.diff LOG: [LLDB] Skip flaky tests on Arm/AArch64 Linux bots Following LLDB tests fail randomly on LLDB Arm/AArch64 Linux buildbots. We still not have a reliable solution for these tests to pass consistently. I am marking them skipped for now. TestBreakpointCallbackCommandSource.py TestIOHandlerResize.py TestEditline.py TestGuiViewLarge.py TestGuiExpandThreadsTree.py TestGuiBreakpoints.py Added: Modified: lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py lldb/test/API/iohandler/resize/TestIOHandlerResize.py lldb/test/API/terminal/TestEditline.py Removed: diff --git a/lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py b/lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py index 3d075c013262a..70729594fde4e 100644 --- a/lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py +++ b/lldb/test/API/commands/gui/breakpoints/TestGuiBreakpoints.py @@ -15,6 +15,7 @@ class TestGuiBasicDebugCommandTest(PExpectTest): # under ASAN on a loaded machine.. @skipIfAsan @skipIfCursesSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_gui(self): self.build() diff --git a/lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py b/lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py index 0e095661d3ec8..c3ec4b285ecd0 100644 --- a/lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py +++ b/lldb/test/API/commands/gui/expand-threads-tree/TestGuiExpandThreadsTree.py @@ -17,6 +17,7 @@ class TestGuiExpandThreadsTree(PExpectTest): # under ASAN on a loaded machine.. @skipIfAsan @skipIfCursesSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_gui(self): self.build() diff --git a/lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py b/lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py index d3f75757c743e..b1be950dd2006 100644 --- a/lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py +++ b/lldb/test/API/commands/gui/viewlarge/TestGuiViewLarge.py @@ -17,6 +17,7 @@ class GuiViewLargeCommandTest(PExpectTest): @skipIfCursesSupportMissing @skipIfRemote # "run" command will not work correctly for remote debug @expectedFailureNetBSD +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_gui(self): self.build() diff --git a/lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py b/lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py index 9d1866d41fef6..d504c984855ce 100644 --- a/lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py +++ b/lldb/test/API/functionalities/breakpoint/breakpoint_callback_command_source/TestBreakpointCallbackCommandSource.py @@ -19,6 +19,7 @@ class BreakpointCallbackCommandSource(PExpectTest): # under ASAN on a loaded machine.. @skipIfAsan @skipIfEditlineSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) @skipIf(oslist=["freebsd"], bugnumber="llvm.org/pr48316") def test_breakpoint_callback_command_source(self): self.build() diff --git a/lldb/test/API/iohandler/resize/TestIOHandlerResize.py b/lldb/test/API/iohandler/resize/TestIOHandlerResize.py index 488553fce7247..c1f303288d52e 100644 --- a/lldb/test/API/iohandler/resize/TestIOHandlerResize.py +++ b/lldb/test/API/iohandler/resize/TestIOHandlerResize.py @@ -17,6 +17,7 @@ class IOHandlerCompletionTest(PExpectTest): # under ASAN on a loaded machine.. @skipIfAsan @skipIfEditlineSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_resize(self): # Start with a small window diff --git a/lldb/test/API/terminal/TestEditline.py b/lldb/test/API/terminal/TestEditline.py index 8e1652a504160..26e43a2090cc4 100644 --- a/lldb/test/API/terminal/TestEditline.py +++ b/lldb/test/API/terminal/TestEditline.py @@ -17,6 +17,7 @@ class EditlineTest(PExpectTest): @skipIfAsan @skipIfEditlineSupportMissing +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_left_right_arrow(self): """Test that ctrl+left/right arrow
[Lldb-commits] [lldb] c63cb0c - [LLDB] Skip TestScriptedProcess on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2021-10-11T12:58:21+05:00 New Revision: c63cb0c80ec7eb2dedad6e89fb9a3042b71d3b0f URL: https://github.com/llvm/llvm-project/commit/c63cb0c80ec7eb2dedad6e89fb9a3042b71d3b0f DIFF: https://github.com/llvm/llvm-project/commit/c63cb0c80ec7eb2dedad6e89fb9a3042b71d3b0f.diff LOG: [LLDB] Skip TestScriptedProcess on Arm/AArch64 Linux This is failing on Arm and AArch64 Linux buildbots since the time it was comitted. https://lab.llvm.org/buildbot/#/builders/96/builds/12628 Differential Revision: https://reviews.llvm.org/D107585 Added: Modified: lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py Removed: diff --git a/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py b/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py index 963ba060f949..9f5b804d91a3 100644 --- a/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py +++ b/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py @@ -43,6 +43,7 @@ def test_python_plugin_package(self): self.expect('script dir(ScriptedProcess)', substrs=["launch"]) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_scripted_process_and_scripted_thread(self): """Test that we can launch an lldb scripted process using the SBAPI, check its process ID, read string from memory, check scripted thread ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 483db1c - [LLDB] Remove xfail decorator TestInferiorAssert.py AArch64/Linux
Author: Muhammad Omair Javaid Date: 2021-10-11T14:41:30+05:00 New Revision: 483db1c706864d0940206228dfe64bdcd17faa4e URL: https://github.com/llvm/llvm-project/commit/483db1c706864d0940206228dfe64bdcd17faa4e DIFF: https://github.com/llvm/llvm-project/commit/483db1c706864d0940206228dfe64bdcd17faa4e.diff LOG: [LLDB] Remove xfail decorator TestInferiorAssert.py AArch64/Linux TestInferiorAssert.py test_inferior_asserting_disassemble passes after upgrading LLDB AArch64/Linux buildbot to Ubuntu Focal. Added: Modified: lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py Removed: diff --git a/lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py b/lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py index c533a1e29a12d..5ac4eeb0514af 100644 --- a/lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py +++ b/lldb/test/API/functionalities/inferior-assert/TestInferiorAssert.py @@ -45,9 +45,7 @@ def test_inferior_asserting_register(self): bugnumber="llvm.org/pr21793: need to implement support for detecting assertion / abort on Windows") @expectedFailureAll( oslist=["linux"], -archs=[ -"aarch64", -"arm"], +archs=["arm"], triple=no_match(".*-android"), bugnumber="llvm.org/pr25338") @expectedFailureAll(bugnumber="llvm.org/pr26592", triple='^mips') ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 71ad0f9 - [LLDB] Skip TestClangREPL.py on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2021-10-04T11:50:17+05:00 New Revision: 71ad0f9d4e5b63ccee1ee4146525940849d2c962 URL: https://github.com/llvm/llvm-project/commit/71ad0f9d4e5b63ccee1ee4146525940849d2c962 DIFF: https://github.com/llvm/llvm-project/commit/71ad0f9d4e5b63ccee1ee4146525940849d2c962.diff LOG: [LLDB] Skip TestClangREPL.py on Arm/AArch64 Linux TestClangREPL.py has been failing randomly on Arm/AArch64 Linux buildbot. I am marking it as skipped to reduce false alarms. Added: Modified: lldb/test/API/repl/clang/TestClangREPL.py Removed: diff --git a/lldb/test/API/repl/clang/TestClangREPL.py b/lldb/test/API/repl/clang/TestClangREPL.py index 6fd89a0264ebf..9ad67af74f9d8 100644 --- a/lldb/test/API/repl/clang/TestClangREPL.py +++ b/lldb/test/API/repl/clang/TestClangREPL.py @@ -22,6 +22,7 @@ def expect_repl(self, expr, substrs=[]): # PExpect uses many timeouts internally and doesn't play well # under ASAN on a loaded machine.. @skipIfAsan +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) # Randomly fails on buildbot @skipIfEditlineSupportMissing def test_basic_completion(self): """Test that we can complete a simple multiline expression""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] d2b9d0f - Round XML register bitsize to byte boundary
Author: Muhammad Omair Javaid Date: 2021-10-06T14:03:49+05:00 New Revision: d2b9d0fdda5e8295a2a81276fa6be8ea8d1fd022 URL: https://github.com/llvm/llvm-project/commit/d2b9d0fdda5e8295a2a81276fa6be8ea8d1fd022 DIFF: https://github.com/llvm/llvm-project/commit/d2b9d0fdda5e8295a2a81276fa6be8ea8d1fd022.diff LOG: Round XML register bitsize to byte boundary This patch allows LLDB to accept register sizes which are not aligned to 8 bits bitsize boundary. This fixes a crash in LLDB when connecting to OpenOCD stub. GDB xml description allows for non-aligned bit lengths but they are rounded off to nearest byte during transfer. In case of OpenOCD some of SOC specific system registers were less than a single byte in length and were causing LLDB to crash. Reviewed By: labath Differential Revision: https://reviews.llvm.org/D31 Added: Modified: lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp lldb/test/API/functionalities/gdb_remote_client/TestArmRegisterDefinition.py Removed: diff --git a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp index 4d3a4c7a072a7..66e33592ba632 100644 --- a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp @@ -4257,7 +4257,8 @@ bool ParseRegisters(XMLNode feature_node, GdbServerTargetInfo _info, reg_info.name.SetString(value); } else if (name == "bitsize") { if (llvm::to_integer(value, reg_info.byte_size)) - reg_info.byte_size /= CHAR_BIT; + reg_info.byte_size = + llvm::divideCeil(reg_info.byte_size, CHAR_BIT); } else if (name == "type") { gdb_type = value.str(); } else if (name == "group") { @@ -4319,7 +4320,11 @@ bool ParseRegisters(XMLNode feature_node, GdbServerTargetInfo _info, assert(dwarf_opcode_len == ret_val); UNUSED_IF_ASSERT_DISABLED(ret_val); } else { -printf("unhandled attribute %s = %s\n", name.data(), value.data()); +Log *log(ProcessGDBRemoteLog::GetLogIfAllCategoriesSet( +GDBR_LOG_PROCESS)); +LLDB_LOGF(log, + "ProcessGDBRemote::%s unhandled reg attribute %s = %s", + __FUNCTION__, name.data(), value.data()); } return true; // Keep iterating through all attributes }); @@ -4353,8 +4358,15 @@ bool ParseRegisters(XMLNode feature_node, GdbServerTargetInfo _info, } } -assert(reg_info.byte_size != 0); -registers.push_back(reg_info); +if (reg_info.byte_size == 0) { + Log *log( + ProcessGDBRemoteLog::GetLogIfAllCategoriesSet(GDBR_LOG_PROCESS)); + LLDB_LOGF(log, +"ProcessGDBRemote::%s Skipping zero bitsize register %s", +__FUNCTION__, reg_info.name.AsCString()); +} else + registers.push_back(reg_info); + return true; // Keep iterating through all "reg" elements }); return true; diff --git a/lldb/test/API/functionalities/gdb_remote_client/TestArmRegisterDefinition.py b/lldb/test/API/functionalities/gdb_remote_client/TestArmRegisterDefinition.py index 28424f0f36263..1f4489374c778 100644 --- a/lldb/test/API/functionalities/gdb_remote_client/TestArmRegisterDefinition.py +++ b/lldb/test/API/functionalities/gdb_remote_client/TestArmRegisterDefinition.py @@ -38,6 +38,10 @@ def qXferRead(self, obj, annex, offset, length): + + + + @@ -87,7 +91,7 @@ def readRegister(self, regnum): return "E01" def readRegisters(self): -return "2000f836002000102fcb0008f8360020a0360020200c0020b87f0120b7d100082ed200080001b87f0120" +return
[Lldb-commits] [lldb] 8079236 - [LLDB] XFAIL on Arm/Linux minidebuginfo-set-and-hit-breakpoint.test
Author: Muhammad Omair Javaid Date: 2021-12-03T21:52:21+05:00 New Revision: 80792368bb87eeb9e2042e37337e0f5b1e5abc4b URL: https://github.com/llvm/llvm-project/commit/80792368bb87eeb9e2042e37337e0f5b1e5abc4b DIFF: https://github.com/llvm/llvm-project/commit/80792368bb87eeb9e2042e37337e0f5b1e5abc4b.diff LOG: [LLDB] XFAIL on Arm/Linux minidebuginfo-set-and-hit-breakpoint.test minidebuginfo-set-and-hit-breakpoint.test is failing on Arm/Linux most probably due to an ill formed binary after removal of certain sections from executable. I am marking it as XFAIL for further investigation. Added: Modified: lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test Removed: diff --git a/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test b/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test index a9650614674ea..f361ccb585783 100644 --- a/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test +++ b/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test @@ -1,3 +1,4 @@ +# XFAIL: target-arm && linux-gnu # REQUIRES: system-linux, lzma, xz # We want to keep the symbol "multiplyByThree" in the .dynamic section and not ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 553a872 - [LLDB] Adjust DumpDataExtractorTest.Formats for Windows
Author: Muhammad Omair Javaid Date: 2021-11-04T08:48:26+05:00 New Revision: 553a87246510632b60d8d87913d8e4d5ddc86529 URL: https://github.com/llvm/llvm-project/commit/553a87246510632b60d8d87913d8e4d5ddc86529 DIFF: https://github.com/llvm/llvm-project/commit/553a87246510632b60d8d87913d8e4d5ddc86529.diff LOG: [LLDB] Adjust DumpDataExtractorTest.Formats for Windows Floating point results mismtach between Visual stdio 2019 and previous versions. This adjusts macro accordingly. Added: Modified: lldb/unittests/Core/DumpDataExtractorTest.cpp Removed: diff --git a/lldb/unittests/Core/DumpDataExtractorTest.cpp b/lldb/unittests/Core/DumpDataExtractorTest.cpp index f76014aa938c..f229dacb6e6f 100644 --- a/lldb/unittests/Core/DumpDataExtractorTest.cpp +++ b/lldb/unittests/Core/DumpDataExtractorTest.cpp @@ -187,7 +187,7 @@ TEST(DumpDataExtractorTest, Formats) { // Some normal numbers. TestDump(std::vector{0b011001001000}, lldb::Format::eFormatVectorOfFloat16, -#ifdef _WIN32 +#if defined(_MSC_VER) && _MSC_VER < 1920 // FIXME: This should print the same on all platforms. "{3.14063}"); #else ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] cbd215d - [LIT] Add win32 PLATFORM env var to test config
Author: Muhammad Omair Javaid Date: 2021-11-04T17:42:43+05:00 New Revision: cbd215dfe51df47e020c676a32c2672c573641a8 URL: https://github.com/llvm/llvm-project/commit/cbd215dfe51df47e020c676a32c2672c573641a8 DIFF: https://github.com/llvm/llvm-project/commit/cbd215dfe51df47e020c676a32c2672c573641a8.diff LOG: [LIT] Add win32 PLATFORM env var to test config LIT skips various system environment variables while building test config. It turns out that we require PLATFORM environment variable for detection of x86 vs Arm windows platform. This patch adds system environment variable PLATFORM into LIT test config for detection of win32 Arm platform. Reviewed By: mstorsjo Differential Revision: https://reviews.llvm.org/D113165 Added: Modified: lldb/test/Shell/helper/build.py llvm/utils/lit/lit/llvm/config.py Removed: diff --git a/lldb/test/Shell/helper/build.py b/lldb/test/Shell/helper/build.py index 5689373d37a51..005f12bc09cf8 100755 --- a/lldb/test/Shell/helper/build.py +++ b/lldb/test/Shell/helper/build.py @@ -277,7 +277,10 @@ class MsvcBuilder(Builder): def __init__(self, toolchain_type, args): Builder.__init__(self, toolchain_type, args, '.obj') -self.msvc_arch_str = 'x86' if self.arch == '32' else 'x64' +if os.getenv('PLATFORM') == 'arm64': +self.msvc_arch_str = 'arm' if self.arch == '32' else 'arm64' +else: +self.msvc_arch_str = 'x86' if self.arch == '32' else 'x64' if toolchain_type == 'msvc': # Make sure we're using the appropriate toolchain for the desired diff --git a/llvm/utils/lit/lit/llvm/config.py b/llvm/utils/lit/lit/llvm/config.py index 7bc4b445b75e0..5231271f8fef9 100644 --- a/llvm/utils/lit/lit/llvm/config.py +++ b/llvm/utils/lit/lit/llvm/config.py @@ -38,7 +38,7 @@ def __init__(self, lit_config, config): # Many tools behave strangely if these environment variables aren't # set. self.with_system_environment( -['SystemDrive', 'SystemRoot', 'TEMP', 'TMP']) +['SystemDrive', 'SystemRoot', 'TEMP', 'TMP', 'PLATFORM']) self.use_lit_shell = True global lit_path_displayed ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] b595137 - [LLDB] Fix Cpsr size for WoA64 target
Author: Muhammad Omair Javaid Date: 2021-11-04T17:43:31+05:00 New Revision: b595137fe1c06c6fd72ad3c5b30a7750eeca07c1 URL: https://github.com/llvm/llvm-project/commit/b595137fe1c06c6fd72ad3c5b30a7750eeca07c1 DIFF: https://github.com/llvm/llvm-project/commit/b595137fe1c06c6fd72ad3c5b30a7750eeca07c1.diff LOG: [LLDB] Fix Cpsr size for WoA64 target CPSR on Arm64 is 4 bytes in size but windows on Arm implementation is trying to read/write 8 bytes against a byte register causing LLDB unit tests failures. Ref: https://docs.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-arm64_nt_context Reviewed By: mstorsjo Differential Revision: https://reviews.llvm.org/D112471 Added: Modified: lldb/source/Plugins/Process/Windows/Common/NativeRegisterContextWindows_arm64.cpp lldb/source/Plugins/Process/Windows/Common/arm64/RegisterContextWindows_arm64.cpp Removed: diff --git a/lldb/source/Plugins/Process/Windows/Common/NativeRegisterContextWindows_arm64.cpp b/lldb/source/Plugins/Process/Windows/Common/NativeRegisterContextWindows_arm64.cpp index 1294928e09a5d..fc65945723218 100644 --- a/lldb/source/Plugins/Process/Windows/Common/NativeRegisterContextWindows_arm64.cpp +++ b/lldb/source/Plugins/Process/Windows/Common/NativeRegisterContextWindows_arm64.cpp @@ -220,7 +220,7 @@ Status NativeRegisterContextWindows_arm64::GPRRead(const uint32_t reg, reg_value.SetUInt64(tls_context.Pc); break; case gpr_cpsr_arm64: -reg_value.SetUInt64(tls_context.Cpsr); +reg_value.SetUInt32(tls_context.Cpsr); break; case gpr_w0_arm64: @@ -317,7 +317,7 @@ NativeRegisterContextWindows_arm64::GPRWrite(const uint32_t reg, tls_context.Pc = reg_value.GetAsUInt64(); break; case gpr_cpsr_arm64: -tls_context.Cpsr = reg_value.GetAsUInt64(); +tls_context.Cpsr = reg_value.GetAsUInt32(); break; case gpr_w0_arm64: diff --git a/lldb/source/Plugins/Process/Windows/Common/arm64/RegisterContextWindows_arm64.cpp b/lldb/source/Plugins/Process/Windows/Common/arm64/RegisterContextWindows_arm64.cpp index 10bab7d37561d..3ce288597c86a 100644 --- a/lldb/source/Plugins/Process/Windows/Common/arm64/RegisterContextWindows_arm64.cpp +++ b/lldb/source/Plugins/Process/Windows/Common/arm64/RegisterContextWindows_arm64.cpp @@ -171,7 +171,7 @@ bool RegisterContextWindows_arm64::ReadRegister(const RegisterInfo *reg_info, reg_value.SetUInt64(m_context.Pc); break; case gpr_cpsr: -reg_value.SetUInt64(m_context.Cpsr); +reg_value.SetUInt32(m_context.Cpsr); break; case gpr_w0: @@ -385,7 +385,7 @@ bool RegisterContextWindows_arm64::WriteRegister( m_context.Pc = reg_value.GetAsUInt64(); break; case gpr_cpsr: -m_context.Cpsr = reg_value.GetAsUInt64(); +m_context.Cpsr = reg_value.GetAsUInt32(); break; case fpu_v0: ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 4c8ea90 - [LLDB] Fix LLDB buildbots break due to --image-base
Author: Muhammad Omair Javaid Date: 2021-10-26T12:07:16+05:00 New Revision: 4c8ea90b252eeead9a6943f67444a229147949fb URL: https://github.com/llvm/llvm-project/commit/4c8ea90b252eeead9a6943f67444a229147949fb DIFF: https://github.com/llvm/llvm-project/commit/4c8ea90b252eeead9a6943f67444a229147949fb.diff LOG: [LLDB] Fix LLDB buildbots break due to --image-base LLDB build were failing due to following two test failures: lldb-shell :: ObjectFile/ELF/basic-info.yaml lldb-shell :: SymbolFile/DWARF/x86/debug-types-address-ranges.s There were caused by commit 6506907a0a1a8a789ad7036ef911f7e31213c9a5 Added: Modified: lldb/test/Shell/ObjectFile/ELF/basic-info.yaml lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s Removed: diff --git a/lldb/test/Shell/ObjectFile/ELF/basic-info.yaml b/lldb/test/Shell/ObjectFile/ELF/basic-info.yaml index f9b9e10b07407..13d81bb921f28 100644 --- a/lldb/test/Shell/ObjectFile/ELF/basic-info.yaml +++ b/lldb/test/Shell/ObjectFile/ELF/basic-info.yaml @@ -1,7 +1,7 @@ # REQUIRES: lld # RUN: yaml2obj %s -o %t.o -# RUN: ld.lld %t.o -o %t -image-base 0x47000 +# RUN: ld.lld %t.o -o %t --image-base 0x47000 # RUN: lldb-test object-file %t | FileCheck %s # CHECK: Plugin name: elf diff --git a/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s b/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s index 2d5a9ae515d05..8b3b0e9d56956 100644 --- a/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s +++ b/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s @@ -7,7 +7,7 @@ # REQUIRES: lld # RUN: llvm-mc -dwarf-version=5 -triple x86_64-pc-linux %s -filetype=obj >%t.o -# RUN: ld.lld %t.o -o %t -image-base=0x47000 -z separate-code +# RUN: ld.lld %t.o -o %t --image-base=0x47000 -z separate-code # RUN: %lldb %t -o "image lookup -a 0x48000 -v" -o exit | FileCheck %s # CHECK: CompileUnit: id = {0x0001}, file = "/tmp/a.cc", language = "c++" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] ab5b8ee - [LLDB] Skip HW breakpoints test_step_until on Arm/Linux
Author: Muhammad Omair Javaid Date: 2021-07-28T13:18:14+05:00 New Revision: ab5b8ee1a7a18fe097419e21224ac4f15591bcd7 URL: https://github.com/llvm/llvm-project/commit/ab5b8ee1a7a18fe097419e21224ac4f15591bcd7 DIFF: https://github.com/llvm/llvm-project/commit/ab5b8ee1a7a18fe097419e21224ac4f15591bcd7.diff LOG: [LLDB] Skip HW breakpoints test_step_until on Arm/Linux test_step_until xpasses on some machines while fails on others. I am marking it as skipped for now. Added: Modified: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py Removed: diff --git a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py index f7787bbf68b12..b629d678d08e6 100644 --- a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py +++ b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py @@ -27,7 +27,7 @@ def test_breakpoint(self): breakpoint = target.BreakpointCreateByLocation("main.c", 1) self.assertTrue(breakpoint.IsHardware()) -@expectedFailureIfFn(supports_hw_breakpoints) +@expectedFailureIfFn(supports_hw_breakpoints) def test_step_range(self): """Test stepping when hardware breakpoints are required.""" self.build() @@ -86,6 +86,7 @@ def test_step_over(self): 'error: Could not create hardware breakpoint for thread plan.' ]) +@skipIf(oslist=["linux"], archs=["arm"]) @expectedFailureIfFn(supports_hw_breakpoints) def test_step_until(self): """Test stepping until when hardware breakpoints are required.""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 6cd0e35 - Revert "[LLDB] Skip HW breakpoints test_step_until on Arm/Linux"
Author: Muhammad Omair Javaid Date: 2021-07-28T13:26:06+05:00 New Revision: 6cd0e35f43ac7aab8ff05acb4c5dfaa9071958d5 URL: https://github.com/llvm/llvm-project/commit/6cd0e35f43ac7aab8ff05acb4c5dfaa9071958d5 DIFF: https://github.com/llvm/llvm-project/commit/6cd0e35f43ac7aab8ff05acb4c5dfaa9071958d5.diff LOG: Revert "[LLDB] Skip HW breakpoints test_step_until on Arm/Linux" This reverts commit ab5b8ee1a7a18fe097419e21224ac4f15591bcd7. This caused some failure on buildbots so reverting it for now. Added: Modified: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py Removed: diff --git a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py index b629d678d08e6..f7787bbf68b12 100644 --- a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py +++ b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py @@ -27,7 +27,7 @@ def test_breakpoint(self): breakpoint = target.BreakpointCreateByLocation("main.c", 1) self.assertTrue(breakpoint.IsHardware()) -@expectedFailureIfFn(supports_hw_breakpoints) +@expectedFailureIfFn(supports_hw_breakpoints) def test_step_range(self): """Test stepping when hardware breakpoints are required.""" self.build() @@ -86,7 +86,6 @@ def test_step_over(self): 'error: Could not create hardware breakpoint for thread plan.' ]) -@skipIf(oslist=["linux"], archs=["arm"]) @expectedFailureIfFn(supports_hw_breakpoints) def test_step_until(self): """Test stepping until when hardware breakpoints are required.""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 30308d1 - [LLDB] Skip HW breakpoints test_step_until on Arm/Linux
Author: Muhammad Omair Javaid Date: 2021-07-28T15:30:47+05:00 New Revision: 30308d1eb966afa35ee2fd5c5b47b17eb0382896 URL: https://github.com/llvm/llvm-project/commit/30308d1eb966afa35ee2fd5c5b47b17eb0382896 DIFF: https://github.com/llvm/llvm-project/commit/30308d1eb966afa35ee2fd5c5b47b17eb0382896.diff LOG: [LLDB] Skip HW breakpoints test_step_until on Arm/Linux test_step_until xpasses on some machines while fails on others. Marking it as skipped for now. Added: Modified: lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py Removed: diff --git a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py index f7787bbf68b12..b27b53bc31d56 100644 --- a/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py +++ b/lldb/test/API/functionalities/breakpoint/hardware_breakpoints/require_hw_breakpoints/TestRequireHWBreakpoints.py @@ -13,6 +13,7 @@ class BreakpointLocationsTestCase(HardwareBreakpointTestBase): mydir = TestBase.compute_mydir(__file__) +@skipIf(oslist=["linux"], archs=["arm"]) def supports_hw_breakpoints(self): return super().supports_hw_breakpoints() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 0dc9c88 - [LLDB] Skip TestGuiBasicDebug.py on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2021-07-28T15:30:48+05:00 New Revision: 0dc9c88aa38ed330ddffe92bae79d4066832c38e URL: https://github.com/llvm/llvm-project/commit/0dc9c88aa38ed330ddffe92bae79d4066832c38e DIFF: https://github.com/llvm/llvm-project/commit/0dc9c88aa38ed330ddffe92bae79d4066832c38e.diff LOG: [LLDB] Skip TestGuiBasicDebug.py on Arm/AArch64 Linux TestGuiBasicDebug.py randomly fails due to timeouts sending out false negatives on LLDB Arm and AArch64 Linux buildbots. I havnt found a reliable wayy to set pexpect timeout for this test to pass regularly. Skipping it on Arm and AArch64 Linux to silence buildbot failures. Added: Modified: lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py Removed: diff --git a/lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py b/lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py index beff76e9374f..e0eca428b6bd 100644 --- a/lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py +++ b/lldb/test/API/commands/gui/basicdebug/TestGuiBasicDebug.py @@ -14,6 +14,7 @@ class TestGuiBasicDebugCommandTest(PExpectTest): # PExpect uses many timeouts internally and doesn't play well # under ASAN on a loaded machine.. @skipIfAsan +@skipIf(oslist=["linux"], archs=["arm","aarch64"]) @skipIfCursesSupportMissing def test_gui(self): self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 3dc858f - [LLDB] Skip TestIOHandlerPythonREPLSigint.py on Arm/Linux
Author: Muhammad Omair Javaid Date: 2022-01-14T15:46:54+05:00 New Revision: 3dc858f9847d1c2dc02e92ad703060b1bfa90ad0 URL: https://github.com/llvm/llvm-project/commit/3dc858f9847d1c2dc02e92ad703060b1bfa90ad0 DIFF: https://github.com/llvm/llvm-project/commit/3dc858f9847d1c2dc02e92ad703060b1bfa90ad0.diff LOG: [LLDB] Skip TestIOHandlerPythonREPLSigint.py on Arm/Linux TestIOHandlerPythonREPLSigint.py is failing on Arm/Linux buildbot. I am marking it as skip for now. Added: Modified: lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py Removed: diff --git a/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py b/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py index a1a27c2baded8..20d18ca974744 100644 --- a/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py +++ b/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py @@ -25,6 +25,7 @@ def start_python_repl(self): # under ASAN on a loaded machine.. @skipIfAsan @skipIfWindows +@skipIf(oslist=["linux"], archs=["arm"]) def test_while_evaluating_code(self): """ Tests SIGINT handling while Python code is being evaluated.""" self.start_python_repl() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] de0b4f4 - [LLDB] Skip TestIOHandlerProcessSTDIO.py for Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2022-03-08T14:15:41+05:00 New Revision: de0b4f4b86fdba0c41723484221575c21bc24ab2 URL: https://github.com/llvm/llvm-project/commit/de0b4f4b86fdba0c41723484221575c21bc24ab2 DIFF: https://github.com/llvm/llvm-project/commit/de0b4f4b86fdba0c41723484221575c21bc24ab2.diff LOG: [LLDB] Skip TestIOHandlerProcessSTDIO.py for Arm/AArch64 Linux This patch disables TestIOHandlerProcessSTDIO.py for Arm/AArch64 Linux to silence random test failures on buildbots. IO handler tests are known to randomly fail on arm/aarch64 linux buildbots due to pexpect timeouts. Added: Modified: lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py Removed: diff --git a/lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py b/lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py index 0db9c56f37f93..cdfe173827581 100644 --- a/lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py +++ b/lldb/test/API/iohandler/stdio/TestIOHandlerProcessSTDIO.py @@ -11,6 +11,7 @@ class TestIOHandlerProcessSTDIO(PExpectTest): # PExpect uses many timeouts internally and doesn't play well # under ASAN on a loaded machine.. @skipIfAsan +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test(self): self.build() self.launch(executable=self.getBuildArtifact("a.out")) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 317a2b1 - [LLDB] Remove XFAIL from minidebuginfo-set-and-hit-breakpoint.test
Author: Muhammad Omair Javaid Date: 2022-02-25T15:55:05+05:00 New Revision: 317a2b1f6004708b28969c47b48526f6378c4e64 URL: https://github.com/llvm/llvm-project/commit/317a2b1f6004708b28969c47b48526f6378c4e64 DIFF: https://github.com/llvm/llvm-project/commit/317a2b1f6004708b28969c47b48526f6378c4e64.diff LOG: [LLDB] Remove XFAIL from minidebuginfo-set-and-hit-breakpoint.test This patch removes XFAIL from minidebuginfo-set-and-hit-breakpoint.test. Test started passing after 3c4ed02698afec021c6bca80740d1e58e3ee019e. Differential Revision: https://reviews.llvm.org/D120305 Added: Modified: lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test Removed: diff --git a/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test b/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test index f361ccb585783..a9650614674ea 100644 --- a/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test +++ b/lldb/test/Shell/ObjectFile/ELF/minidebuginfo-set-and-hit-breakpoint.test @@ -1,4 +1,3 @@ -# XFAIL: target-arm && linux-gnu # REQUIRES: system-linux, lzma, xz # We want to keep the symbol "multiplyByThree" in the .dynamic section and not ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] cc7bf4a - [LLDB] XFAIL TestUnambiguousTailCalls.py for Arm/Linux
Author: Muhammad Omair Javaid Date: 2022-02-25T17:09:50+05:00 New Revision: cc7bf4afeefc6d3951871dcb091873243a563646 URL: https://github.com/llvm/llvm-project/commit/cc7bf4afeefc6d3951871dcb091873243a563646 DIFF: https://github.com/llvm/llvm-project/commit/cc7bf4afeefc6d3951871dcb091873243a563646.diff LOG: [LLDB] XFAIL TestUnambiguousTailCalls.py for Arm/Linux This patch marks TestUnambiguousTailCalls.py as XFAIL on Arm/Linux. Test started failing after 3c4ed02698afec021c6bca80740d1e58e3ee019e. Differential Revision: https://reviews.llvm.org/D120305 Added: Modified: lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py Removed: diff --git a/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py b/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py index 19aad2ab1ec32..cef500f0e7754 100644 --- a/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py +++ b/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py @@ -2,6 +2,7 @@ from lldbsuite.test import decorators decor = [decorators.skipUnlessHasCallSiteInfo, + decorators.skipIf(archs=['arm'],oslist=["linux"]), decorators.skipIf(dwarf_version=['<', '4']), decorators.skipIf(compiler="clang", compiler_version=['<', '11.0'])] lldbinline.MakeInlineTest(__file__, globals(), name="UnambiguousTailCalls_V5", ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5c6ee13 - [LLDB] Skip TestProcessIOHandlerInterrupt Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2022-03-28T12:32:49+05:00 New Revision: 5c6ee1305e771bd40b523b4de4df8bffaa2e98ad URL: https://github.com/llvm/llvm-project/commit/5c6ee1305e771bd40b523b4de4df8bffaa2e98ad DIFF: https://github.com/llvm/llvm-project/commit/5c6ee1305e771bd40b523b4de4df8bffaa2e98ad.diff LOG: [LLDB] Skip TestProcessIOHandlerInterrupt Arm/AArch64 Linux This patch skips TestProcessIOHandlerInterrupt on Arm/AArch64. PExpect tests are not stable when run in containerized machine. Added: Modified: lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py Removed: diff --git a/lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py b/lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py index 707c84eeacdac..b1d93b6a30b1c 100644 --- a/lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py +++ b/lldb/test/API/iohandler/sigint/TestProcessIOHandlerInterrupt.py @@ -13,6 +13,7 @@ class TestCase(PExpectTest): mydir = TestBase.compute_mydir(__file__) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test(self): self.build(dictionary={"CXX_SOURCES":"cat.cpp"}) self.launch(executable=self.getBuildArtifact()) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] c103eac - [LLDB] Skip TestJobControl.py AArch64/Arm Linux
Author: Muhammad Omair Javaid Date: 2022-04-01T13:58:20+05:00 New Revision: c103eac9d8596cf154ccf5249f5c919badd831d6 URL: https://github.com/llvm/llvm-project/commit/c103eac9d8596cf154ccf5249f5c919badd831d6 DIFF: https://github.com/llvm/llvm-project/commit/c103eac9d8596cf154ccf5249f5c919badd831d6.diff LOG: [LLDB] Skip TestJobControl.py AArch64/Arm Linux TestJobControl.py is randomly failing on AArch64/Arm Linux buildbots. I am marking it as skipped to make buildbot stable. Added: Modified: lldb/test/API/driver/job_control/TestJobControl.py Removed: diff --git a/lldb/test/API/driver/job_control/TestJobControl.py b/lldb/test/API/driver/job_control/TestJobControl.py index 4faaaf0a9edca..8afa65ac3b271 100644 --- a/lldb/test/API/driver/job_control/TestJobControl.py +++ b/lldb/test/API/driver/job_control/TestJobControl.py @@ -10,7 +10,8 @@ class JobControlTest(PExpectTest): mydir = TestBase.compute_mydir(__file__) - + +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_job_control(self): def post_spawn(): self.child.expect("PID=([0-9]+)") ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] a1901f5 - [LLDB] Fix TestJobControl.py decorators import
Author: Muhammad Omair Javaid Date: 2022-04-01T14:13:11+05:00 New Revision: a1901f501ca971e532f8386b479e13967cd32b93 URL: https://github.com/llvm/llvm-project/commit/a1901f501ca971e532f8386b479e13967cd32b93 DIFF: https://github.com/llvm/llvm-project/commit/a1901f501ca971e532f8386b479e13967cd32b93.diff LOG: [LLDB] Fix TestJobControl.py decorators import Added: Modified: lldb/test/API/driver/job_control/TestJobControl.py Removed: diff --git a/lldb/test/API/driver/job_control/TestJobControl.py b/lldb/test/API/driver/job_control/TestJobControl.py index 8afa65ac3b271..946938273c101 100644 --- a/lldb/test/API/driver/job_control/TestJobControl.py +++ b/lldb/test/API/driver/job_control/TestJobControl.py @@ -2,7 +2,7 @@ Test lldb's handling of job control signals (SIGTSTP, SIGCONT). """ - +from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * from lldbsuite.test.lldbpexpect import PExpectTest ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 73a961b - [LLDB] Port toolchain-msvc.test for Arm/AArch4 Windows
Author: Muhammad Omair Javaid Date: 2022-02-09T17:40:39+05:00 New Revision: 73a961b9cca1ecaa16ca7d9a456961ab6510bd1c URL: https://github.com/llvm/llvm-project/commit/73a961b9cca1ecaa16ca7d9a456961ab6510bd1c DIFF: https://github.com/llvm/llvm-project/commit/73a961b9cca1ecaa16ca7d9a456961ab6510bd1c.diff LOG: [LLDB] Port toolchain-msvc.test for Arm/AArch4 Windows This patch updates toolchain-msvc.test to cater for Arm64 windows platform. Reviewed By: labath Differential Revision: https://reviews.llvm.org/D117676 Added: Modified: lldb/test/Shell/BuildScript/toolchain-msvc.test Removed: diff --git a/lldb/test/Shell/BuildScript/toolchain-msvc.test b/lldb/test/Shell/BuildScript/toolchain-msvc.test index 85a8f0d62f0ca..0ffd44489729f 100644 --- a/lldb/test/Shell/BuildScript/toolchain-msvc.test +++ b/lldb/test/Shell/BuildScript/toolchain-msvc.test @@ -1,62 +1,62 @@ -REQUIRES: system-windows, msvc - -RUN: %build -n --verbose --arch=32 --compiler=msvc --mode=compile-and-link -o %t/foo.exe foobar.c \ -RUN:| FileCheck --check-prefix=X86 %s - -RUN: %build -n --verbose --arch=64 --compiler=msvc --mode=compile-and-link -o %t/foo.exe foobar.c \ -RUN:| FileCheck --check-prefix=X64 %s - -X86: Script Arguments: -X86: Arch: 32 -X86: Compiler: msvc -X86: Outdir: {{.*}} -X86: Output: {{.*}}toolchain-msvc.test.tmp\foo.exe -X86: Nodefaultlib: False -X86: Opt: none -X86: Mode: compile -X86: Clean: True -X86: Verbose: True -X86: Dryrun: True -X86: Inputs: foobar.c -X86: Cleaning {{.*}}toolchain-msvc.test.tmp\foobar.ilk -X86: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe-foobar.obj -X86: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.pdb -X86: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe -X86: compiling foobar.c -> foo.exe-foobar.obj -X86: Command Line: {{.*}}\{{[Hh]ost[Xx]64}}\x86\cl.exe -X86: linking foo.exe-foobar.obj -> foo.exe -X86: Command Line: {{.*}}\{{[Hh]ost[Xx]64}}\x86\link.exe -X86: Env -X86: LIB = {{.*}}\ATLMFC\lib\x86 -X86: {{.*}}\lib\x86 -X86: {{.*}}\ucrt\x86 -X86: {{.*}}\um\x86 -X86: PATH = {{.*}}\bin\{{[Hh]ost[Xx]64}}\x64 - - -X64: Script Arguments: -X64: Arch: 64 -X64: Compiler: msvc -X64: Outdir: {{.*}} -X64: Output: {{.*}}toolchain-msvc.test.tmp\foo.exe -X64: Nodefaultlib: False -X64: Opt: none -X64: Mode: compile -X64: Clean: True -X64: Verbose: True -X64: Dryrun: True -X64: Inputs: foobar.c -X64: Cleaning {{.*}}toolchain-msvc.test.tmp\foobar.ilk -X64: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe-foobar.obj -X64: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.pdb -X64: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe -X64: compiling foobar.c -> foo.exe-foobar.obj -X64: Command Line: {{.*}}\{{[Hh]ost[Xx]64}}\x64\cl.exe -X64: linking foo.exe-foobar.obj -> foo.exe -X64: Command Line: {{.*}}\{{[Hh]ost[Xx]64}}\x64\link.exe -X64: Env -X64: LIB = {{.*}}\ATLMFC\lib\x64 -X64: {{.*}}\lib\x64 -X64: {{.*}}\ucrt\x64 -X64: {{.*}}\um\x64 -X64: PATH = {{.*}}\bin\{{[Hh]ost[Xx]64}}\x64 +REQUIRES: system-windows, msvc + +RUN: %build -n --verbose --arch=32 --compiler=msvc --mode=compile-and-link -o %t/foo.exe foobar.c \ +RUN:| FileCheck --check-prefix=32BIT %s + +RUN: %build -n --verbose --arch=64 --compiler=msvc --mode=compile-and-link -o %t/foo.exe foobar.c \ +RUN:| FileCheck --check-prefix=64BIT %s + +32BIT: Script Arguments: +32BIT: Arch: 32 +32BIT: Compiler: msvc +32BIT: Outdir: {{.*}} +32BIT: Output: {{.*}}toolchain-msvc.test.tmp\foo.exe +32BIT: Nodefaultlib: False +32BIT: Opt: none +32BIT: Mode: compile +32BIT: Clean: True +32BIT: Verbose: True +32BIT: Dryrun: True +32BIT: Inputs: foobar.c +32BIT: Cleaning {{.*}}toolchain-msvc.test.tmp\foobar.ilk +32BIT: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe-foobar.obj +32BIT: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.pdb +32BIT: Cleaning {{.*}}toolchain-msvc.test.tmp\foo.exe +32BIT: compiling foobar.c -> foo.exe-foobar.obj +32BIT: Command Line: {{.*}}\{{[Hh]ost[Xx](64|86)}}\{{(x86|arm)}}\cl.exe +32BIT: linking foo.exe-foobar.obj -> foo.exe +32BIT: Command Line: {{.*}}\{{[Hh]ost[Xx](64|86)}}\{{(x86|arm)}}\link.exe +32BIT: Env +32BIT: LIB = {{.*}}\ATLMFC\lib\{{(x86|arm)}} +32BIT: {{.*}}\lib\{{(x86|arm)}} +32BIT: {{.*}}\ucrt\{{(x86|arm)}} +32BIT: {{.*}}\um\{{(x86|arm)}} +32BIT: PATH = {{.*}}\bin\{{[Hh]ost[Xx](64|86)}}\{{(x86|x64)}} + + +64BIT: Script Arguments: +64BIT: Arch: 64 +64BIT: Compiler: msvc +64BIT: Outdir: {{.*}} +64BIT: Output: {{.*}}toolchain-msvc.test.tmp\foo.exe +64BIT: Nodefaultlib: False +64BIT: Opt: none +64BIT: Mode: compile +64BIT: Clean: True +64BIT: Verbose: True +64BIT: Dryrun: True +64BIT: Inputs: foobar.c +64BIT: Cleaning {{.*}}toolchain-msvc.test.tmp\foobar.ilk +64BIT: Cleaning
[Lldb-commits] [lldb] df13239 - [LLDB] Skip TestIOHandlerPythonREPLSigint.py on AArch64/Linux
Author: Muhammad Omair Javaid Date: 2022-01-15T03:24:26+05:00 New Revision: df13239c1177c1c73fcd3422023f9d1224f57545 URL: https://github.com/llvm/llvm-project/commit/df13239c1177c1c73fcd3422023f9d1224f57545 DIFF: https://github.com/llvm/llvm-project/commit/df13239c1177c1c73fcd3422023f9d1224f57545.diff LOG: [LLDB] Skip TestIOHandlerPythonREPLSigint.py on AArch64/Linux TestIOHandlerPythonREPLSigint.py is running falky on AArch64/Linux buildbot failing randomly. Skipping it for AArch64/Linux as well. Added: Modified: lldb/test/API/commands/watchpoints/multiple_threads/TestWatchpointMultipleThreads.py lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py Removed: diff --git a/lldb/test/API/commands/watchpoints/multiple_threads/TestWatchpointMultipleThreads.py b/lldb/test/API/commands/watchpoints/multiple_threads/TestWatchpointMultipleThreads.py index d6d8cca2f439f..996353d927ca7 100644 --- a/lldb/test/API/commands/watchpoints/multiple_threads/TestWatchpointMultipleThreads.py +++ b/lldb/test/API/commands/watchpoints/multiple_threads/TestWatchpointMultipleThreads.py @@ -23,6 +23,7 @@ def test_watchpoint_before_thread_start(self): """Test that we can hit a watchpoint we set before starting another thread""" self.do_watchpoint_test("Before running the thread") +@skipIfWindows # This test is flaky on Windows def test_watchpoint_after_thread_launch(self): """Test that we can hit a watchpoint we set after launching another thread""" self.do_watchpoint_test("After launching the thread") diff --git a/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py b/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py index 20d18ca974744..79ffb2a7e300c 100644 --- a/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py +++ b/lldb/test/API/iohandler/sigint/TestIOHandlerPythonREPLSigint.py @@ -25,7 +25,7 @@ def start_python_repl(self): # under ASAN on a loaded machine.. @skipIfAsan @skipIfWindows -@skipIf(oslist=["linux"], archs=["arm"]) +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_while_evaluating_code(self): """ Tests SIGINT handling while Python code is being evaluated.""" self.start_python_repl() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 9c4e93c - [LLDB] Adjust compiler-full-path.test for Windows/Arm64
Author: TCWG Date: 2022-01-19T19:47:03+05:00 New Revision: 9c4e93c71a80e9d6d4e9f1e9f90b14a6126e1f47 URL: https://github.com/llvm/llvm-project/commit/9c4e93c71a80e9d6d4e9f1e9f90b14a6126e1f47 DIFF: https://github.com/llvm/llvm-project/commit/9c4e93c71a80e9d6d4e9f1e9f90b14a6126e1f47.diff LOG: [LLDB] Adjust compiler-full-path.test for Windows/Arm64 This patch updates compiler-full-path.test to make sure it passes on Windows Arm64 platform with MSVC. Added: Modified: lldb/test/Shell/BuildScript/compiler-full-path.test Removed: diff --git a/lldb/test/Shell/BuildScript/compiler-full-path.test b/lldb/test/Shell/BuildScript/compiler-full-path.test index 592024e690eb5..5a781f570bd9e 100644 --- a/lldb/test/Shell/BuildScript/compiler-full-path.test +++ b/lldb/test/Shell/BuildScript/compiler-full-path.test @@ -7,5 +7,5 @@ RUN:FileCheck %s --check-prefix=CHECK-MSVC CHECK-CLANG: Command Line: /path/to/my/clang CHECK-SAME: -o -CHECK-MSVC: Command Line: /path/to/my/x64/cl.exe +CHECK-MSVC: Command Line: /path/to/my{{(\/|\\)(arm64|x64)(\/|\\)}}cl.exe CHECK-SAME: /Fo ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] e821914 - [LLDB] Skip TestBSDArchives.py on windows
Author: Muhammad Omair Javaid Date: 2023-09-06T14:03:21+05:00 New Revision: e82191469ec408a39cf13ebe6a7dfb03787f09c1 URL: https://github.com/llvm/llvm-project/commit/e82191469ec408a39cf13ebe6a7dfb03787f09c1 DIFF: https://github.com/llvm/llvm-project/commit/e82191469ec408a39cf13ebe6a7dfb03787f09c1.diff LOG: [LLDB] Skip TestBSDArchives.py on windows This fixes LLDB windows buildbot after updates to TestBSDArchives.py. https://lab.llvm.org/buildbot/#/builders/219/builds/5408 I have marked new failing test as an expected failure on Windows. Added: Modified: lldb/test/API/functionalities/archives/TestBSDArchives.py Removed: diff --git a/lldb/test/API/functionalities/archives/TestBSDArchives.py b/lldb/test/API/functionalities/archives/TestBSDArchives.py index cefcb95cb9e0b6..9ec21ba2e821c1 100644 --- a/lldb/test/API/functionalities/archives/TestBSDArchives.py +++ b/lldb/test/API/functionalities/archives/TestBSDArchives.py @@ -124,6 +124,10 @@ def test_frame_var_errors_when_archive_missing(self): self.check_frame_variable_errors(thread, error_strings) @skipIfRemote +@expectedFailureAll( +oslist=["windows"], +bugnumber="llvm.org/pr24527. Makefile.rules doesn't know how to build static libs on Windows", +) def test_archive_specifications(self): """ Create archives and make sure the information we get when retrieving ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] ec8df0c - [LLDB] Skip TestTlsGlobals.py for Linux Arm/AArch64
Author: Muhammad Omair Javaid Date: 2023-09-28T16:16:41+05:00 New Revision: ec8df0c7e3a3d9e6352a3d8c5c4540a9d0352ca0 URL: https://github.com/llvm/llvm-project/commit/ec8df0c7e3a3d9e6352a3d8c5c4540a9d0352ca0 DIFF: https://github.com/llvm/llvm-project/commit/ec8df0c7e3a3d9e6352a3d8c5c4540a9d0352ca0.diff LOG: [LLDB] Skip TestTlsGlobals.py for Linux Arm/AArch64 Recently added TLS linux support fails on Arm/AArch64. I am skiping test for now and will investigate the issue later. Added: Modified: lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py Removed: diff --git a/lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py b/lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py index a853b284c2cce4d..dfe29b451df0a66 100644 --- a/lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py +++ b/lldb/test/API/lang/c/tls_globals/TestTlsGlobals.py @@ -38,6 +38,7 @@ def setUp(self): # TLS works diff erently on Windows, this would need to be implemented # separately. @skipIfWindows +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) @skipIf(oslist=no_match([lldbplatformutil.getDarwinOSTriples(), "linux"])) def test(self): """Test thread-local storage.""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 8e946fe - Revert "[mlir][complex] Convert complex.abs to arith with fastmath flag"
Author: Muhammad Omair Javaid Date: 2023-08-29T02:01:20+05:00 New Revision: 8e946fec0441e7a4eb4604c806afed20c6930cc4 URL: https://github.com/llvm/llvm-project/commit/8e946fec0441e7a4eb4604c806afed20c6930cc4 DIFF: https://github.com/llvm/llvm-project/commit/8e946fec0441e7a4eb4604c806afed20c6930cc4.diff LOG: Revert "[mlir][complex] Convert complex.abs to arith with fastmath flag" This reverts commit 653f77690bb2473ff405ccc681c73217fae8b748. This breaks lldb-aarch64-windows buildbot. I have reproduced the issue on x86_64 Windows as well. https://lab.llvm.org/buildbot/#/builders/219/builds/5130 Added: lldb/unittests/SymbolFile/PDB/Inputs/test-pdb.exe Modified: mlir/lib/Conversion/ComplexToStandard/ComplexToStandard.cpp mlir/test/Conversion/ComplexToStandard/convert-to-standard.mlir Removed: diff --git a/lldb/unittests/SymbolFile/PDB/Inputs/test-pdb.exe b/lldb/unittests/SymbolFile/PDB/Inputs/test-pdb.exe new file mode 100644 index 00..3a2c64504ed93c Binary files /dev/null and b/lldb/unittests/SymbolFile/PDB/Inputs/test-pdb.exe diff er diff --git a/mlir/lib/Conversion/ComplexToStandard/ComplexToStandard.cpp b/mlir/lib/Conversion/ComplexToStandard/ComplexToStandard.cpp index 2bcec4ea10f92c..9c05cadc2f07e0 100644 --- a/mlir/lib/Conversion/ComplexToStandard/ComplexToStandard.cpp +++ b/mlir/lib/Conversion/ComplexToStandard/ComplexToStandard.cpp @@ -35,18 +35,13 @@ struct AbsOpConversion : public OpConversionPattern { auto loc = op.getLoc(); auto type = op.getType(); -arith::FastMathFlagsAttr fmf = op.getFastMathFlagsAttr(); - Value real = rewriter.create(loc, type, adaptor.getComplex()); Value imag = rewriter.create(loc, type, adaptor.getComplex()); -Value realSqr = -rewriter.create(loc, real, real, fmf.getValue()); -Value imagSqr = -rewriter.create(loc, imag, imag, fmf.getValue()); -Value sqNorm = -rewriter.create(loc, realSqr, imagSqr, fmf.getValue()); +Value realSqr = rewriter.create(loc, real, real); +Value imagSqr = rewriter.create(loc, imag, imag); +Value sqNorm = rewriter.create(loc, realSqr, imagSqr); rewriter.replaceOpWithNewOp(op, sqNorm); return success(); diff --git a/mlir/test/Conversion/ComplexToStandard/convert-to-standard.mlir b/mlir/test/Conversion/ComplexToStandard/convert-to-standard.mlir index bc2ea0dd7a5847..5e8986a4a9a464 100644 --- a/mlir/test/Conversion/ComplexToStandard/convert-to-standard.mlir +++ b/mlir/test/Conversion/ComplexToStandard/convert-to-standard.mlir @@ -707,19 +707,3 @@ func.func @complex_angle(%arg: complex) -> f32 { // CHECK: %[[IMAG:.*]] = complex.im %[[ARG]] : complex // CHECK: %[[RESULT:.*]] = math.atan2 %[[IMAG]], %[[REAL]] : f32 // CHECK: return %[[RESULT]] : f32 - -// - - -// CHECK-LABEL: func @complex_abs_with_fmf -// CHECK-SAME: %[[ARG:.*]]: complex -func.func @complex_abs_with_fmf(%arg: complex) -> f32 { - %abs = complex.abs %arg fastmath : complex - return %abs : f32 -} -// CHECK: %[[REAL:.*]] = complex.re %[[ARG]] : complex -// CHECK: %[[IMAG:.*]] = complex.im %[[ARG]] : complex -// CHECK-DAG: %[[REAL_SQ:.*]] = arith.mulf %[[REAL]], %[[REAL]] fastmath : f32 -// CHECK-DAG: %[[IMAG_SQ:.*]] = arith.mulf %[[IMAG]], %[[IMAG]] fastmath : f32 -// CHECK: %[[SQ_NORM:.*]] = arith.addf %[[REAL_SQ]], %[[IMAG_SQ]] fastmath : f32 -// CHECK: %[[NORM:.*]] = math.sqrt %[[SQ_NORM]] : f32 -// CHECK: return %[[NORM]] : f32 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5341b5f - [LLDB] Update inspect getargspec to getfullargspec
Author: Muhammad Omair Javaid Date: 2022-04-21T01:33:26+05:00 New Revision: 5341b5f8d3cec9a38867bc4745fd680946300b87 URL: https://github.com/llvm/llvm-project/commit/5341b5f8d3cec9a38867bc4745fd680946300b87 DIFF: https://github.com/llvm/llvm-project/commit/5341b5f8d3cec9a38867bc4745fd680946300b87.diff LOG: [LLDB] Update inspect getargspec to getfullargspec This patch replaces getargspec with getfullargspec in funcutils.py. getargspec has been deprecated by python 11x release. This is important to run LLDB testsuite in Windows/Arm64 platform where Python native will be available from python release onwards. Note: getfullargspec is not available in python 2 Reviewed By: labath Differential Revision: https://reviews.llvm.org/D121786 Added: Modified: lldb/packages/Python/lldbsuite/support/funcutils.py Removed: diff --git a/lldb/packages/Python/lldbsuite/support/funcutils.py b/lldb/packages/Python/lldbsuite/support/funcutils.py index 648d95d23d970..af5da0061e1ca 100644 --- a/lldb/packages/Python/lldbsuite/support/funcutils.py +++ b/lldb/packages/Python/lldbsuite/support/funcutils.py @@ -1,7 +1,7 @@ import inspect def requires_self(func): -func_argc = len(inspect.getargspec(func).args) +func_argc = len(inspect.getfullargspec(func).args) if func_argc == 0 or ( getattr( func, ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] e3cd8fe - [LLDB] Skip TestCrashDuringStep.py AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-04-21T05:10:37+05:00 New Revision: e3cd8fedcac31a037a38889abace9e0d0205c451 URL: https://github.com/llvm/llvm-project/commit/e3cd8fedcac31a037a38889abace9e0d0205c451 DIFF: https://github.com/llvm/llvm-project/commit/e3cd8fedcac31a037a38889abace9e0d0205c451.diff LOG: [LLDB] Skip TestCrashDuringStep.py AArch64/Windows TestCrashDuringStep.py hangs on AArch64 windows with no resonable possible fix. I am marking it skipped for now. Added: Modified: lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py Removed: diff --git a/lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py b/lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py index 6a3ef9527746e..e371cd74fa038 100644 --- a/lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py +++ b/lldb/test/API/functionalities/thread/crash_during_step/TestCrashDuringStep.py @@ -20,6 +20,7 @@ def setUp(self): # IO error due to breakpoint at invalid address @expectedFailureAll(triple=re.compile('^mips')) +@skipIf(oslist=['windows'], archs=['aarch64']) def test_step_inst_with(self): """Test thread creation during step-inst handling.""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] b876c23 - Revert "[lldb] Consider binary as module of last resort"
Author: Muhammad Omair Javaid Date: 2022-05-23T11:19:48+05:00 New Revision: b876c23604c748bd267c1fcb0572845ee61549cc URL: https://github.com/llvm/llvm-project/commit/b876c23604c748bd267c1fcb0572845ee61549cc DIFF: https://github.com/llvm/llvm-project/commit/b876c23604c748bd267c1fcb0572845ee61549cc.diff LOG: Revert "[lldb] Consider binary as module of last resort" This reverts commit a3c3482ceb529206b0ae4e7782e5496da5e0879d. It broke LLDB API test TestBadAddressBreakpoints.py Differential revision: https://reviews.llvm.org/D124731 Added: Modified: lldb/source/Breakpoint/BreakpointResolverAddress.cpp lldb/source/Commands/Options.td Removed: lldb/test/API/commands/breakpoint/set/address-nomodule/Makefile lldb/test/API/commands/breakpoint/set/address-nomodule/TestBreakpointAddressNoModule.py lldb/test/API/commands/breakpoint/set/address-nomodule/inferior.c diff --git a/lldb/source/Breakpoint/BreakpointResolverAddress.cpp b/lldb/source/Breakpoint/BreakpointResolverAddress.cpp index 9b6b6d29cbce8..c173fc0c2a7a6 100644 --- a/lldb/source/Breakpoint/BreakpointResolverAddress.cpp +++ b/lldb/source/Breakpoint/BreakpointResolverAddress.cpp @@ -121,27 +121,16 @@ Searcher::CallbackReturn BreakpointResolverAddress::SearchCallback( if (filter.AddressPasses(m_addr)) { if (breakpoint.GetNumLocations() == 0) { - // If the address is just an offset ... - if (!m_addr.IsSectionOffset()) { -ModuleSP containing_module_sp = nullptr; + // If the address is just an offset, and we're given a module, see if we + // can find the appropriate module loaded in the binary, and fix up + // m_addr to use that. + if (!m_addr.IsSectionOffset() && m_module_filespec) { Target = breakpoint.GetTarget(); -if (m_module_filespec) { - // ... and we're given a module, see if we can find the - // appropriate module loaded in the binary, and fix up - // m_addr to use that. - ModuleSpec module_spec(m_module_filespec); - containing_module_sp = - target.GetImages().FindFirstModule(module_spec); -} else { - // ... and we're not given a module, see if the offset is - // somewhere in the executable module. If it is, then we'll - // fix up m_addr to use that. - containing_module_sp = target.GetExecutableModule(); -} -if (containing_module_sp) { +ModuleSpec module_spec(m_module_filespec); +ModuleSP module_sp = target.GetImages().FindFirstModule(module_spec); +if (module_sp) { Address tmp_address; - if (containing_module_sp->ResolveFileAddress(m_addr.GetOffset(), - tmp_address)) + if (module_sp->ResolveFileAddress(m_addr.GetOffset(), tmp_address)) m_addr = tmp_address; } } diff --git a/lldb/source/Commands/Options.td b/lldb/source/Commands/Options.td index 284437887a0b9..c326f8a320748 100644 --- a/lldb/source/Commands/Options.td +++ b/lldb/source/Commands/Options.td @@ -128,15 +128,13 @@ let Command = "breakpoint set" in { Arg<"AddressOrExpression">, Required, Desc<"Set the breakpoint at the specified address. If the address maps " "uniquely to a particular binary, then the address will be converted to " -"a \"file\" address, so that the breakpoint will track that binary+offset " +"a \"file\"address, so that the breakpoint will track that binary+offset " "no matter where the binary eventually loads. Alternately, if you also " "specify the module - with the -s option - then the address will be " "treated as a file address in that module, and resolved accordingly. " "Again, this will allow lldb to track that offset on subsequent reloads. " "The module need not have been loaded at the time you specify this " -"breakpoint, and will get resolved when the module is loaded. If no " -"module is specified, the binary being debugged is considered as a " -"fallback.">; +"breakpoint, and will get resolved when the module is loaded.">; def breakpoint_set_name : Option<"name", "n">, Group<3>, Arg<"FunctionName">, Completion<"Symbol">, Required, Desc<"Set the breakpoint by function name. Can be repeated multiple times " diff --git a/lldb/test/API/commands/breakpoint/set/address-nomodule/Makefile b/lldb/test/API/commands/breakpoint/set/address-nomodule/Makefile deleted file mode 100644 index 7c82a2dde6c2e..0 --- a/lldb/test/API/commands/breakpoint/set/address-nomodule/Makefile +++ /dev/null @@ -1,3 +0,0 @@ -C_SOURCES := inferior.c - -include Makefile.rules diff --git a/lldb/test/API/commands/breakpoint/set/address-nomodule/TestBreakpointAddressNoModule.py
[Lldb-commits] [lldb] ba14e4d - [LLDB] Disable TestGdbRemoteFork* for Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2022-07-05T13:45:26+04:00 New Revision: ba14e4d65cddb6057374c71232e17cbc03be974d URL: https://github.com/llvm/llvm-project/commit/ba14e4d65cddb6057374c71232e17cbc03be974d DIFF: https://github.com/llvm/llvm-project/commit/ba14e4d65cddb6057374c71232e17cbc03be974d.diff LOG: [LLDB] Disable TestGdbRemoteFork* for Arm/AArch64 Linux This test is causing some trouble with LLDB Arm/AArch64 Linux buildbot. I am disabling is temporarily to make buildbot green. Added: Modified: lldb/test/API/tools/lldb-server/TestGdbRemoteFork.py lldb/test/API/tools/lldb-server/TestGdbRemoteForkNonStop.py Removed: diff --git a/lldb/test/API/tools/lldb-server/TestGdbRemoteFork.py b/lldb/test/API/tools/lldb-server/TestGdbRemoteFork.py index 0c169de3f4d06..a67c566d265ba 100644 --- a/lldb/test/API/tools/lldb-server/TestGdbRemoteFork.py +++ b/lldb/test/API/tools/lldb-server/TestGdbRemoteFork.py @@ -7,6 +7,11 @@ class TestGdbRemoteFork(GdbRemoteForkTestBase): +def setUp(self): +GdbRemoteForkTestBase.setUp(self) +if self.getPlatform() == "linux" and self.getArchitecture() in ['arm', 'aarch64']: +self.skipTest("Unsupported for Arm/AArch64 Linux") + @add_test_categories(["fork"]) def test_fork_multithreaded(self): _, _, child_pid, _ = self.start_fork_test(["thread:new"]*2 + ["fork"]) diff --git a/lldb/test/API/tools/lldb-server/TestGdbRemoteForkNonStop.py b/lldb/test/API/tools/lldb-server/TestGdbRemoteForkNonStop.py index 764f238a51eea..7ba3764855137 100644 --- a/lldb/test/API/tools/lldb-server/TestGdbRemoteForkNonStop.py +++ b/lldb/test/API/tools/lldb-server/TestGdbRemoteForkNonStop.py @@ -5,6 +5,11 @@ class TestGdbRemoteForkNonStop(GdbRemoteForkTestBase): +def setUp(self): +GdbRemoteForkTestBase.setUp(self) +if self.getPlatform() == "linux" and self.getArchitecture() in ['arm', 'aarch64']: +self.skipTest("Unsupported for Arm/AArch64 Linux") + @add_test_categories(["fork"]) def test_vfork_nonstop(self): parent_pid, parent_tid = self.fork_and_detach_test("vfork", ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 3b2496e - [LLDB] Skip TestTwoHitsOneActual.py on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2022-07-05T15:01:51+04:00 New Revision: 3b2496e8faae2ba99f2d56f11f1cb44b68c353ae URL: https://github.com/llvm/llvm-project/commit/3b2496e8faae2ba99f2d56f11f1cb44b68c353ae DIFF: https://github.com/llvm/llvm-project/commit/3b2496e8faae2ba99f2d56f11f1cb44b68c353ae.diff LOG: [LLDB] Skip TestTwoHitsOneActual.py on Arm/AArch64 Linux This test has some race condition which is making it hang on LLDB Arm/AArch64 Linux buildbot. I am marking it as skipped until we investigate whats going wrong. Added: Modified: lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py Removed: diff --git a/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py b/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py index 530e715d3c3a9..cd3c314358f75 100644 --- a/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py +++ b/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py @@ -14,6 +14,7 @@ class TestTwoHitsOneActual(TestBase): NO_DEBUG_INFO_TESTCASE = True +@skipIf(oslist=["linux"], archs=["arm", "aarch64"]) def test_two_hits_one_actual(self): """There can be many tests in a test case - describe this test here.""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] b7b1109 - [LLDB] Fix decorator import in TestTwoHitsOneActual.py
Author: Muhammad Omair Javaid Date: 2022-07-05T15:26:26+04:00 New Revision: b7b11091efd2f9e5e90bc449b1c2591ae0af9648 URL: https://github.com/llvm/llvm-project/commit/b7b11091efd2f9e5e90bc449b1c2591ae0af9648 DIFF: https://github.com/llvm/llvm-project/commit/b7b11091efd2f9e5e90bc449b1c2591ae0af9648.diff LOG: [LLDB] Fix decorator import in TestTwoHitsOneActual.py Added: Modified: lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py Removed: diff --git a/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py b/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py index cd3c314358f7..6e5c721b6900 100644 --- a/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py +++ b/lldb/test/API/functionalities/breakpoint/two_hits_one_actual/TestTwoHitsOneActual.py @@ -7,6 +7,7 @@ import lldb import lldbsuite.test.lldbutil as lldbutil +from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5cca2ef - [LLDB] Remove TestLoadUnload.py Arm/Linux Xfail decorator
Author: Muhammad Omair Javaid Date: 2022-07-06T01:14:40+04:00 New Revision: 5cca2ef3c35a08ce439e65e04a8d18d5bb4a6e4e URL: https://github.com/llvm/llvm-project/commit/5cca2ef3c35a08ce439e65e04a8d18d5bb4a6e4e DIFF: https://github.com/llvm/llvm-project/commit/5cca2ef3c35a08ce439e65e04a8d18d5bb4a6e4e.diff LOG: [LLDB] Remove TestLoadUnload.py Arm/Linux Xfail decorator This patch removes Xfail decorator from TestLoadUnload.py as it is now passing on Arm/Linux buildbot. Added: Modified: lldb/test/API/functionalities/load_unload/TestLoadUnload.py Removed: diff --git a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py index eb5c5592cd8c7..58123251a64e5 100644 --- a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py +++ b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py @@ -295,7 +295,6 @@ def run_lldb_process_load_and_unload_commands(self): self.runCmd("process continue") @expectedFailureAll(oslist=["windows"]) # breakpoint not hit -@expectedFailureAll(oslist=["linux"], archs=["arm"]) # Fails on ubuntu jammy def test_load_unload(self): self.setSvr4Support(False) self.run_load_unload() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] bb9b30f - [LLDB] Remove TestLoadUnload.py Arm/Linux Xfail decorator
Author: Muhammad Omair Javaid Date: 2022-07-06T01:39:52+04:00 New Revision: bb9b30ffbe7c80c94807f01eb31429e4f9f2ce2e URL: https://github.com/llvm/llvm-project/commit/bb9b30ffbe7c80c94807f01eb31429e4f9f2ce2e DIFF: https://github.com/llvm/llvm-project/commit/bb9b30ffbe7c80c94807f01eb31429e4f9f2ce2e.diff LOG: [LLDB] Remove TestLoadUnload.py Arm/Linux Xfail decorator This is a follow up on my last commit where one of the decorator was left unremoved. This patch removes Xfail decorator from TestLoadUnload.py as it is now passing on Arm/Linux buildbot. Added: Modified: lldb/test/API/functionalities/load_unload/TestLoadUnload.py Removed: diff --git a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py index 58123251a64e..70d08f4884c0 100644 --- a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py +++ b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py @@ -201,7 +201,6 @@ def test_dyld_library_path(self): hostoslist=["windows"], triple='.*-android') @expectedFailureAll(oslist=["windows"]) # process load not implemented -@expectedFailureAll(oslist=["linux"], archs=["arm"]) # Fails on ubuntu jammy def test_lldb_process_load_and_unload_commands(self): self.setSvr4Support(False) self.run_lldb_process_load_and_unload_commands() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 695c22c - [LLDB] Fix PDB/pointers.test for 32bit Arm/Windows
Author: Muhammad Omair Javaid Date: 2022-06-29T12:47:02+04:00 New Revision: 695c22c84a36daf0ed12b212c2ac9772f45c61f3 URL: https://github.com/llvm/llvm-project/commit/695c22c84a36daf0ed12b212c2ac9772f45c61f3 DIFF: https://github.com/llvm/llvm-project/commit/695c22c84a36daf0ed12b212c2ac9772f45c61f3.diff LOG: [LLDB] Fix PDB/pointers.test for 32bit Arm/Windows PDB/pointers.test was orignally written for 32bit x86 keeping in mind __cdecl and __stdcall calling conventions which does name mangling for example like adding "_" underscore before function name. This is only x86 specific but purpose of pointers.test is NOT to test calling convention. I am have made a few minor changes to this test which will make it pass when run on Windows/Arm platform. Reviewed By: mstorsjo Differential Revision: https://reviews.llvm.org/D128668 Added: Modified: lldb/test/Shell/SymbolFile/PDB/pointers.test Removed: diff --git a/lldb/test/Shell/SymbolFile/PDB/pointers.test b/lldb/test/Shell/SymbolFile/PDB/pointers.test index a8f84f14783de..841fe8804b44c 100644 --- a/lldb/test/Shell/SymbolFile/PDB/pointers.test +++ b/lldb/test/Shell/SymbolFile/PDB/pointers.test @@ -19,7 +19,7 @@ MAIN-ST-NEXT: int a; MAIN-ST-NEXT: int {{.*}}f(int); MAIN-ST-NEXT:} -MAIN: Function{[[FID1:.*]]}, mangled = _main +MAIN: Function{[[FID1:.*]]}, mangled = {{_?}}main MAIN-NEXT: Block{[[FID1]]} MAIN: Variable{{.*}}, name = "array_pointer" MAIN-SAME:(int (*)[2][4]), scope = local @@ -28,11 +28,11 @@ MAIN-SAME:(int *), scope = local MAIN: Variable{{.*}}, name = "p_member_field" MAIN-SAME:(int ST::*), scope = local MAIN: Variable{{.*}}, name = "p_member_method" -MAIN-SAME:(int (ST::*)(int) __attribute__((thiscall))), scope = local +MAIN-SAME:(int (ST::*)(int){{( __attribute__\(\(thiscall\)\))?}}), scope = local F: Function{[[FID2:.*]]}, demangled = {{.*}}f(int) F-NEXT: Block{[[FID2]]} F: Variable{{.*}}, name = "this" -F-SAME:(ST *), scope = parameter, location = {{.*}}, artificial +F-SAME:(ST *), scope = parameter,{{( location = DW_OP.*,)?}} artificial F: Variable{{.*}}, name = "x" F-SAME:(int), scope = parameter, decl = PointerTypeTest.cpp:8 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 01bc838 - [LLDB] Add PDB/calling-conventions.test for Arm/Windows
Author: Muhammad Omair Javaid Date: 2022-06-29T12:58:16+04:00 New Revision: 01bc838e4512ad645f72afd1d6b613d12c929aa4 URL: https://github.com/llvm/llvm-project/commit/01bc838e4512ad645f72afd1d6b613d12c929aa4 DIFF: https://github.com/llvm/llvm-project/commit/01bc838e4512ad645f72afd1d6b613d12c929aa4.diff LOG: [LLDB] Add PDB/calling-conventions.test for Arm/Windows This patch renames PDB/calling-conventions.test to calling-conventions-x86.test. Also restrict it to run only for target-x86*. This patch also adds a arm specific test PDB/calling-conventions-arm.test which tests that x86 specifc calling convention decorators are ignored by Arm compiler. Reviewed By: labath Differential Revision: https://reviews.llvm.org/D128678 Added: lldb/test/Shell/SymbolFile/PDB/calling-conventions-arm.test lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test Modified: Removed: lldb/test/Shell/SymbolFile/PDB/calling-conventions.test diff --git a/lldb/test/Shell/SymbolFile/PDB/calling-conventions-arm.test b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-arm.test new file mode 100644 index 0..07dc89d460293 --- /dev/null +++ b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-arm.test @@ -0,0 +1,11 @@ +REQUIRES: system-windows, lld, (target-arm || target-aarch64) +RUN: %build --compiler=clang-cl --arch=32 --nodefaultlib --output=%t.exe %S/Inputs/CallingConventionsTest.cpp +RUN: %build --compiler=clang-cl --arch=64 --nodefaultlib --output=%t.exe %S/Inputs/CallingConventionsTest.cpp +RUN: lldb-test symbols -dump-ast %t.exe | FileCheck %s + +CHECK: Module: {{.*}} +CHECK-DAG: int (*FuncCCallPtr)(); +CHECK-DAG: int (*FuncStdCallPtr)(); +CHECK-DAG: int (*FuncFastCallPtr)(); +CHECK-DAG: int (*FuncVectorCallPtr)(); +CHECK-DAG: int (S::*FuncThisCallPtr)(); diff --git a/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test new file mode 100644 index 0..065c8b69b06dd --- /dev/null +++ b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test @@ -0,0 +1,19 @@ +REQUIRES: system-windows, lld, (target-x86 || target-x86_64) +RUN: %build --compiler=clang-cl --arch=32 --nodefaultlib --output=%t.exe %S/Inputs/CallingConventionsTest.cpp \ +RUN: && lldb-test symbols -dump-ast %t.exe | FileCheck --check-prefix 32BIT-CHECK %s +RUN: %build --compiler=clang-cl --arch=64 --nodefaultlib --output=%t.exe %S/Inputs/CallingConventionsTest.cpp \ +RUN: && lldb-test symbols -dump-ast %t.exe | FileCheck --check-prefix 64BIT-CHECK %s + +64BIT-CHECK: Module: {{.*}} +64BIT-CHECK-DAG: int (*FuncCCallPtr)(); +64BIT-CHECK-DAG: int (*FuncStdCallPtr)(); +64BIT-CHECK-DAG: int (*FuncFastCallPtr)(); +64BIT-CHECK-DAG: int (*FuncVectorCallPtr)() __attribute__((vectorcall)); +64BIT-CHECK-DAG: int (S::*FuncThisCallPtr)(); + +32BIT-CHECK: Module: {{.*}} +32BIT-CHECK-DAG: int (*FuncCCallPtr)(); +32BIT-CHECK-DAG: int (*FuncStdCallPtr)() __attribute__((stdcall)); +32BIT-CHECK-DAG: int (*FuncFastCallPtr)() __attribute__((fastcall)); +32BIT-CHECK-DAG: int (*FuncVectorCallPtr)() __attribute__((vectorcall)); +32BIT-CHECK-DAG: int (S::*FuncThisCallPtr)() __attribute__((thiscall)); diff --git a/lldb/test/Shell/SymbolFile/PDB/calling-conventions.test b/lldb/test/Shell/SymbolFile/PDB/calling-conventions.test deleted file mode 100644 index a85dc65ff04dd..0 --- a/lldb/test/Shell/SymbolFile/PDB/calling-conventions.test +++ /dev/null @@ -1,10 +0,0 @@ -REQUIRES: system-windows, lld -RUN: %build --compiler=clang-cl --arch=32 --nodefaultlib --output=%t.exe %S/Inputs/CallingConventionsTest.cpp -RUN: lldb-test symbols -dump-ast %t.exe | FileCheck %s - -CHECK: Module: {{.*}} -CHECK-DAG: int (*FuncCCallPtr)(); -CHECK-DAG: int (*FuncStdCallPtr)() __attribute__((stdcall)); -CHECK-DAG: int (*FuncFastCallPtr)() __attribute__((fastcall)); -CHECK-DAG: int (*FuncVectorCallPtr)() __attribute__((vectorcall)); -CHECK-DAG: int (S::*FuncThisCallPtr)() __attribute__((thiscall)); ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] a18baf1 - [LLDB] Add Arm64 CodeView to LLDB regnum mapping
Author: Muhammad Omair Javaid Date: 2022-06-29T12:50:57+04:00 New Revision: a18baf16c665aab5631faace24a9d0fdc6b071bf URL: https://github.com/llvm/llvm-project/commit/a18baf16c665aab5631faace24a9d0fdc6b071bf DIFF: https://github.com/llvm/llvm-project/commit/a18baf16c665aab5631faace24a9d0fdc6b071bf.diff LOG: [LLDB] Add Arm64 CodeView to LLDB regnum mapping This patch writes a mapping structure for converting CodeView Arm64 register numbers to LLDB Arm64 regnums. This fixes various symbols and variable location test failures on AArch64/Windows. Reviewed By: DavidSpickett Differential Revision: https://reviews.llvm.org/D128221 Added: Modified: lldb/source/Plugins/SymbolFile/NativePDB/CodeViewRegisterMapping.cpp Removed: diff --git a/lldb/source/Plugins/SymbolFile/NativePDB/CodeViewRegisterMapping.cpp b/lldb/source/Plugins/SymbolFile/NativePDB/CodeViewRegisterMapping.cpp index ca9ddcec287fc..3d8030916c84f 100644 --- a/lldb/source/Plugins/SymbolFile/NativePDB/CodeViewRegisterMapping.cpp +++ b/lldb/source/Plugins/SymbolFile/NativePDB/CodeViewRegisterMapping.cpp @@ -10,10 +10,196 @@ #include "lldb/lldb-defines.h" +#include "Plugins/Process/Utility/lldb-arm64-register-enums.h" #include "Plugins/Process/Utility/lldb-x86-register-enums.h" using namespace lldb_private; +static const uint32_t g_code_view_to_lldb_registers_arm64[] = { +LLDB_INVALID_REGNUM, // NONE +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +gpr_w0_arm64, // ARM64_W0, 10) +gpr_w1_arm64, // ARM64_W1, 11) +gpr_w2_arm64, // ARM64_W2, 12) +gpr_w3_arm64, // ARM64_W3, 13) +gpr_w4_arm64, // ARM64_W4, 14) +gpr_w5_arm64, // ARM64_W5, 15) +gpr_w6_arm64, // ARM64_W6, 16) +gpr_w7_arm64, // ARM64_W7, 17) +gpr_w8_arm64, // ARM64_W8, 18) +gpr_w9_arm64, // ARM64_W9, 19) +gpr_w10_arm64, // ARM64_W10, 20) +gpr_w11_arm64, // ARM64_W11, 21) +gpr_w12_arm64, // ARM64_W12, 22) +gpr_w13_arm64, // ARM64_W13, 23) +gpr_w14_arm64, // ARM64_W14, 24) +gpr_w15_arm64, // ARM64_W15, 25) +gpr_w16_arm64, // ARM64_W16, 26) +gpr_w17_arm64, // ARM64_W17, 27) +gpr_w18_arm64, // ARM64_W18, 28) +gpr_w19_arm64, // ARM64_W19, 29) +gpr_w20_arm64, // ARM64_W20, 30) +gpr_w21_arm64, // ARM64_W21, 31) +gpr_w22_arm64, // ARM64_W22, 32) +gpr_w23_arm64, // ARM64_W23, 33) +gpr_w24_arm64, // ARM64_W24, 34) +gpr_w25_arm64, // ARM64_W25, 35) +gpr_w26_arm64, // ARM64_W26, 36) +gpr_w27_arm64, // ARM64_W27, 37) +gpr_w28_arm64, // ARM64_W28, 38) +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +gpr_x0_arm64, // ARM64_X0, 50) +gpr_x1_arm64, // ARM64_X1, 51) +gpr_x2_arm64, // ARM64_X2, 52) +gpr_x3_arm64, // ARM64_X3, 53) +gpr_x4_arm64, // ARM64_X4, 54) +gpr_x5_arm64, // ARM64_X5, 55) +gpr_x6_arm64, // ARM64_X6, 56) +gpr_x7_arm64, // ARM64_X7, 57) +gpr_x8_arm64, // ARM64_X8, 58) +gpr_x9_arm64, // ARM64_X9, 59) +gpr_x10_arm64, // ARM64_X10, 60) +gpr_x11_arm64, // ARM64_X11, 61) +gpr_x12_arm64, // ARM64_X12, 62) +gpr_x13_arm64, // ARM64_X13, 63) +gpr_x14_arm64, // ARM64_X14, 64) +gpr_x15_arm64, // ARM64_X15, 65) +gpr_x16_arm64, // ARM64_X16, 66) +gpr_x17_arm64, // ARM64_X17, 67) +gpr_x18_arm64, // ARM64_X18, 68) +gpr_x19_arm64, // ARM64_X19, 69) +gpr_x20_arm64, // ARM64_X20, 70) +gpr_x21_arm64, // ARM64_X21, 71) +gpr_x22_arm64, // ARM64_X22, 72) +gpr_x23_arm64, // ARM64_X23, 73) +gpr_x24_arm64, // ARM64_X24, 74) +gpr_x25_arm64, // ARM64_X25, 75) +gpr_x26_arm64, // ARM64_X26, 76) +gpr_x27_arm64, // ARM64_X27, 77) +gpr_x28_arm64, // ARM64_X28, 78) +gpr_fp_arm64, // ARM64_FP, 79) +gpr_lr_arm64, // ARM64_LR, 80) +gpr_sp_arm64, // ARM64_SP, 81) +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +gpr_cpsr_arm64, // ARM64_NZCV, 90) +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, LLDB_INVALID_REGNUM, +fpu_s0_arm64, // (ARM64_S0, 100) +fpu_s1_arm64, // (ARM64_S1, 101) +fpu_s2_arm64, // (ARM64_S2, 102) +fpu_s3_arm64, // (ARM64_S3, 103) +fpu_s4_arm64, // (ARM64_S4, 104) +fpu_s5_arm64, // (ARM64_S5, 105) +fpu_s6_arm64, // (ARM64_S6, 106) +fpu_s7_arm64, // (ARM64_S7, 107) +
[Lldb-commits] [lldb] 3d477bb - [LLDB] Xfail TestStepNoDebug.py AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-01T12:25:43+04:00 New Revision: 3d477bbeee55ca965553778e62085a37d062323f URL: https://github.com/llvm/llvm-project/commit/3d477bbeee55ca965553778e62085a37d062323f DIFF: https://github.com/llvm/llvm-project/commit/3d477bbeee55ca965553778e62085a37d062323f.diff LOG: [LLDB] Xfail TestStepNoDebug.py AArch64/Windows LLDB fails to step in/out/over code with missing debug information. This is only reproducible on AArch64/Windows. I have reported a issue upstream at llvm.org/pr56292 This patch Xfail TestStepNoDebug.py for AArch64/Windows. Added: Modified: lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py Removed: diff --git a/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py b/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py index 9c72b0f03f791..98b80051368a9 100644 --- a/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py +++ b/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py @@ -14,6 +14,7 @@ class StepAvoidsNoDebugTestCase(TestBase): @add_test_categories(['pyapi']) +@expectedFailureAll(archs=["aarch64"], oslist=["windows"], bugnumber="llvm.org/pr56292") def test_step_out_with_python(self): """Test stepping out using avoid-no-debug with dsyms.""" self.build() @@ -31,6 +32,7 @@ def test_step_out_with_python(self): archs=["i386"], oslist=no_match(["freebsd"]), bugnumber="llvm.org/pr28549") +@expectedFailureAll(archs=["aarch64"], oslist=["windows"], bugnumber="llvm.org/pr56292") def test_step_over_with_python(self): """Test stepping over using avoid-no-debug with dwarf.""" self.build() @@ -48,6 +50,7 @@ def test_step_over_with_python(self): archs=["i386"], oslist=no_match(["freebsd"]), bugnumber="llvm.org/pr28549") +@expectedFailureAll(archs=["aarch64"], oslist=["windows"], bugnumber="llvm.org/pr56292") def test_step_in_with_python(self): """Test stepping in using avoid-no-debug with dwarf.""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 68cc1ee - [LLDB] Fix NativePDB/local-variables.cpp for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-12T16:26:47+05:00 New Revision: 68cc1eeb1d7fbcaf307fbf199a7c61debf1dd1c1 URL: https://github.com/llvm/llvm-project/commit/68cc1eeb1d7fbcaf307fbf199a7c61debf1dd1c1 DIFF: https://github.com/llvm/llvm-project/commit/68cc1eeb1d7fbcaf307fbf199a7c61debf1dd1c1.diff LOG: [LLDB] Fix NativePDB/local-variables.cpp for AArch64/Windows This patch fixes NativePDB/local-variables.cpp test for AArch64 Windows. There are two changes: 1) Replace function breakpoint with line breakpoint required due to pr56288 2) Adjust "target modules dump ast" test as the output was slightly different on AArch64/Windows. Added: Modified: lldb/test/Shell/SymbolFile/NativePDB/Inputs/local-variables.lldbinit lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp Removed: diff --git a/lldb/test/Shell/SymbolFile/NativePDB/Inputs/local-variables.lldbinit b/lldb/test/Shell/SymbolFile/NativePDB/Inputs/local-variables.lldbinit index 0d7371e86f1cb..1071edd25c92b 100644 --- a/lldb/test/Shell/SymbolFile/NativePDB/Inputs/local-variables.lldbinit +++ b/lldb/test/Shell/SymbolFile/NativePDB/Inputs/local-variables.lldbinit @@ -1,4 +1,4 @@ -break set -n main +break set -f local-variables.cpp -l 17 run a b c d e f g p argc step diff --git a/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp b/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp index 68b23d49a31e5..4779a28c8b380 100644 --- a/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp +++ b/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp @@ -22,7 +22,7 @@ int main(int argc, char **argv) { // CHECK-NEXT: Current executable set to '{{.*}}local-variables.cpp.tmp.exe' // CHECK-NEXT: (lldb) command source -s 0 '{{.*}}local-variables.lldbinit' // CHECK-NEXT: Executing commands in '{{.*}}local-variables.lldbinit'. -// CHECK-NEXT: (lldb) break set -n main +// CHECK-NEXT: (lldb) break set -f local-variables.cpp -l 17 // CHECK-NEXT: Breakpoint 1: where = local-variables.cpp.tmp.exe`main + {{.*}} at local-variables.cpp:{{.*}}, address = {{.*}} // CHECK-NEXT: (lldb) run a b c d e f g // CHECK-NEXT: Process {{.*}} stopped @@ -158,6 +158,6 @@ int main(int argc, char **argv) { // CHECK-NEXT: | `-ParmVarDecl {{.*}} argv 'char **' // CHECK-NEXT: |-FunctionDecl {{.*}} __scrt_common_main_seh 'int ()' static // CHECK-NEXT: |-FunctionDecl {{.*}} invoke_main 'int ()' inline -// CHECK-NEXT: `-FunctionDecl {{.*}} Function 'int (int, char)' +// CHECK: `-FunctionDecl {{.*}} Function 'int (int, char)' // CHECK-NEXT: |-ParmVarDecl {{.*}} Param1 'int' // CHECK-NEXT: `-ParmVarDecl {{.*}} Param2 'char' ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 7b69843 - [LLDB] Catagory decorator for watchpoint test in TestCompletion.py
Author: Muhammad Omair Javaid Date: 2022-07-12T17:15:33+05:00 New Revision: 7b69843f0b502bb765206f534d7f50dcf88a60e5 URL: https://github.com/llvm/llvm-project/commit/7b69843f0b502bb765206f534d7f50dcf88a60e5 DIFF: https://github.com/llvm/llvm-project/commit/7b69843f0b502bb765206f534d7f50dcf88a60e5.diff LOG: [LLDB] Catagory decorator for watchpoint test in TestCompletion.py This patch adds watchpoint catagory decorator to watchpoint dependent tests in TestCompletion.py. Added: Modified: lldb/test/API/functionalities/completion/TestCompletion.py Removed: diff --git a/lldb/test/API/functionalities/completion/TestCompletion.py b/lldb/test/API/functionalities/completion/TestCompletion.py index 17c1b29362ae9..49950e0cec13a 100644 --- a/lldb/test/API/functionalities/completion/TestCompletion.py +++ b/lldb/test/API/functionalities/completion/TestCompletion.py @@ -291,6 +291,7 @@ def test_help_watchpoint_s(self): self.complete_from_to('help watchpoint s', 'help watchpoint set ') @expectedFailureNetBSD +@add_test_categories(["watchpoint"]) def test_common_complete_watchpoint_ids(self): subcommands = ['enable', 'disable', 'delete', 'modify', 'ignore'] ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] f5ba0a3 - Fix inline-record.test for Arm/Windows
Author: Muhammad Omair Javaid Date: 2022-06-29T23:21:02+04:00 New Revision: f5ba0a3d059380c62dd06cc8091e6aee53f3401f URL: https://github.com/llvm/llvm-project/commit/f5ba0a3d059380c62dd06cc8091e6aee53f3401f DIFF: https://github.com/llvm/llvm-project/commit/f5ba0a3d059380c62dd06cc8091e6aee53f3401f.diff LOG: Fix inline-record.test for Arm/Windows This patch fixes inline-record.test to run on multiple platforms including Arm/Windows. Test is fixed to expect any value for id fields of functions and blocks returned by 'image lookup' command. This field can be any value as it is internally generated id. Added: Modified: lldb/test/Shell/SymbolFile/Breakpad/inline-record.test Removed: diff --git a/lldb/test/Shell/SymbolFile/Breakpad/inline-record.test b/lldb/test/Shell/SymbolFile/Breakpad/inline-record.test index ebf777657f883..280fc96130a51 100644 --- a/lldb/test/Shell/SymbolFile/Breakpad/inline-record.test +++ b/lldb/test/Shell/SymbolFile/Breakpad/inline-record.test @@ -5,46 +5,46 @@ # CHECK-LABEL: (lldb) image lookup -a 0x400010 -v # CHECK: Summary: inline-record.out`f1 [inlined] inlined_f1 at a.c:3 # CHECK-NEXT: inline-record.out`f1 at a.c:8 -# CHECK: Function: id = {0x}, name = "f1", range = [0x00400010-0x00400020) -# CHECK-NEXT: Blocks: id = {0x}, range = [0x00400010-0x00400020) -# CHECK-NEXT: id = {0x0010}, ranges = [0x00400010-0x00400015)[0x00400017-0x0040001b), name = "inlined_f1" +# CHECK: Function: id = {{.*}}, name = "f1", range = [0x00400010-0x00400020) +# CHECK-NEXT: Blocks: id = {{.*}}, range = [0x00400010-0x00400020) +# CHECK-NEXT: id = {{.*}}, ranges = [0x00400010-0x00400015)[0x00400017-0x0040001b), name = "inlined_f1" # CHECK-LABEL: (lldb) image lookup -a 0x400016 -v # CHECK: Summary: inline-record.out`f1 + 6 at a.c:3 # CHECK-NOT:inline-record.out`f1 -# CHECK: Function: id = {0x}, name = "f1", range = [0x00400010-0x00400020) -# CHECK-NEXT: Blocks: id = {0x}, range = [0x00400010-0x00400020) +# CHECK: Function: id = {{.*}}, name = "f1", range = [0x00400010-0x00400020) +# CHECK-NEXT: Blocks: id = {{.*}}, range = [0x00400010-0x00400020) # CHECK-LABEL: (lldb) image lookup -a 0x400023 -v # CHECK: Summary: inline-record.out`f2 + 3 [inlined] inlined_f2 at b.c:2 # CHECK-NEXT: inline-record.out`f2 + 3 [inlined] inlined_f1 at b.c:4 # CHECK-NEXT: inline-record.out`f2 + 3 at a.c:3 -# CHECK: Function: id = {0x0001}, name = "f2", range = [0x00400020-0x00400030) -# CHECK-NEXT: Blocks: id = {0x0001}, range = [0x00400020-0x00400030) -# CHECK-NEXT: id = {0x0043}, range = [0x00400023-0x0040002d), name = "inlined_f1" -# CHECK-NEXT: id = {0x0057}, range = [0x00400023-0x00400028), name = "inlined_f2" +# CHECK: Function: id = {{.*}}, name = "f2", range = [0x00400020-0x00400030) +# CHECK-NEXT: Blocks: id = {{.*}}, range = [0x00400020-0x00400030) +# CHECK-NEXT: id = {{.*}}, range = [0x00400023-0x0040002d), name = "inlined_f1" +# CHECK-NEXT: id = {{.*}}, range = [0x00400023-0x00400028), name = "inlined_f2" # CHECK-LABEL: (lldb) image lookup -a 0x400029 -v # CHECK: Summary: inline-record.out`f2 + 9 [inlined] inlined_f1 + 6 at b.c:2 # CHECK-NEXT: inline-record.out`f2 + 3 at a.c:3 -# CHECK: Function: id = {0x0001}, name = "f2", range = [0x00400020-0x00400030) -# CHECK-NEXT: Blocks: id = {0x0001}, range = [0x00400020-0x00400030) -# CHECK-NEXT: id = {0x0043}, range = [0x00400023-0x0040002d), name = "inlined_f1" +# CHECK: Function: id = {{.*}}, name = "f2", range = [0x00400020-0x00400030) +# CHECK-NEXT: Blocks: id = {{.*}}, range = [0x00400020-0x00400030) +# CHECK-NEXT: id = {{.*}}, range = [0x00400023-0x0040002d), name = "inlined_f1" # CHECK-LABEL: (lldb) image lookup -a 0x400030 -v # CHECK: Summary: inline-record.out`f3 [inlined] inlined_f1 at b.c:3 # CHECK-NEXT: inline-record.out`f3 at 3 -# CHECK: Function: id = {0x0002}, name = "f3", range = [0x00400030-0x00400040) -# CHECK-NEXT: Blocks: id = {0x0002}, range = [0x00400030-0x00400040) -# CHECK-NEXT: id = {0x0085}, range = [0x00400030-0x00400035), name = "inlined_f1" +# CHECK: Function: id = {{.*}}, name = "f3", range = [0x00400030-0x00400040) +# CHECK-NEXT: Blocks: id = {{.*}}, range = [0x00400030-0x00400040) +# CHECK-NEXT: id = {{.*}}, range = [0x00400030-0x00400035), name = "inlined_f1" # CHECK-LABEL: (lldb) image lookup -a 0x400035 -v # CHECK: Summary: inline-record.out`f3 + 5 [inlined] at b.c:3 # CHECK-NEXT:
[Lldb-commits] [lldb] 9c6e043 - [LLDB] Allow API tests to override -gdwarf on Windows
Author: Muhammad Omair Javaid Date: 2022-06-29T23:24:18+04:00 New Revision: 9c6e04359282e9051f7b2744b99266ece32db001 URL: https://github.com/llvm/llvm-project/commit/9c6e04359282e9051f7b2744b99266ece32db001 DIFF: https://github.com/llvm/llvm-project/commit/9c6e04359282e9051f7b2744b99266ece32db001.diff LOG: [LLDB] Allow API tests to override -gdwarf on Windows This patch fixes LLDB API tests MakeFile.rules to allow overriding of debug symbol flags when compiling tests for Windows. Previously windows tests were forced to emit only dwarf debug symbols as majority of the tests rely on dwarf debug info. After this patch any test can override debug symbol flag by setting DEBUG_INFO_FLAG variable in its make file. Added: Modified: lldb/packages/Python/lldbsuite/test/make/Makefile.rules Removed: diff --git a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules index 9023128067f5e..b065a43cb1934 100644 --- a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules +++ b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules @@ -212,6 +212,12 @@ ifneq (,$(findstring clang,$(CC))) MODULE_DEBUG_INFO_FLAGS += -gmodules endif +# If the OS is Windows, we need to pass -gdwarf to clang, otherwise it will build +# with codeview by default but all the tests rely on dwarf. +ifeq "$(OS)" "Windows_NT" + DEBUG_INFO_FLAG ?= -gdwarf +endif + DEBUG_INFO_FLAG ?= -g CFLAGS ?= $(DEBUG_INFO_FLAG) -O0 @@ -236,12 +242,6 @@ endif CFLAGS += $(NO_LIMIT_DEBUG_INFO_FLAGS) $(ARCH_CFLAGS) -# If the OS is Windows, we need to pass -gdwarf to clang, otherwise it will build -# with codeview by default but all the tests rely on dwarf. -ifeq "$(OS)" "Windows_NT" - CFLAGS += -gdwarf -endif - # Use this one if you want to build one part of the result without debug information: ifeq "$(OS)" "Darwin" CFLAGS_NO_DEBUG = -O0 $(ARCHFLAG) $(ARCH) $(FRAMEWORK_INCLUDES) $(ARCH_CFLAGS) $(CFLAGS_EXTRAS) -isysroot "$(SDKROOT)" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5fe0da6 - [LLDB] Fix TestSTL.py on Windows
Author: Muhammad Omair Javaid Date: 2022-06-30T13:27:14+04:00 New Revision: 5fe0da6d7bcda22b03c470bef030030fa2d6d6f0 URL: https://github.com/llvm/llvm-project/commit/5fe0da6d7bcda22b03c470bef030030fa2d6d6f0 DIFF: https://github.com/llvm/llvm-project/commit/5fe0da6d7bcda22b03c470bef030030fa2d6d6f0.diff LOG: [LLDB] Fix TestSTL.py on Windows TestSTL.py was broken by 9c6e04359282e9051f7b2744b99266ece32db001. This patch fixes it with changes to its Makefile. Added: Modified: lldb/test/API/lang/cpp/stl/Makefile Removed: diff --git a/lldb/test/API/lang/cpp/stl/Makefile b/lldb/test/API/lang/cpp/stl/Makefile index 4617d67aca299..3c20771e6dba6 100644 --- a/lldb/test/API/lang/cpp/stl/Makefile +++ b/lldb/test/API/lang/cpp/stl/Makefile @@ -1,4 +1,5 @@ CXX_SOURCES := main.cpp -CFLAGS := -g -O0 + +DEBUG_INFO_FLAG := -gdwarf -O0 include Makefile.rules ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 8b7f5ee - [LLDB] Fix TestSTL.py Makefile to remove -gdwarf O0
Author: Muhammad Omair Javaid Date: 2022-06-30T14:06:21+04:00 New Revision: 8b7f5ee5f05a0972802055204a423009d3398a0d URL: https://github.com/llvm/llvm-project/commit/8b7f5ee5f05a0972802055204a423009d3398a0d DIFF: https://github.com/llvm/llvm-project/commit/8b7f5ee5f05a0972802055204a423009d3398a0d.diff LOG: [LLDB] Fix TestSTL.py Makefile to remove -gdwarf O0 This is a follow up to my previous commit where TestSTL.py got broken due to 9c6e04359282e9051f7b2744b99266ece32db001. Now that we force dwarf symbols by default on windows we dont need to specifically put -gdwarf O0 in debug flags for this test. Added: Modified: lldb/test/API/lang/cpp/stl/Makefile Removed: diff --git a/lldb/test/API/lang/cpp/stl/Makefile b/lldb/test/API/lang/cpp/stl/Makefile index 3c20771e6dba..8b20bcb0 100644 --- a/lldb/test/API/lang/cpp/stl/Makefile +++ b/lldb/test/API/lang/cpp/stl/Makefile @@ -1,5 +1,3 @@ CXX_SOURCES := main.cpp -DEBUG_INFO_FLAG := -gdwarf -O0 - include Makefile.rules ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] dd01d9a - Fix TestCommandScript.py for Arm/Windows
Author: Muhammad Omair Javaid Date: 2022-06-30T17:48:28+04:00 New Revision: dd01d9aadb6107075c1c2254a2de0670a4d2f0ed URL: https://github.com/llvm/llvm-project/commit/dd01d9aadb6107075c1c2254a2de0670a4d2f0ed DIFF: https://github.com/llvm/llvm-project/commit/dd01d9aadb6107075c1c2254a2de0670a4d2f0ed.diff LOG: Fix TestCommandScript.py for Arm/Windows TestCommandScript.py fails on Arm/Windows due following issues: https://llvm.org/pr56288 https://llvm.org/pr56292 LLDB fails to skip prologue and also step over library function or nodebug functions fails due to PDB/DWARF mismatch. This patch replace function breakpoint with line breakpoint so that we can expect LLDB to stop on desired line. Also replace dwarf with PDB debug info for this test only. Added: Modified: lldb/test/API/commands/command/script/Makefile lldb/test/API/commands/command/script/TestCommandScript.py Removed: diff --git a/lldb/test/API/commands/command/script/Makefile b/lldb/test/API/commands/command/script/Makefile index 8b20bcb05..c9a35c808f22b 100644 --- a/lldb/test/API/commands/command/script/Makefile +++ b/lldb/test/API/commands/command/script/Makefile @@ -1,3 +1,5 @@ CXX_SOURCES := main.cpp +DEBUG_INFO_FLAG := -g + include Makefile.rules diff --git a/lldb/test/API/commands/command/script/TestCommandScript.py b/lldb/test/API/commands/command/script/TestCommandScript.py index 6f369470803f9..756cb4a3632f8 100644 --- a/lldb/test/API/commands/command/script/TestCommandScript.py +++ b/lldb/test/API/commands/command/script/TestCommandScript.py @@ -113,7 +113,7 @@ def cleanup(): self.expect("longwait", substrs=['Done; if you saw the delays I am doing OK']) -self.runCmd("b main") +self.runCmd("break set -f main.cpp -l 48") self.runCmd("run") self.runCmd("mysto 3") self.expect("frame variable array", ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 8e9360d - Fix PDB/func-symbols.test for Arm/Windows
Author: Muhammad Omair Javaid Date: 2022-06-30T17:58:19+04:00 New Revision: 8e9360db1b4128ad4d90a6fe1cf1c20879976f64 URL: https://github.com/llvm/llvm-project/commit/8e9360db1b4128ad4d90a6fe1cf1c20879976f64 DIFF: https://github.com/llvm/llvm-project/commit/8e9360db1b4128ad4d90a6fe1cf1c20879976f64.diff LOG: Fix PDB/func-symbols.test for Arm/Windows PDB/func-symbols.test was orignally written for 32bit x86, keeping in mind cdecl and stdcall calling conventions which does name mangling for example like adding "_" underscore before function name. This is only x86 specific but purpose of pointers.test is NOT to test calling convention. I have made a minor change to make this test pass on Windows/Arm. Added: Modified: lldb/test/Shell/SymbolFile/PDB/func-symbols.test Removed: diff --git a/lldb/test/Shell/SymbolFile/PDB/func-symbols.test b/lldb/test/Shell/SymbolFile/PDB/func-symbols.test index 676be1c632b03..5990952938e67 100644 --- a/lldb/test/Shell/SymbolFile/PDB/func-symbols.test +++ b/lldb/test/Shell/SymbolFile/PDB/func-symbols.test @@ -27,7 +27,7 @@ CHECK-ONE-DAG: Function{[[UID1]]}, mangled = ?Func_arg_void@@YAXXZ, demangled = CHECK-ONE-DAG: Function{[[UID2]]}, mangled = ?Func_arg_none@@YAXXZ, demangled = {{.*}}, type = [[TY2]] CHECK-ONE-DAG: Function{[[UID3]]}, mangled = ?Func_varargs@@YAXZZ, demangled = {{.*}}, type = [[TY3]] CHECK-ONE-DAG: Function{[[UID4]]}, mangled = ?Func@NS@@YAXDH@Z, demangled = {{.*}}, type = [[TY4]] -CHECK-ONE-DAG: Function{[[UID5]]}, mangled = _main, demangled = {{.*}}, type = [[TY5]] +CHECK-ONE-DAG: Function{[[UID5]]}, mangled = {{_?}}main, demangled = {{.*}}, type = [[TY5]] CHECK-ONE-DAG: Function{[[UID6]]}, demangled = {{.*}}`anonymous namespace'::Func{{.*}}, type = [[TY6]] CHECK-ONE-DAG: Function{[[UID7]]}, demangled = {{.*}}StaticFunction{{.*}}, type = [[TY7]] CHECK-ONE-DAG: Function{[[UID8]]}, mangled = ?Func@A@MemberTest@@QAAHHZZ, demangled = {{.*}}, type = [[TY8]] ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 91d61c1 - [LLDB] Mark TestExprsChar Xfail for Windows/AArch64
Author: Muhammad Omair Javaid Date: 2022-06-24T13:59:22+04:00 New Revision: 91d61c1431c2ec46fa7a243db1643154580ab043 URL: https://github.com/llvm/llvm-project/commit/91d61c1431c2ec46fa7a243db1643154580ab043 DIFF: https://github.com/llvm/llvm-project/commit/91d61c1431c2ec46fa7a243db1643154580ab043.diff LOG: [LLDB] Mark TestExprsChar Xfail for Windows/AArch64 test_unsigned_char test in TestExprsChar.py fails on AArch64/Windows platform. There is known bug already present for the failure for various arch/os combinations. This patch marks the test as xfail for windows/AArch64. Added: Modified: lldb/test/API/commands/expression/char/TestExprsChar.py Removed: diff --git a/lldb/test/API/commands/expression/char/TestExprsChar.py b/lldb/test/API/commands/expression/char/TestExprsChar.py index cd9c55b5a44bb..849615ef91453 100644 --- a/lldb/test/API/commands/expression/char/TestExprsChar.py +++ b/lldb/test/API/commands/expression/char/TestExprsChar.py @@ -38,5 +38,6 @@ def test_signed_char(self): 'arm64_32'], bugnumber="llvm.org/pr23069, ") @expectedFailureAll(triple='mips*', bugnumber="llvm.org/pr23069") +@expectedFailureAll(oslist=['windows'], archs=['aarch64'], bugnumber="llvm.org/pr23069") def test_unsigned_char(self): self.do_test(dictionary={'CFLAGS_EXTRAS': '-funsigned-char'}) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] e4ed7ca - [LLDB] Avoid using -fno-builtin for building API tests
Author: Muhammad Omair Javaid Date: 2022-06-07T12:41:29+04:00 New Revision: e4ed7ca996ba5bb1be7b877c4c53ef2a5fb534f5 URL: https://github.com/llvm/llvm-project/commit/e4ed7ca996ba5bb1be7b877c4c53ef2a5fb534f5 DIFF: https://github.com/llvm/llvm-project/commit/e4ed7ca996ba5bb1be7b877c4c53ef2a5fb534f5.diff LOG: [LLDB] Avoid using -fno-builtin for building API tests This patch removes use of -fno-builtin flag for building LLDB API tests. LLDB API tests are built using Makefile.rules where we were using -fno-builtin flag to avoid gcc intrinsic optimization conflicting with Android runtime in past. Now that we no longer use gcc for building testsuite and compiling LLDB API tests on AArch64/Windows require clang to optimize certain calls like _setjmp to setjmpex as former is not implemented by AArch64 windows runtime. Added: Modified: lldb/packages/Python/lldbsuite/test/make/Makefile.rules Removed: diff --git a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules index 6917d73130c4a..9023128067f5e 100644 --- a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules +++ b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules @@ -214,7 +214,7 @@ endif DEBUG_INFO_FLAG ?= -g -CFLAGS ?= $(DEBUG_INFO_FLAG) -O0 -fno-builtin +CFLAGS ?= $(DEBUG_INFO_FLAG) -O0 ifeq "$(OS)" "Darwin" ifneq "$(SDKROOT)" "" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] d3d9bbd - [LLDB] Fix TestBase.generateSource for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-06-07T19:25:35+04:00 New Revision: d3d9bbd104368850d5e362ce8c5982f468272ae8 URL: https://github.com/llvm/llvm-project/commit/d3d9bbd104368850d5e362ce8c5982f468272ae8 DIFF: https://github.com/llvm/llvm-project/commit/d3d9bbd104368850d5e362ce8c5982f468272ae8.diff LOG: [LLDB] Fix TestBase.generateSource for AArch64/Windows This patch adds a minor fix in lldbtest.py TestBase.generateSource function. Generated Python source with directory paths was not being escaped properly. This fix makes sure we treat dir path as raw string. Added: Modified: lldb/packages/Python/lldbsuite/test/lldbtest.py Removed: diff --git a/lldb/packages/Python/lldbsuite/test/lldbtest.py b/lldb/packages/Python/lldbsuite/test/lldbtest.py index e1c8373eb29a4..5c536f4ed8ae4 100644 --- a/lldb/packages/Python/lldbsuite/test/lldbtest.py +++ b/lldb/packages/Python/lldbsuite/test/lldbtest.py @@ -1775,7 +1775,7 @@ def generateSource(self, source): if self.hasDarwinFramework(): include_stmt = "'#include <%s>' % os.path.join('LLDB', header)" else: -include_stmt = "'#include <%s>' % os.path.join('" + public_api_dir + "', header)" +include_stmt = "'#include <%s>' % os.path.join(r'" + public_api_dir + "', header)" list = [eval(include_stmt) for header in public_headers if ( header.startswith("SB") and header.endswith(".h"))] includes = '\n'.join(list) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 7daa9a9 - [LLDB] Remove decorator from XPASSes AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-06-07T19:30:26+04:00 New Revision: 7daa9a9b40a22c8ebac529f2fe7772191f2cea5a URL: https://github.com/llvm/llvm-project/commit/7daa9a9b40a22c8ebac529f2fe7772191f2cea5a DIFF: https://github.com/llvm/llvm-project/commit/7daa9a9b40a22c8ebac529f2fe7772191f2cea5a.diff LOG: [LLDB] Remove decorator from XPASSes AArch64/Windows This patch remove XFAIL decorator from tests which as passing on AArch64 Windows. This is tested on surface pro x using tot llvm and clang 14.0.3 as compiler with visual studio 2019 x86_arm64 environment. Added: Modified: lldb/test/API/api/command-return-object/TestSBCommandReturnObject.py lldb/test/API/api/multiple-targets/TestMultipleTargets.py lldb/test/API/commands/expression/char/TestExprsChar.py lldb/test/API/commands/expression/xvalue/TestXValuePrinting.py lldb/test/API/functionalities/return-value/TestReturnValue.py lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py lldb/test/API/lang/cpp/class-template-type-parameter-pack/TestClassTemplateTypeParameterPack.py Removed: diff --git a/lldb/test/API/api/command-return-object/TestSBCommandReturnObject.py b/lldb/test/API/api/command-return-object/TestSBCommandReturnObject.py index c7aa2eced83d9..1de460a5ac43a 100644 --- a/lldb/test/API/api/command-return-object/TestSBCommandReturnObject.py +++ b/lldb/test/API/api/command-return-object/TestSBCommandReturnObject.py @@ -15,7 +15,7 @@ class TestSBCommandReturnObject(TestBase): @skipIfNoSBHeaders @expectedFailureAll( -oslist=["windows"], +oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr43570") def test_sb_command_return_object(self): env = {self.dylibPath: self.getLLDBLibraryEnvVal()} diff --git a/lldb/test/API/api/multiple-targets/TestMultipleTargets.py b/lldb/test/API/api/multiple-targets/TestMultipleTargets.py index 94b09c71ce2f1..02b231f219914 100644 --- a/lldb/test/API/api/multiple-targets/TestMultipleTargets.py +++ b/lldb/test/API/api/multiple-targets/TestMultipleTargets.py @@ -20,7 +20,7 @@ class TestMultipleTargets(TestBase): @skipIfNoSBHeaders @skipIfHostIncompatibleWithRemote @expectedFailureAll( -oslist=["windows"], +oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr20282") @expectedFlakeyNetBSD def test_multiple_targets(self): diff --git a/lldb/test/API/commands/expression/char/TestExprsChar.py b/lldb/test/API/commands/expression/char/TestExprsChar.py index a7f37e868b4dd..ab3d4f40265ff 100644 --- a/lldb/test/API/commands/expression/char/TestExprsChar.py +++ b/lldb/test/API/commands/expression/char/TestExprsChar.py @@ -20,10 +20,9 @@ def do_test(self, dictionary=None): def test_default_char(self): self.do_test() -@skipIf(oslist=["linux"], archs=["arm"], bugnumber="llvm.org/pr23069") +@skipIf(oslist=["linux"], archs=["aarch64", "arm"], bugnumber="llvm.org/pr23069") @expectedFailureAll( archs=[ -"aarch64", "powerpc64le", "s390x"], bugnumber="llvm.org/pr23069") diff --git a/lldb/test/API/commands/expression/xvalue/TestXValuePrinting.py b/lldb/test/API/commands/expression/xvalue/TestXValuePrinting.py index f5122b84839a9..69308a58d3f55 100644 --- a/lldb/test/API/commands/expression/xvalue/TestXValuePrinting.py +++ b/lldb/test/API/commands/expression/xvalue/TestXValuePrinting.py @@ -7,7 +7,7 @@ class ExprXValuePrintingTestCase(TestBase): mydir = TestBase.compute_mydir(__file__) -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr21765") +@expectedFailureAll(oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr21765") def test(self): """Printing an xvalue should work.""" self.build() diff --git a/lldb/test/API/functionalities/return-value/TestReturnValue.py b/lldb/test/API/functionalities/return-value/TestReturnValue.py index 517ed46a4fe9f..9f4745cb79018 100644 --- a/lldb/test/API/functionalities/return-value/TestReturnValue.py +++ b/lldb/test/API/functionalities/return-value/TestReturnValue.py @@ -175,7 +175,7 @@ def test_with_python(self): "3.6"], archs=["i386"]) @expectedFailureAll(compiler=["gcc"], archs=["x86_64", "i386"]) -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24778") +@expectedFailureAll(oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr24778") def test_vector_values(self): self.build() exe = self.getBuildArtifact("a.out") diff --git a/lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py b/lldb/test/API/lang/cpp/class-template-non-type-parameter-pack/TestClassTemplateNonTypeParameterPack.py
[Lldb-commits] [lldb] 3fd9aeb - [LLDB] XFAIL TestLoadUnload fails on Arm/Ubuntu Jammy
Author: Muhammad Omair Javaid Date: 2022-06-17T12:06:35+04:00 New Revision: 3fd9aebbb75ab0966bd767e15ba6a69cad17f160 URL: https://github.com/llvm/llvm-project/commit/3fd9aebbb75ab0966bd767e15ba6a69cad17f160 DIFF: https://github.com/llvm/llvm-project/commit/3fd9aebbb75ab0966bd767e15ba6a69cad17f160.diff LOG: [LLDB] XFAIL TestLoadUnload fails on Arm/Ubuntu Jammy This patch marks following tests as XFAIL for Arm/Ubuntu Jammy 22.04: test_lldb_process_load_and_unload_commands test_load_unload Added: Modified: lldb/test/API/functionalities/load_unload/TestLoadUnload.py Removed: diff --git a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py index f3b715c4c35ed..15e602cc784db 100644 --- a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py +++ b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py @@ -203,6 +203,7 @@ def test_dyld_library_path(self): hostoslist=["windows"], triple='.*-android') @expectedFailureAll(oslist=["windows"]) # process load not implemented +@expectedFailureAll(oslist=["linux"], archs=["arm"]) # Fails on ubuntu jammy def test_lldb_process_load_and_unload_commands(self): self.setSvr4Support(False) self.run_lldb_process_load_and_unload_commands() @@ -296,6 +297,7 @@ def run_lldb_process_load_and_unload_commands(self): self.runCmd("process continue") @expectedFailureAll(oslist=["windows"]) # breakpoint not hit +@expectedFailureAll(oslist=["linux"], archs=["arm"]) # Fails on ubuntu jammy def test_load_unload(self): self.setSvr4Support(False) self.run_load_unload() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] b82b018 - [LLDB] XFail TestLoadUnload.test_static_init_during_load AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-13T16:18:18+05:00 New Revision: b82b0187129ddb40d85c6fc0847c536967273600 URL: https://github.com/llvm/llvm-project/commit/b82b0187129ddb40d85c6fc0847c536967273600 DIFF: https://github.com/llvm/llvm-project/commit/b82b0187129ddb40d85c6fc0847c536967273600.diff LOG: [LLDB] XFail TestLoadUnload.test_static_init_during_load AArch64/Windows This patch fixes marks TestLoadUnload.test_static_init_during_load as xfail for AArch64 windows. It is failing similar to Linux and already marked xfail for linux. Added: Modified: lldb/test/API/functionalities/load_unload/TestLoadUnload.py Removed: diff --git a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py index 70d08f4884c08..d310c08d77426 100644 --- a/lldb/test/API/functionalities/load_unload/TestLoadUnload.py +++ b/lldb/test/API/functionalities/load_unload/TestLoadUnload.py @@ -377,6 +377,7 @@ def run_step_over_load(self): # We can't find a breakpoint location for d_init before launching because # executable dependencies are resolved relative to the debuggers PWD. Bug? @expectedFailureAll(oslist=["freebsd", "linux", "netbsd"], triple=no_match('aarch64-.*-android')) +@expectedFailureAll(oslist=["windows"], archs=["aarch64"]) def test_static_init_during_load(self): """Test that we can set breakpoints correctly in static initializers""" self.copy_shlibs_to_remote() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 7610524 - [LLDB] Fix TestThreadAPI.py for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-13T16:30:09+05:00 New Revision: 7610524af3c99e63ec6b3a452c45af51ffae57fa URL: https://github.com/llvm/llvm-project/commit/7610524af3c99e63ec6b3a452c45af51ffae57fa DIFF: https://github.com/llvm/llvm-project/commit/7610524af3c99e63ec6b3a452c45af51ffae57fa.diff LOG: [LLDB] Fix TestThreadAPI.py for AArch64/Windows This patch fixes TestThreadAPI for AArch64 windows by switching over to PDB debug info instead of DWARF. This is needed to step over library functions like printf as there is debug info mismatch between DWARF and PDB. PDB DWARF interworking is not fully supported by LLDB at the moment. Added: Modified: lldb/test/API/python_api/thread/Makefile Removed: diff --git a/lldb/test/API/python_api/thread/Makefile b/lldb/test/API/python_api/thread/Makefile index 30749db9a67cf..57ef8f826d22d 100644 --- a/lldb/test/API/python_api/thread/Makefile +++ b/lldb/test/API/python_api/thread/Makefile @@ -1,3 +1,5 @@ CXX_SOURCES ?= main.cpp +DEBUG_INFO_FLAG := -g + include Makefile.rules ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 891319f - [LLDB] Fix pointers.test for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-13T15:55:31+05:00 New Revision: 891319f654c102572cf7028ed04bbaf6c59e7bff URL: https://github.com/llvm/llvm-project/commit/891319f654c102572cf7028ed04bbaf6c59e7bff DIFF: https://github.com/llvm/llvm-project/commit/891319f654c102572cf7028ed04bbaf6c59e7bff.diff LOG: [LLDB] Fix pointers.test for AArch64/Windows pointers.test started failing again for AArch64 windows after D125509 This patch fixes the test to make it pass on AArch64 windows again. LLDB AArch64 Windows buildbot running at: https://lab.llvm.org/staging/#/builders/207 Added: Modified: lldb/test/Shell/SymbolFile/PDB/pointers.test Removed: diff --git a/lldb/test/Shell/SymbolFile/PDB/pointers.test b/lldb/test/Shell/SymbolFile/PDB/pointers.test index 841fe8804b44c..a3e6f557fed6f 100644 --- a/lldb/test/Shell/SymbolFile/PDB/pointers.test +++ b/lldb/test/Shell/SymbolFile/PDB/pointers.test @@ -33,6 +33,6 @@ MAIN-SAME:(int (ST::*)(int){{( __attribute__\(\(thiscall\)\))?}}), scope = l F: Function{[[FID2:.*]]}, demangled = {{.*}}f(int) F-NEXT: Block{[[FID2]]} F: Variable{{.*}}, name = "this" -F-SAME:(ST *), scope = parameter,{{( location = DW_OP.*,)?}} artificial +F-SAME:(ST *), scope = parameter, location = {{(DW_OP.*)|()}}, artificial F: Variable{{.*}}, name = "x" F-SAME:(int), scope = parameter, decl = PointerTypeTest.cpp:8 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] f827b4b - [LLDB] Fix TestConvenienceVariables.test AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-07-13T16:46:55+05:00 New Revision: f827b4b657d5922beef3799337e91ba98fce852e URL: https://github.com/llvm/llvm-project/commit/f827b4b657d5922beef3799337e91ba98fce852e DIFF: https://github.com/llvm/llvm-project/commit/f827b4b657d5922beef3799337e91ba98fce852e.diff LOG: [LLDB] Fix TestConvenienceVariables.test AArch64/Windows This patch fixes TestConvenienceVariables.test for AArch64 Windows. Clang/LLD was unable to find printf apparently available as a macro definition in stdio.h. Added: Modified: lldb/test/Shell/Driver/Inputs/hello.cpp lldb/test/Shell/Driver/TestConvenienceVariables.test Removed: diff --git a/lldb/test/Shell/Driver/Inputs/hello.cpp b/lldb/test/Shell/Driver/Inputs/hello.cpp index 1ec0677aeb2c7..7a46e19b927a5 100644 --- a/lldb/test/Shell/Driver/Inputs/hello.cpp +++ b/lldb/test/Shell/Driver/Inputs/hello.cpp @@ -1,11 +1,6 @@ -// The build.py script always runs the compiler in C++ mode, regardless of the -// file extension. This results in mangled names presented to the linker which -// in turn cannot find the printf symbol. -extern "C" { -int printf(const char *format, ...); +#include int main(int argc, char **argv) { printf("Hello World\n"); return 0; } -} diff --git a/lldb/test/Shell/Driver/TestConvenienceVariables.test b/lldb/test/Shell/Driver/TestConvenienceVariables.test index 63ba15ec7468c..45dc7673bfc51 100644 --- a/lldb/test/Shell/Driver/TestConvenienceVariables.test +++ b/lldb/test/Shell/Driver/TestConvenienceVariables.test @@ -19,7 +19,7 @@ CHECK-NEXT: SBProcess: pid = {{[0-9]+}}, state = stopped, threads = {{[0-9]+}}, CHECK: script print(lldb.thread.GetStopDescription(100)) CHECK-NEXT: breakpoint 1.1 CHECK: script lldb.frame.GetLineEntry().GetLine() -CHECK-NEXT: 8 +CHECK-NEXT: 4 CHECK: script lldb.frame.GetLineEntry().GetFileSpec().GetFilename() CHECK-NEXT: hello.c CHECK: script lldb.frame.GetFunctionName() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] a1bf0c0 - [LLDB] Skip buildbot failures AArch64/Windows
Author: Muhammad Omair Javaid Date: 2022-08-02T16:59:12+05:00 New Revision: a1bf0c08947d54a38cf10fed8e2b88fed2d50e52 URL: https://github.com/llvm/llvm-project/commit/a1bf0c08947d54a38cf10fed8e2b88fed2d50e52 DIFF: https://github.com/llvm/llvm-project/commit/a1bf0c08947d54a38cf10fed8e2b88fed2d50e52.diff LOG: [LLDB] Skip buildbot failures AArch64/Windows TestInlineStepping.py is flaky while TestUseSourceCache.py fails on Windows 11 only. Marked them skipped to make buildbot happy. Added: Modified: lldb/test/API/commands/settings/use_source_cache/TestUseSourceCache.py lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py Removed: diff --git a/lldb/test/API/commands/settings/use_source_cache/TestUseSourceCache.py b/lldb/test/API/commands/settings/use_source_cache/TestUseSourceCache.py index b6b279aaec65a..712642d0ce01e 100644 --- a/lldb/test/API/commands/settings/use_source_cache/TestUseSourceCache.py +++ b/lldb/test/API/commands/settings/use_source_cache/TestUseSourceCache.py @@ -17,6 +17,7 @@ def test_set_use_source_cache_false(self): self.set_use_source_cache_and_test(False) @skipIf(hostoslist=no_match(["windows"])) +@skipIf(oslist=['windows'], archs=['aarch64']) # Fails on windows 11 def test_set_use_source_cache_true(self): """Test that after 'set use-source-cache false', files are locked.""" self.set_use_source_cache_and_test(True) diff --git a/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py b/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py index 64045739984c7..7c5ae442cc5b9 100644 --- a/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py +++ b/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py @@ -11,6 +11,7 @@ class TestInlineStepping(TestBase): @add_test_categories(['pyapi']) +@skipIf(oslist=['windows'], archs=['aarch64']) # Flaky on buildbot @expectedFailureAll( compiler="icc", bugnumber="# Not really a bug. ICC combines two inlined functions.") ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 849ca46 - [LLDB] Skip TestFunctionTemplateSpecializationTempArgs for Arm64/Windows
Author: Muhammad Omair Javaid Date: 2022-08-24T20:07:00+05:00 New Revision: 849ca4626e9706d7b132ea696c5bf8c0ba0dc977 URL: https://github.com/llvm/llvm-project/commit/849ca4626e9706d7b132ea696c5bf8c0ba0dc977 DIFF: https://github.com/llvm/llvm-project/commit/849ca4626e9706d7b132ea696c5bf8c0ba0dc977.diff LOG: [LLDB] Skip TestFunctionTemplateSpecializationTempArgs for Arm64/Windows This test fails on buildbot while passes on standalone builds. I am marking it as skipped until actual problem is found and resolved. Added: Modified: lldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py Removed: diff --git a/lldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py b/lldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py index 5bbed6e88751..a065153832af 100644 --- a/lldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py +++ b/lldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py @@ -5,6 +5,7 @@ class TestFunctionTemplateSpecializationTempArgs(TestBase): +@skipIf(oslist=['windows'], archs=['aarch64']) def test_function_template_specialization_temp_args(self): self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 4db7832 - [LLDB] Make API tests to run using MSYS tools
Author: Muhammad Omair Javaid Date: 2022-09-01T14:00:46+05:00 New Revision: 4db78322031ffbd5ea607d7ff66fed5fafb40d68 URL: https://github.com/llvm/llvm-project/commit/4db78322031ffbd5ea607d7ff66fed5fafb40d68 DIFF: https://github.com/llvm/llvm-project/commit/4db78322031ffbd5ea607d7ff66fed5fafb40d68.diff LOG: [LLDB] Make API tests to run using MSYS tools MSYS 'uname' on windows returns "MSYS_NT*" instead of windows32 and also MSYS 'pwd' returns non-windows path string. This patch fixes Makefile.rules to make adjustments required to run LLDB API tests using MSYS tools. Differential Revision: https://reviews.llvm.org/D133002 Added: Modified: lldb/packages/Python/lldbsuite/test/make/Makefile.rules Removed: diff --git a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules index 36ef02810152..937a2ae06fc4 100644 --- a/lldb/packages/Python/lldbsuite/test/make/Makefile.rules +++ b/lldb/packages/Python/lldbsuite/test/make/Makefile.rules @@ -49,8 +49,9 @@ LLDB_BASE_DIR := $(THIS_FILE_DIR)/../../../../../ #-- # If OS is not defined, use 'uname -s' to determine the OS name. # -# uname on Windows gives "windows32" or "server version windows32", but most -# environments standardize on "Windows_NT", so we'll make it consistent here. +# GNUWin32 uname gives "windows32" or "server version windows32" while +# some versions of MSYS uname return "MSYS_NT*", but most environments +# standardize on "Windows_NT", so we'll make it consistent here. # When running tests from Visual Studio, the environment variable isn't # inherited all the way down to the process spawned for make. #-- @@ -58,6 +59,11 @@ HOST_OS := $(shell uname -s) ifneq (,$(findstring windows32,$(HOST_OS))) HOST_OS := Windows_NT endif + +ifneq (,$(findstring MSYS_NT,$(HOST_OS))) + HOST_OS := Windows_NT +endif + ifeq "$(OS)" "" OS := $(HOST_OS) endif @@ -68,9 +74,12 @@ endif # Some versions of make on Windows will search for other shells such as # C:\cygwin\bin\sh.exe. This shell fails for numerous diff erent reasons # so default to using cmd.exe. +# Also reset BUILDDIR value because "pwd" returns cygwin or msys path +# which needs to be converted to windows path. #-- ifeq "$(OS)" "Windows_NT" SHELL = $(WINDIR)\system32\cmd.exe + BUILDDIR := $(shell echo %cd%) endif #-- ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 0e6a71e - [LLDB] Make build.py use uname to set platform
Author: Muhammad Omair Javaid Date: 2022-09-01T14:00:47+05:00 New Revision: 0e6a71e6a3d11f6d9c9664b56f304757edf1c82e URL: https://github.com/llvm/llvm-project/commit/0e6a71e6a3d11f6d9c9664b56f304757edf1c82e DIFF: https://github.com/llvm/llvm-project/commit/0e6a71e6a3d11f6d9c9664b56f304757edf1c82e.diff LOG: [LLDB] Make build.py use uname to set platform This patch makes build helper script build.py to use platform.uname for machine/architecture detection. Visual studio environment when set using various batch files like vcvars*.bat set PLATFORM environment variable however VsDevCmd.bat does not set PLATFORM variable. Differential Revision: https://reviews.llvm.org/D133011 Added: Modified: lldb/test/Shell/helper/build.py Removed: diff --git a/lldb/test/Shell/helper/build.py b/lldb/test/Shell/helper/build.py index 4b1fe239239a..96684b7b3e66 100755 --- a/lldb/test/Shell/helper/build.py +++ b/lldb/test/Shell/helper/build.py @@ -2,6 +2,7 @@ import argparse import os +import platform import shutil import signal import subprocess @@ -274,7 +275,7 @@ class MsvcBuilder(Builder): def __init__(self, toolchain_type, args): Builder.__init__(self, toolchain_type, args, '.obj') -if os.getenv('PLATFORM') == 'arm64': +if platform.uname().machine.lower() == 'arm64': self.msvc_arch_str = 'arm' if self.arch == '32' else 'arm64' else: self.msvc_arch_str = 'x86' if self.arch == '32' else 'x64' ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 2b8c308 - [LLDB] Skip TestThreadSpecificBreakpoint.py on AArch64/Windows
Author: Muhammad Omair Javaid Date: 2023-01-03T18:42:43+04:00 New Revision: 2b8c308fa1d3ba504c1bde16f262683685b19726 URL: https://github.com/llvm/llvm-project/commit/2b8c308fa1d3ba504c1bde16f262683685b19726 DIFF: https://github.com/llvm/llvm-project/commit/2b8c308fa1d3ba504c1bde16f262683685b19726.diff LOG: [LLDB] Skip TestThreadSpecificBreakpoint.py on AArch64/Windows TestThreadSpecificBreakpoint.py is flaky on AArch64/Windows buildbot and results in timeout randomly. This patch marks the test skipped. Added: Modified: lldb/test/API/functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py Removed: diff --git a/lldb/test/API/functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py b/lldb/test/API/functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py index 521e56109ea38..f5561ef856ed6 100644 --- a/lldb/test/API/functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py +++ b/lldb/test/API/functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py @@ -26,6 +26,7 @@ class ThreadSpecificBreakTestCase(TestBase): @add_test_categories(['pyapi']) @expectedFailureAll(oslist=['ios', 'watchos', 'tvos', 'bridgeos'], archs=['armv7', 'armv7k'], bugnumber='rdar://problem/34563920') # armv7 ios problem - breakpoint with tid qualifier isn't working +@skipIf(oslist=['windows'], archs=['aarch64']) # Flaky on buildbot def test_thread_id(self): self.do_test(set_thread_id) @@ -35,6 +36,7 @@ def test_thread_name(self): self.do_test(set_thread_name) @expectedFailureAll(oslist=['ios', 'watchos', 'tvos', 'bridgeos'], archs=['armv7', 'armv7k'], bugnumber='rdar://problem/34563920') # armv7 ios problem - breakpoint with tid qualifier isn't working +@skipIf(oslist=['windows'], archs=['aarch64']) # Flaky on buildbot def test_current_token(self): self.do_test(using_current) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 21be357 - [LLDB] Skip python exception unit test on AArch64/Windows
Author: Muhammad Omair Javaid Date: 2023-01-03T18:42:43+04:00 New Revision: 21be357873c0325495c7f6599259579735f54f3e URL: https://github.com/llvm/llvm-project/commit/21be357873c0325495c7f6599259579735f54f3e DIFF: https://github.com/llvm/llvm-project/commit/21be357873c0325495c7f6599259579735f54f3e.diff LOG: [LLDB] Skip python exception unit test on AArch64/Windows This patch marks python exception test as skipped for AArch64/Windows platform. This is temporary to make LLDB WoA buildbot happy until a proper fix is found. Added: Modified: lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp Removed: diff --git a/lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp b/lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp index 8dd55a5c6a611..2bf713e085760 100644 --- a/lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp +++ b/lldb/unittests/ScriptInterpreter/Python/PythonDataObjectsTests.cpp @@ -788,6 +788,8 @@ main = foo testing::ContainsRegex("line 7, in baz"), testing::ContainsRegex("ZeroDivisionError"); +#if !((defined(_WIN32) || defined(_WIN64)) && (defined(__aarch64__) || defined(_M_ARM64))) + static const char script2[] = R"( class MyError(Exception): def __str__(self): @@ -804,6 +806,8 @@ def main(): llvm::Failed(testing::Property( ::ReadBacktrace, testing::ContainsRegex("unprintable MyError"; + +#endif } TEST_F(PythonDataObjectsTest, TestRun) { ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] dbee45d - [LLDB] Enable TestSignedTypes.py for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2023-01-02T19:33:45+04:00 New Revision: dbee45d8fea97dca9666b09688cc7548d5023c4e URL: https://github.com/llvm/llvm-project/commit/dbee45d8fea97dca9666b09688cc7548d5023c4e DIFF: https://github.com/llvm/llvm-project/commit/dbee45d8fea97dca9666b09688cc7548d5023c4e.diff LOG: [LLDB] Enable TestSignedTypes.py for AArch64/Windows TestSignedTypes.py passes on AArch64 Windows. This patch disables this test only for i[3-6]86 and x86_64 Windows platform. Added: Modified: lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py Removed: diff --git a/lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py b/lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py index e94dabe7ac48f..015eaea547dc4 100644 --- a/lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py +++ b/lldb/test/API/lang/cpp/signed_types/TestSignedTypes.py @@ -20,7 +20,7 @@ def setUp(self): self.line = line_number( self.source, '// Set break point at this line.') -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24489") +@expectedFailureAll(oslist=["windows"], archs=["i[3-6]86", "x86_64"], bugnumber="llvm.org/pr24489") def test(self): """Test that variables with signed types display correctly.""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 58e9cc1 - Revert "[lldb] Remove redundant .c_str() and .get() calls"
Author: Muhammad Omair Javaid Date: 2022-12-19T13:52:10+05:00 New Revision: 58e9cc13e24f668a33abdae201d59a02e10c22c0 URL: https://github.com/llvm/llvm-project/commit/58e9cc13e24f668a33abdae201d59a02e10c22c0 DIFF: https://github.com/llvm/llvm-project/commit/58e9cc13e24f668a33abdae201d59a02e10c22c0.diff LOG: Revert "[lldb] Remove redundant .c_str() and .get() calls" This reverts commit fbaf48be0ff6fb24b9aa8fe9c2284fe88a8798dd. This has broken all LLDB buildbots: https://lab.llvm.org/buildbot/#/builders/68/builds/44990 https://lab.llvm.org/buildbot/#/builders/96/builds/33160 Added: Modified: lldb/include/lldb/Target/Process.h lldb/source/API/SBCommandReturnObject.cpp lldb/source/API/SBExpressionOptions.cpp lldb/source/API/SBSourceManager.cpp lldb/source/Breakpoint/BreakpointResolverScripted.cpp lldb/source/Commands/CommandObjectBreakpoint.cpp lldb/source/Commands/CommandObjectExpression.cpp lldb/source/Commands/CommandObjectHelp.cpp lldb/source/Commands/CommandObjectMultiword.cpp lldb/source/Commands/CommandObjectTarget.cpp lldb/source/Commands/CommandObjectThread.cpp lldb/source/Core/Disassembler.cpp lldb/source/Core/FormatEntity.cpp lldb/source/Core/IOHandlerCursesGUI.cpp lldb/source/Expression/REPL.cpp lldb/source/Interpreter/CommandInterpreter.cpp lldb/source/Interpreter/OptionArgParser.cpp lldb/source/Interpreter/OptionValueArch.cpp lldb/source/Interpreter/ScriptInterpreter.cpp lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp lldb/source/Plugins/ExpressionParser/Clang/ClangPersistentVariables.cpp lldb/source/Plugins/ExpressionParser/Clang/NameSearchContext.cpp lldb/source/Plugins/InstrumentationRuntime/TSan/InstrumentationRuntimeTSan.cpp lldb/source/Plugins/InstrumentationRuntime/UBSan/InstrumentationRuntimeUBSan.cpp lldb/source/Plugins/Language/ObjC/Cocoa.cpp lldb/source/Plugins/MemoryHistory/asan/MemoryHistoryASan.cpp lldb/source/Plugins/Platform/Android/AdbClient.cpp lldb/source/Plugins/Platform/Android/PlatformAndroidRemoteGDBServer.cpp lldb/source/Plugins/Platform/MacOSX/PlatformDarwinDevice.cpp lldb/source/Plugins/Platform/MacOSX/PlatformDarwinKernel.cpp lldb/source/Plugins/Platform/MacOSX/objcxx/PlatformiOSSimulatorCoreSimulatorSupport.h lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerCommon.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerPlatform.cpp lldb/source/Plugins/Process/scripted/ScriptedProcess.cpp lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp lldb/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp lldb/source/Plugins/SymbolVendor/MacOSX/SymbolVendorMacOSX.cpp lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.h lldb/source/Symbol/LocateSymbolFileMacOSX.cpp lldb/source/Target/LanguageRuntime.cpp lldb/source/Target/TargetList.cpp lldb/source/Target/Thread.cpp lldb/source/Target/ThreadPlanStack.cpp lldb/tools/debugserver/source/DNBTimer.h lldb/tools/lldb-vscode/BreakpointBase.cpp Removed: diff --git a/lldb/include/lldb/Target/Process.h b/lldb/include/lldb/Target/Process.h index 8bb8b85e22fbc..47040137078f6 100644 --- a/lldb/include/lldb/Target/Process.h +++ b/lldb/include/lldb/Target/Process.h @@ -2704,7 +2704,7 @@ void PruneThreadPlans(); }; void SetNextEventAction(Process::NextEventAction *next_event_action) { -if (m_next_event_action_up) +if (m_next_event_action_up.get()) m_next_event_action_up->HandleBeingUnshipped(); m_next_event_action_up.reset(next_event_action); diff --git a/lldb/source/API/SBCommandReturnObject.cpp b/lldb/source/API/SBCommandReturnObject.cpp index bf9c66453c90b..7d2c102b3d8c1 100644 --- a/lldb/source/API/SBCommandReturnObject.cpp +++ b/lldb/source/API/SBCommandReturnObject.cpp @@ -292,7 +292,7 @@ void SBCommandReturnObject::PutCString(const char *string, int len) { return; } else if (len > 0) { std::string buffer(string, len); -ref().AppendMessage(buffer); +ref().AppendMessage(buffer.c_str()); } else ref().AppendMessage(string); } diff --git a/lldb/source/API/SBExpressionOptions.cpp b/lldb/source/API/SBExpressionOptions.cpp index 6ae57f24606af..d07acbc0aa2db 100644 --- a/lldb/source/API/SBExpressionOptions.cpp +++ b/lldb/source/API/SBExpressionOptions.cpp @@ -254,5 +254,5 @@ EvaluateExpressionOptions *SBExpressionOptions::get() const { } EvaluateExpressionOptions ::ref() const { - return *m_opaque_up;
[Lldb-commits] [lldb] d599ac4 - [LLDB] Xfail TestVSCode_eventStatistic.py on Arm/AArch64 Linux
Author: Muhammad Omair Javaid Date: 2022-11-16T10:45:24+04:00 New Revision: d599ac41aabddeb2442db7b31faacf143d63abe4 URL: https://github.com/llvm/llvm-project/commit/d599ac41aabddeb2442db7b31faacf143d63abe4 DIFF: https://github.com/llvm/llvm-project/commit/d599ac41aabddeb2442db7b31faacf143d63abe4.diff LOG: [LLDB] Xfail TestVSCode_eventStatistic.py on Arm/AArch64 Linux This patch marks TestVSCode_eventStatistic.py as xfail on Arm/AArch64 Linux platform. test_initialized_event testcase is failing. See buildbot logs below: https://lab.llvm.org/buildbot/#/builders/17/builds/30199 https://lab.llvm.org/buildbot/#/builders/96/builds/31528 Differential Revision: https://reviews.llvm.org/D138077 Added: Modified: lldb/test/API/tools/lldb-vscode/eventStatistic/TestVSCode_eventStatistic.py Removed: diff --git a/lldb/test/API/tools/lldb-vscode/eventStatistic/TestVSCode_eventStatistic.py b/lldb/test/API/tools/lldb-vscode/eventStatistic/TestVSCode_eventStatistic.py index b70e21ef7d9d..2b7630795dca 100644 --- a/lldb/test/API/tools/lldb-vscode/eventStatistic/TestVSCode_eventStatistic.py +++ b/lldb/test/API/tools/lldb-vscode/eventStatistic/TestVSCode_eventStatistic.py @@ -70,6 +70,7 @@ def test_terminated_event(self): @skipIfWindows @skipIfRemote +@expectedFailureAll(oslist=['linux'], archs=['arm', 'aarch64']) def test_initialized_event(self): ''' Initialized Event ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] e1bbe50 - Revert "[lldb] Make SBSection::GetSectionData call Section::GetSectionData."
Author: Muhammad Omair Javaid Date: 2023-01-30T12:34:37+05:00 New Revision: e1bbe50f5a48e9b5407de9e5f4ab8197dedc85c5 URL: https://github.com/llvm/llvm-project/commit/e1bbe50f5a48e9b5407de9e5f4ab8197dedc85c5 DIFF: https://github.com/llvm/llvm-project/commit/e1bbe50f5a48e9b5407de9e5f4ab8197dedc85c5.diff LOG: Revert "[lldb] Make SBSection::GetSectionData call Section::GetSectionData." This reverts commit 805600c7d573cf88cf035d01a2ea9389fc24d435. LLDB windows buildbots were broken by the TestSectionAPI.py test. I dont have full context of the commit to fix it. Reverting it temporarily. https://lab.llvm.org/buildbot/#/builders/83/builds/28617 https://lab.llvm.org/buildbot/#/builders/219/builds/180 Differential Revision: https://reviews.llvm.org/D142672 Added: Modified: lldb/source/API/SBSection.cpp lldb/test/API/python_api/section/TestSectionAPI.py Removed: lldb/test/API/python_api/section/compressed-sections.yaml diff --git a/lldb/source/API/SBSection.cpp b/lldb/source/API/SBSection.cpp index b7b94f3ece1a6..3a9cf20e484a5 100644 --- a/lldb/source/API/SBSection.cpp +++ b/lldb/source/API/SBSection.cpp @@ -182,10 +182,35 @@ SBData SBSection::GetSectionData(uint64_t offset, uint64_t size) { SBData sb_data; SectionSP section_sp(GetSP()); if (section_sp) { -DataExtractor section_data; -section_sp->GetSectionData(section_data); -sb_data.SetOpaque( -std::make_shared(section_data, offset, size)); +const uint64_t sect_file_size = section_sp->GetFileSize(); +if (sect_file_size > 0) { + ModuleSP module_sp(section_sp->GetModule()); + if (module_sp) { +ObjectFile *objfile = module_sp->GetObjectFile(); +if (objfile) { + const uint64_t sect_file_offset = + objfile->GetFileOffset() + section_sp->GetFileOffset(); + const uint64_t file_offset = sect_file_offset + offset; + uint64_t file_size = size; + if (file_size == UINT64_MAX) { +file_size = section_sp->GetByteSize(); +if (file_size > offset) + file_size -= offset; +else + file_size = 0; + } + auto data_buffer_sp = FileSystem::Instance().CreateDataBuffer( + objfile->GetFileSpec().GetPath(), file_size, file_offset); + if (data_buffer_sp && data_buffer_sp->GetByteSize() > 0) { +DataExtractorSP data_extractor_sp( +new DataExtractor(data_buffer_sp, objfile->GetByteOrder(), + objfile->GetAddressByteSize())); + +sb_data.SetOpaque(data_extractor_sp); + } +} + } +} } return sb_data; } diff --git a/lldb/test/API/python_api/section/TestSectionAPI.py b/lldb/test/API/python_api/section/TestSectionAPI.py index b01ddece0de36..ab9ae56238c8b 100644 --- a/lldb/test/API/python_api/section/TestSectionAPI.py +++ b/lldb/test/API/python_api/section/TestSectionAPI.py @@ -48,18 +48,3 @@ def test_get_alignment(self): section = target.modules[0].sections[0] self.assertEqual(section.GetAlignment(), 0x1000) self.assertEqual(section.alignment, 0x1000) - -def test_compressed_section_data(self): -exe = self.getBuildArtifact("compressed-sections.out") -self.yaml2obj("compressed-sections.yaml", exe) -target = self.dbg.CreateTarget(exe) -self.assertTrue(target, VALID_TARGET) - -# exe contains a single section with SHF_COMPRESSED. Check that -# GetSectionData returns the uncompressed data and not the raw contents -# of the section. -section = target.modules[0].sections[0] -section_data = section.GetSectionData().uint8s -self.assertEqual(section_data, - [0x20, 0x30, 0x40, 0x50, 0x60, 0x70, 0x80, 0x90]) - diff --git a/lldb/test/API/python_api/section/compressed-sections.yaml b/lldb/test/API/python_api/section/compressed-sections.yaml deleted file mode 100644 index a41307ef7d1fc..0 --- a/lldb/test/API/python_api/section/compressed-sections.yaml +++ /dev/null @@ -1,11 +0,0 @@ !ELF -FileHeader: - Class: ELFCLASS32 - Data:ELFDATA2LSB - Type:ET_REL - Machine: EM_386 -Sections: - - Name:.compressed -Type:SHT_PROGBITS -Flags: [ SHF_COMPRESSED ] -Content: 010008000100789c533070084828689809c802c1 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] bde5d31 - Revert "Revert "[lldb] Make SBSection::GetSectionData call Section::GetSectionData.""
Author: Muhammad Omair Javaid Date: 2023-01-30T16:49:15+05:00 New Revision: bde5d31e96f556fed30bf9120cc6ff05a2116b64 URL: https://github.com/llvm/llvm-project/commit/bde5d31e96f556fed30bf9120cc6ff05a2116b64 DIFF: https://github.com/llvm/llvm-project/commit/bde5d31e96f556fed30bf9120cc6ff05a2116b64.diff LOG: Revert "Revert "[lldb] Make SBSection::GetSectionData call Section::GetSectionData."" This reverts commit e1bbe50f5a48e9b5407de9e5f4ab8197dedc85c5. Differential Revision: https://reviews.llvm.org/D142672 Added: lldb/test/API/python_api/section/compressed-sections.yaml Modified: lldb/source/API/SBSection.cpp lldb/test/API/python_api/section/TestSectionAPI.py Removed: diff --git a/lldb/source/API/SBSection.cpp b/lldb/source/API/SBSection.cpp index 3a9cf20e484a..b7b94f3ece1a 100644 --- a/lldb/source/API/SBSection.cpp +++ b/lldb/source/API/SBSection.cpp @@ -182,35 +182,10 @@ SBData SBSection::GetSectionData(uint64_t offset, uint64_t size) { SBData sb_data; SectionSP section_sp(GetSP()); if (section_sp) { -const uint64_t sect_file_size = section_sp->GetFileSize(); -if (sect_file_size > 0) { - ModuleSP module_sp(section_sp->GetModule()); - if (module_sp) { -ObjectFile *objfile = module_sp->GetObjectFile(); -if (objfile) { - const uint64_t sect_file_offset = - objfile->GetFileOffset() + section_sp->GetFileOffset(); - const uint64_t file_offset = sect_file_offset + offset; - uint64_t file_size = size; - if (file_size == UINT64_MAX) { -file_size = section_sp->GetByteSize(); -if (file_size > offset) - file_size -= offset; -else - file_size = 0; - } - auto data_buffer_sp = FileSystem::Instance().CreateDataBuffer( - objfile->GetFileSpec().GetPath(), file_size, file_offset); - if (data_buffer_sp && data_buffer_sp->GetByteSize() > 0) { -DataExtractorSP data_extractor_sp( -new DataExtractor(data_buffer_sp, objfile->GetByteOrder(), - objfile->GetAddressByteSize())); - -sb_data.SetOpaque(data_extractor_sp); - } -} - } -} +DataExtractor section_data; +section_sp->GetSectionData(section_data); +sb_data.SetOpaque( +std::make_shared(section_data, offset, size)); } return sb_data; } diff --git a/lldb/test/API/python_api/section/TestSectionAPI.py b/lldb/test/API/python_api/section/TestSectionAPI.py index ab9ae56238c8..684de3f3eec6 100644 --- a/lldb/test/API/python_api/section/TestSectionAPI.py +++ b/lldb/test/API/python_api/section/TestSectionAPI.py @@ -11,6 +11,8 @@ class SectionAPITestCase(TestBase): +@no_debug_info_test +@skipIfXmlSupportMissing def test_get_target_byte_size(self): d = {'EXE': 'b.out'} self.build(dictionary=d) @@ -38,6 +40,8 @@ def test_get_target_byte_size(self): self.assertIsNotNone(data_section) self.assertEqual(data_section.target_byte_size, 1) +@no_debug_info_test +@skipIfXmlSupportMissing def test_get_alignment(self): exe = self.getBuildArtifact("aligned.out") self.yaml2obj("aligned.yaml", exe) @@ -48,3 +52,20 @@ def test_get_alignment(self): section = target.modules[0].sections[0] self.assertEqual(section.GetAlignment(), 0x1000) self.assertEqual(section.alignment, 0x1000) + +@no_debug_info_test +@skipIfXmlSupportMissing +def test_compressed_section_data(self): +exe = self.getBuildArtifact("compressed-sections.out") +self.yaml2obj("compressed-sections.yaml", exe) +target = self.dbg.CreateTarget(exe) +self.assertTrue(target, VALID_TARGET) + +# exe contains a single section with SHF_COMPRESSED. Check that +# GetSectionData returns the uncompressed data and not the raw contents +# of the section. +section = target.modules[0].sections[0] +section_data = section.GetSectionData().uint8s +self.assertEqual(section_data, + [0x20, 0x30, 0x40, 0x50, 0x60, 0x70, 0x80, 0x90]) + diff --git a/lldb/test/API/python_api/section/compressed-sections.yaml b/lldb/test/API/python_api/section/compressed-sections.yaml new file mode 100644 index ..a41307ef7d1f --- /dev/null +++ b/lldb/test/API/python_api/section/compressed-sections.yaml @@ -0,0 +1,11 @@ +--- !ELF +FileHeader: + Class: ELFCLASS32 + Data:ELFDATA2LSB + Type:ET_REL + Machine: EM_386 +Sections: + - Name:.compressed +Type:SHT_PROGBITS +Flags: [ SHF_COMPRESSED ] +Content: 010008000100789c533070084828689809c802c1 ___
[Lldb-commits] [lldb] 71b3806 - Fix LLDB windows build
Author: Muhammad Omair Javaid Date: 2023-03-07T05:37:15+04:00 New Revision: 71b38063b282937640e05ab219c2baa6ed7d4ac7 URL: https://github.com/llvm/llvm-project/commit/71b38063b282937640e05ab219c2baa6ed7d4ac7 DIFF: https://github.com/llvm/llvm-project/commit/71b38063b282937640e05ab219c2baa6ed7d4ac7.diff LOG: Fix LLDB windows build LLDB WoA buildbot is failing due to pid_t redefinition after recent changes in lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp. Process.h includes PosixApi.h which defines pid_t. Python.h on windows also typedefs pid_t. To make sure that we include Python.h before PosixApi this patch renforces the workaround previously set up to guard this issue. https://lab.llvm.org/buildbot/#/builders/219 Reviewed By: mib Differential Revision: https://reviews.llvm.org/D145446 Added: Modified: lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp Removed: diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp index cffa3bda3ab03..c985065835727 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp +++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.cpp @@ -7,6 +7,10 @@ //===--===// #include "lldb/Host/Config.h" +#if LLDB_ENABLE_PYTHON +// LLDB Python header must be included first +#include "lldb-python.h" +#endif #include "lldb/Target/Process.h" #include "lldb/Utility/Log.h" #include "lldb/Utility/Status.h" @@ -14,9 +18,6 @@ #if LLDB_ENABLE_PYTHON -// LLDB Python header must be included first -#include "lldb-python.h" - #include "SWIGPythonBridge.h" #include "ScriptInterpreterPythonImpl.h" #include "ScriptedProcessPythonInterface.h" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 9d28e00 - [LLDB] XFAIL TestRunLocker.py on Windows
Author: Muhammad Omair Javaid Date: 2023-03-02T11:05:23+04:00 New Revision: 9d28e00e741cb19684111656803434aceef4c2a0 URL: https://github.com/llvm/llvm-project/commit/9d28e00e741cb19684111656803434aceef4c2a0 DIFF: https://github.com/llvm/llvm-project/commit/9d28e00e741cb19684111656803434aceef4c2a0.diff LOG: [LLDB] XFAIL TestRunLocker.py on Windows Added: Modified: lldb/test/API/python_api/run_locker/TestRunLocker.py Removed: diff --git a/lldb/test/API/python_api/run_locker/TestRunLocker.py b/lldb/test/API/python_api/run_locker/TestRunLocker.py index 191400d6c024f..ff34d47142b41 100644 --- a/lldb/test/API/python_api/run_locker/TestRunLocker.py +++ b/lldb/test/API/python_api/run_locker/TestRunLocker.py @@ -14,11 +14,13 @@ class TestRunLocker(TestBase): NO_DEBUG_INFO_TESTCASE = True +@expectedFailureAll(oslist=["windows"]) def test_run_locker(self): """Test that the run locker is set correctly when we launch""" self.build() self.runlocker_test(False) +@expectedFailureAll(oslist=["windows"]) def test_run_locker_stop_at_entry(self): """Test that the run locker is set correctly when we launch""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 588da01 - Revert "[LLDB] XFAIL TestRunLocker.py on Windows"
Author: Muhammad Omair Javaid Date: 2023-03-02T11:22:25+04:00 New Revision: 588da01621a1f8efd139e677526b64c1e5ecf303 URL: https://github.com/llvm/llvm-project/commit/588da01621a1f8efd139e677526b64c1e5ecf303 DIFF: https://github.com/llvm/llvm-project/commit/588da01621a1f8efd139e677526b64c1e5ecf303.diff LOG: Revert "[LLDB] XFAIL TestRunLocker.py on Windows" This reverts commit 9d28e00e741cb19684111656803434aceef4c2a0. Added: Modified: lldb/test/API/python_api/run_locker/TestRunLocker.py Removed: diff --git a/lldb/test/API/python_api/run_locker/TestRunLocker.py b/lldb/test/API/python_api/run_locker/TestRunLocker.py index ff34d47142b41..191400d6c024f 100644 --- a/lldb/test/API/python_api/run_locker/TestRunLocker.py +++ b/lldb/test/API/python_api/run_locker/TestRunLocker.py @@ -14,13 +14,11 @@ class TestRunLocker(TestBase): NO_DEBUG_INFO_TESTCASE = True -@expectedFailureAll(oslist=["windows"]) def test_run_locker(self): """Test that the run locker is set correctly when we launch""" self.build() self.runlocker_test(False) -@expectedFailureAll(oslist=["windows"]) def test_run_locker_stop_at_entry(self): """Test that the run locker is set correctly when we launch""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] e85e5ab - [LLDB] XFAIL TestRunLocker.py for windows
Author: Muhammad Omair Javaid Date: 2023-03-02T11:51:35+04:00 New Revision: e85e5abdceff6983a7ca1b647a97d0e0aaf6bf38 URL: https://github.com/llvm/llvm-project/commit/e85e5abdceff6983a7ca1b647a97d0e0aaf6bf38 DIFF: https://github.com/llvm/llvm-project/commit/e85e5abdceff6983a7ca1b647a97d0e0aaf6bf38.diff LOG: [LLDB] XFAIL TestRunLocker.py for windows TestRunLocker.py is failing on windows x64 and AArch64 buildbots. Buildbot log suggests that test needs some minor modification for windows which I will do later. https://lab.llvm.org/buildbot/#/builders/83/builds/29680 https://lab.llvm.org/buildbot/#/builders/219/builds/942 Added: Modified: lldb/test/API/python_api/run_locker/TestRunLocker.py Removed: diff --git a/lldb/test/API/python_api/run_locker/TestRunLocker.py b/lldb/test/API/python_api/run_locker/TestRunLocker.py index 191400d6c024f..c257684d22c24 100644 --- a/lldb/test/API/python_api/run_locker/TestRunLocker.py +++ b/lldb/test/API/python_api/run_locker/TestRunLocker.py @@ -7,6 +7,7 @@ import lldb import lldbsuite.test.lldbutil as lldbutil +from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * @@ -14,11 +15,13 @@ class TestRunLocker(TestBase): NO_DEBUG_INFO_TESTCASE = True +@expectedFailureAll(oslist=["windows"]) def test_run_locker(self): """Test that the run locker is set correctly when we launch""" self.build() self.runlocker_test(False) +@expectedFailureAll(oslist=["windows"]) def test_run_locker_stop_at_entry(self): """Test that the run locker is set correctly when we launch""" self.build() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 9fdf82d - [LLDB] Fix broken Windows unittests build
Author: Muhammad Omair Javaid Date: 2023-04-17T08:31:43+05:00 New Revision: 9fdf82dc32dc38e0b92dab3215a83d8f3c2f9bbf URL: https://github.com/llvm/llvm-project/commit/9fdf82dc32dc38e0b92dab3215a83d8f3c2f9bbf DIFF: https://github.com/llvm/llvm-project/commit/9fdf82dc32dc38e0b92dab3215a83d8f3c2f9bbf.diff LOG: [LLDB] Fix broken Windows unittests build LLDB Windows tests were broken because SymbolFilePDBTests.cpp failed to compile after 6cdfa295743729178ff6f15a8dcd36f8f7d27c2c. This patch fixes the SymbolFilePDBTests.cpp. (Tested on Surface X Pro) https://lab.llvm.org/buildbot/#/builders/219 Differential Revision: https://reviews.llvm.org/D147436 Added: Modified: lldb/unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp Removed: diff --git a/lldb/unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp b/lldb/unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp index 2c49b34b34fe3..bd69d246072ca 100644 --- a/lldb/unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp +++ b/lldb/unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp @@ -456,7 +456,8 @@ TEST_F(SymbolFilePDBTests, TestClassInNamespace) { symfile->ParseDeclsForContext(CompilerDeclContext( clang_ast_ctx, static_cast(tu))); - auto ns_namespace = symfile->FindNamespace(ConstString("NS"), CompilerDeclContext()); + auto ns_namespace = + symfile->FindNamespace(ConstString("NS"), CompilerDeclContext(), true); EXPECT_TRUE(ns_namespace.IsValid()); symfile->FindTypes(ConstString("NSClass"), ns_namespace, 0, searched_files, ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 6ea1a0d - [LLDB] Add/Remove xfail for some API tests on Windows
Author: Muhammad Omair Javaid Date: 2023-05-03T04:45:55+05:00 New Revision: 6ea1a0d4fc3823de143a288df2059b48dc01cf72 URL: https://github.com/llvm/llvm-project/commit/6ea1a0d4fc3823de143a288df2059b48dc01cf72 DIFF: https://github.com/llvm/llvm-project/commit/6ea1a0d4fc3823de143a288df2059b48dc01cf72.diff LOG: [LLDB] Add/Remove xfail for some API tests on Windows This patch add or removes XFAIL decorator from various tests which were marked xfail for windows. since 44363f2 various tests have started passing but introduced a couple of new failures. Weight is in favor of new XPasses and I have removed XFail decorator from them. Also some new tests have started failing for which we need to file separate bugs. I have marked them xfail for now and will add the bug id after investigating the issue. Differential Revision: https://reviews.llvm.org/D149235 Added: Modified: lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py lldb/test/API/lang/c/step-target/TestStepTarget.py lldb/test/API/lang/cpp/constructors/TestCppConstructors.py lldb/test/API/lang/cpp/global_variables/TestCPPGlobalVariables.py lldb/test/API/lang/cpp/namespace/TestNamespace.py lldb/test/API/lang/cpp/static_members/TestCPPStaticMembers.py lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py lldb/test/API/python_api/function_symbol/TestDisasmAPI.py lldb/test/API/python_api/function_symbol/TestSymbolAPI.py lldb/test/API/python_api/symbol-context/TestSymbolContext.py lldb/test/API/python_api/target/TestTargetAPI.py lldb/test/API/python_api/value/TestValueAPI.py Removed: diff --git a/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py b/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py index e14f160f1e576..2ee90181d9327 100644 --- a/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py +++ b/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py @@ -2,4 +2,4 @@ from lldbsuite.test import decorators lldbinline.MakeInlineTest(__file__, globals(), - [decorators.expectedFailureAll(bugnumber="llvm.org/pr50814", compiler="gcc")]) + [decorators.expectedFailureAll(bugnumber="llvm.org/pr50814", compiler="gcc"), decorators.expectedFailureAll(oslist=["windows"])]) diff --git a/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py b/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py index 157bed4880a3d..e3e20ad94707d 100644 --- a/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py +++ b/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py @@ -22,7 +22,6 @@ def cleanJITFiles(self): os.remove(j) return -@expectedFailureAll(oslist=["windows"]) def test_save_jit_objects(self): self.build() os.chdir(self.getBuildDir()) diff --git a/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py b/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py index 8a143bdf3817a..edac8b1981fdf 100644 --- a/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py +++ b/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py @@ -13,20 +13,17 @@ class TestScriptedResolver(TestBase): NO_DEBUG_INFO_TESTCASE = True -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_scripted_resolver(self): """Use a scripted resolver to set a by symbol name breakpoint""" self.build() self.do_test() -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_search_depths(self): """ Make sure we are called at the right depths depending on what we return from __get_depth__""" self.build() self.do_test_depths() -@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_command_line(self): """ Test setting a resolver breakpoint from the command line """ self.build() diff --git a/lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py
[Lldb-commits] [lldb] d093111 - [LLDB] Remove XFAIL on Windows decorator XPASSes
Author: Muhammad Omair Javaid Date: 2023-05-29T12:13:16+04:00 New Revision: d093111ab135154cabc77e5bad625d9d7cd720d5 URL: https://github.com/llvm/llvm-project/commit/d093111ab135154cabc77e5bad625d9d7cd720d5 DIFF: https://github.com/llvm/llvm-project/commit/d093111ab135154cabc77e5bad625d9d7cd720d5.diff LOG: [LLDB] Remove XFAIL on Windows decorator XPASSes Following tests are now passing on LLDB AArch64 Windows buildbot: lldb-api :: commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py lldb-api :: functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py lldb-api :: lang/cpp/constructors/TestCppConstructors.py lldb-api :: lang/cpp/namespace/TestNamespace.py lldb-api :: lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py https://lab.llvm.org/buildbot/#/builders/219/builds/3012 This patch removes XFAIL decorator from all of the above. Differential Revision: https://reviews.llvm.org/D151268 Added: Modified: lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py lldb/test/API/lang/cpp/constructors/TestCppConstructors.py lldb/test/API/lang/cpp/namespace/TestNamespace.py lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py Removed: diff --git a/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py b/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py index c69b4e5b32ef5..ce74dd27cc179 100644 --- a/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py +++ b/lldb/test/API/commands/expression/deleting-implicit-copy-constructor/TestDeletingImplicitCopyConstructor.py @@ -6,6 +6,5 @@ globals(), [ decorators.expectedFailureAll(bugnumber="llvm.org/pr50814", compiler="gcc"), -decorators.expectedFailureAll(oslist=["windows"]), ], ) diff --git a/lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py b/lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py index 47840102cf3cc..f602d017f28b7 100644 --- a/lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py +++ b/lldb/test/API/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py @@ -16,7 +16,6 @@ def setUp(self): self.line = line_number("main.cpp", "// Set break point at this line.") @expectedFlakeyNetBSD -@expectedFailureAll(oslist=["windows"]) def test_with_run_command(self): """Test that that file and class static variables display correctly.""" self.build() diff --git a/lldb/test/API/lang/cpp/constructors/TestCppConstructors.py b/lldb/test/API/lang/cpp/constructors/TestCppConstructors.py index 0c3de3aaf1a55..4c50de0cd7502 100644 --- a/lldb/test/API/lang/cpp/constructors/TestCppConstructors.py +++ b/lldb/test/API/lang/cpp/constructors/TestCppConstructors.py @@ -6,7 +6,6 @@ class TestCase(TestBase): @expectedFailureAll(bugnumber="llvm.org/pr50814", compiler="gcc") -@expectedFailureAll(oslist=["windows"]) def test_constructors(self): self.build() lldbutil.run_to_source_breakpoint( diff --git a/lldb/test/API/lang/cpp/namespace/TestNamespace.py b/lldb/test/API/lang/cpp/namespace/TestNamespace.py index 1301342599df1..1dc9d00fcd993 100644 --- a/lldb/test/API/lang/cpp/namespace/TestNamespace.py +++ b/lldb/test/API/lang/cpp/namespace/TestNamespace.py @@ -11,7 +11,6 @@ class NamespaceBreakpointTestCase(TestBase): @expectedFailureAll(bugnumber="llvm.org/pr28548", compiler="gcc") -@expectedFailureAll(oslist=["windows"]) def test_breakpoints_func_auto(self): """Test that we can set breakpoints correctly by basename to find all functions whose basename is "func".""" self.build() diff --git a/lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py b/lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py index a307d091ed0d7..2321246a2e7e5 100644 --- a/lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py +++ b/lldb/test/API/lang/cpp/this_class_type_mixing/TestThisClassTypeMixing.py @@ -16,7 +16,6 @@ class by injecting a "$__lldb_expr" member function into the class. This class TestCase(TestBase): @no_debug_info_test -@expectedFailureAll(oslist=["windows"]) def test(self): self.build() lldbutil.run_to_source_breakpoint( ___ lldb-commits mailing list
[Lldb-commits] [lldb] ab05d91 - Revert "[LLDB] Add/Remove xfail for some API tests on Windows"
Author: tcwg Date: 2023-05-29T17:39:36+04:00 New Revision: ab05d9134d18db34501985a01fbfc02609767587 URL: https://github.com/llvm/llvm-project/commit/ab05d9134d18db34501985a01fbfc02609767587 DIFF: https://github.com/llvm/llvm-project/commit/ab05d9134d18db34501985a01fbfc02609767587.diff LOG: Revert "[LLDB] Add/Remove xfail for some API tests on Windows" This reverts commit 6ea1a0d4fc3823de143a288df2059b48dc01cf72. It again marks XFAIL LLDB tests failing after c384fcd3ea1dad782eaaea89b32fc33c0c3528b8 Added: Modified: lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py lldb/test/API/lang/c/step-target/TestStepTarget.py lldb/test/API/lang/cpp/global_variables/TestCPPGlobalVariables.py lldb/test/API/lang/cpp/namespace/TestNamespace.py lldb/test/API/lang/cpp/static_members/TestCPPStaticMembers.py lldb/test/API/python_api/function_symbol/TestDisasmAPI.py lldb/test/API/python_api/function_symbol/TestSymbolAPI.py lldb/test/API/python_api/symbol-context/TestSymbolContext.py lldb/test/API/python_api/target/TestTargetAPI.py lldb/test/API/python_api/value/TestValueAPI.py Removed: diff --git a/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py b/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py index 48377a75d23bb..438b92cdc4846 100644 --- a/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py +++ b/lldb/test/API/commands/expression/save_jit_objects/TestSaveJITObjects.py @@ -22,6 +22,7 @@ def cleanJITFiles(self): os.remove(j) return +@expectedFailureAll(oslist=["windows"]) def test_save_jit_objects(self): self.build() os.chdir(self.getBuildDir()) diff --git a/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py b/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py index 745700a14a3f0..9f477f951cd86 100644 --- a/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py +++ b/lldb/test/API/functionalities/breakpoint/scripted_bkpt/TestScriptedResolver.py @@ -12,17 +12,20 @@ class TestScriptedResolver(TestBase): NO_DEBUG_INFO_TESTCASE = True +@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_scripted_resolver(self): """Use a scripted resolver to set a by symbol name breakpoint""" self.build() self.do_test() +@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_search_depths(self): """Make sure we are called at the right depths depending on what we return from __get_depth__""" self.build() self.do_test_depths() +@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr24528") def test_command_line(self): """Test setting a resolver breakpoint from the command line""" self.build() diff --git a/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py b/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py index ae4847bb788fe..49a72c2863e74 100644 --- a/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py +++ b/lldb/test/API/functionalities/inline-stepping/TestInlineStepping.py @@ -25,7 +25,8 @@ def test_step_over_with_python_api(self): self.build() self.inline_stepping_step_over() -@add_test_categories(["pyapi"]) +@add_test_categories(['pyapi']) +@expectedFailureAll(oslist=["windows"], bugnumber="llvm.org/pr32343") def test_step_in_template_with_python_api(self): """Test stepping in to templated functions.""" self.build() diff --git a/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py b/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py index 1d4a0008f6b44..6c399b8a0a1b2 100644 --- a/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py +++ b/lldb/test/API/functionalities/step-avoids-no-debug/TestStepNoDebug.py @@ -10,7 +10,9 @@ class StepAvoidsNoDebugTestCase(TestBase): -@add_test_categories(["pyapi"]) + +@add_test_categories(['pyapi']) +@expectedFailureAll(archs=["aarch64"], oslist=["windows"], bugnumber="llvm.org/pr56292") def test_step_out_with_python(self): """Test stepping out using avoid-no-debug with dsyms.""" self.build() @@ -24,8 +26,8 @@ def test_step_out_with_python(self): compiler_version=[">=", "3.9"], archs=["i386"], oslist=no_match(["freebsd"]), -bugnumber="llvm.org/pr28549", -) +bugnumber="llvm.org/pr28549")
[Lldb-commits] [lldb] 7fb60b0 - [LLDB] Add XFAIL on AArch64/Windows to TestNamespace.py
Author: Muhammad Omair Javaid Date: 2023-05-29T18:53:42+04:00 New Revision: 7fb60b0123e50389afbde0286a0e59923d154210 URL: https://github.com/llvm/llvm-project/commit/7fb60b0123e50389afbde0286a0e59923d154210 DIFF: https://github.com/llvm/llvm-project/commit/7fb60b0123e50389afbde0286a0e59923d154210.diff LOG: [LLDB] Add XFAIL on AArch64/Windows to TestNamespace.py Added: Modified: lldb/test/API/lang/cpp/namespace/TestNamespace.py Removed: diff --git a/lldb/test/API/lang/cpp/namespace/TestNamespace.py b/lldb/test/API/lang/cpp/namespace/TestNamespace.py index 960cdac06dea..1dc9d00fcd99 100644 --- a/lldb/test/API/lang/cpp/namespace/TestNamespace.py +++ b/lldb/test/API/lang/cpp/namespace/TestNamespace.py @@ -37,6 +37,7 @@ def test_breakpoints_func_auto(self): ) @expectedFailureAll(bugnumber="llvm.org/pr28548", compiler="gcc") +@expectedFailureAll(oslist=["windows"]) def test_breakpoints_func_full(self): """Test that we can set breakpoints correctly by fullname to find all functions whose fully qualified name is "func" (no namespaces).""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] f2a8661 - [LLDB] Fix TestVarPath.py for AArch64 Windows
Author: Muhammad Omair Javaid Date: 2023-05-29T16:17:13+04:00 New Revision: f2a866170c4961137608eee1c26f6eaa1e8e62a1 URL: https://github.com/llvm/llvm-project/commit/f2a866170c4961137608eee1c26f6eaa1e8e62a1 DIFF: https://github.com/llvm/llvm-project/commit/f2a866170c4961137608eee1c26f6eaa1e8e62a1.diff LOG: [LLDB] Fix TestVarPath.py for AArch64 Windows Since 44bb442 LLDB TestVarPath.py crashes on AArch64 Windows. GetValueForVariablePath function seems to be triggering the crash. This patch disable parts of this test causing the crash. Bug reported upstream: https://github.com/llvm/llvm-project/issues/62983 Added: Modified: lldb/test/API/functionalities/var_path/TestVarPath.py Removed: diff --git a/lldb/test/API/functionalities/var_path/TestVarPath.py b/lldb/test/API/functionalities/var_path/TestVarPath.py index 06b4a2d8da313..f79b2a7584ae9 100644 --- a/lldb/test/API/functionalities/var_path/TestVarPath.py +++ b/lldb/test/API/functionalities/var_path/TestVarPath.py @@ -5,6 +5,7 @@ import lldb import lldbsuite.test.lldbutil as lldbutil +from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * @@ -115,7 +116,7 @@ def do_test(self): self.assertSuccess(v.GetError(), "Make sure we find 'pt_sp'") # Make sure we don't crash when looking for non existant child # in type with synthetic children. This used to cause a crash. -v = frame.GetValueForVariablePath("pt_sp->not_valid_child") -self.assertTrue( -v.GetError().Fail(), "Make sure we don't find 'pt_sp->not_valid_child'" -) +if not self.isAArch64Windows(): +v = frame.GetValueForVariablePath("pt_sp->not_valid_child") +self.assertTrue(v.GetError().Fail(), +"Make sure we don't find 'pt_sp->not_valid_child'") ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 898b880 - [LLDB] Update AArch64/Windows XFAIl decorators on TestNamespace.py
Author: Muhammad Omair Javaid Date: 2023-05-30T13:06:09+04:00 New Revision: 898b880308f1ce31520c939ab19366dc3b82c930 URL: https://github.com/llvm/llvm-project/commit/898b880308f1ce31520c939ab19366dc3b82c930 DIFF: https://github.com/llvm/llvm-project/commit/898b880308f1ce31520c939ab19366dc3b82c930.diff LOG: [LLDB] Update AArch64/Windows XFAIl decorators on TestNamespace.py Added: Modified: lldb/test/API/lang/cpp/namespace/TestNamespace.py Removed: diff --git a/lldb/test/API/lang/cpp/namespace/TestNamespace.py b/lldb/test/API/lang/cpp/namespace/TestNamespace.py index 1dc9d00fcd993..3006699b6623a 100644 --- a/lldb/test/API/lang/cpp/namespace/TestNamespace.py +++ b/lldb/test/API/lang/cpp/namespace/TestNamespace.py @@ -11,6 +11,7 @@ class NamespaceBreakpointTestCase(TestBase): @expectedFailureAll(bugnumber="llvm.org/pr28548", compiler="gcc") +@expectedFailureAll(oslist=["windows"]) def test_breakpoints_func_auto(self): """Test that we can set breakpoints correctly by basename to find all functions whose basename is "func".""" self.build() @@ -37,7 +38,6 @@ def test_breakpoints_func_auto(self): ) @expectedFailureAll(bugnumber="llvm.org/pr28548", compiler="gcc") -@expectedFailureAll(oslist=["windows"]) def test_breakpoints_func_full(self): """Test that we can set breakpoints correctly by fullname to find all functions whose fully qualified name is "func" (no namespaces).""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 5dfec67 - [LLDB] Skip TestInterruptBacktrace.py on Arm/Linux
Author: Muhammad Omair Javaid Date: 2023-05-22T14:53:35+04:00 New Revision: 5dfec676c3ab4fa2b7ea95d203f97faf7768b77f URL: https://github.com/llvm/llvm-project/commit/5dfec676c3ab4fa2b7ea95d203f97faf7768b77f DIFF: https://github.com/llvm/llvm-project/commit/5dfec676c3ab4fa2b7ea95d203f97faf7768b77f.diff LOG: [LLDB] Skip TestInterruptBacktrace.py on Arm/Linux TestInterruptBacktrace.py started randonmly failing on Arm/Linux buildbot since e19387e6936c. This patch marks it skipped. Differential Revision: https://reviews.llvm.org/D150236 Added: Modified: lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py Removed: diff --git a/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py b/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py index 57a994d11035d..8d4161355122c 100644 --- a/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py +++ b/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py @@ -12,6 +12,7 @@ class TestInterruptingBacktrace(TestBase): NO_DEBUG_INFO_TESTCASE = True +@skipIf(oslist=["linux"], archs=["arm"]) def test_backtrace_interrupt(self): """Use RequestInterrupt followed by stack operations to ensure correct interrupt behavior for stacks.""" ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] a7c7c61 - [LLDB] Fix missing import in TestInterruptBacktrace.py
Author: Muhammad Omair Javaid Date: 2023-05-22T15:47:05+04:00 New Revision: a7c7c61af63188a66bd1ad67f9f25b48e5722b58 URL: https://github.com/llvm/llvm-project/commit/a7c7c61af63188a66bd1ad67f9f25b48e5722b58 DIFF: https://github.com/llvm/llvm-project/commit/a7c7c61af63188a66bd1ad67f9f25b48e5722b58.diff LOG: [LLDB] Fix missing import in TestInterruptBacktrace.py This fixed missing import of lldbsuite.test.decorators in TestInterruptBacktrace.py. Added: Modified: lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py Removed: diff --git a/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py b/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py index 8d4161355122..ae2863c28f46 100644 --- a/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py +++ b/lldb/test/API/functionalities/bt-interrupt/TestInterruptBacktrace.py @@ -6,7 +6,7 @@ import lldb import lldbsuite.test.lldbutil as lldbutil from lldbsuite.test.lldbtest import * - +from lldbsuite.test.decorators import * class TestInterruptingBacktrace(TestBase): ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 039b28e - [LLDB] Fix TestDataFormatterSynthVal.py for AArch64/Windows
Author: Muhammad Omair Javaid Date: 2023-05-16T00:14:20+04:00 New Revision: 039b28e14e6d5a4b9b9b333695dabe9dc57233b0 URL: https://github.com/llvm/llvm-project/commit/039b28e14e6d5a4b9b9b333695dabe9dc57233b0 DIFF: https://github.com/llvm/llvm-project/commit/039b28e14e6d5a4b9b9b333695dabe9dc57233b0.diff LOG: [LLDB] Fix TestDataFormatterSynthVal.py for AArch64/Windows Since 44363f2 various tests have started passing but introduced a expression evaluation failure in TestDataFormatterSynthVal.py. This patch marks the expression evaluation part as skipped while rest of the test passes. This patch aslo introduces a new helper isAArch64Windows in lldbtest.py. Added: Modified: lldb/packages/Python/lldbsuite/test/lldbtest.py lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py Removed: diff --git a/lldb/packages/Python/lldbsuite/test/lldbtest.py b/lldb/packages/Python/lldbsuite/test/lldbtest.py index 31539f6a768bd..0ca0fac7bb3f6 100644 --- a/lldb/packages/Python/lldbsuite/test/lldbtest.py +++ b/lldb/packages/Python/lldbsuite/test/lldbtest.py @@ -1252,6 +1252,13 @@ def isAArch64PAuth(self): return True return self.isAArch64() and "paca" in self.getCPUInfo() +def isAArch64Windows(self): +"""Returns true if the architecture is AArch64 and platform windows.""" +if self.getPlatform() == 'windows': +arch = self.getArchitecture().lower() +return arch in ["aarch64", "arm64", "arm64e"] +return False + def getArchitecture(self): """Returns the architecture in effect the test suite is running with.""" module = builder_module() diff --git a/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py b/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py index 2e1367563cd7b..67619287ef65e 100644 --- a/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py +++ b/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py @@ -96,9 +96,10 @@ def cleanup(): # check that an aptly defined synthetic provider does not affect # one-lining -self.expect( -"expression struct Struct { myInt theInt{12}; }; Struct()", -substrs=['(theInt = 12)']) +if self.isAArch64Windows(): +self.expect( +"expression struct Struct { myInt theInt{12}; }; Struct()", +substrs=['(theInt = 12)']) # check that we can use a synthetic value in a summary self.runCmd("type summary add hasAnInt -s ${var.theInt}") ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 58e6caa - Revert "[lldb] Refactor SBFileSpec::GetDirectory"
Author: Muhammad Omair Javaid Date: 2023-05-15T22:49:00+04:00 New Revision: 58e6caaba1cf623292c8898be30a5a56722432b3 URL: https://github.com/llvm/llvm-project/commit/58e6caaba1cf623292c8898be30a5a56722432b3 DIFF: https://github.com/llvm/llvm-project/commit/58e6caaba1cf623292c8898be30a5a56722432b3.diff LOG: Revert "[lldb] Refactor SBFileSpec::GetDirectory" This reverts commit 2bea2d7b070dc5df723ce2b92dbc654b8bb1847e. It introduced following failures on buildbot lldb-aarch64-windows: lldb-api :: functionalities/process_save_core/TestProcessSaveCore.py lldb-api :: python_api/symbol-context/TestSymbolContext.py Differential Revision: https://reviews.llvm.org/D149625 Added: Modified: lldb/source/API/SBFileSpec.cpp Removed: diff --git a/lldb/source/API/SBFileSpec.cpp b/lldb/source/API/SBFileSpec.cpp index 8668b64b4ce76..a7df9afc4b8eb 100644 --- a/lldb/source/API/SBFileSpec.cpp +++ b/lldb/source/API/SBFileSpec.cpp @@ -114,7 +114,9 @@ const char *SBFileSpec::GetFilename() const { const char *SBFileSpec::GetDirectory() const { LLDB_INSTRUMENT_VA(this); - return m_opaque_up->GetDirectory().GetCString(); + FileSpec directory{*m_opaque_up}; + directory.ClearFilename(); + return directory.GetPathAsConstString().GetCString(); } void SBFileSpec::SetFilename(const char *filename) { ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 617c31c - [LLDB] Fix typo in TestDataFormatterSynthVal.py
Author: Muhammad Omair Javaid Date: 2023-05-16T10:13:06+04:00 New Revision: 617c31c6a1ddd57c6b750b3882c177175067a735 URL: https://github.com/llvm/llvm-project/commit/617c31c6a1ddd57c6b750b3882c177175067a735 DIFF: https://github.com/llvm/llvm-project/commit/617c31c6a1ddd57c6b750b3882c177175067a735.diff LOG: [LLDB] Fix typo in TestDataFormatterSynthVal.py This is follow up to 039b28e14e6d to fix a typo to make sure skipped part of test is only skipped for AArch64 Windows platform. Added: Modified: lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py Removed: diff --git a/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py b/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py index 67619287ef65..6b0397626690 100644 --- a/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py +++ b/lldb/test/API/functionalities/data-formatter/data-formatter-synthval/TestDataFormatterSynthVal.py @@ -96,7 +96,7 @@ def cleanup(): # check that an aptly defined synthetic provider does not affect # one-lining -if self.isAArch64Windows(): +if not self.isAArch64Windows(): self.expect( "expression struct Struct { myInt theInt{12}; }; Struct()", substrs=['(theInt = 12)']) ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] c1fe190 - Revert "Add new API in SBTarget for loading core from SBFile (#71769)"
Author: Muhammad Omair Javaid Date: 2023-11-20T11:12:34+05:00 New Revision: c1fe1900491ae773e45e41604af25312e5fc6559 URL: https://github.com/llvm/llvm-project/commit/c1fe1900491ae773e45e41604af25312e5fc6559 DIFF: https://github.com/llvm/llvm-project/commit/c1fe1900491ae773e45e41604af25312e5fc6559.diff LOG: Revert "Add new API in SBTarget for loading core from SBFile (#71769)" This reverts commit e2fb816c4f0286ddf8b1030148a343d5efc14e01. It breaks TestLinuxCore.py on lldb-*-windows. See buildbot below: https://lab.llvm.org/buildbot/#/builders/219/builds/7014 Added: Modified: lldb/include/lldb/API/SBTarget.h lldb/source/API/SBTarget.cpp lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py Removed: diff --git a/lldb/include/lldb/API/SBTarget.h b/lldb/include/lldb/API/SBTarget.h index 8e44cd5513c5b20..83087623088c5b4 100644 --- a/lldb/include/lldb/API/SBTarget.h +++ b/lldb/include/lldb/API/SBTarget.h @@ -184,7 +184,6 @@ class LLDB_API SBTarget { SBProcess LoadCore(const char *core_file); SBProcess LoadCore(const char *core_file, lldb::SBError ); - SBProcess LoadCore(const SBFile , lldb::SBError ); /// Launch a new process with sensible defaults. /// diff --git a/lldb/source/API/SBTarget.cpp b/lldb/source/API/SBTarget.cpp index 9632627e3cefc42..2d029554492a05c 100644 --- a/lldb/source/API/SBTarget.cpp +++ b/lldb/source/API/SBTarget.cpp @@ -16,7 +16,6 @@ #include "lldb/API/SBEnvironment.h" #include "lldb/API/SBEvent.h" #include "lldb/API/SBExpressionOptions.h" -#include "lldb/API/SBFile.h" #include "lldb/API/SBFileSpec.h" #include "lldb/API/SBListener.h" #include "lldb/API/SBModule.h" @@ -261,31 +260,6 @@ SBProcess SBTarget::LoadCore(const char *core_file, lldb::SBError ) { return sb_process; } -SBProcess SBTarget::LoadCore(const SBFile , lldb::SBError ) { - LLDB_INSTRUMENT_VA(this, file, error); - - SBProcess sb_process; - TargetSP target_sp(GetSP()); - if (target_sp) { -FileSP file_sp = file.GetFile(); -FileSpec filespec; -file_sp->GetFileSpec(filespec); -FileSystem::Instance().Resolve(filespec); -ProcessSP process_sp(target_sp->CreateProcess( -target_sp->GetDebugger().GetListener(), "", , false)); -if (process_sp) { - error.SetError(process_sp->LoadCore()); - if (error.Success()) -sb_process.SetSP(process_sp); -} else { - error.SetErrorString("Failed to create the process"); -} - } else { -error.SetErrorString("SBTarget is invalid"); - } - return sb_process; -} - SBProcess SBTarget::LaunchSimple(char const **argv, char const **envp, const char *working_directory) { LLDB_INSTRUMENT_VA(this, argv, envp, working_directory); diff --git a/lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py b/lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py index a6a8518f9397da3..58f104eb49de245 100644 --- a/lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py +++ b/lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py @@ -53,11 +53,6 @@ def test_x86_64(self): """Test that lldb can read the process information from an x86_64 linux core file.""" self.do_test("linux-x86_64", self._x86_64_pid, self._x86_64_regions, "a.out") -@skipIfLLVMTargetMissing("X86") -def test_x86_64_fd(self): -"""Test that lldb can read the process information from an x86_64 linux core file.""" -self.do_test_fd("linux-x86_64", self._x86_64_pid, self._x86_64_regions, "a.out") - @skipIfLLVMTargetMissing("SystemZ") def test_s390x(self): """Test that lldb can read the process information from an s390x linux core file.""" @@ -762,19 +757,6 @@ def do_test(self, filename, pid, region_count, thread_name): self.dbg.DeleteTarget(target) -def do_test_fd(self, filename, pid, region_count, thread_name): -file_object = open(filename + ".core", "r") -fd = file_object.fileno() -file = lldb.SBFile(fd, "r", True) -target = self.dbg.CreateTarget(filename + ".out") -error = lldb.SBError() -process = target.LoadCore(file, error) - -self.check_all(process, pid, region_count, thread_name) - -self.dbg.DeleteTarget(target) - - def replace_path(binary, replace_from, replace_to): src = replace_from.encode() ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] bc17361 - [lldb][DWARF] Fix delayed-definition-die-searching.test for Windows
Author: Muhammad Omair Javaid Date: 2024-05-13T16:53:15+05:00 New Revision: bc17361c2baa0351f7f19b716fbe76bc9f99e903 URL: https://github.com/llvm/llvm-project/commit/bc17361c2baa0351f7f19b716fbe76bc9f99e903 DIFF: https://github.com/llvm/llvm-project/commit/bc17361c2baa0351f7f19b716fbe76bc9f99e903.diff LOG: [lldb][DWARF] Fix delayed-definition-die-searching.test for Windows This is follow up fix on top of 9a7262c2601874e5aa64c5db19746770212d4b44 This fixes delayed-definition-die-searching.test to use -gdwarf. This is required to explicitly select DWARF instead of PDB on windows. Fixe LLDB build lldb-aarch64-windows: https://lab.llvm.org/buildbot/#/builders/219/builds/11303 Added: Modified: lldb/test/Shell/SymbolFile/DWARF/delayed-definition-die-searching.test Removed: diff --git a/lldb/test/Shell/SymbolFile/DWARF/delayed-definition-die-searching.test b/lldb/test/Shell/SymbolFile/DWARF/delayed-definition-die-searching.test index a2b36dadedd21..836fcd7b587bc 100644 --- a/lldb/test/Shell/SymbolFile/DWARF/delayed-definition-die-searching.test +++ b/lldb/test/Shell/SymbolFile/DWARF/delayed-definition-die-searching.test @@ -1,7 +1,7 @@ # Test definition DIE searching is delayed until complete type is required. # RUN: split-file %s %t -# RUN: %clangxx_host %t/main.cpp %t/t1_def.cpp -g -o %t.out +# RUN: %clangxx_host %t/main.cpp %t/t1_def.cpp -gdwarf -o %t.out # RUN: %lldb -b %t.out -s %t/lldb.cmd | FileCheck %s # CHECK: (lldb) p v1 @@ -31,4 +31,4 @@ int main() { struct t1 { // this CU contains definition DIE for t1. int x; }; -t1 v2; \ No newline at end of file +t1 v2; ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 0a6103e - Revert "[lldb] Attempt to fix signal-in-leaf-function-aarch64 on darwin"
Author: Muhammad Omair Javaid Date: 2024-05-13T16:05:02+05:00 New Revision: 0a6103eaeb7f22c009f9add87c84780b6f7f293a URL: https://github.com/llvm/llvm-project/commit/0a6103eaeb7f22c009f9add87c84780b6f7f293a DIFF: https://github.com/llvm/llvm-project/commit/0a6103eaeb7f22c009f9add87c84780b6f7f293a.diff LOG: Revert "[lldb] Attempt to fix signal-in-leaf-function-aarch64 on darwin" This reverts commit b903badd73a2467fdd4e363231f2bf9b0704b546. TestInterruptBacktrace was broken on AArch64/Windows as a result of this change. see lldb-aarch64-windows buildbot here: https://lab.llvm.org/buildbot/#/builders/219/builds/11261 Added: Modified: lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test Removed: diff --git a/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c b/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c index fe020affcad0f..9a751330623f4 100644 --- a/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c +++ b/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c @@ -7,7 +7,7 @@ int __attribute__((naked)) signal_generating_add(int a, int b) { "ret"); } -void sigill_handler(int signo) { _exit(0); } +void sigill_handler(int) { _exit(0); } int main() { signal(SIGILL, sigill_handler); diff --git a/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test b/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test index 09f17c174bbfd..0580d0cf734ae 100644 --- a/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test +++ b/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test @@ -4,9 +4,6 @@ # RUN: %clang_host %S/Inputs/signal-in-leaf-function-aarch64.c -o %t # RUN: %lldb -s %s -o exit %t | FileCheck %s -# Convert EXC_BAD_INSTRUCTION to SIGILL on darwin -settings set platform.plugin.darwin.ignored-exceptions EXC_BAD_INSTRUCTION - breakpoint set -n sigill_handler # CHECK: Breakpoint 1: where = {{.*}}`sigill_handler ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [lldb] 4b44502 - Revert "[lldb/aarch64] Fix unwinding when signal interrupts a leaf function (#91321)"
Author: Muhammad Omair Javaid Date: 2024-05-13T16:05:02+05:00 New Revision: 4b44502ac81259630b422e791a82e0252e6478c3 URL: https://github.com/llvm/llvm-project/commit/4b44502ac81259630b422e791a82e0252e6478c3 DIFF: https://github.com/llvm/llvm-project/commit/4b44502ac81259630b422e791a82e0252e6478c3.diff LOG: Revert "[lldb/aarch64] Fix unwinding when signal interrupts a leaf function (#91321)" This reverts commit fd1bd53ba5a06f344698a55578f6a5d79c457e30. TestInterruptBacktrace was broken on AArch64/Windows as a result of this change. See lldb-aarch64-windows buildbot here: https://lab.llvm.org/buildbot/#/builders/219/builds/11261 Added: Modified: lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp lldb/source/Target/RegisterContextUnwind.cpp lldb/unittests/UnwindAssembly/ARM64/TestArm64InstEmulation.cpp Removed: lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test diff --git a/lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp b/lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp index 62ecac3e0831d..6ca4fb052457e 100644 --- a/lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp +++ b/lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp @@ -444,8 +444,6 @@ bool EmulateInstructionARM64::CreateFunctionEntryUnwind( // Our previous Call Frame Address is the stack pointer row->GetCFAValue().SetIsRegisterPlusOffset(gpr_sp_arm64, 0); - row->SetRegisterLocationToSame(gpr_lr_arm64, /*must_replace=*/false); - row->SetRegisterLocationToSame(gpr_fp_arm64, /*must_replace=*/false); unwind_plan.AppendRow(row); unwind_plan.SetSourceName("EmulateInstructionARM64"); diff --git a/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp b/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp index 49edd40544e32..c4a171ec7d01b 100644 --- a/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp +++ b/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp @@ -424,6 +424,8 @@ size_t UnwindAssemblyInstEmulation::WriteMemory( log->PutString(strm.GetString()); } + const bool cant_replace = false; + switch (context.type) { default: case EmulateInstruction::eContextInvalid: @@ -465,7 +467,7 @@ size_t UnwindAssemblyInstEmulation::WriteMemory( m_pushed_regs[reg_num] = addr; const int32_t offset = addr - m_initial_sp; m_curr_row->SetRegisterLocationToAtCFAPlusOffset(reg_num, offset, - /*can_replace=*/true); + cant_replace); m_curr_row_modified = true; } } diff --git a/lldb/source/Target/RegisterContextUnwind.cpp b/lldb/source/Target/RegisterContextUnwind.cpp index e2d712cb72eae..13e101413a477 100644 --- a/lldb/source/Target/RegisterContextUnwind.cpp +++ b/lldb/source/Target/RegisterContextUnwind.cpp @@ -1555,12 +1555,12 @@ RegisterContextUnwind::SavedLocationForRegister( } if (unwindplan_regloc.IsSame()) { -if (!m_all_registers_available && +if (!IsFrameZero() && (regnum.GetAsKind(eRegisterKindGeneric) == LLDB_REGNUM_GENERIC_PC || regnum.GetAsKind(eRegisterKindGeneric) == LLDB_REGNUM_GENERIC_RA)) { UnwindLogMsg("register %s (%d) is marked as 'IsSame' - it is a pc or " - "return address reg on a frame which does not have all " - "registers available -- treat as if we have no information", + "return address reg on a non-zero frame -- treat as if we " + "have no information", regnum.GetName(), regnum.GetAsKind(eRegisterKindLLDB)); return UnwindLLDB::RegisterSearchResult::eRegisterNotFound; } else { diff --git a/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c b/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c deleted file mode 100644 index 9a751330623f4..0 --- a/lldb/test/Shell/Unwind/Inputs/signal-in-leaf-function-aarch64.c +++ /dev/null @@ -1,15 +0,0 @@ -#include -#include - -int __attribute__((naked)) signal_generating_add(int a, int b) { - asm("add w0, w1, w0\n\t" - "udf #0xdead\n\t" - "ret"); -} - -void sigill_handler(int) { _exit(0); } - -int main() { - signal(SIGILL, sigill_handler); - return signal_generating_add(42, 47); -} diff --git a/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test b/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test deleted file mode 100644 index 0580d0cf734ae..0 --- a/lldb/test/Shell/Unwind/signal-in-leaf-function-aarch64.test