Skip to content

[lldb][test][win][x86_64] XFAIL already failing Shell tests #100476

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

kendalharland
Copy link
Contributor

I'm currently working on getting the LLDB test suites to pass on Windows x86_64 which is not currently included in LLVM CI. These tests are currently failing in this configuration.

See #100474

@llvmbot
Copy link
Member

llvmbot commented Jul 24, 2024

@llvm/pr-subscribers-lldb

Author: Kendal Harland (kendalharland)

Changes

I'm currently working on getting the LLDB test suites to pass on Windows x86_64 which is not currently included in LLVM CI. These tests are currently failing in this configuration.

See #100474


Full diff: https://github.com/llvm/llvm-project/pull/100476.diff

18 Files Affected:

  • (modified) lldb/test/Shell/Driver/TestConvenienceVariables.test (+1)
  • (modified) lldb/test/Shell/Driver/TestSingleQuote.test (+1)
  • (modified) lldb/test/Shell/Recognizer/verbose_trap.test (+4)
  • (modified) lldb/test/Shell/Settings/TestEchoCommands.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/DWARF/x86/dead-code-filtering.yaml (+2)
  • (modified) lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp (+2)
  • (modified) lldb/test/Shell/SymbolFile/NativePDB/stack_unwinding01.cpp (+2)
  • (modified) lldb/test/Shell/SymbolFile/PDB/ast-restore.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/class-layout.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/enums-layout.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/expressions.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/func-symbols.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/pointers.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/type-quals.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/typedefs.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/udt-layout.test (+1)
  • (modified) lldb/test/Shell/SymbolFile/PDB/variables.test (+1)
diff --git a/lldb/test/Shell/Driver/TestConvenienceVariables.test b/lldb/test/Shell/Driver/TestConvenienceVariables.test
index 45dc7673bfc51..32c3d160153fb 100644
--- a/lldb/test/Shell/Driver/TestConvenienceVariables.test
+++ b/lldb/test/Shell/Driver/TestConvenienceVariables.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: python
 RUN: mkdir -p %t
 RUN: %build %p/Inputs/hello.cpp -o %t/target.out
diff --git a/lldb/test/Shell/Driver/TestSingleQuote.test b/lldb/test/Shell/Driver/TestSingleQuote.test
index af321ba04db39..49f6548e0c5b1 100644
--- a/lldb/test/Shell/Driver/TestSingleQuote.test
+++ b/lldb/test/Shell/Driver/TestSingleQuote.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 # Make sure lldb can handle filenames with single quotes in them.
 # RUN: %clang_host %p/Inputs/hello.c -g -o "%t-'pat"
 # RUN: %lldb -s %s "%t-'pat" | FileCheck %s
diff --git a/lldb/test/Shell/Recognizer/verbose_trap.test b/lldb/test/Shell/Recognizer/verbose_trap.test
index dafab7bdea688..76ba87f0f115a 100644
--- a/lldb/test/Shell/Recognizer/verbose_trap.test
+++ b/lldb/test/Shell/Recognizer/verbose_trap.test
@@ -1,4 +1,5 @@
 # UNSUPPORTED: system-windows
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 #
 # RUN: %clang_host -g -O0 %S/Inputs/verbose_trap.cpp -o %t.out -DVERBOSE_TRAP_TEST_CATEGORY=\"Foo\" -DVERBOSE_TRAP_TEST_MESSAGE=\"Bar\"
 # RUN: %lldb -b -s %s %t.out | FileCheck %s --check-prefixes=CHECK,CHECK-BOTH
@@ -12,6 +13,9 @@
 # RUN: %clang_host -g -O0 %S/Inputs/verbose_trap.cpp -o %t.out -DVERBOSE_TRAP_TEST_CATEGORY=\"\" -DVERBOSE_TRAP_TEST_MESSAGE=\"\"
 # RUN: %lldb -b -s %s %t.out | FileCheck %s --check-prefixes=CHECK,CHECK-NONE
 
+# RUN: %clang_host -g -O0 %S/Inputs/verbose_trap.cpp -o %t.out
+# RUN: %lldb -b -s %s %t.out | FileCheck %s
+
 run
 # CHECK-BOTH:          thread #{{.*}}stop reason = Foo: Bar
 # CHECK-MESSAGE_ONLY:  thread #{{.*}}stop reason = <empty category>: Bar
