On Thu, 2010-01-07 at 15:24 -0500, Peter Harris wrote:
> On 2010-01-07 14:54, Adam Jackson wrote:
> >  void 
> > diff --git a/x11perf.c b/x11perf.c
> > index 15eb04d..410967c 100644
> > --- a/x11perf.c
> > +++ b/x11perf.c
> > @@ -38,12 +38,18 @@ SOFTWARE.
> >  #define Time_t time_t
> >  #include <stdlib.h>
> >  
> > +#include <limits.h>
> > +#include <sys/time.h>
> > +#ifndef ITIMER_REAL
> > +#define NEED_CALIBRATE
> > +#endif
> 
> My platform doesn't have a <sys/time.h>. I suspect it should be
> protected by an #ifdef ITIMER_REAL.

<sys/time.h> is where that gets defined though.  Needs to be a configure
test I guess.

> > @@ -138,6 +139,19 @@ extern int abortTest;
> >  extern void AbortTest (void);
> >  
> >  #define CheckAbort()  if (abortTest) AbortTest ()
> > +
> > +#include <stdio.h>
> > +static inline Bool CheckCancel(void)
> > +{
> > +    if (abortTest == SIGALRM) {
> > +   abortTest = 0;
> > +   return 1;
> > +    } else
> 
> My platform (Win32) doesn't have SIGALRM either. This hunk should
> probably be protected by #ifndef NEED_CALIBRATE or similar.

Noted.  I thought it did though.

> Also, "inline" is a C99ism. Should that read _X_INLINE to support C89
> compilers?

Nggh yeah I guess.  Although there's really not point to making it be
inline, it's not slow enough to affect timing.

There is a definite bug in the patch though, -repeat values greater than
1 occasionally don't run all the repetitions you ask for.  Haven't
figured that out yet, but definitely won't merge until that's fixed.

- ajax

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
xorg-devel mailing list
[email protected]
http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to