1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-06-26 03:11:44 +02:00

Cap the runtime for rs-race

This commit is contained in:
Arun Sharma 2010-03-10 22:57:43 -08:00
parent f8a15e9679
commit d3ddc9b96b

View file

@ -29,6 +29,15 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
#include <libunwind.h>
#include <execinfo.h>
/* ITERS=1000, NTHREAD=10 caught some bugs in the past */
#ifndef ITERS
#define ITERS 100
#endif
#ifndef NTHREAD
#define NTHREAD 2
#endif
int verbose;
void
@ -1325,7 +1334,7 @@ void *
bar(void *p)
{
int i;
for (i = 0; i < 1000; ++i) {
for (i = 0; i < ITERS; ++i) {
foo_0 ();
foo_1 ();
foo_2 ();
@ -1459,10 +1468,6 @@ bar(void *p)
return NULL;
}
#ifndef NTHREAD
#define NTHREAD 10
#endif
int doit ()
{
pthread_t tid[NTHREAD];