From 20c6849e2d12d4b486774622999ce585d2a4fd98 Mon Sep 17 00:00:00 2001 From: Andy Ayers Date: Mon, 4 Feb 2019 08:47:48 -0800 Subject: [PATCH] Fix arm32 unwind for large methods (dotnet/coreclr#22381) * Fix arm32 unwind for large methods For arm32, the unwinder bails out with an error if the method offset is not within the fragment range. And the jit copies prolog unwind codes to all fragments, so there's no need to walk back and find the root unwind record. Closes dotnet/coreclr#22260. * re-enable test Commit migrated from https://github.com/dotnet/coreclr/commit/75dfe5cfff56ad028bcf256ae0857bf64e4197e9 --- src/coreclr/src/vm/codeman.cpp | 6 ++++-- src/coreclr/tests/issues.targets | 3 --- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/coreclr/src/vm/codeman.cpp b/src/coreclr/src/vm/codeman.cpp index 663605b..0c596e3 100644 --- a/src/coreclr/src/vm/codeman.cpp +++ b/src/coreclr/src/vm/codeman.cpp @@ -3914,8 +3914,10 @@ PTR_RUNTIME_FUNCTION EEJitManager::LazyGetFunctionEntry(EECodeInfo * pCodeInfo) if (RUNTIME_FUNCTION__BeginAddress(pFunctionEntry) <= address && address < RUNTIME_FUNCTION__EndAddress(pFunctionEntry, baseAddress)) { -#if defined(EXCEPTION_DATA_SUPPORTS_FUNCTION_FRAGMENTS) - // If we may have fragmented unwind make sure we're returning the root record +#if defined(EXCEPTION_DATA_SUPPORTS_FUNCTION_FRAGMENTS) && defined(_TARGET_ARM64_) + // If we might have fragmented unwind, and we're on ARM64, make sure + // to returning the root record, as the trailing records don't have + // prolog unwind codes. pFunctionEntry = FindRootEntry(pFunctionEntry, baseAddress); #endif diff --git a/src/coreclr/tests/issues.targets b/src/coreclr/tests/issues.targets index 21ec785..9097e7b 100644 --- a/src/coreclr/tests/issues.targets +++ b/src/coreclr/tests/issues.targets @@ -619,9 +619,6 @@ 22015 - - 22260 - -- 2.7.4