Chris Lattner | 97e8b6f | 2007-10-07 06:04:32 +0000 | [diff] [blame] | 1 | //===--- ASTConsumers.h - ASTConsumer implementations -----------*- C++ -*-===// |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
Chris Lattner | 0bc735f | 2007-12-29 19:59:25 +0000 | [diff] [blame] | 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | // |
Chris Lattner | 97e8b6f | 2007-10-07 06:04:32 +0000 | [diff] [blame] | 10 | // AST Consumers. |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 11 | // |
| 12 | //===----------------------------------------------------------------------===// |
| 13 | |
Chris Lattner | 97e8b6f | 2007-10-07 06:04:32 +0000 | [diff] [blame] | 14 | #ifndef DRIVER_ASTCONSUMERS_H |
| 15 | #define DRIVER_ASTCONSUMERS_H |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 16 | |
Eli Friedman | 7df3d71 | 2008-02-16 23:17:23 +0000 | [diff] [blame] | 17 | #include <string> |
Ted Kremenek | ea75c55 | 2007-11-28 21:32:21 +0000 | [diff] [blame] | 18 | #include <iosfwd> |
Ted Kremenek | 1b5a4bd | 2007-11-27 21:46:50 +0000 | [diff] [blame] | 19 | |
Chris Lattner | e66b65c | 2008-02-06 01:42:25 +0000 | [diff] [blame] | 20 | namespace llvm { |
| 21 | class Module; |
| 22 | namespace sys { class Path; } |
| 23 | } |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 24 | namespace clang { |
| 25 | |
Chris Lattner | 556beb7 | 2007-09-15 22:56:56 +0000 | [diff] [blame] | 26 | class ASTConsumer; |
Chris Lattner | c0508f9 | 2007-09-15 23:21:08 +0000 | [diff] [blame] | 27 | class Diagnostic; |
Ted Kremenek | dca2466 | 2007-12-05 00:26:13 +0000 | [diff] [blame] | 28 | class FileManager; |
Chris Lattner | 45e8cbd | 2007-11-28 05:34:05 +0000 | [diff] [blame] | 29 | struct LangOptions; |
Chris Lattner | 3245a0a | 2008-04-16 06:11:58 +0000 | [diff] [blame] | 30 | class Preprocessor; |
Ted Kremenek | 339b9c2 | 2008-04-17 22:31:54 +0000 | [diff] [blame] | 31 | class PreprocessorFactory; |
| 32 | |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 33 | |
Ted Kremenek | ea75c55 | 2007-11-28 21:32:21 +0000 | [diff] [blame] | 34 | ASTConsumer *CreateASTPrinter(std::ostream* OS = NULL); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 35 | |
Chris Lattner | 3d4997d | 2007-09-15 23:02:28 +0000 | [diff] [blame] | 36 | ASTConsumer *CreateASTDumper(); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 37 | |
Ted Kremenek | 80de08f | 2007-09-19 21:29:43 +0000 | [diff] [blame] | 38 | ASTConsumer *CreateASTViewer(); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 39 | |
Ted Kremenek | 5f39c2d | 2008-02-22 20:00:31 +0000 | [diff] [blame] | 40 | ASTConsumer *CreateCFGDumper(bool ViewGraphs, const std::string& FName); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 41 | |
Ted Kremenek | bfc10c9 | 2008-02-22 20:13:09 +0000 | [diff] [blame] | 42 | ASTConsumer *CreateLiveVarAnalyzer(const std::string& fname); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 43 | |
Chris Lattner | c0508f9 | 2007-09-15 23:21:08 +0000 | [diff] [blame] | 44 | ASTConsumer *CreateDeadStoreChecker(Diagnostic &Diags); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 45 | |
Ted Kremenek | 2bf5514 | 2007-09-17 20:49:30 +0000 | [diff] [blame] | 46 | ASTConsumer *CreateUnitValsChecker(Diagnostic &Diags); |
Ted Kremenek | e603df4 | 2008-01-08 18:04:06 +0000 | [diff] [blame] | 47 | |
Ted Kremenek | cb33093 | 2008-02-18 21:21:23 +0000 | [diff] [blame] | 48 | ASTConsumer *CreateGRSimpleVals(Diagnostic &Diags, |
Ted Kremenek | 339b9c2 | 2008-04-17 22:31:54 +0000 | [diff] [blame] | 49 | Preprocessor* PP, PreprocessorFactory* PPF, |
Ted Kremenek | cb33093 | 2008-02-18 21:21:23 +0000 | [diff] [blame] | 50 | const std::string& Function, |
Ted Kremenek | 55af98c | 2008-04-14 18:40:58 +0000 | [diff] [blame] | 51 | const std::string& HTMLDir, bool Visualize, |
| 52 | bool TrimGraph, bool AnalyzeAll); |
Ted Kremenek | 2fff37e | 2008-03-06 00:08:09 +0000 | [diff] [blame] | 53 | |
Ted Kremenek | d71ed26 | 2008-04-10 22:16:52 +0000 | [diff] [blame] | 54 | ASTConsumer *CreateCFRefChecker(Diagnostic &Diags, |
Ted Kremenek | 339b9c2 | 2008-04-17 22:31:54 +0000 | [diff] [blame] | 55 | Preprocessor* PP, PreprocessorFactory* PPF, |
Ted Kremenek | e5c3012 | 2008-04-29 05:13:59 +0000 | [diff] [blame] | 56 | const LangOptions& LangOpts, |
Ted Kremenek | d71ed26 | 2008-04-10 22:16:52 +0000 | [diff] [blame] | 57 | const std::string& Function, |
Ted Kremenek | 55af98c | 2008-04-14 18:40:58 +0000 | [diff] [blame] | 58 | const std::string& HTMLDir, bool Visualize, |
| 59 | bool TrimGraph, bool AnalyzeAll); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 60 | |
Fariborz Jahanian | b4b2f0c | 2008-01-18 01:15:54 +0000 | [diff] [blame] | 61 | ASTConsumer *CreateCodeRewriterTest(const std::string& InFile, |
Chris Lattner | c68ab77 | 2008-03-22 00:08:40 +0000 | [diff] [blame] | 62 | const std::string& OutFile, |
Steve Naroff | 4f943c2 | 2008-03-10 20:43:59 +0000 | [diff] [blame] | 63 | Diagnostic &Diags, |
| 64 | const LangOptions &LOpts); |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 65 | |
Chris Lattner | 3245a0a | 2008-04-16 06:11:58 +0000 | [diff] [blame] | 66 | ASTConsumer* CreateHTMLPrinter(const std::string &OutFile, Diagnostic &D, |
Ted Kremenek | 339b9c2 | 2008-04-17 22:31:54 +0000 | [diff] [blame] | 67 | Preprocessor *PP, PreprocessorFactory* PPF); |
Ted Kremenek | 6a34083 | 2008-03-18 21:19:49 +0000 | [diff] [blame] | 68 | |
Ted Kremenek | fdfc198 | 2007-12-19 22:24:34 +0000 | [diff] [blame] | 69 | ASTConsumer *CreateSerializationTest(Diagnostic &Diags, |
Ted Kremenek | e7d07d1 | 2008-06-04 15:55:15 +0000 | [diff] [blame^] | 70 | FileManager& FMgr); |
Ted Kremenek | a1fa3a1 | 2007-12-13 00:37:31 +0000 | [diff] [blame] | 71 | |
Ted Kremenek | f06c928 | 2007-12-19 23:49:37 +0000 | [diff] [blame] | 72 | ASTConsumer *CreateASTSerializer(const std::string& InFile, |
| 73 | const std::string& EmitDir, |
Ted Kremenek | e7d07d1 | 2008-06-04 15:55:15 +0000 | [diff] [blame^] | 74 | Diagnostic &Diags); |
Ted Kremenek | 055c275 | 2007-09-06 23:00:42 +0000 | [diff] [blame] | 75 | |
Reid Spencer | 5f016e2 | 2007-07-11 17:01:13 +0000 | [diff] [blame] | 76 | } // end clang namespace |
| 77 | |
| 78 | #endif |