| Age | Commit message (Collapse) | Author |
|
as tracked in issue [#10895](https://github.com/RT-Thread/rt-thread/issues/10895). This leads to high maintenance costs, difficulty for new contributors, and inefficient code reviews.
Solution:
This patch adds the full, standardized documentation block to `sched_mtx_tc.c`, `sched_sem_tc.c`, `sched_thread_tc.c`, `sched_timed_mtx_tc.c` and `sched_timed_sem_tc.c` following the approved template.
The documentation details:
- Test Objectives and tested APIs
- Test Scenarios
- Verification Metrics
- Dependencies
- Test Execution command and Expected Results
This makes the test case's purpose and behavior immediately clear to future maintainers and reviewers.
Relates to [#10895](https://github.com/RT-Thread/rt-thread/issues/10895)
Signed-off-by: lhxj <[email protected]>
|
|
|
|
suspend repeatedly (#10970)
* Enhance thread suspend function with stricter checks
Refactor thread suspension logic to improve clarity and correctness.
* Clean up formatting in thread.c
Removed unnecessary blank line in thread.c.
* Refactor thread suspend state handling
Refactor thread suspension logic to improve clarity and maintainability.
* Update thread.c
* Fix indentation for RT_THREAD_SUSPEND_KILLABLE case
|
|
spinlock) #11011
|
|
Add comments for smp_thread_preemption.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Currently, the print information of this test case fails to demonstrate that
the high-priority thread has preempted the low-priority thread. This is because
when the high-priority thread prints the thread list, there is no information
about the low-priority thread (tlow), as tlow has already completed execution
and been destroyed. Therefore, the current execution logic cannot confirm the
successful completion of the preemption operation.
Solution: After the low-priority thread (tlow) releases the lock, add a busy-wait
loop while(!finish_flag);. At this point, when the high-priority thread (thigh)
prints the thread list information, tlow can be observed in the ready state, indicating
that it has been preempted by thigh.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
In smp_assigned_idle_cores_tc, the finish_flag involves atomic operations
and thus requires address alignment.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Add comments for smp_bind_affinity, And fixed some comment issues in smp_affinity_pri2_tc.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Add comments for smp_affinity_pri2
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Add comments for smp_affinity_pri1
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Signed-off-by: ChuanN-sudo <[email protected]>
|
|
|
|
|
|
for idle harts
Add explanatory comments for the utest of smp_assigned_idle_cores.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
Currently, this utest cannot determine whether threads are evenly distributed
across idle harts by observing the result of list_thread(). This is because
the presence of rt_thread_delay(5); causes all other threads to be in the
suspended state when thread information is printed. For example, if RT_CPUS_NR=4,
T0 executes list_thread() to print information, while T1~T3 are in hibernation
and thus it is impossible to observe which hart they are running on.
Solution:Here, the completion judgment condition has been modified. For example,
when RT_CPUS_NR=4, only RT_CPUS_NR-1 threads will be created (i.e., T0 to T2),
because running the utest occupies one hart. The execution is judged as completed
when finish_flag=0x0007, and the thread running the utest will call list_thread()
to print the information. Observe whether T0 to T2 are running on different
harts simultaneously.
Signed-off-by: Mengchen Teng <[email protected]>
|
|
truncation #10943
|
|
Signed-off-by: Ze-Hou <[email protected]>
|
|
Signed-off-by: Ze-Hou <[email protected]>
|
|
by improper priority configuration. (#10956)
|
|
by improper priority configuration.
|
|
mtsafe_kprint_tc #10945
|
|
|
|
Signed-off-by: Ze-Hou <[email protected]>
|
|
* [fix][utest] correct spelling of ''pref_test' to 'perf_test'
|
|
|
|
|
|
|
|
|
|
|
|
Signed-off-by: Ze-Hou <[email protected]>
|
|
Signed-off-by: Ze-Hou <[email protected]>
|
|
* [utest]: [signal]:Standardized function comment blocks have been added.
Added comments to the utest for the signal module, including: test purpose,
usage scenarios, dependency configurations, expected outcomes, and expected
behaviors.
Signed-off-by: Mengchen Teng <[email protected]>
* [utest]: [signal]:Correct issues including grammatical errors, spelling mistakes, and ambiguities in function names.
Fixed the issue of grammatical errors in words; changed the variable 'recive_sig' to 'receive_sig'.
Originally, rt_signal_unmask_test was testing the masking function of rt_signal_mask, while
rt_signal_mask_test was verifying whether signals could be sent correctly during unmasking——the
function names were exactly opposite to their functions. Now the two function names have been swapped,
and the corresponding comments have also been updated accordingly.After modification, it has been
verified that the signal-related utests can be executed correctly.
Signed-off-by: Mengchen Teng <[email protected]>
---------
Signed-off-by: Mengchen Teng <[email protected]>
|
|
* docs(utest): Add standardized documentation for core.irq (irq_tc.c)
Most test cases in `src/utest` lack standardized functional
documentation, as tracked in issue #10895. This leads to high
maintenance costs, difficulty for new contributors, and inefficient
code reviews.
Solution:
This patch adds the full, standardized documentation block to
`src/utest/irq_tc.c`, following the approved template.
The documentation details:
- Test Objectives and tested APIs
- Test Scenarios (for `irq_test` and `interrupt_test`)
- Verification Metrics (the `uassert` criteria)
- Dependencies (Kconfig options and hardware)
- Test Execution command and Expected Results
This makes the test case's purpose and behavior immediately clear
to future maintainers and reviewers.
Relates to #10895
Signed-off-by: lhxj <[email protected]>
* Update src/utest/irq_tc.c
Co-authored-by: Copilot <[email protected]>
---------
Signed-off-by: lhxj <[email protected]>
Co-authored-by: Copilot <[email protected]>
|
|
times.
|
|
|
|
|
|
|
|
Which is missed in PR #10808 "utest: unify configname", add it.
Signed-off-by: Chen Wang <[email protected]>
|
|
Use "Test" instead of "Unit Testcases" to make string shorter.
Use uppercase to make it look more eye-catching.
Signed-off-by: Chen Wang <[email protected]>
|
|
The original project display was completely flat,
now it is organized into a tree-like hierarchical
structure based on the layout of the code.
mm & tmpfs test are still keep as pervious bcos we
have not move the source for these two components.
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|
|
Signed-off-by: Chen Wang <[email protected]>
|