Skip to content

SEH Windows tests are fixed. - #8

Draft
yasster wants to merge 1 commit into
mainfrom
user/mmissoum/seh-test-fix
Draft

SEH Windows tests are fixed.#8
yasster wants to merge 1 commit into
mainfrom
user/mmissoum/seh-test-fix

Conversation

@yasster

@yasster yasster commented Jan 9, 2026

Copy link
Copy Markdown
Owner

No description provided.

@@ -2216,27 +2216,44 @@ void CodeGenFunction::ExitSEHTryStmt(const SEHTryStmt &S) {
return;
}

// Otherwise, we must have an __except block.
const SEHExceptStmt *Except = S.getExceptHandler();

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Why did this need to be moved up?

@@ -1754,7 +1750,19 @@ auto CodeGenFunction::GetDestForLoopControlStmt(const LoopControlStmt &S)
}

void CodeGenFunction::EmitBreakStmt(const BreakStmt &S) {
assert(!BreakContinueStack.empty() && "break stmt not in a loop or switch!");
// If we're in an outlined SEH finally function and there's no loop context,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is there some other way that we can check this? Can we see that we're in a funclet, or check the functions EH personality?

@@ -0,0 +1,26 @@
// RUN: %clang_cc1 -triple x86_64-windows-msvc -fms-compatibility -emit-llvm -o - %s | FileCheck %s

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Can we add another run of this test without ms-compat and verify the opposite behavior?

Comment thread llvm/test/CodeGen/X86/seh-finally-noreturn.ll
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants