llvmc: fix two tests, remove XFAILs.
authorMikhail Glushenkov <foldr@codedgers.com>
Fri, 13 Aug 2010 02:29:24 +0000 (02:29 +0000)
committerMikhail Glushenkov <foldr@codedgers.com>
Fri, 13 Aug 2010 02:29:24 +0000 (02:29 +0000)
Tested on Linux and Darwin; please add platform-specific XFAILs/mail me a bug
report if this still fails.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110998 91177308-0d34-0410-b5e6-96231b3b80d8

test/LLVMC/MultiplePluginPriorities.td
test/LLVMC/OutputSuffixHook.td
utils/TableGen/LLVMCConfigurationEmitter.cpp

index 2fe06450eecb4a4244a2d8a8001cdfc90f62cb54..f1086418f1994cfa56c281c35b451c98422ee097 100644 (file)
@@ -4,10 +4,6 @@
 // Disable for Darwin PPC: <rdar://problem/7598390>
 // XFAIL: powerpc-apple-darwin
 
-// Generally XFAIL'ed for now, this is (sometimes?) failing on x86_64-apple-darwin10.
-// RUN: false
-// XFAIL: *
-
 include "llvm/CompilerDriver/Common.td"
 
 def Graph : CompilationGraph<[]>;
index 4ecad2360ba062baf9e5e6cc95c056e997c1c3f3..39c8a8ae8846018cb7c60f28caaf88be4ba093fa 100644 (file)
@@ -2,7 +2,6 @@
 // RUN: tblgen -I %p/../../include --gen-llvmc %s -o %t
 // RUN: FileCheck -input-file %t %s
 // RUN: %compile_cxx -fexceptions -x c++ %t
-// XFAIL: *
 
 include "llvm/CompilerDriver/Common.td"
 
@@ -13,7 +12,7 @@ def OptList : OptionList<[
 ]>;
 
 def dummy_tool : Tool<[
-(cmd_line "dummy_cmd $INFILE"),
+(command "dummy_cmd"),
 (in_language "dummy_lang"),
 (out_language "dummy_lang"),
 (actions (case
index d4624e26ccd8af3f07f877989a590677e628f86d..7a68d696f9213283ba88c45ccf9b6e233f2badbd 100644 (file)
@@ -2177,8 +2177,8 @@ void EmitGenerateActionMethodHeader(const ToolDescription& D,
       << "std::vector<std::pair<unsigned, std::string> > vec;\n";
     O.indent(Indent2) << "bool stop_compilation = !HasChildren;\n";
     O.indent(Indent2) << "bool no_out_file = false;\n";
-    O.indent(Indent2) << "const char* output_suffix = \""
-                      << D.OutputSuffix << "\";\n";
+    O.indent(Indent2) << "std::string output_suffix(\""
+                      << D.OutputSuffix << "\");\n";
   }
 }
 
@@ -2235,7 +2235,8 @@ void EmitGenerateActionMethod (const ToolDescription& D,
 
   O.indent(Indent3) << "out_file = this->OutFilename("
                     << (IsJoin ? "sys::Path(),\n" : "inFile,\n");
-  O.indent(Indent4) << "TempDir, stop_compilation, output_suffix).str();\n\n";
+  O.indent(Indent4) <<
+    "TempDir, stop_compilation, output_suffix.c_str()).str();\n\n";
   O.indent(Indent3) << "vec.push_back(std::make_pair(65536, out_file));\n";
 
   O.indent(Indent2) << "}\n\n";