Skip to content

[clang] Correctly RAII reset two "new" Sema fields#15004

Merged
hahnjo merged 3 commits into
root-project:masterfrom
hahnjo:cling-raii
Apr 2, 2024
Merged

[clang] Correctly RAII reset two "new" Sema fields#15004
hahnjo merged 3 commits into
root-project:masterfrom
hahnjo:cling-raii

Conversation

@hahnjo

@hahnjo hahnjo commented Mar 18, 2024

Copy link
Copy Markdown
Member

FunctionScopesStart and InventedParameterInfosStart were introduced by upstream commit llvm/llvm-project@5c845c1 and are handled in ContextRAII, but not our ContextAndScopeRAII. The second commit reuses ContextRAII and should avoid this kind of problem in the future.

Could fix #14230, to be confirmed.

@hahnjo hahnjo self-assigned this Mar 18, 2024
@phsft-bot

Copy link
Copy Markdown

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

@github-actions

github-actions Bot commented Mar 19, 2024

Copy link
Copy Markdown

Test Results

    12 files      12 suites   2d 0h 27m 19s ⏱️
 2 605 tests  2 604 ✅ 0 💤 1 ❌
29 280 runs  29 279 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit fd66a49.

♻️ This comment has been updated with latest results.

hahnjo added 3 commits April 2, 2024 09:55
FunctionScopesStart and InventedParameterInfosStart were introduced
by upstream commit
llvm/llvm-project@5c845c1
and are handled in ContextRAII, but not our ContextAndScopeRAII.
@phsft-bot

Copy link
Copy Markdown

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

@hahnjo hahnjo marked this pull request as ready for review April 2, 2024 09:06
@hahnjo

hahnjo commented Apr 2, 2024

Copy link
Copy Markdown
Member Author

Independently from testing by ALICE, I believe this change is correct and I went ahead and synchronized it into a tag in our fork of the LLVM monorepo. @vgvassilev can you review please?

@vgvassilev vgvassilev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. Do we have a plan how to move that upstream?

@phsft-bot

Copy link
Copy Markdown

Build failed on ROOT-ubuntu2004/python3.
See console output.

@hahnjo

hahnjo commented Apr 2, 2024

Copy link
Copy Markdown
Member Author

Do we have a plan how to move that upstream?

I was wondering the same. AFAICT we use it for autoloading, which will be hard to argue upstream. But by reusing ContextRAII, we can maybe get away with exposing a couple of public API functions and move it out of the Clang headers...

@hahnjo hahnjo merged commit 9950a44 into root-project:master Apr 2, 2024
@hahnjo hahnjo deleted the cling-raii branch April 2, 2024 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ROOT 6.30.01 + C++20 crashes when interpreting specially crafted macro

3 participants