[clang] [clang] return first Decl for CanonicalDecl in TranslationUnitDecl (PR #110101)

2024-09-26 Thread Vipul Cariappa via cfe-commits
https://github.com/Vipul-Cariappa created https://github.com/llvm/llvm-project/pull/110101 Return the first `Decl` when using `TranslationUnitDecl::getCanonicalDecl` >From 43d0e353e6e5870cf601ea83d072d8c05dbe94eb Mon Sep 17 00:00:00 2001 From: Vipul Cariappa Date: Thu, 26 Sep 2024 10:28:02 +00

[clang] [clang] return first Decl for CanonicalDecl in TranslationUnitDecl (PR #110101)

2024-09-26 Thread Vipul Cariappa via cfe-commits
Vipul-Cariappa wrote: ping @vgvassilev https://github.com/llvm/llvm-project/pull/110101 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] return first Decl for CanonicalDecl in TranslationUnitDecl (PR #110101)

2024-09-26 Thread Vipul Cariappa via cfe-commits
https://github.com/Vipul-Cariappa updated https://github.com/llvm/llvm-project/pull/110101 >From 43d0e353e6e5870cf601ea83d072d8c05dbe94eb Mon Sep 17 00:00:00 2001 From: Vipul Cariappa Date: Thu, 26 Sep 2024 10:28:02 + Subject: [PATCH 1/2] [clang] return first Decl for CanonicalDecl in Tran

[clang] [clang-repl] fix error recovery while parsing completely fails (PR #127087)

2025-02-18 Thread Vipul Cariappa via cfe-commits
Vipul-Cariappa wrote: My theory with limited testing: The crash is caused by assertion failure at https://github.com/llvm/llvm-project/blob/eb7c947272952d40d3235d89652a10da52cb2b4d/clang/lib/AST/DeclBase.cpp#L1757C1-L1758C54. So if we disable assertions it does not crash, and crashes otherwise.

[clang] [clang-repl] fix error recovery while parsing completely fails (PR #127087)

2025-02-13 Thread Vipul Cariappa via cfe-commits
https://github.com/Vipul-Cariappa created https://github.com/llvm/llvm-project/pull/127087 Fixes the following crash in clang-repl ```c++ clang-repl> try { throw 1; } catch { 0; } In file included from <<< inputs >>>:1: input_line_1:1:23: error: expected '(' 1 | try { throw 1; } catch { 0;

[clang] [clang-repl] fix error recovery while parsing completely fails (PR #127087)

2025-02-13 Thread Vipul Cariappa via cfe-commits
Vipul-Cariappa wrote: cc @vgvassilev https://github.com/llvm/llvm-project/pull/127087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang-Repl] Add support for out-of-process execution. (PR #110418)

2025-06-11 Thread Vipul Cariappa via cfe-commits
Vipul-Cariappa wrote: Hi @SahilPatidar, I see that this PR was reverted. Any ideas on when it will be re-applied? https://github.com/llvm/llvm-project/pull/110418 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] [llvm] [Clang-Repl] Add support for out-of-process execution. (PR #110418)

2025-06-11 Thread Vipul Cariappa via cfe-commits
@@ -47,6 +80,72 @@ static llvm::cl::opt OptHostSupportsJit("host-supports-jit", static llvm::cl::list OptInputs(llvm::cl::Positional, llvm::cl::desc("[code to run]")); +static llvm::Error sanitizeOopArguments(const char *ArgV0) { +

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
@@ -26,7 +26,8 @@ llvm::Expected> launchExecutor(llvm::StringRef ExecutablePath, bool UseSharedMemory, - llvm::StringRef SlabAllocateSizeString); + llvm::StringRef SlabAllocateSizeString, + std::function CustomizeFork = nullptr); -

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
https://github.com/Vipul-Cariappa edited https://github.com/llvm/llvm-project/pull/147478 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
https://github.com/Vipul-Cariappa commented: LGTM! Please address the comments I have left. I guess, you can remove the `[wip]` and draft status. https://github.com/llvm/llvm-project/pull/147478 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
@@ -54,6 +67,93 @@ createInterpreter(const Args &ExtraArgs = {}, return cantFail(clang::Interpreter::create(std::move(CI))); } +static std::string getExecutorPath() { + llvm::SmallString<256> ExecutorPath(llvm::sys::fs::getMainExecutable( + nullptr, reinterpret_cast(&g

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
@@ -155,6 +163,8 @@ launchExecutor(StringRef ExecutablePath, bool UseSharedMemory, << ExecutorPath.get() << "\"\n"; exit(1); } + } else { +LaunchedExecutorPID.push_back(ChildPID); } // else we're the parent... Vipul-Cariappa

[clang] [wip][Clang-Repl] Add custom function as lambda in launchExecutor and fetch PID of launched executor (PR #147478)

2025-07-29 Thread Vipul Cariappa via cfe-commits
@@ -91,7 +95,8 @@ createSharedMemoryManager(SimpleRemoteEPC &SREPC, Expected> launchExecutor(StringRef ExecutablePath, bool UseSharedMemory, - llvm::StringRef SlabAllocateSizeString) { + llvm::StringRef SlabAllocateSizeString, + std::f