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

[task] support percpu run-queue and cpu affinity for axtask #176

Merged
merged 51 commits into from
Oct 11, 2024
Merged

Conversation

hky1999
Copy link
Contributor

@hky1999 hky1999 commented Sep 20, 2024

@hky1999 hky1999 force-pushed the percpu_rq branch 4 times, most recently from 8496126 to ae26348 Compare September 23, 2024 12:10
@hky1999 hky1999 requested a review from equation314 September 28, 2024 07:14
@hky1999 hky1999 requested a review from equation314 September 30, 2024 06:02
@hky1999
Copy link
Contributor Author

hky1999 commented Oct 10, 2024

Modifications to arceos-apps: https://github.com/arceos-org/arceos-apps/pull/1/files

@hky1999 hky1999 requested a review from equation314 October 11, 2024 08:49
@hky1999 hky1999 merged commit d25a3e0 into main Oct 11, 2024
26 checks passed
@hky1999 hky1999 deleted the percpu_rq branch October 11, 2024 16:43
buhenxihuan pushed a commit to buhenxihuan/arceos that referenced this pull request Nov 13, 2024
…rg#176)

* [task] support percpu run-queue and cpu affinity for axtask

* refactor: add preempt guard for AxRunQueue through AxRunQueueRef

* refactor: use kernel_guard hold by RQ in wait_queue.rs

* feat: introduce cpumask

* [feat] add on_cpu and prev_task_on_cpu_ptr field in AxTaskInner

* fix: delete redundant kernel guard in WaitQueue wait()

* Add percpu scheduler doc

* [fix] unit test error related to doc comment

* [feat] delete cancel_alarm from timers

* Update percpu_rq

* [fix] use timer ticket id to prevent potential bug introduced by timer event confusion

* [feat] use type CpuSet to wrap cpumask::CpuMask

* [fix] use allow(clippy::modulo_one) to bypass modulo 1 error in select_run_queue_index

* [fix] miss doc for type alias CpuSet

* [fix] little modification in axtask api.rs

* [fix] some review opinions

* [fix] delete if self.on_cpu() block in unblock_locked

* [refactor] remove in_timer_list flag in axtask

* [fix] doc error in unblock_task

* [refactor] timer ticket id

* [fix] use put_prev_task in unblock_task

* [fix] pontential bug in unblock_locked, set on_cpu as true for init tasks

* [feat] enrich code comments and scheduling-related docs

* [refactor] move percpu related docs to discussions

* [fix] first round fix of review suggestions

* [refactor] add block_current in run_queue.rs

* [refactor] pass SpinNoIrqGuard to blocked_resched

* [feat] add WaitQueueGuard

* [refactor] merge unblock_task, add TaskUnblockGuard

* [fix] second round fix of review suggestions

* [fix] third round fix of review suggestions

* [refactor] use weak reference for prev task to manipulate on_cpu flag

* [feat] enable on_cpu flag only with smp feature enabled

* [fix] enable on_cpu flag only with smp feature enabled

* [fix] change the pos of NoPreemptIrqSave guard hold by rq in wait_queue.rs

* [refactor] delete unblock_locked, use atomic compare_exchange in unblock_task

* [fix] bug in wait_timeout, modify assert in blocked_resched and switch_to

* [fix] modify assert about irqs_enabled in switch_to

* [refactor] keep the guard in the loop in wait_timeout_until

* [fix] some compile warnings

* Update the commit hash for arceos-apps

* Update the commit hash for arceos-apps again

* Update the commit hash for arceos-apps again and again

* [fix] bug in wait_timeout and wait_timeout_until

* [CI] update dependencies for qemu build

* [fix] fourth round fix of review suggestions

* [fix] problems related to WAIT_FOR_EXIT in gc_entry

* [refactor] use current_ref_mut_raw to get TIMER_LIST in check_events()

* [refactor] improve notify_all in wait_queue.rs

* [refactor] delete redundant assertion in block_resched()

* [fix] some compile warnings
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.

4 participants