Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | Try to guess when the auto-generated cl::Sink option should be marked 'extern'. | Mikhail Glushenkov | 2008-12-07 | 1 | -5/+20 | |
| | | | | | | | This would be much easier to do if the CommandLine library didn't use global state. Global state is evil. llvm-svn: 60659 | |||||
* | Add a (progn)-like construct for (actions). Implemented as a DAG list. | Mikhail Glushenkov | 2008-12-07 | 1 | -10/+37 | |
| | | | | llvm-svn: 60658 | |||||
* | Use (actions) instead of option properties, support external options. | Mikhail Glushenkov | 2008-12-07 | 1 | -975/+885 | |
| | | | | | | | Also includes a major refactoring. See documentation for more information. llvm-svn: 60656 | |||||
* | The use of the construct: | Cedric Venet | 2008-12-05 | 1 | -12/+12 | |
| | | | | | | | | for(Type1 B = ...;;) { Type2 B ; ... } is bad: code is hard to read and VS VS don't like it (it ignore the second declaration of B). This patch fix the problem in tablegen. Please don't write code like this. llvm-svn: 60590 | |||||
* | Support multiple compilation graph definitions. Not terribly useful, but ↵ | Mikhail Glushenkov | 2008-11-28 | 1 | -42/+51 | |
| | | | | | | makes the code more generic. llvm-svn: 60199 | |||||
* | Add 'hidden' and 'really_hidden' option properties. | Mikhail Glushenkov | 2008-11-28 | 1 | -1/+43 | |
| | | | | llvm-svn: 60198 | |||||
* | Small fix: the error message was incorrect in some cases. | Mikhail Glushenkov | 2008-11-26 | 1 | -3/+3 | |
| | | | | llvm-svn: 60099 | |||||
* | Support dependencies between plugins by priority-sorting. | Mikhail Glushenkov | 2008-11-17 | 1 | -5/+19 | |
| | | | | llvm-svn: 59449 | |||||
* | Filter ToolPropertiesList to exclude all Tools not mentioned in the ↵ | Mikhail Glushenkov | 2008-11-17 | 1 | -49/+78 | |
| | | | | | | compilation graph. llvm-svn: 59448 | |||||
* | Add a layer of indirection to make plugins more flexible. | Mikhail Glushenkov | 2008-11-17 | 1 | -55/+58 | |
| | | | | | | | Use strings instead of TableGen defs in the compilation graph definition. Makes it easier for the plugins to modify an existing graph. llvm-svn: 59447 | |||||
* | Check the return value of std::getenv. | Mikhail Glushenkov | 2008-11-12 | 1 | -4/+8 | |
| | | | | | | | | | When constructing std::strings from C strings, we should check the input value to be not NULL so that the std::string constructor does not segfault. Fixes #3047. llvm-svn: 59131 | |||||
* | Add a bit of lazy evaluation to PopulateCompilationGraph(). | Mikhail Glushenkov | 2008-11-12 | 1 | -11/+18 | |
| | | | | | | | | Only the tools that are mentioned in the compilation graph definition are now inserted by PopulateCompilationGraph(). This should cut down plugin loading time a little. llvm-svn: 59097 | |||||
* | Some cosmetic changes. | Mikhail Glushenkov | 2008-11-12 | 1 | -0/+2 | |
| | | | | llvm-svn: 59096 | |||||
* | Allow $CALL and $ENV in command names. Fixes #3025. | Mikhail Glushenkov | 2008-11-08 | 1 | -1/+1 | |
| | | | | llvm-svn: 58922 | |||||
* | Properly escape dashes in TableGen's LLVMC2 emitter. | Anton Korobeynikov | 2008-11-08 | 1 | -2/+2 | |
| | | | | | | Patch by Patrick Walton! llvm-svn: 58901 | |||||
* | Move llvmc2 header files under include/llvm/CompilerDriver | Mikhail Glushenkov | 2008-09-22 | 1 | -3/+3 | |
| | | | | llvm-svn: 56466 | |||||
* | Plugin support for llvmc2 (a-la opt). | Mikhail Glushenkov | 2008-09-22 | 1 | -4/+42 | |
| | | | | llvm-svn: 56465 | |||||
* | Make comments a little bit more clear. | Mikhail Glushenkov | 2008-09-22 | 1 | -2/+4 | |
| | | | | llvm-svn: 56463 | |||||
* | Get rid of GlobalLanguageMap. Global state is evil. | Mikhail Glushenkov | 2008-09-22 | 1 | -7/+9 | |
| | | | | llvm-svn: 56462 | |||||
* | Add a (forward_as) option property | Mikhail Glushenkov | 2008-09-22 | 1 | -11/+39 | |
| | | | | llvm-svn: 56459 | |||||
* | Delete the file llvmc2/doc/LLVMC-Enhancements.rst + some minor ↵ | Mikhail Glushenkov | 2008-09-22 | 1 | -3/+2 | |
| | | | | | | language/spelling fixes. llvm-svn: 56458 | |||||
* | Add #includes required by GCC 4.3, thanks for Zhongxing Xu | Chris Lattner | 2008-06-04 | 1 | -2/+1 | |
| | | | | | | for reporting this. llvm-svn: 51926 | |||||
* | Initialize members properly during construction | Anton Korobeynikov | 2008-06-01 | 1 | -2/+2 | |
| | | | | llvm-svn: 51841 | |||||
* | Callback was not executed on OS X when it was a function. | Mikhail Glushenkov | 2008-05-31 | 1 | -1/+1 | |
| | | | | llvm-svn: 51814 | |||||
* | Add a check for side effect-free options (specified only in the OptionList). | Mikhail Glushenkov | 2008-05-30 | 1 | -2/+38 | |
| | | | | llvm-svn: 51759 | |||||
* | Refactoring: remove code duplication introduced in the previous patch. | Mikhail Glushenkov | 2008-05-30 | 1 | -86/+65 | |
| | | | | llvm-svn: 51757 | |||||
* | Refactoring: split CollectProperties into two separate function objects. | Mikhail Glushenkov | 2008-05-30 | 1 | -137/+226 | |
| | | | | llvm-svn: 51756 | |||||
* | New feature: OptionList. | Mikhail Glushenkov | 2008-05-30 | 1 | -4/+31 | |
| | | | | | | | | | | | | | | | | | | It can be handy to have all information about options gathered in a single place to provide an overview of all supported options. This patch allows the following: def Options : OptionList<[ (switch_option "E", (help "Help string")), (alias_option "quiet", "q") ... ]>; Tool-specific option properties (like 'append_cmd') have (obviously) no meaning in this context, so the only properties that are allowed are 'help' and 'required'. See usage example in examples/Clang.td. llvm-svn: 51754 | |||||
* | A small optimization: use static char* array instead of StrVector. | Mikhail Glushenkov | 2008-05-30 | 1 | -12/+21 | |
| | | | | llvm-svn: 51752 | |||||
* | Make it possible to test if the '-o' option is provided. | Mikhail Glushenkov | 2008-05-30 | 1 | -5/+11 | |
| | | | | | | | | | | The following is now allowed: (case (not_empty "o"), do_something, ...) This didn't work previously because "-o" is built-in. llvm-svn: 51751 | |||||
* | Fix: 'sink' handling was broken. | Mikhail Glushenkov | 2008-05-30 | 1 | -5/+5 | |
| | | | | llvm-svn: 51750 | |||||
* | Add support for option aliases. | Mikhail Glushenkov | 2008-05-30 | 1 | -17/+68 | |
| | | | | llvm-svn: 51749 | |||||
* | Allow nesting of case expressions. | Mikhail Glushenkov | 2008-05-30 | 1 | -17/+36 | |
| | | | | | | | | | | | The following is now legal: (case (in_language "c"), (case (switch_on "E"), "gcc -x c -E $INFILE", (default), "gcc -x c $INFILE"), (default), "gcc $INFILE $OUTFILE") llvm-svn: 51748 | |||||
* | Small error message improvement. | Mikhail Glushenkov | 2008-05-30 | 1 | -0/+5 | |
| | | | | llvm-svn: 51747 | |||||
* | Remove RequireDefault parameter from EmitCaseConstructHandler. | Mikhail Glushenkov | 2008-05-30 | 1 | -9/+3 | |
| | | | | | | There are now no situations when 'default' is required. llvm-svn: 51746 | |||||
* | Fix some headers. | Mikhail Glushenkov | 2008-05-30 | 1 | -1/+1 | |
| | | | | llvm-svn: 51745 | |||||
* | New tests for the 'case' expression: not_empty, in_language. | Mikhail Glushenkov | 2008-05-30 | 1 | -4/+14 | |
| | | | | llvm-svn: 51744 | |||||
* | Make it possible to have multiple input languages for a single tool. | Mikhail Glushenkov | 2008-05-30 | 1 | -24/+65 | |
| | | | | llvm-svn: 51742 | |||||
* | Better error reporting for the 'case' construct. | Mikhail Glushenkov | 2008-05-30 | 1 | -4/+17 | |
| | | | | llvm-svn: 51738 | |||||
* | Do not generate empty 'if's for the output_suffix property. | Mikhail Glushenkov | 2008-05-30 | 1 | -5/+13 | |
| | | | | llvm-svn: 51737 | |||||
* | Make it possible to use hooks like this: '$CALL(MyHook)/path/to/file'. | Mikhail Glushenkov | 2008-05-30 | 1 | -17/+36 | |
| | | | | llvm-svn: 51734 | |||||
* | Make it possible to change the output file suffix based on command-line options. | Mikhail Glushenkov | 2008-05-30 | 1 | -3/+32 | |
| | | | | | | | | | | For instance, the following command: llvmc2 -E hello.c now generates a file with the correct suffix (hello.i). llvm-svn: 51733 | |||||
* | Add support for user-provided hooks and environment variable reads to the ↵ | Mikhail Glushenkov | 2008-05-30 | 1 | -16/+113 | |
| | | | | | | | | | | | | | | cmd_line tool property. Used like this: (cmd_line "$CALL(MyHook) --option -o $ENV(VARIABLE) $CALL(AnotherHook)") Also works with case expressions. Hook declarations are auto-generated, the definitions should be provided by the user (just drop a .cpp file in the tools/llvmc2 directory). Hooks should live in the "hooks" namespace and have type std::string hooks::Hook(void). llvm-svn: 51732 | |||||
* | Some small tweaks to make the generated code prettier. | Mikhail Glushenkov | 2008-05-30 | 1 | -4/+14 | |
| | | | | llvm-svn: 51729 | |||||
* | Make it possible to use the generalised 'case' construct in the cmd_line ↵ | Mikhail Glushenkov | 2008-05-30 | 1 | -177/+218 | |
| | | | | | | property. llvm-svn: 51728 | |||||
* | Add a generalised 'case' construct. | Mikhail Glushenkov | 2008-05-30 | 1 | -72/+106 | |
| | | | | | | Besides assigning edge weights, it will also be used by the cmd_line tool property. llvm-svn: 51727 | |||||
* | Filter option names to escape symbols not allowed as C++ identifiers. | Mikhail Glushenkov | 2008-05-12 | 1 | -5/+22 | |
| | | | | | | | Makes it possible to use options with names like "Wa,". Also fixes the -Wall option handling as a side-effect. llvm-svn: 50973 | |||||
* | Reapply 50867: A small refactoring (extract method) + some comment fixes. | Mikhail Glushenkov | 2008-05-09 | 1 | -54/+64 | |
| | | | | | | Fixed the build breakage, sorry for that. llvm-svn: 50895 | |||||
* | Revertin 50867 since it was breaking the build. | Tanya Lattner | 2008-05-08 | 1 | -62/+52 | |
| | | | | llvm-svn: 50871 | |||||
* | A small refactoring (extract method) + some comment fixes. | Mikhail Glushenkov | 2008-05-08 | 1 | -52/+62 | |
| | | | | llvm-svn: 50867 |