[clang] [clang-repl] Simplify the value printing logic to enable out-of-process. (PR #107737)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 20 06:39:53 PDT 2024


================
@@ -39,11 +44,13 @@ class IncrementalCUDADeviceParser : public IncrementalParser {
   ~IncrementalCUDADeviceParser();
 
 protected:
-  IncrementalParser &HostParser;
+  std::unique_ptr<CompilerInstance> DeviceCI;
   int SMVersion;
   llvm::SmallString<1024> PTXCode;
   llvm::SmallVector<char, 1024> FatbinContent;
   llvm::IntrusiveRefCntPtr<llvm::vfs::InMemoryFileSystem> VFS;
+  CodeGenOptions &CodeGenOpts; // intentionally a reference.
----------------
AaronBallman wrote:

```suggestion
  CodeGenOptions &CodeGenOpts; // Intentionally a reference.
```
Not certain the comment adds much -- we usually don't add reference members accidentally.

https://github.com/llvm/llvm-project/pull/107737


More information about the cfe-commits mailing list