diff --git a/lldb/test/Shell/Settings/TestEchoCommands.test b/lldb/test/Shell/Settings/TestEchoCommands.test
index 234b9742bfa2a..02f50d7b21ba5 100644
--- a/lldb/test/Shell/Settings/TestEchoCommands.test
+++ b/lldb/test/Shell/Settings/TestEchoCommands.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 # RUN: %lldb -x -b -o 'settings set interpreter.echo-comment-commands true'  -s %S/Inputs/EchoCommandsTest.in | FileCheck %S/Inputs/EchoCommandsAll.out
 # RUN: %lldb -x -b -o 'settings set interpreter.echo-comment-commands false' -s %S/Inputs/EchoCommandsTest.in | FileCheck %S/Inputs/EchoCommandsNoComments.out
 # RUN: %lldb -x -b -o 'settings set interpreter.echo-commands false'         -s %S/Inputs/EchoCommandsTest.in | FileCheck %S/Inputs/EchoCommandsNone.out
diff --git a/lldb/test/Shell/SymbolFile/DWARF/x86/dead-code-filtering.yaml b/lldb/test/Shell/SymbolFile/DWARF/x86/dead-code-filtering.yaml
index 9ac922ef3159c..84175041ea1da 100644
--- a/lldb/test/Shell/SymbolFile/DWARF/x86/dead-code-filtering.yaml
+++ b/lldb/test/Shell/SymbolFile/DWARF/x86/dead-code-filtering.yaml
@@ -1,3 +1,5 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
+
 # RUN: yaml2obj %s > %t
 # RUN: lldb-test symbols %t | FileCheck %s --check-prefix=TEST
 # RUN: %lldb %t -o "image dump line-table a.c" -o "image lookup -n _start" -o "image lookup -n f" -o exit | FileCheck %s
diff --git a/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp b/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp
index 9aa25adf6bcc7..3e767230e04db 100644
--- a/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp
+++ b/lldb/test/Shell/SymbolFile/NativePDB/local-variables.cpp
@@ -1,5 +1,7 @@
 // clang-format off
 
+// XFAIL: target=x86_64-{{.*}}-windows{{.*}}
+
 // REQUIRES: system-windows
 // RUN: %build -o %t.exe -- %s
 // RUN: env LLDB_USE_NATIVE_PDB_READER=1 %lldb -f %t.exe -s \
diff --git a/lldb/test/Shell/SymbolFile/NativePDB/stack_unwinding01.cpp b/lldb/test/Shell/SymbolFile/NativePDB/stack_unwinding01.cpp
index e96e3ed6a0107..c0bbf68d66146 100644
--- a/lldb/test/Shell/SymbolFile/NativePDB/stack_unwinding01.cpp
+++ b/lldb/test/Shell/SymbolFile/NativePDB/stack_unwinding01.cpp
@@ -1,6 +1,8 @@
 // clang-format off
 // REQUIRES: lld, system-windows
 
+// XFAIL: target=x86_64-{{.*}}-windows{{.*}}
+
 // RUN: %build --compiler=clang-cl --nodefaultlib -o %t.exe -- %s
 // RUN: env LLDB_USE_NATIVE_PDB_READER=1 %lldb -f %t.exe -s \
 // RUN:     %p/Inputs/stack_unwinding01.lldbinit 2>&1 | FileCheck %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/ast-restore.test b/lldb/test/Shell/SymbolFile/PDB/ast-restore.test
index 2763f46070244..cfb270c3013f5 100644
--- a/lldb/test/Shell/SymbolFile/PDB/ast-restore.test
+++ b/lldb/test/Shell/SymbolFile/PDB/ast-restore.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=msvc --nodefaultlib --output=%t.exe %S/Inputs/AstRestoreTest.cpp
 RUN: env LLDB_USE_NATIVE_PDB_READER=0 lldb-test symbols -dump-ast %t.exe | FileCheck --check-prefix=ENUM %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test
