Csound Csound-dev Csound-tekno Search About

[Cs-dev] syncgrain.c and MAXINT

Date2009-05-03 19:00
Fromvictor
Subject[Cs-dev] syncgrain.c and MAXINT
AttachmentsNone  None  
John,
 
the change fin syncgrain.c from
 
p->count = 0xFFFFFFFF;
 
to
 
p->count = MAXINT;
 
seems to have introduced a bug in the code. Would you be able to suggest
a solution?
 
Victor

Date2009-05-04 11:10
Fromvictor
SubjectRe: [Cs-dev] syncgrain.c and MAXINT
AttachmentsNone  None  
Never mind, I found a solution.
----- Original Message -----
From: victor
Sent: Sunday, May 03, 2009 7:00 PM
Subject: [Cs-dev] syncgrain.c and MAXINT

John,
 
the change fin syncgrain.c from
 
p->count = 0xFFFFFFFF;
 
to
 
p->count = MAXINT;
 
seems to have introduced a bug in the code. Would you be able to suggest
a solution?
 
Victor


------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations
Conference from O'Reilly Media. Velocity features a full day of
expert-led, hands-on workshops and two days of sessions from industry
leaders in dedicated Performance & Operations tracks. Use code vel09scf
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf


_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Date2009-05-04 11:18
Fromjpff
SubjectRe: [Cs-dev] syncgrain.c and MAXINT
The problem is that 0xffffffff is negative on a 32bit machine but not
on 64bit.  I am sure old code is wrong but do not understand what is
happening.
  Will take another look
==John ffitch

------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2009-05-04 11:28
Fromjpff
SubjectRe: [Cs-dev] syncgrain.c and MAXINT
What do you want count to start as?

-1 (0xffffffff on 32bits)
a large number
any negative number?
UINT_MAX?
INT_MIN?

==John ffitch

------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2009-05-04 11:36
Fromvictor
SubjectRe: [Cs-dev] syncgrain.c and MAXINT
I changed the code so that count can be initialised to 0.

Victor
----- Original Message ----- 
From: "jpff" 
To: "Developer discussions" 
Cc: 
Sent: Monday, May 04, 2009 11:28 AM
Subject: Re: [Cs-dev] syncgrain.c and MAXINT


> What do you want count to start as?
>
> -1 (0xffffffff on 32bits)
> a large number
> any negative number?
> UINT_MAX?
> INT_MIN?
>
> ==John ffitch
>
> ------------------------------------------------------------------------------
> Register Now & Save for Velocity, the Web Performance & Operations
> Conference from O'Reilly Media. Velocity features a full day of
> expert-led, hands-on workshops and two days of sessions from industry
> leaders in dedicated Performance & Operations tracks. Use code vel09scf
> and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel 


------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net