Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception when Boogie exits #733

Open
shazqadeer opened this issue May 22, 2023 · 6 comments
Open

Exception when Boogie exits #733

shazqadeer opened this issue May 22, 2023 · 6 comments

Comments

@shazqadeer
Copy link
Contributor

Recently, I have noticed that Boogie routinely crashes towards the end of processing when I run Boogie under a debugger. The typical problem is that task has exited but some state pertinent to the task is being examined. The phenomenon appears to be new. I was wondering if any of the folks who have done commits to Boogie recently may have some insights into why this is happening. I will post more information about the location of the crash next time I encounter it.

cc: @keyboardDrummer , @atomb

@keyboardDrummer
Copy link
Collaborator

keyboardDrummer commented May 25, 2023

Can you say more about the crash? Is there a particular exception?

Maybe this commit improves the problem: fcf0dde

@shazqadeer
Copy link
Contributor Author

shazqadeer commented May 25, 2023

I ran "Test/bitvectors/bv5.bpl -proverOpt:BATCH_MODE=true" on the master version of Boogie in JetBrains Rider and got an exception at this line.

System.InvalidOperationException: Cannot process request because the process (45793) has exited.
   at System.Diagnostics.Process.ThrowIfExited(Boolean refresh)
   at System.Diagnostics.Process.EnsureState(State state)
   at System.Diagnostics.Process.get_UserProcessorTime()
   at Microsoft.Boogie.SMTLib.SMTLibProcess.Close() in /Users/shaz/Source/boogie/Source/Provers/SMTLib/SMTLibProcess.cs:line 290

@atomb
Copy link
Collaborator

atomb commented May 25, 2023

That's very strange. The line at the root of that stack trace is inside a try block with catch (Exception e), so the fact that an InvalidOperationException is escaping is surprising.

@atomb
Copy link
Collaborator

atomb commented May 25, 2023

That's very strange. The line at the root of that stack trace is inside a try block with catch (Exception e), so the fact that an InvalidOperationException is escaping is surprising.

That is, the line that invokes Process.get_UserProcessorTime().

@shazqadeer
Copy link
Contributor Author

I was being inaccurate when I said in my original issue that "Boogie crashes". I really meant that I was seeing these exceptions when a process was being accessed after it had already exited. The exception seemed harmful and unintended. Is the code logic such that an exception like this is normal behavior?

@keyboardDrummer
Copy link
Collaborator

I was being inaccurate when I said in my original issue that "Boogie crashes". I really meant that I was seeing these exceptions when a process was being accessed after it had already exited. The exception seemed harmful and unintended. Is the code logic such that an exception like this is normal behavior?

I'm guessing such an exception is a bug in the dispose logic, probably harmless for users, but could be harmful during testing and it is better to resolve.

@shazqadeer shazqadeer changed the title Boogie crashes Exception when Boogie exits Aug 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants