Skip to content

Commit 6484af8

Browse files
[WASM] Revert NeedsThunk patch for thin to thick
1 parent 2d6e6f8 commit 6484af8

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

lib/SIL/IR/TypeLowering.cpp

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2885,23 +2885,10 @@ TypeConverter::checkFunctionForABIDifferences(SILModule &M,
28852885
return ABIDifference::NeedsThunk;
28862886
}
28872887

2888-
// There is no ABI compatibility between non-throws and throws on WebAssembly,
2889-
// so need thunk.
2890-
if (M.getASTContext().LangOpts.Target.isOSBinFormatWasm()) {
2891-
if (!fnTy1->hasErrorResult() && fnTy2->hasErrorResult()) {
2892-
return ABIDifference::NeedsThunk;
2893-
}
2894-
}
2895-
28962888
auto rep1 = fnTy1->getRepresentation(), rep2 = fnTy2->getRepresentation();
28972889
if (rep1 != rep2) {
28982890
if (rep1 == SILFunctionTypeRepresentation::Thin &&
28992891
rep2 == SILFunctionTypeRepresentation::Thick) {
2900-
// There is no ABI compatibility between thin and thick on WebAssembly,
2901-
// so need thunk.
2902-
if (M.getASTContext().LangOpts.Target.isOSBinFormatWasm()) {
2903-
return ABIDifference::NeedsThunk;
2904-
}
29052892
if (DifferentFunctionTypesHaveDifferentRepresentation) {
29062893
// FIXME: check whether the representations are compatible modulo
29072894
// context

0 commit comments

Comments
 (0)