Skip to content
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

[ASan][test] XFAIL global-overflow.cpp etc. on SPARC #108200

Merged

Conversation

rorth
Copy link
Collaborator

@rorth rorth commented Sep 11, 2024

When enabling ASan testing on SPARC as per PR #107405, two tests FAIL in similar ways as detailed in Issue #108194: at -O1 and above, one line of the stacktrace lacks the line number info, causing the tests to FAIL. I could trace this to clang generating incomplete line number info; g++ gets this right.

To avoid this, this patch XFAILs the affected tests on SPARC.

Tested on sparcv9-sun-solaris2.11.

When enabling ASan testing on SPARC as per PR llvm#107405, two tests `FAIL` in
similar ways as detailed in Issue llvm#108194: at `-O1` and above, one line of
the stacktrace lacks the line number info, causing the tests to `FAIL`.  I
could trace this to `clang` generating incomplete line number info; `g++`
gets this right.

To avoid this, this patch `XFAIL`s the affected tests on SPARC.

Tested on `sparcv9-sun-solaris2.11`.
@llvmbot
Copy link
Member

llvmbot commented Sep 11, 2024

@llvm/pr-subscribers-compiler-rt-sanitizer

Author: Rainer Orth (rorth)

Changes

When enabling ASan testing on SPARC as per PR #107405, two tests FAIL in similar ways as detailed in Issue #108194: at -O1 and above, one line of the stacktrace lacks the line number info, causing the tests to FAIL. I could trace this to clang generating incomplete line number info; g++ gets this right.

To avoid this, this patch XFAILs the affected tests on SPARC.

Tested on sparcv9-sun-solaris2.11.


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

2 Files Affected:

  • (modified) compiler-rt/test/asan/TestCases/global-overflow.cpp (+3)
  • (modified) compiler-rt/test/asan/TestCases/large_func_test.cpp (+3)
diff --git a/compiler-rt/test/asan/TestCases/global-overflow.cpp b/compiler-rt/test/asan/TestCases/global-overflow.cpp
index df44d676585724..ed276ca44aa26c 100644
--- a/compiler-rt/test/asan/TestCases/global-overflow.cpp
+++ b/compiler-rt/test/asan/TestCases/global-overflow.cpp
@@ -3,6 +3,9 @@
 // RUN: %clangxx_asan -O2 %s -o %t && not %run %t 2>&1 | FileCheck %s
 // RUN: %clangxx_asan -O3 %s -o %t && not %run %t 2>&1 | FileCheck %s
 
+// Issue #108194: Incomplete .debug_line at -O1 and above.
+// XFAIL: target={{.*sparc.*}}
+
 #include <string.h>
 int main(int argc, char **argv) {
   static char XXX[10];
diff --git a/compiler-rt/test/asan/TestCases/large_func_test.cpp b/compiler-rt/test/asan/TestCases/large_func_test.cpp
index 37fec8bef6ce81..c64fc7d3c7aa74 100644
--- a/compiler-rt/test/asan/TestCases/large_func_test.cpp
+++ b/compiler-rt/test/asan/TestCases/large_func_test.cpp
@@ -4,6 +4,9 @@
 // RUN: %clangxx_asan -O3 %s -o %t && not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-%os --check-prefix=CHECK
 // REQUIRES: stable-runtime
 
+// Issue #108194: Incomplete .debug_line at -O1 and above.
+// XFAIL: target={{.*sparc.*}}
+
 #include <stdlib.h>
 __attribute__((noinline))
 static void LargeFunction(int *x, int zero) {

@rorth rorth merged commit 961bc37 into llvm:main Sep 16, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants