r205271 - Fix up compression related test cases

David Blaikie dblaikie at gmail.com
Mon Mar 31 17:27:29 PDT 2014


Author: dblaikie
Date: Mon Mar 31 19:27:28 2014
New Revision: 205271

URL: http://llvm.org/viewvc/llvm-project?rev=205271&view=rev
Log:
Fix up compression related test cases

Fallout from r205261, ensure it doesn't matter how we disable compressed
debug info, even if zlib is missing and that we warn when we don't have
zlib and don't warn when we do, all while silently suppressing these
tests on the systems they weren't intended for...

Added:
    cfe/trunk/test/Driver/nozlibcompress.c
Modified:
    cfe/trunk/test/Driver/compress.c
    cfe/trunk/test/Driver/integrated-as.s

Modified: cfe/trunk/test/Driver/compress.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/compress.c?rev=205271&r1=205270&r2=205271&view=diff
==============================================================================
--- cfe/trunk/test/Driver/compress.c (original)
+++ cfe/trunk/test/Driver/compress.c Mon Mar 31 19:27:28 2014
@@ -1,4 +1,8 @@
-// RUN: %clang -c %s -Wa,--compress-debug-sections 2>&1 | FileCheck %s
-// REQUIRES: nozlib
+// RUN: %clang -### -c -integrated-as -Wa,-compress-debug-sections %s 2>&1 | FileCheck --check-prefix=COMPRESS_DEBUG %s
+// RUN: %clang -### -c -integrated-as -Wa,--compress-debug-sections %s 2>&1 | FileCheck --check-prefix=COMPRESS_DEBUG %s
+// REQUIRES: zlib
 
-// CHECK: warning: cannot compress debug sections (zlib not installed)
+// COMPRESS_DEBUG: "-compress-debug-sections"
+
+// RUN: %clang -### -c -integrated-as -Wa,--compress-debug-sections -Wa,--nocompress-debug-sections %s 2>&1 | FileCheck --check-prefix=NOCOMPRESS_DEBUG %s
+// NOCOMPRESS_DEBUG-NOT: "-compress-debug-sections"

Modified: cfe/trunk/test/Driver/integrated-as.s
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/integrated-as.s?rev=205271&r1=205270&r2=205271&view=diff
==============================================================================
--- cfe/trunk/test/Driver/integrated-as.s (original)
+++ cfe/trunk/test/Driver/integrated-as.s Mon Mar 31 19:27:28 2014
@@ -29,9 +29,3 @@
 // XA_INCLUDE2: cc1as
 // XA_INCLUDE2: "-Ifoo_dir"
 
-// RUN: %clang -### -c -integrated-as -Wa,-compress-debug-sections %s 2>&1 | FileCheck --check-prefix=COMPRESS_DEBUG %s
-// RUN: %clang -### -c -integrated-as -Wa,--compress-debug-sections %s 2>&1 | FileCheck --check-prefix=COMPRESS_DEBUG %s
-// COMPRESS_DEBUG: "-compress-debug-sections"
-
-// RUN: %clang -### -c -integrated-as -Wa,-compress-debug-sections -Wa,-nocompress-debug-sections %s 2>&1 | FileCheck --check-prefix=NOCOMPRESS_DEBUG %s
-// NOCOMPRESS_DEBUG-NOT: "-compress-debug-sections"

Added: cfe/trunk/test/Driver/nozlibcompress.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/nozlibcompress.c?rev=205271&view=auto
==============================================================================
--- cfe/trunk/test/Driver/nozlibcompress.c (added)
+++ cfe/trunk/test/Driver/nozlibcompress.c Mon Mar 31 19:27:28 2014
@@ -0,0 +1,6 @@
+// RUN: %clang -c %s -Wa,--compress-debug-sections 2>&1 | FileCheck %s
+// RUN: %clang -c %s -Wa,--compress-debug-sections -Wa,--nocompress-debug-sections 2>&1 | FileCheck --check-prefix=NOWARN %s
+// REQUIRES: nozlib
+
+// CHECK: warning: cannot compress debug sections (zlib not installed)
+// NOWARN-NOT: warning: cannot compress debug sections (zlib not installed)





More information about the cfe-commits mailing list