') + ')', 'gi'); if (regex.test(text)) { found = true; var frag = document.createDocumentFragment(); var parts = text.split(regex); parts.forEach(function(part, i) { if (i % 2 === 0) { frag.appendChild(document.createTextNode(part)); } else { var span = document.createElement('span'); span.className = 'userscript-highlight'; span.textContent = part; frag.appendChild(span); } }); node.parentNode.replaceChild(frag, node); } }); } else if (node.nodeType === 1 && node.childNodes) { // element var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT']; if (!skipTags.includes(node.tagName)) { Array.from(node.childNodes).forEach(highlight); } } } highlight(document.body); // Re-highlight on dynamic content var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1 || node.nodeType === 3) highlight(node); }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Strip utm_, fbclid, gclid, etc. from all links on page (function() { var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content', 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid', 'ref', 'ref_src', 'source', 'medium', 'campaign']; function cleanUrl(url) { try { var u = new URL(url, window.location.origin); var changed = false; trackingParams.forEach(function(p) { if (u.searchParams.has(p)) { u.searchParams.delete(p); changed = true; } }); return changed ? u.toString() : url; } catch (e) { return url; } } function cleanLinks() { document.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } cleanLinks(); var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1) { if (node.tagName === 'A') cleanLinks(); node.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Auto-enable theater mode on YouTube (function() { function tryTheater() { var btn = document.querySelector('button[aria-label="Theater mode"], ytd-player #player button[title="Theater mode"]'); if (btn && !btn.classList.contains('activated')) { btn.click(); } } // Try immediately tryTheater(); // Try after navigation (SPA) var lastUrl = location.href; setInterval(function() { if (location.href !== lastUrl) { lastUrl = location.href; setTimeout(tryTheater, 500); } }, 1000); // Also try on player load var observer = new MutationObserver(tryTheater); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Remove or un-stick sticky/fixed headers that block content (function() { function unstick() { document.querySelectorAll('header, nav, [role="banner"], .header, .navbar, .sticky, .fixed-top, [style*="position: fixed"], [style*="position:sticky"]').forEach(function(el) { if (el.style.position === 'fixed' || el.style.position === 'sticky' || getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') { el.style.position = 'static'; el.style.top = 'auto'; el.style.zIndex = 'auto'; } }); } unstick(); var observer = new MutationObserver(unstick); observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] }); })(); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); })(); [6.0] Fix the tiering delay to account for changing IL/native code versions during the delay by kouvel · Pull Request #78670 · dotnet/runtime · GitHub
Skip to content

[6.0] Fix the tiering delay to account for changing IL/native code versions during the delay - #78670

Merged
carlossanlop merged 1 commit into
dotnet:release/6.0from
kouvel:TierFix6
Nov 29, 2022
Merged

[6.0] Fix the tiering delay to account for changing IL/native code versions during the delay#78670
carlossanlop merged 1 commit into
dotnet:release/6.0from
kouvel:TierFix6

Conversation

@kouvel

@kouvelkouvel commented Nov 22, 2022

Copy link
Copy Markdown
Contributor

Fixes#77973

Customer Impact

Apps that use profiler APIs to modify a method's IL may occasionally crash. If a new IL code version is added to a method while it's queued for call counting during the tiering delay, after the delay expires a call counting stub may be created that when called, would cause the app to crash. A workaround is to disable tiered compilation.

Regression?

No

Testing

Reproed the issue by inducing the timing with code changes and verified the fix. Scanned over the few other paths where call counting stubs would be created and verified that all of them guarantee a non-null code entry point for the method.

Risk

Low

…rsions during the delay
- Port of #78668
- Added a check to see if the currently active native code version has a code entry point
Fixes#77973
@carlossanlop

Copy link
Copy Markdown
Contributor

@kouvel for the January servicing release, we only have a window of one day to merge backports (from Nov. 29th to Nov. 30th). For that reason, I'm asking all backport submitters to make sure the PR is ready for me to just hit the merge button on that day.

If this is ready, please ask @jeffschwMSFT if he approves the backport. If approved, then:

  • Get a code review sign-off from an area owner (@davmason / @noahfalk).
  • Add the servicing-consider label.
  • Send an email to Tactics requesting approval.

@jeffschwMSFTjeffschwMSFT 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.

approved. we will take for consideration in 6.0.x

@jeffschwMSFTjeffschwMSFT added the Servicing-consider Issue for next servicing release review label Nov 23, 2022
@kouvel

Copy link
Copy Markdown
ContributorAuthor

cc @mangod9@tommcdon

@jeffschwMSFTjeffschwMSFT added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Nov 28, 2022
@jeffschwMSFTjeffschwMSFT modified the milestones: 6.0.x, 6.0.13Nov 29, 2022
@carlossanlop

Copy link
Copy Markdown
Contributor

Branding has been done. Milestone is 6.0.13. Approved by Tactics. Signed-off by area owners. CI is green. No OOB package authoring changes needed.
Ready to merge. :shipit:

@carlossanlop
carlossanlop merged commit 7fa7f65 into dotnet:release/6.0Nov 29, 2022
@kouvel
kouvel deleted the TierFix6 branch November 30, 2022 18:20
@ghostghost locked as resolved and limited conversation to collaborators Dec 30, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

@kouvel@carlossanlop@noahfalk@jeffschwMSFT@davmason@mangod9