llvm-project/clang/lib
Yaxun (Sam) Liu 3193133add [OpenCL] Do not include default header for preprocessor output as input
When clang driver is used with -save-temps to compile OpenCL program,
clang driver first launches clang -cc1 -E to generate preprocessor expansion output,
then launches clang -cc1 with the generated preprocessor expansion output as input
to generate LLVM IR.

Currently clang by default passes "-finclude-default-header" "-fdeclare-opencl-builtins"
in both steps, which causes default header included again in the second step, which
causes error.

This patch let clang not to include default header when input type is preprocessor expansion
output, which fixes the issue.

Reviewed by: Anastasia Stulova

Differential Revision: https://reviews.llvm.org/D104800
2021-06-25 10:01:51 -04:00
..
APINotes [clang][APINotes] Fix -Wunused-function warning (NFC) 2021-04-01 09:52:43 +08:00
ARCMigrate [SystemZ][z/OS] Set files in FileRemapper.cpp are text 2021-04-19 07:59:42 -04:00
AST AST: Create __va_list in the std namespace even in C. 2021-06-23 18:59:10 -07:00
ASTMatchers [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
Analysis [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
Basic [PowerPC] Add XL compat __compare_and_swap builtins 2021-06-25 01:08:48 +00:00
CodeGen [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C 2021-06-25 11:48:42 +01:00
CrossTU [analyzer][ctu] Reland "Avoid parsing invocation list again and again.. 2021-05-25 09:44:13 +02:00
DirectoryWatcher Revert "Re-Revert "DirectoryWatcher: add an implementation for Windows"" 2021-06-19 09:19:52 -07:00
Driver [OpenCL] Do not include default header for preprocessor output as input 2021-06-25 10:01:51 -04:00
Edit [Matrix] Implement C-style explicit type conversions for matrix types. 2021-04-10 11:48:41 +01:00
Format [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
Frontend [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
FrontendTool [OptTable] Rename PrintHelp to printHelp 2021-06-24 14:47:03 -07:00
Headers [PowerPC] Fix vec_add for 64-bit on pre-Power7 subtargets 2021-06-24 18:42:44 -05:00
Index [index] Fix performance regression with indexing macros 2021-06-16 10:16:26 -07:00
IndexSerialization [index-while-building] Fix build with -DBUILD_SHARED_LIBS=True 2020-08-20 15:12:56 +01:00
Interpreter [clang] Fix a race condition in the build of clangInterpreter 2021-06-17 10:03:33 -07:00
Lex [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
Parse Handle interactions between reserved identifier and user-defined suffixes 2021-06-23 15:38:42 +02:00
Rewrite [clang] DeltaTree::AddDelta - fix "initialization is never read" clang-tidy warning. NFCI. 2021-03-02 15:01:34 +00:00
Sema [RISCV] Add vget/vset intrinsics for inserting and extracting between different lmuls. 2021-06-24 18:06:36 -07:00
Serialization [clang][AST] Make `getLocalOrImportedSubmoduleID` work with const `Module*`. NFC. 2021-06-17 17:29:12 -07:00
StaticAnalyzer [Analyzer][solver] Fix crashes during symbol simplification 2021-06-25 11:49:26 +02:00
Testing Fix MSVC "not all control paths return a value" warning. NFC. 2020-06-05 10:45:59 +01:00
Tooling [clang] Rename StringRef _lower() method calls to _insensitive() 2021-06-25 00:22:01 +03:00
CMakeLists.txt [clang-repl] Recommit "Land initial infrastructure for incremental parsing" 2021-05-13 06:30:29 +00:00