[Lldb-commits] [lldb] [lldb] Fixed the TestNetBSDCore test (PR #92285)
Dmitry Vasilyev via lldb-commits
lldb-commits at lists.llvm.org
Wed May 15 10:00:46 PDT 2024
https://github.com/slydiman updated https://github.com/llvm/llvm-project/pull/92285
>From cd181f2b87008ae86c4195a74e9405b8a6e78da2 Mon Sep 17 00:00:00 2001
From: Dmitry Vasilyev <dvassiliev at accesssoftek.com>
Date: Wed, 15 May 2024 19:39:05 +0400
Subject: [PATCH 1/2] [lldb] Fixed the TestNetBSDCore test
TestNetBSDCore.py contains 3 classes with the same test names test_aarch64 and test_amd64. It causes conflicts because the same build dir. Add suffixes to avoid conflicts.
The error message on the Windows host running with `-j 2` is the following:
```
PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: 'E:\\projects\\lldb\\build-lldb\\lldb-test-build.noindex\\functionalities\\postmortem\\netbsd-core\\TestNetBSDCore.test_aarch64\\Incomplete.log'
```
---
.../postmortem/netbsd-core/TestNetBSDCore.py | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py b/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
index 756f4d1e81caa..d56b38eb513e9 100644
--- a/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
+++ b/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
@@ -147,12 +147,12 @@ def check_stack(self, process, pid, filename):
self.check_backtrace(thread, filename, backtrace)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64(self):
+ def test_aarch64_A(self):
"""Test single-threaded aarch64 core dump."""
self.do_test("1lwp_SIGSEGV.aarch64", pid=8339, region_count=32)
@skipIfLLVMTargetMissing("X86")
- def test_amd64(self):
+ def test_amd64_A(self):
"""Test single-threaded amd64 core dump."""
self.do_test("1lwp_SIGSEGV.amd64", pid=693, region_count=21)
@@ -177,12 +177,12 @@ def check_stack(self, process, pid, filename):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), 0)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64(self):
+ def test_aarch64_B(self):
"""Test double-threaded aarch64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.aarch64", pid=14142, region_count=31)
@skipIfLLVMTargetMissing("X86")
- def test_amd64(self):
+ def test_amd64_B(self):
"""Test double-threaded amd64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.amd64", pid=622, region_count=24)
@@ -207,11 +207,11 @@ def check_stack(self, process, pid, filename):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), signal.SIGSEGV)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64(self):
+ def test_aarch64_C(self):
"""Test double-threaded aarch64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.aarch64", pid=1403, region_count=30)
@skipIfLLVMTargetMissing("X86")
- def test_amd64(self):
+ def test_amd64_C(self):
"""Test double-threaded amd64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.amd64", pid=665, region_count=24)
>From 9032144a256cf8ba2838e935dfc3fc79fddff9ce Mon Sep 17 00:00:00 2001
From: Dmitry Vasilyev <dvassiliev at accesssoftek.com>
Date: Wed, 15 May 2024 21:00:30 +0400
Subject: [PATCH 2/2] Renamed to more meaningful names.
---
.../postmortem/netbsd-core/TestNetBSDCore.py | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py b/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
index d56b38eb513e9..ff1ef21e02e31 100644
--- a/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
+++ b/lldb/test/API/functionalities/postmortem/netbsd-core/TestNetBSDCore.py
@@ -147,12 +147,12 @@ def check_stack(self, process, pid, filename):
self.check_backtrace(thread, filename, backtrace)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64_A(self):
+ def test_aarch64_single_threaded(self):
"""Test single-threaded aarch64 core dump."""
self.do_test("1lwp_SIGSEGV.aarch64", pid=8339, region_count=32)
@skipIfLLVMTargetMissing("X86")
- def test_amd64_A(self):
+ def test_amd64_single_threaded(self):
"""Test single-threaded amd64 core dump."""
self.do_test("1lwp_SIGSEGV.amd64", pid=693, region_count=21)
@@ -177,12 +177,12 @@ def check_stack(self, process, pid, filename):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), 0)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64_B(self):
+ def test_aarch64_thread_signaled(self):
"""Test double-threaded aarch64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.aarch64", pid=14142, region_count=31)
@skipIfLLVMTargetMissing("X86")
- def test_amd64_B(self):
+ def test_amd64_thread_signaled(self):
"""Test double-threaded amd64 core dump where thread 2 is signalled."""
self.do_test("2lwp_t2_SIGSEGV.amd64", pid=622, region_count=24)
@@ -207,11 +207,11 @@ def check_stack(self, process, pid, filename):
self.assertEqual(thread.GetStopReasonDataAtIndex(0), signal.SIGSEGV)
@skipIfLLVMTargetMissing("AArch64")
- def test_aarch64_C(self):
+ def test_aarch64_process_signaled(self):
"""Test double-threaded aarch64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.aarch64", pid=1403, region_count=30)
@skipIfLLVMTargetMissing("X86")
- def test_amd64_C(self):
+ def test_amd64_process_signaled(self):
"""Test double-threaded amd64 core dump where process is signalled."""
self.do_test("2lwp_process_SIGSEGV.amd64", pid=665, region_count=24)
More information about the lldb-commits
mailing list