Summary: | [patch] sched_yield is a no-op | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | Base System | Reporter: | eric | ||||||
Component: | kern | Assignee: | freebsd-bugs (Nobody) <bugs> | ||||||
Status: | Closed FIXED | ||||||||
Severity: | Affects Some People | CC: | chris, emaste, mav | ||||||
Priority: | --- | ||||||||
Version: | 10.0-RELEASE | ||||||||
Hardware: | Any | ||||||||
OS: | Any | ||||||||
Attachments: |
|
Description
eric
2014-08-22 18:24:00 UTC
Created attachment 146162 [details]
test case
sched_4bsd.c would need a similar change. A commit references this bug: Author: mav Date: Sat Aug 23 17:31:56 UTC 2014 New revision: 270423 URL: http://svnweb.freebsd.org/changeset/base/270423 Log: Restore pre-r239157 handling of sched_yield(), when thread time slice was aborted, allowing other threads to run. Without this change thread is just rescheduled again, that was illustrated by provided test tool. PR: 192926 Submitted by: eric@vangyzen.net MFC after: 2 weeks Changes: head/sys/kern/sched_4bsd.c head/sys/kern/sched_ule.c I've confirmed the issue with provided test tool, and committed the proposed patch and its SCHED_4BSD counterpart to FreeBSD HEAD branch. A commit references this bug: Author: mav Date: Sat Sep 6 15:26:39 UTC 2014 New revision: 271194 URL: http://svnweb.freebsd.org/changeset/base/271194 Log: MFC r270423: Restore pre-r239157 handling of sched_yield(), when thread time slice was aborted, allowing other threads to run. Without this change thread is just rescheduled again, that was illustrated by provided test tool. PR: 192926 Submitted by: eric@vangyzen.net Approved by: re (marius) Changes: _U stable/10/ stable/10/sys/kern/sched_4bsd.c stable/10/sys/kern/sched_ule.c A commit references this bug: Author: mav Date: Sat Sep 6 15:30:58 UTC 2014 New revision: 271195 URL: http://svnweb.freebsd.org/changeset/base/271195 Log: MFC r270423: Restore pre-r239157 handling of sched_yield(), when thread time slice was aborted, allowing other threads to run. Without this change thread is just rescheduled again, that was illustrated by provided test tool. PR: 192926 Submitted by: eric@vangyzen.net Changes: _U stable/9/ _U stable/9/sys/ stable/9/sys/kern/sched_4bsd.c stable/9/sys/kern/sched_ule.c |