llvm.org GIT mirror llvm / e3c55a5
Remove the -emit-bytecode option. Noone in the llvm tree uses it, and this keeps llvm-upgrade a simple "source to source" tool. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36848 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 13 years ago
2 changed file(s) with 3 addition(s) and 13 deletion(s). Raw diff Collapse all Expand all
88
99 LEVEL = ../..
1010 TOOLNAME = llvm-upgrade
11 LINK_COMPONENTS := BCWriter Core support system
11 LINK_COMPONENTS := Core support system
1212 REQUIRES_EH := 1
1313
1414 include $(LEVEL)/Makefile.common
2020
2121 #include "UpgradeInternals.h"
2222 #include "llvm/Module.h"
23 #include "llvm/Bytecode/Writer.h"
2423 #include "llvm/Support/CommandLine.h"
2524 #include "llvm/Support/ManagedStatic.h"
2625 #include "llvm/Support/Streams.h"
4847 static cl::opt
4948 Debug("debug-upgrade-yacc", cl::desc("Print debug output from yacc parser"),
5049 cl::Hidden, cl::init(false));
51
52 static cl::opt
53 EmitByteCode("emit-bytecode", cl::desc("Emit bytecode instead of assembly"),
54 cl::init(false));
5550
5651 int main(int argc, char **argv) {
5752 llvm_shutdown_obj X; // Call llvm_shutdown() on exit.
127122 Module *M = UpgradeAssembly(InputFilename, *In, Debug, AddAttrs);
128123 if (!M) {
129124 cerr << argv[0] << ": No module returned from assembly parsing\n";
130 if (!EmitByteCode)
131 *Out << argv[0] << ": parse failed.";
125 *Out << argv[0] << ": parse failed.";
132126 exit(1);
133127 }
134128
135129 // Finally, print the module on the output stream.
136 if (EmitByteCode) {
137 OStream OS(*Out);
138 WriteBytecodeToFile(M, OS);
139 } else
140 M->print(Out);
130 M->print(Out);
141131
142132 } catch (const std::string& caught_message) {
143133 cerr << argv[0] << ": " << caught_message << "\n";