diff options
author | Anubhab Ghosh <anubhabghosh.me@gmail.com> | 2023-03-06 16:50:02 +0530 |
---|---|---|
committer | Anubhab Ghosh <anubhabghosh.me@gmail.com> | 2023-05-20 14:00:48 +0530 |
commit | 80e7eed6a610ab3c7289e6f9b7ec006bc7d7ae31 (patch) | |
tree | 01efc2c4d2fa8819d158fca07890b2134f51010d /clang/unittests/Interpreter/InterpreterTest.cpp | |
parent | 14f245d01a1ee489a13e843e9c77cecf5c7183a9 (diff) | |
download | llvm-80e7eed6a610ab3c7289e6f9b7ec006bc7d7ae31.zip llvm-80e7eed6a610ab3c7289e6f9b7ec006bc7d7ae31.tar.gz llvm-80e7eed6a610ab3c7289e6f9b7ec006bc7d7ae31.tar.bz2 |
[clang-repl][CUDA] Initial interactive CUDA support for clang-repl
CUDA support can be enabled in clang-repl with --cuda flag.
Device code linking is not yet supported. inline must be used with all
__device__ functions.
Differential Revision: https://reviews.llvm.org/D146389
Diffstat (limited to 'clang/unittests/Interpreter/InterpreterTest.cpp')
-rw-r--r-- | clang/unittests/Interpreter/InterpreterTest.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/unittests/Interpreter/InterpreterTest.cpp b/clang/unittests/Interpreter/InterpreterTest.cpp index d555911..5e03eea 100644 --- a/clang/unittests/Interpreter/InterpreterTest.cpp +++ b/clang/unittests/Interpreter/InterpreterTest.cpp @@ -40,7 +40,9 @@ createInterpreter(const Args &ExtraArgs = {}, DiagnosticConsumer *Client = nullptr) { Args ClangArgs = {"-Xclang", "-emit-llvm-only"}; ClangArgs.insert(ClangArgs.end(), ExtraArgs.begin(), ExtraArgs.end()); - auto CI = cantFail(clang::IncrementalCompilerBuilder::create(ClangArgs)); + auto CB = clang::IncrementalCompilerBuilder(); + CB.SetCompilerArgs(ClangArgs); + auto CI = cantFail(CB.CreateCpp()); if (Client) CI->getDiagnostics().setClient(Client, /*ShouldOwnClient=*/false); return cantFail(clang::Interpreter::create(std::move(CI))); |