diff mbox

add check_effective_target_masm_intel

Message ID 20121026191444.GA12098@bromo.med.uc.edu
State New
Headers show

Commit Message

Jack Howarth Oct. 26, 2012, 7:14 p.m. UTC
Currently targets like darwin which use older assemblers which lack support for the
-masm=intel command line option fail these tests. The attached patch adds a proc for
check_effective_target_masm_intel to target-supports.exp and uses it in the
gcc.target/i386/asm-dialect-1.c test case. Tested on x86_64-apple-darwin12.
Okay for gcc trunk?
            Jack

gcc/testsuite/

2012-10-26  Jack Howarth  <howarth@bromo.med.uc.edu>

	PR target/54255
	* lib/target-supports.exp (check_effective_target_masm_intel): New proc.
	* gcc.target/i386/asm-dialect-1.c: Use dg-require-effective-target masm_intel.

Comments

Mike Stump Oct. 26, 2012, 9:28 p.m. UTC | #1
On Oct 26, 2012, at 12:14 PM, Jack Howarth <howarth@bromo.med.uc.edu> wrote:
> Currently targets like darwin which use older assemblers which lack support for the
> -masm=intel command line option fail these tests. The attached patch adds a proc for
> check_effective_target_masm_intel to target-supports.exp and uses it in the
> gcc.target/i386/asm-dialect-1.c test case. Tested on x86_64-apple-darwin12.
> Okay for gcc trunk?

Ok.
diff mbox

Patch

Index: gcc/testsuite/gcc.target/i386/asm-dialect-1.c
===================================================================
--- gcc/testsuite/gcc.target/i386/asm-dialect-1.c	(revision 192855)
+++ gcc/testsuite/gcc.target/i386/asm-dialect-1.c	(working copy)
@@ -1,4 +1,5 @@ 
 /* { dg-options "-masm=intel" } */
+/* { dg-require-effective-target masm_intel } */
 
 extern void abort (void);
 
Index: gcc/testsuite/lib/target-supports.exp
===================================================================
--- gcc/testsuite/lib/target-supports.exp	(revision 192855)
+++ gcc/testsuite/lib/target-supports.exp	(working copy)
@@ -4617,6 +4617,15 @@  proc check_effective_target_split_stack 
     } "-fsplit-stack"]
 }
 
+# Return 1 if this target supports the -masm=intel option, 0
+# otherwise
+
+proc check_effective_target_masm_intel  {} {
+    return [check_no_compiler_messages masm_intel object {
+	extern void abort (void);
+    } "-masm=intel"]
+}
+
 # Return 1 if the language for the compiler under test is C.
 
 proc check_effective_target_c { } {