wangzhijun 发表于 2022-3-22 11:28:46

无法调整应用程序中的线程优先级

使用应用时,无法调整线程优先级

root@firefly:/home/firefly/test# gcc test.c
root@firefly:/home/firefly/test# ./a.out
policy = SCHED_OTHER
Show current configuration of priority
max_priority = 0
min_priority = 0
show SCHED_FIFO of priority
max_priority = 99
min_priority = 1
show SCHED_RR of priority
max_priority = 99
min_priority = 1
show priority of current thread
priority = 0
Set thread policy
policy = UNKNOWN
set SCHED_RR policy
policy = UNKNOWN
Restore current policy
policy = UNKNOWN
Hello, world

时间的蝴蝶 发表于 2022-3-23 17:01:47

参数写错了吧,policy = UNKNOWN
页: [1]
查看完整版本: 无法调整应用程序中的线程优先级