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

Any task, using libfbclient, hangs on exit. [CORE1240] #1664

Closed
firebird-automations opened this issue May 3, 2007 · 7 comments
Closed

Any task, using libfbclient, hangs on exit. [CORE1240] #1664

firebird-automations opened this issue May 3, 2007 · 7 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: @AlexPeshkoff

Is related to CORE1242

Bug was reported by Paul Beach to me privately.

Commits: 6f8fb87 0332ae8

@firebird-automations
Copy link
Collaborator Author

Commented by: @AlexPeshkoff

This bug had two reasons - first (and primary) that we relied upon some order of objects' destruction, where default_stats_group was destroyed after all other objects, which used dynamic memory allocation. But nobody actually guarantees this, and on PPC bug happened. Mutex, used in AtomicCounter, was already destroyed at a moment, when it was attempted to be used in some destructor. Exception system_call_failed happened, and here we come to the second reason.

We can't (at least using this platform) throw exceptions from memory pool, when it's mutex is locked! Compiler needs some memory to create exception, it calls new for this - and in that new that same mutex is attempted to be entered once more. Deadlock and hang.

I fixed wrong destruction order making default_stats_group permanent pointer, i.e. it will never be destoryed, but will dye together with a process. Therefore I mark this particular bug as resolved, though we must decide what to do with exceptions in memory manager.

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 2.1 Beta 1 [ 10141 ]

Fix Version: 2.0.2 [ 10130 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Link: This issue is related to CORE1242 [ CORE1242 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Workflow: jira [ 12001 ] => Firebird [ 15461 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

QA Status: No test

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Closed [ 6 ] => Closed [ 6 ]

QA Status: No test => Cannot be tested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants