mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-23 22:23:00 +00:00
Fix assertion when C++ EH filters are present in functions using SEH
Should fix PR22305. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226969 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -221,12 +221,11 @@ void Win64Exception::emitCSpecificHandlerTable() {
|
||||
|
||||
// Do a parallel iteration across typeids and clause labels, skipping filter
|
||||
// clauses.
|
||||
assert(LPad->TypeIds.size() == LPad->ClauseLabels.size());
|
||||
size_t NextClauseLabel = 0;
|
||||
for (size_t I = 0, E = LPad->TypeIds.size(); I < E; ++I) {
|
||||
// AddLandingPadInfo stores the clauses in reverse, but there is a FIXME
|
||||
// to change that.
|
||||
int Selector = LPad->TypeIds[E - I - 1];
|
||||
MCSymbol *ClauseLabel = LPad->ClauseLabels[I];
|
||||
|
||||
// Ignore C++ filter clauses in SEH.
|
||||
// FIXME: Implement cleanup clauses.
|
||||
@@ -243,6 +242,7 @@ void Win64Exception::emitCSpecificHandlerTable() {
|
||||
else // Otherwise, this is a "catch i8* null", or catch all.
|
||||
Asm->OutStreamer.EmitIntValue(1, 4);
|
||||
}
|
||||
MCSymbol *ClauseLabel = LPad->ClauseLabels[NextClauseLabel++];
|
||||
Asm->OutStreamer.EmitValue(createImageRel32(ClauseLabel), 4);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user