Crash when using context bound scheduler

28 views
Skip to first unread message

edward

unread,
Nov 5, 2009, 12:21:40 PM11/5/09
to Relacy Race Detector
Hi,

First of all, thanks Dmitriy for creating Relacy! I've already fixed
my first bug using it. :)

So I thought that I'd try more rigorous testing by using the context
bound scheduler (instead of random). But then it immediately crashed
in scheduler.hpp, line 217 because running_thread_thread_count is 0.
Here's the code around that point:

if (1 != running_thread_count)
{
unsigned const index = this->rand
(running_thread_count, sched_type_sched);
thread_index = this->running_threads[index];
}

It's entirely possible that I'm doing something wrong though. Here's
how I run my test:

bool
runUnitTest()
{
rl::test_params params;

params.search_type = rl::fair_context_bound_scheduler_type;
return rl::simulate<ut_LockState::_RaceTest>(params);
}

Are there more parameters that I'm supposed to initialize? I tried
modifying the mutex_business_logic example to run its test in a
similar fashion and it didn't crash though.

Any ideas welcome!

Thanks,
-Edward

Dmitriy Vyukov

unread,
Nov 6, 2009, 4:43:04 AM11/6/09
to Relacy Race Detector
Edward, do you able to provide source code of the test that causes the
error? That's probably some error in the Relacy itself, however w/o
the code it's difficult to say something.

--
Dmitriy V'jukov

edward

unread,
Nov 9, 2009, 9:01:55 AM11/9/09
to Relacy Race Detector
Sorry, I'm not at liberty to do that. I was just throwing out there
just in case there was some obvious answer. If I can narrow it down
some more, I'll post my results.

Thanks,
-Edward

Dmitriy Vyukov

unread,
Nov 9, 2009, 12:09:02 PM11/9/09
to Relacy Race Detector
No, unfortunately there is no known issues with that now.
I've tried to run some complicated tests under context bound
scheduler, but was unable to model the problem.
I will appreciate if you will provide some more info on your failing
test, probably you may write separate minimal test that exposes the
problem.
Thank you.

--
Dmitriy V'jukov
Reply all
Reply to author
Forward
0 new messages