index 065c8b69b06dd..e01774adb410e 100644
--- a/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test
+++ b/lldb/test/Shell/SymbolFile/PDB/calling-conventions-x86.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 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
diff --git a/lldb/test/Shell/SymbolFile/PDB/class-layout.test b/lldb/test/Shell/SymbolFile/PDB/class-layout.test
index c99a180f4f632..0156126c98a9a 100644
--- a/lldb/test/Shell/SymbolFile/PDB/class-layout.test
+++ b/lldb/test/Shell/SymbolFile/PDB/class-layout.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=clang-cl --mode=compile --arch=32 --nodefaultlib --output=%T/ClassLayoutTest.cpp.obj %S/Inputs/ClassLayoutTest.cpp
 RUN: %build --compiler=msvc --mode=link --arch=32 --nodefaultlib --output=%T/ClassLayoutTest.cpp.exe %T/ClassLayoutTest.cpp.obj
diff --git a/lldb/test/Shell/SymbolFile/PDB/enums-layout.test b/lldb/test/Shell/SymbolFile/PDB/enums-layout.test
index ad7d1549e3620..cf7e9d8b5df7a 100644
--- a/lldb/test/Shell/SymbolFile/PDB/enums-layout.test
+++ b/lldb/test/Shell/SymbolFile/PDB/enums-layout.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=msvc --arch=32 --nodefaultlib --output=%T/SimpleTypesTest.cpp.enums.exe %S/Inputs/SimpleTypesTest.cpp
 RUN: lldb-test symbols %T/SimpleTypesTest.cpp.enums.exe | FileCheck --check-prefix=ENUM %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/expressions.test b/lldb/test/Shell/SymbolFile/PDB/expressions.test
index 89d7c94e7aa06..55bdc323d1316 100644
--- a/lldb/test/Shell/SymbolFile/PDB/expressions.test
+++ b/lldb/test/Shell/SymbolFile/PDB/expressions.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=msvc --nodefaultlib --output=%t.exe %S/Inputs/ExpressionsTest.cpp
 RUN: not %lldb -b -s %S/Inputs/ExpressionsTest0.script -s %S/Inputs/ExpressionsTest1.script -s %S/Inputs/ExpressionsTest2.script -- %t.exe 2>&1 | FileCheck %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/func-symbols.test b/lldb/test/Shell/SymbolFile/PDB/func-symbols.test
index 5990952938e67..571d14f60535d 100644
--- a/lldb/test/Shell/SymbolFile/PDB/func-symbols.test
+++ b/lldb/test/Shell/SymbolFile/PDB/func-symbols.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, lld
 RUN: %build --compiler=clang-cl --arch=32 --nodefaultlib --output=%T/FuncSymbolsTest.exe %S/Inputs/FuncSymbolsTestMain.cpp %S/Inputs/FuncSymbols.cpp
 RUN: lldb-test symbols %T/FuncSymbolsTest.exe | FileCheck --check-prefix=CHECK-ONE %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/pointers.test b/lldb/test/Shell/SymbolFile/PDB/pointers.test
index a3e6f557fed6f..848d7509e5e41 100644
--- a/lldb/test/Shell/SymbolFile/PDB/pointers.test
+++ b/lldb/test/Shell/SymbolFile/PDB/pointers.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=clang-cl --mode=compile --arch=32 --nodefaultlib --output=%T/PointerTypeTest.cpp.obj %S/Inputs/PointerTypeTest.cpp
 RUN: %build --compiler=msvc --mode=link --arch=32 --nodefaultlib --output=%T/PointerTypeTest.cpp.exe %T/PointerTypeTest.cpp.obj
diff --git a/lldb/test/Shell/SymbolFile/PDB/type-quals.test b/lldb/test/Shell/SymbolFile/PDB/type-quals.test
index cf65c79223b23..cc53fc2e3db98 100644
--- a/lldb/test/Shell/SymbolFile/PDB/type-quals.test
+++ b/lldb/test/Shell/SymbolFile/PDB/type-quals.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=clang-cl --mode=compile --arch=32 --nodefaultlib --output=%T/TypeQualsTest.cpp.obj %S/Inputs/TypeQualsTest.cpp
 RUN: %build --compiler=msvc --mode=link --arch=32 --nodefaultlib --output=%T/TypeQualsTest.cpp.exe %T/TypeQualsTest.cpp.obj
