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

Test "YieldTasks" fails on CPUs with more than 8 physical threads #7

Open
jkunstwald opened this issue Jun 2, 2019 · 1 comment
Open
Assignees

Comments

@jkunstwald
Copy link

In SimpleTests.cpp, line 192, this vector is declared:

MT::StaticVector<YieldTask, 512> tasks;

which is then filled with taskCount elements. On CPUs with many threads, taskCount easily exceeds 512, it is 900 with 16 threads for example.

Subsequently if raising that limit to a "safe" maximum, like 2048, line 206 has to be adjusted as well to pass taskCount instead of tasks.Size() to RunAsync:

scheduler.RunAsync(MT::TaskGroup::Default(), tasks.Begin(), (uint32)taskCount);

Sadly the test fails on my CPU even after this fix at the check in line 163:

CHECK_EQUAL(TASK_COUNT_PER_WORKER, state1->counterPhase0);

Where TASK_COUNT_PER_WORKER is 60, but state1->counterPhase0 is 0.

System:
Win10 1809
VS19 Toolset v142
Ryzen 2700X

@SergeyMakeev
Copy link
Owner

Thank you for this feedback. I'll take a look at this and I hope I'll make a fix soon.

@SergeyMakeev SergeyMakeev self-assigned this Jul 5, 2019
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

No branches or pull requests

2 participants