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

thread_yield() possible to return error_number obtained from thread_i… #560

Merged
merged 1 commit into from
Sep 18, 2024

Conversation

lihuiba
Copy link
Collaborator

@lihuiba lihuiba commented Sep 14, 2024

making thread_yield() possible to return error_number obtained from thread_interrupt()

if (unlikely(th->state != states::SLEEPING)) return;
if (unlikely(th->state != states::SLEEPING)) {
out: // may have thread_yield()-ed
if (th->state != states::READY || th->error_number == 0)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it be
th->state == states::READY && th->error_number == 0?
Means thread is in READY queue and error number not set

Copy link
Collaborator

@Coldwings Coldwings left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lihuiba lihuiba merged commit e951a93 into alibaba:release/0.8 Sep 18, 2024
11 checks passed
lihuiba added a commit that referenced this pull request Sep 18, 2024
* Fix pooled stack allocator in-pool size calculation (#542)

Signed-off-by: Coldwings <coldwings@me.com>

* fix fstack-dpdk build in release/0.8 (#547)

* add fstack CI (#549)

* thread_yield() possible to return error_number obtained from thread_interrupt() (#560)

---------

Signed-off-by: Coldwings <coldwings@me.com>
Co-authored-by: Coldwings <coldwings@me.com>
Co-authored-by: Bob Chen <beef9999@qq.com>
Co-authored-by: Huiba Li <huiba.lhb@alibaba-inc.com>
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

Successfully merging this pull request may close these issues.

2 participants