diff --git a/lldb/test/Shell/SymbolFile/PDB/typedefs.test b/lldb/test/Shell/SymbolFile/PDB/typedefs.test
index ebbcc4b9ab11b..5a966d80b9117 100644
--- a/lldb/test/Shell/SymbolFile/PDB/typedefs.test
+++ b/lldb/test/Shell/SymbolFile/PDB/typedefs.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=msvc --arch=32 --nodefaultlib --output=%T/SimpleTypesTest.cpp.typedefs.exe %S/Inputs/SimpleTypesTest.cpp
 RUN: lldb-test symbols %T/SimpleTypesTest.cpp.typedefs.exe | FileCheck %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/udt-layout.test b/lldb/test/Shell/SymbolFile/PDB/udt-layout.test
index 84414cbf8440d..4a6610b4abbac 100644
--- a/lldb/test/Shell/SymbolFile/PDB/udt-layout.test
+++ b/lldb/test/Shell/SymbolFile/PDB/udt-layout.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, lld
 RUN: %build --compiler=clang-cl --output=%t.exe %S/Inputs/UdtLayoutTest.cpp
 RUN: %lldb -b -s %S/Inputs/UdtLayoutTest.script -- %t.exe | FileCheck %s
diff --git a/lldb/test/Shell/SymbolFile/PDB/variables.test b/lldb/test/Shell/SymbolFile/PDB/variables.test
index 0043ebb917160..862c52242daf1 100644
--- a/lldb/test/Shell/SymbolFile/PDB/variables.test
+++ b/lldb/test/Shell/SymbolFile/PDB/variables.test
@@ -1,3 +1,4 @@
+# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
 REQUIRES: system-windows, msvc
 RUN: %build --compiler=clang-cl --mode=compile --arch=64 --nodefaultlib --output=%T/VariablesTest.cpp.obj %S/Inputs/VariablesTest.cpp
 RUN: %build --compiler=msvc --mode=link --arch=64 --nodefaultlib --output=%T/VariablesTest.cpp.exe %T/VariablesTest.cpp.obj

@kendalharland kendalharland force-pushed the swiftlang/kendal/xfail-failing-lldb-shell-tests branch from f293bea to fc88c4a Compare July 24, 2024 22:49
@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JDevlieghere please LMK if the target triple can be expressed more clearly as a combination of other filters in .test files, here and throughout.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

something like system-windows && target-x86_64 ought to do it. However, like I said in the other review, I think we ought to figure out why are these failing for you.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interestingly, this test is green on our Windows native CI. It uses cmd.exe. Here's the log:

