Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9237959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T07:38:58+00:00 2026-06-18T07:38:58+00:00

A curious question: How does the well-known Process is terminated due to StackOverflowException screen

  • 0

A curious question:

How does the well-known “Process is terminated due to StackOverflowException” screen appear if the stack for the current process is full? Is it the runtime saving some registers for its graceful degradation or it’s an internal trick that could possibly run another temp process displaying this screen?

P.S. Knowing a possible answer to this question could help someone to build his own “graceful degradation (assuming a very limited functionality of showing such a message)” mechanism from similar critical failure situations.

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T07:38:59+00:00Added an answer on June 18, 2026 at 7:38 am

    This message is displayed by the CLR. You can see the code in the SSCLI20 distribution, clr/src/vm/eepolicy.cpp source code file:

    void DisplayStackOverflowException()
    {
        PrintToStdErrA("\n");
    
        PrintToStdErrA("Process is terminated due to StackOverflowException.\n");
    }
    

    Which in turn is called by the EEPolicy::HandleFatalStackOverflow() method. The only reason you can see it at all is because you are running a console mode app so output to stderr ends up on the console window. And you’ll only see it if Windows Error Reporting (WER) hasn’t itself terminated the app.

    There is no option to intercept this exception, the CLR cannot continue running managed code since there is too little stack space left to run any managed code safely. The line of code after the DisplayStackOverflowException() call is:

        TerminateProcess(GetCurrentProcess(), COR_E_STACKOVERFLOW);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is actually a two part question. First,does the HttpContext.Current correspond to the current
As question mention, I am very curious, why when the deserialization happen, it does
This is but a curious question. I cannot find any useful links from Google
Just a curious question but is there any programs that can help/aid you when
This is just an I am Curious question. In C#-in-depth Jon Skeet says about
This question has been asked in a C++ context but I'm curious about Java.
As the question says, I am curious if any of you know about attributes
The title is the question. I am curious to know about the importance of
This must be a stupid question, but nevertheless I find it curious: Say I
This is a really esoteric question, but I'm genuinely curious. I'm using usort for

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.