[llvm-commits] CVS: llvm/tools/gccld/GenerateCode.cpp

Chris Lattner lattner at cs.uiuc.edu
Thu Apr 8 10:16:04 PDT 2004


Changes in directory llvm/tools/gccld:

GenerateCode.cpp updated: 1.23 -> 1.24

---
Log message:

Right, we break strict aliasing requirements.  Make sure to disable strict
aliasing in the C compiler.


---
Diffs of the changes:  (+6 -5)

Index: llvm/tools/gccld/GenerateCode.cpp
diff -u llvm/tools/gccld/GenerateCode.cpp:1.23 llvm/tools/gccld/GenerateCode.cpp:1.24
--- llvm/tools/gccld/GenerateCode.cpp:1.23	Tue Apr  6 11:54:04 2004
+++ llvm/tools/gccld/GenerateCode.cpp	Thu Apr  8 10:14:43 2004
@@ -176,15 +176,16 @@
                         const std::string &InputFile,
                         const std::string &llc, char ** const envp) {
   // Run LLC to convert the bytecode file into C.
-  const char *cmd[7];
+  const char *cmd[8];
 
   cmd[0] = llc.c_str();
   cmd[1] = "-march=c";
   cmd[2] = "-f";
-  cmd[3] = "-o";
-  cmd[4] = OutputFile.c_str();
-  cmd[5] = InputFile.c_str();
-  cmd[6] = 0;
+  cmd[3] = "-fno-strict-aliasing";
+  cmd[4] = "-o";
+  cmd[5] = OutputFile.c_str();
+  cmd[6] = InputFile.c_str();
+  cmd[7] = 0;
   return ExecWait(cmd, envp);
 }
 





More information about the llvm-commits mailing list