********************
PASS: lldb-shell :: Driver/TestConvenienceVariables.test (88 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 2
mkdir -p C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp
# executed command: mkdir -p 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp'
# note: command had no output on stdout or stderr
# RUN: at line 3
'C:\Python312\python.exe' C:\lldb\test\Shell\helper\build.py --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib C:\lldb\test\Shell\Driver/Inputs/hello.cpp -o C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out
# executed command: 'C:\Python312\python.exe' 'C:\lldb\test\Shell\helper\build.py' --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib 'C:\lldb\test\Shell\Driver/Inputs/hello.cpp' -o 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out'
# .---command stdout------------
# | Cleaning hello.ilk
# | Cleaning target.out-hello.obj
# | Cleaning target.pdb
# | Cleaning target.out
# | 
# | 
# | 
# | compiling hello.cpp -> target.out-hello.obj
# |   STDOUT:
# | 
# | 
# | 
# | 
# | linking target.out-hello.obj -> target.out
# |   STDOUT:
# | 
# `-----------------------------
# RUN: at line 4
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out -s C:\lldb\test\Shell\Driver/Inputs/convenience.in -o quit | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Driver\TestConvenienceVariables.test
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out' -s 'C:\lldb\test\Shell\Driver/Inputs/convenience.in' -o quit
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Driver\TestConvenienceVariables.test'
# note: command had no output on stdout or stderr

--

However, I'm unsure if the quotes are printed in log the same way they are passed to cmd.

Copy link
Contributor Author

@kendalharland kendalharland Jul 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dzhidzhoev would you be able to share the CMake configuration your Windows native CI is using? I'm having trouble spotting what's wrong with my local build.

Copy link
Contributor Author

@kendalharland kendalharland Jul 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For reference, my current setup steps are the following commands run in a non-admin cmd.exe

"C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\Tools\VsDevCmd.bat" -host_arch=amd64 -arch=amd64
"C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\Tools\VsDevCmd.bat" -test

set LLDB_USE_LLDB_SERVER=1
set MSVC_INSTALL_DIR=C:\Program Files\Microsoft Visual Studio\2022\Community
set "PATH=%MSVC_INSTALL_DIR%\DIA SDK\bin\amd64;%PATH%"
set "PATH=%MSVC_INSTALL_DIR%\VC\Tools\Llvm\x64\bin;%PATH%"

cmake -G Ninja ^
      -S llvm ^
      -B build ^
      -D Python3_EXECUTABLE="C:\Program Files\Python312\python.exe" ^
      -D CMAKE_C_COMPILER="C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\Llvm\x64\bin\clang-cl.exe" ^
      -D CMAKE_CXX_COMPILER="C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\Llvm\x64\bin\clang-cl.exe" ^
      -D CMAKE_C_COMPILER_LAUNCHER=ccache ^
      -D CMAKE_CXX_COMPILER_LAUNCHER=ccache ^
      -D CMAKE_BUILD_TYPE="Release" ^
      -D CMAKE_LINKER="C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\Llvm\x64\bin\lld-link.exe" ^
      -D LLVM_ENABLE_PROJECTS="clang;lldb;lld" ^
      -D LLVM_HOST_TRIPLE="x86_64-unknown-windows-msvc" ^
      -D LLVM_ENABLE_LLD="YES" ^
      -D LLVM_ENABLE_LIBEDIT="NO" ^
      -D LLVM_ENABLE_DIA_SDK="OFF" ^
      -D LLDB_ENABLE_PYTHON=1 ^
      -D LLDB_PYTHON_EXE_RELATIVE_PATH="python.exe" ^
      -D LLDB_TEST_USER_ARGS=--skip-category=watchpoint ^
      -D LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS=1 ^
      -D CMAKE_CXX_STANDARD=14

ninja -C build check-lldb

Copy link
Contributor Author

@kendalharland kendalharland Jul 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Locally, i've removed CMAKE_CXX_STANDARD=14 above as it is leftover from debugging and not correct or necessary.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dzhidzhoev would you be able to share the CMake configuration your Windows native CI is using? I'm having trouble spotting what's wrong with my local build.

For sure! Sorry, I needed some time to sort it out, because I hadn't reproduced it on my local machine before, only had it in CI.

cmake -DLLVM_LIT_ARGS="-v -vv --threads=8 --xunit-xml-output=xunit-report.xml" ^
  -G Ninja -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache ^
  -DCMAKE_INSTALL_PREFIX=native -DCMAKE_BUILD_TYPE=Release ^
  -DLLVM_ENABLE_PROJECTS=lldb;llvm;clang;lld -DLLVM_ENABLE_ASSERTIONS=ON ^
  -DMake_EXECUTABLE=c:/bin/make-wfix.exe ^
  -DLLDB_TEST_USER_ARGS=--skip-category=watchpoint ^
  -DLLDB_ENFORCE_STRICT_TEST_REQUIREMENTS=ON ^
 c:/lldb-test-scripts/llvm

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LLVM_ENABLE_DIA_SDK="OFF" Seems to have been the culprit for me. After removing this and using the default "ON" all of the Shell tests I was previously seeing fail are now passing for me. Thanks so much for your help in debugging!

@@ -1,4 +1,5 @@
# UNSUPPORTED: system-windows
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be necessary given the UNSUPPORTED clause above.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And this test I'm pretty sure is only failing due to cmd line syntax issues, but no confirmation yet.

@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

something like system-windows && target-x86_64 ought to do it. However, like I said in the other review, I think we ought to figure out why are these failing for you.

@@ -1,3 +1,5 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is particularly concerning, given that this test just operates on static binary data (expressed in yaml form). There should be nothing target-specific here.

Maybe we could start by looking at what's making this test in particular fail?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have it green as well

********************
PASS: lldb-shell :: SymbolFile/DWARF/x86/dead-code-filtering.yaml (389 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 1
c:\build-lldb-native\bin\yaml2obj.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml > C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp
# executed command: 'c:\build-lldb-native\bin\yaml2obj.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml'
# note: command had no output on stdout or stderr
# RUN: at line 2
c:\build-lldb-native\bin\lldb-test.exe symbols C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml --check-prefix=TEST
# executed command: 'c:\build-lldb-native\bin\lldb-test.exe' symbols 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml' --check-prefix=TEST
# note: command had no output on stdout or stderr
# RUN: at line 3
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp -o "image dump line-table a.c" -o "image lookup -n _start" -o "image lookup -n f" -o exit | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp' -o 'image dump line-table a.c' -o 'image lookup -n _start' -o 'image lookup -n f' -o exit
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml'
# note: command had no output on stdout or stderr

--


@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
# Make sure lldb can handle filenames with single quotes in them.
# RUN: %clang_host %p/Inputs/hello.c -g -o "%t-'pat"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And this looks like you may have a different shell (one that handles quotes differently) from the other windows devs/bots. Maybe we can figure out an invocation that works with both? @DavidSpickett

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same as for TestConvenienceVariables.test:

PASS: lldb-shell :: Driver/TestSingleQuote.test (75 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 2
c:\build-lldb-native\bin\clang.exe --target=specify-a-target-or-use-a-_host-substitution --target=x86_64-pc-windows-msvc -fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell C:\lldb\test\Shell\Driver/Inputs/hello.c -g -o "C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'pat"
# executed command: 'c:\build-lldb-native\bin\clang.exe' --target=specify-a-target-or-use-a-_host-substitution --target=x86_64-pc-windows-msvc '-fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell' 'C:\lldb\test\Shell\Driver/Inputs/hello.c' -g -o 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'"'"'pat'
# .---command stderr------------
# | clang: warning: argument unused during compilation: '-fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell' [-Wunused-command-line-argument]
# `-----------------------------
# RUN: at line 3
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -s C:\lldb\test\Shell\Driver\TestSingleQuote.test "C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'pat" | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Driver\TestSingleQuote.test
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -s 'C:\lldb\test\Shell\Driver\TestSingleQuote.test' 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'"'"'pat'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Driver\TestSingleQuote.test'
# note: command had no output on stdout or stderr

--

@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
# Make sure lldb can handle filenames with single quotes in them.
# RUN: %clang_host %p/Inputs/hello.c -g -o "%t-'pat"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same as for TestConvenienceVariables.test:

PASS: lldb-shell :: Driver/TestSingleQuote.test (75 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 2
c:\build-lldb-native\bin\clang.exe --target=specify-a-target-or-use-a-_host-substitution --target=x86_64-pc-windows-msvc -fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell C:\lldb\test\Shell\Driver/Inputs/hello.c -g -o "C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'pat"
# executed command: 'c:\build-lldb-native\bin\clang.exe' --target=specify-a-target-or-use-a-_host-substitution --target=x86_64-pc-windows-msvc '-fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell' 'C:\lldb\test\Shell\Driver/Inputs/hello.c' -g -o 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'"'"'pat'
# .---command stderr------------
# | clang: warning: argument unused during compilation: '-fmodules-cache-path=C:/build-lldb-native/lldb-test-build.noindex/module-cache-clang\lldb-shell' [-Wunused-command-line-argument]
# `-----------------------------
# RUN: at line 3
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -s C:\lldb\test\Shell\Driver\TestSingleQuote.test "C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'pat" | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Driver\TestSingleQuote.test
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -s 'C:\lldb\test\Shell\Driver\TestSingleQuote.test' 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestSingleQuote.test.tmp-'"'"'pat'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Driver\TestSingleQuote.test'
# note: command had no output on stdout or stderr

--

@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interestingly, this test is green on our Windows native CI. It uses cmd.exe. Here's the log:

********************
PASS: lldb-shell :: Driver/TestConvenienceVariables.test (88 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 2
mkdir -p C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp
# executed command: mkdir -p 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp'
# note: command had no output on stdout or stderr
# RUN: at line 3
'C:\Python312\python.exe' C:\lldb\test\Shell\helper\build.py --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib C:\lldb\test\Shell\Driver/Inputs/hello.cpp -o C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out
# executed command: 'C:\Python312\python.exe' 'C:\lldb\test\Shell\helper\build.py' --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib 'C:\lldb\test\Shell\Driver/Inputs/hello.cpp' -o 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out'
# .---command stdout------------
# | Cleaning hello.ilk
# | Cleaning target.out-hello.obj
# | Cleaning target.pdb
# | Cleaning target.out
# | 
# | 
# | 
# | compiling hello.cpp -> target.out-hello.obj
# |   STDOUT:
# | 
# | 
# | 
# | 
# | linking target.out-hello.obj -> target.out
# |   STDOUT:
# | 
# `-----------------------------
# RUN: at line 4
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out -s C:\lldb\test\Shell\Driver/Inputs/convenience.in -o quit | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Driver\TestConvenienceVariables.test
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' 'C:\build-lldb-native\tools\lldb\test\Shell\Driver\Output\TestConvenienceVariables.test.tmp/target.out' -s 'C:\lldb\test\Shell\Driver/Inputs/convenience.in' -o quit
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Driver\TestConvenienceVariables.test'
# note: command had no output on stdout or stderr

--

However, I'm unsure if the quotes are printed in log the same way they are passed to cmd.

@@ -1,3 +1,5 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have it green as well

********************
PASS: lldb-shell :: SymbolFile/DWARF/x86/dead-code-filtering.yaml (389 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 1
c:\build-lldb-native\bin\yaml2obj.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml > C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp
# executed command: 'c:\build-lldb-native\bin\yaml2obj.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml'
# note: command had no output on stdout or stderr
# RUN: at line 2
c:\build-lldb-native\bin\lldb-test.exe symbols C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml --check-prefix=TEST
# executed command: 'c:\build-lldb-native\bin\lldb-test.exe' symbols 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml' --check-prefix=TEST
# note: command had no output on stdout or stderr
# RUN: at line 3
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp -o "image dump line-table a.c" -o "image lookup -n _start" -o "image lookup -n f" -o exit | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\DWARF\x86\Output\dead-code-filtering.yaml.tmp' -o 'image dump line-table a.c' -o 'image lookup -n _start' -o 'image lookup -n f' -o exit
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\SymbolFile\DWARF\x86\dead-code-filtering.yaml'
# note: command had no output on stdout or stderr

--


@@ -1,3 +1,4 @@
# XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

********************
PASS: lldb-shell :: Settings/TestEchoCommands.test (315 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 1
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -x -b -o 'settings set interpreter.echo-comment-commands true'  -s C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Settings/Inputs/EchoCommandsAll.out
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -x -b -o 'settings set interpreter.echo-comment-commands true' -s 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsAll.out'
# note: command had no output on stdout or stderr
# RUN: at line 2
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -x -b -o 'settings set interpreter.echo-comment-commands false' -s C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Settings/Inputs/EchoCommandsNoComments.out
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -x -b -o 'settings set interpreter.echo-comment-commands false' -s 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsNoComments.out'
# note: command had no output on stdout or stderr
# RUN: at line 3
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -x -b -o 'settings set interpreter.echo-commands false'         -s C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\Settings/Inputs/EchoCommandsNone.out
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -x -b -o 'settings set interpreter.echo-commands false' -s 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsNone.out'
# note: command had no output on stdout or stderr
# RUN: at line 7
echo start >C:\build-lldb-native\tools\lldb\test\Shell\Settings\Output\TestEchoCommands.test.tmp.file
# executed command: echo start
# note: command had no output on stdout or stderr
# RUN: at line 8
c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -x -b --source-quietly -s C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in >>C:\build-lldb-native\tools\lldb\test\Shell\Settings\Output\TestEchoCommands.test.tmp.file
# executed command: 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -x -b --source-quietly -s 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsTest.in'
# note: command had no output on stdout or stderr
# RUN: at line 9
echo done >>C:\build-lldb-native\tools\lldb\test\Shell\Settings\Output\TestEchoCommands.test.tmp.file
# executed command: echo done
# note: command had no output on stdout or stderr
# RUN: at line 10
c:\build-lldb-native\bin\filecheck.exe  C:\lldb\test\Shell\Settings/Inputs/EchoCommandsQuiet.out <C:\build-lldb-native\tools\lldb\test\Shell\Settings\Output\TestEchoCommands.test.tmp.file
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\Settings/Inputs/EchoCommandsQuiet.out'
# note: command had no output on stdout or stderr

--

@@ -1,5 +1,7 @@
// clang-format off

// XFAIL: target=x86_64-{{.*}}-windows{{.*}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As far as I understand, NativePDB tests only run for Windows host+Windows target, contrary to the tests from the PDB folder which we managed to run on Linux target as part of our effort here https://discourse.llvm.org/t/rfc-lldb-support-remote-run-of-shell-tests/80072/10.
It's surprising that they didn't pass with your config

PASS: lldb-shell :: SymbolFile/NativePDB/stack_unwinding01.cpp (533 of 543)
Exit Code: 0

Command Output (stdout):
--
# RUN: at line 4
'C:\Python312\python.exe' C:\lldb\test\Shell\helper\build.py --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib --compiler=clang-cl --nodefaultlib -o C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\NativePDB\Output\stack_unwinding01.cpp.tmp.exe -- C:\lldb\test\Shell\SymbolFile\NativePDB\stack_unwinding01.cpp
# executed command: 'C:\Python312\python.exe' 'C:\lldb\test\Shell\helper\build.py' --compiler=any --arch=64 --tools-dir=C:/build-lldb-native/./bin --libs-dir=C:/build-lldb-native/./lib --compiler=clang-cl --nodefaultlib -o 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\NativePDB\Output\stack_unwinding01.cpp.tmp.exe' -- 'C:\lldb\test\Shell\SymbolFile\NativePDB\stack_unwinding01.cpp'
# .---command stdout------------
# | Cleaning stack_unwinding01.ilk
# | Cleaning stack_unwinding01.cpp.tmp.exe-stack_unwinding01.obj
# | Cleaning stack_unwinding01.cpp.tmp.pdb
# | Cleaning stack_unwinding01.cpp.tmp.exe
# | 
# | 
# | 
# | compiling stack_unwinding01.cpp -> stack_unwinding01.cpp.tmp.exe-stack_unwinding01.obj
# |   STDOUT:
# | 
# | 
# | 
# | 
# | linking stack_unwinding01.cpp.tmp.exe-stack_unwinding01.obj -> stack_unwinding01.cpp.tmp.exe
# |   STDOUT:
# | 
# `-----------------------------
# RUN: at line 5
env LLDB_USE_NATIVE_PDB_READER=1 c:\build-lldb-native\bin\lldb.exe --no-lldbinit -S C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet -f C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\NativePDB\Output\stack_unwinding01.cpp.tmp.exe -s      C:\lldb\test\Shell\SymbolFile\NativePDB/Inputs/stack_unwinding01.lldbinit 2>&1 | c:\build-lldb-native\bin\filecheck.exe C:\lldb\test\Shell\SymbolFile\NativePDB\stack_unwinding01.cpp
# executed command: env LLDB_USE_NATIVE_PDB_READER=1 'c:\build-lldb-native\bin\lldb.exe' --no-lldbinit -S 'C:/build-lldb-native/tools/lldb\test\Shell\lit-lldb-init-quiet' -f 'C:\build-lldb-native\tools\lldb\test\Shell\SymbolFile\NativePDB\Output\stack_unwinding01.cpp.tmp.exe' -s 'C:\lldb\test\Shell\SymbolFile\NativePDB/Inputs/stack_unwinding01.lldbinit'
# note: command had no output on stdout or stderr
# executed command: 'c:\build-lldb-native\bin\filecheck.exe' 'C:\lldb\test\Shell\SymbolFile\NativePDB\stack_unwinding01.cpp'
# note: command had no output on stdout or stderr


@kendalharland
Copy link
Contributor Author

See previous comments: My local CMake configuration contained LLVM_ENABLE_DIA_SDK="ON" which was causing all of these tests to fail. This PR is no longer necessary.

@labath
Copy link
Collaborator

labath commented Aug 5, 2024

One of the problems here is that we actually have two implementations of pdb readers in lldb (SymbolFilePDB, and SymbolFileNativePDB). PDB is the default (kind of -- if you are on windows, and cmake manages to find the DIA SDK), while the majority of users (my non-scientific sample consists of the two of you plus the chromium team (cc @ZequanWu)) appear to use/prefer the NativePDB implementation. Maybe it would be a good idea to switch the default to use NativePDB, or even consider deleting the PDB implementation entirely?

@kendalharland kendalharland deleted the swiftlang/kendal/xfail-failing-lldb-shell-tests branch August 15, 2024 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants