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

When does ktsan task destroy? #213

Open
zizhiyoumu-fuzz opened this issue Apr 29, 2019 · 2 comments
Open

When does ktsan task destroy? #213

zizhiyoumu-fuzz opened this issue Apr 29, 2019 · 2 comments
Labels
KTSAN KTSAN-related issues wontfix

Comments

@zizhiyoumu-fuzz
Copy link

While testing , I found sometimes ktsan task is not destroy.At this time, task state is TASK_DEAD, but not enter finish_task_switch function.After adding some log, I found during context switch, task is switch.Why?When does ktsan task destroy?

@anatol
Copy link

anatol commented May 18, 2019

The ktsan task data structures are cleaned up (destroyed) by ktsan_task_destroy function. Please check its implementation.

This function is called in finish_task_switch in case if the process is in DEAD state and its context need to be cleaned up.

Does it answer you question?

@zizhiyoumu-fuzz
Copy link
Author

The function finish_task_switch I can found.But I find that in finish_task_switch function, it's unlikely prev_state is TASK_DEAD.When I fork and exit processes frequently, the ktsan_task_destroy is slower than create, the maximum number of threads is reached。How can I deal with it?

@xairy xairy transferred this issue from google/ktsan Dec 23, 2021
@xairy xairy added the KTSAN KTSAN-related issues label Dec 23, 2021
@melver melver added the wontfix label Jan 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
KTSAN KTSAN-related issues wontfix
Projects
None yet
Development

No branches or pull requests

4 participants