Csound Csound-dev Csound-tekno Search About

[Cs-dev] Type agnostic ring buffer

Date2013-06-22 02:06
FromAndres Cabrera
Subject[Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
Would this be possible?

Cheers,
Andrés

Date2013-06-22 09:19
FromVictor Lazzarini
SubjectRe: [Cs-dev] Type agnostic ring buffer
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
> 
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
> 
> Build for Windows Store.
> 
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2013-06-22 18:58
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Date2013-06-22 20:26
FromVictor Lazzarini
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
Well, if you want to have a go at it, be my guest.
On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




Date2013-06-24 05:58
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



Date2013-06-24 05:59
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
However, looking at the sources, I am not convinced the implementation is entirely thread safe. Wouldn't some type of barriers or atomic operations be needed in some cases?

In any case, this implementation should do and will allow for any future adjustments without the need to change the API.

Cheers,
Andrés


On Sun, Jun 23, 2013 at 9:58 PM, Andres Cabrera <mantaraya36@gmail.com> wrote:
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel




Date2013-06-24 07:44
FromJohn Lato
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
I didn't look at the sources you listed, however I'm almost certain it's not thread-safe.  The documentation says it's for a single-reader, single-writer case only.


On Mon, Jun 24, 2013 at 12:59 PM, Andres Cabrera <mantaraya36@gmail.com> wrote:
However, looking at the sources, I am not convinced the implementation is entirely thread safe. Wouldn't some type of barriers or atomic operations be needed in some cases?

In any case, this implementation should do and will allow for any future adjustments without the need to change the API.

Cheers,
Andrés


On Sun, Jun 23, 2013 at 9:58 PM, Andres Cabrera <mantaraya36@gmail.com> wrote:
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



Date2013-06-24 08:15
FromVictor Lazzarini
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
Did you need to change the internal Csound code that uses the ring buffer (in the various places)?

Victor
On 24 Jun 2013, at 05:58, Andres Cabrera wrote:

OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




Date2013-06-24 08:18
FromVictor Lazzarini
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
In that case, we should revert the code to use spinlocks. Spinlocks are not too bad, IMHO.

Victor
On 24 Jun 2013, at 07:44, John Lato wrote:

I didn't look at the sources you listed, however I'm almost certain it's not thread-safe.  The documentation says it's for a single-reader, single-writer case only.


On Mon, Jun 24, 2013 at 12:59 PM, Andres Cabrera <mantaraya36@gmail.com> wrote:
However, looking at the sources, I am not convinced the implementation is entirely thread safe. Wouldn't some type of barriers or atomic operations be needed in some cases?

In any case, this implementation should do and will allow for any future adjustments without the need to change the API.

Cheers,
Andrés


On Sun, Jun 23, 2013 at 9:58 PM, Andres Cabrera <mantaraya36@gmail.com> wrote:
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




Date2013-06-24 10:00
Fromjpff@cs.bath.ac.uk
SubjectRe: [Cs-dev] Type agnostic ring buffer
Surely one ougt to be using lock-free methods

> I didn't look at the sources you listed, however I'm almost certain it's
> not thread-safe.  The documentation says it's for a single-reader,
> single-writer case only.
>
>
> On Mon, Jun 24, 2013 at 12:59 PM, Andres Cabrera
> wrote:
>
>> However, looking at the sources, I am not convinced the implementation
>> is
>> entirely thread safe. Wouldn't some type of barriers or atomic
>> operations
>> be needed in some cases?
>>
>> In any case, this implementation should do and will allow for any future
>> adjustments without the need to change the API.
>>
>> Cheers,
>> Andrés
>>
>>
>> On Sun, Jun 23, 2013 at 9:58 PM, Andres Cabrera
>> wrote:
>>
>>> OK done :).
>>>
>>> Ring buffer should now be type agnostic (and added some test programs
>>> for
>>> it). I have changed the usage in the android sources to comply with
>>> changes, but since I don't build that, please let me know if its'
>>> working
>>> there fine or not.
>>>
>>> Cheers,
>>> Andrés
>>>
>>>
>>> On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <
>>> Victor.Lazzarini@nuim.ie> wrote:
>>>
>>>> Well, if you want to have a go at it, be my guest.
>>>>
>>>> On 22 Jun 2013, at 18:58, Andres Cabrera wrote:
>>>>
>>>> That's true, but on the other hand, if they are not done now, they
>>>> will
>>>> need to wait for Csound7...
>>>>
>>>> I have used the lock free ring buffer in port audio, and this one
>>>> allows
>>>> any type. I suspect the implementation is not so different and the
>>>> changes
>>>> might not be to large.
>>>> http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html
>>>>
>>>> Cheers,
>>>> Andres
>>>> On Jun 22, 2013 1:20 AM, "Victor Lazzarini" 
>>>> wrote:
>>>>
>>>>> It might be possible, but I am not sure. It might not be as efficient
>>>>> for audio. Since we are close to 6.00, I would not be less inclined
>>>>> to
>>>>> make big changes right now.
>>>>>
>>>>> Victor
>>>>> On 22 Jun 2013, at 02:06, Andres Cabrera wrote:
>>>>>
>>>>> > Would this be possible?
>>>>> >
>>>>> > Cheers,
>>>>> > Andrés
>>>>> >
>>>>> ------------------------------------------------------------------------------
>>>>> > This SF.net email is sponsored by Windows:
>>>>> >
>>>>> > Build for Windows Store.
>>>>> >
>>>>> >
>>>>> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
>>>>> > Csound-devel mailing list
>>>>> > Csound-devel@lists.sourceforge.net
>>>>> > https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>> Dr Victor Lazzarini
>>>>> Senior Lecturer
>>>>> Dept. of Music
>>>>> NUI Maynooth Ireland
>>>>> tel.: +353 1 708 3545
>>>>> Victor dot Lazzarini AT nuim dot ie
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> This SF.net email is sponsored by Windows:
>>>>>
>>>>> Build for Windows Store.
>>>>>
>>>>> http://p.sf.net/sfu/windows-dev2dev
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> This SF.net email is sponsored by Windows:
>>>>
>>>> Build for Windows Store.
>>>>
>>>>
>>>> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>  Dr Victor Lazzarini
>>>> Senior Lecturer
>>>> Dept. of Music
>>>> NUI Maynooth Ireland
>>>> tel.: +353 1 708 3545
>>>> Victor dot Lazzarini AT nuim dot ie
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> This SF.net email is sponsored by Windows:
>>>>
>>>> Build for Windows Store.
>>>>
>>>> http://p.sf.net/sfu/windows-dev2dev
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>
>>
>>
>> ------------------------------------------------------------------------------
>> This SF.net email is sponsored by Windows:
>>
>> Build for Windows Store.
>>
>> http://p.sf.net/sfu/windows-dev2dev
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2013-06-24 16:43
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
I only found usage in the Android sources and changed it there. Is it used anywhere else?

Cheers,
Andrés


On Mon, Jun 24, 2013 at 12:15 AM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Did you need to change the internal Csound code that uses the ring buffer (in the various places)?

Victor

On 24 Jun 2013, at 05:58, Andres Cabrera wrote:

OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



Date2013-06-24 16:44
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
Yes, lock-free but thread safe methods would be ideal, but I think it might be OK for now, since the implementation can be changed without the need for changing the API.

Cheers,
Andrés


On Mon, Jun 24, 2013 at 2:00 AM, <jpff@cs.bath.ac.uk> wrote:
Surely one ougt to be using lock-free methods

> I didn't look at the sources you listed, however I'm almost certain it's
> not thread-safe.  The documentation says it's for a single-reader,
> single-writer case only.
>
>
> On Mon, Jun 24, 2013 at 12:59 PM, Andres Cabrera
> <mantaraya36@gmail.com>wrote:
>
>> However, looking at the sources, I am not convinced the implementation
>> is
>> entirely thread safe. Wouldn't some type of barriers or atomic
>> operations
>> be needed in some cases?
>>
>> In any case, this implementation should do and will allow for any future
>> adjustments without the need to change the API.
>>
>> Cheers,
>> Andrés
>>
>>
>> On Sun, Jun 23, 2013 at 9:58 PM, Andres Cabrera
>> <mantaraya36@gmail.com>wrote:
>>
>>> OK done :).
>>>
>>> Ring buffer should now be type agnostic (and added some test programs
>>> for
>>> it). I have changed the usage in the android sources to comply with
>>> changes, but since I don't build that, please let me know if its'
>>> working
>>> there fine or not.
>>>
>>> Cheers,
>>> Andrés
>>>
>>>
>>> On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <
>>> Victor.Lazzarini@nuim.ie> wrote:
>>>
>>>> Well, if you want to have a go at it, be my guest.
>>>>
>>>> On 22 Jun 2013, at 18:58, Andres Cabrera wrote:
>>>>
>>>> That's true, but on the other hand, if they are not done now, they
>>>> will
>>>> need to wait for Csound7...
>>>>
>>>> I have used the lock free ring buffer in port audio, and this one
>>>> allows
>>>> any type. I suspect the implementation is not so different and the
>>>> changes
>>>> might not be to large.
>>>> http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html
>>>>
>>>> Cheers,
>>>> Andres
>>>> On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie>
>>>> wrote:
>>>>
>>>>> It might be possible, but I am not sure. It might not be as efficient
>>>>> for audio. Since we are close to 6.00, I would not be less inclined
>>>>> to
>>>>> make big changes right now.
>>>>>
>>>>> Victor
>>>>> On 22 Jun 2013, at 02:06, Andres Cabrera wrote:
>>>>>
>>>>> > Would this be possible?
>>>>> >
>>>>> > Cheers,
>>>>> > Andrés
>>>>> >
>>>>> ------------------------------------------------------------------------------
>>>>> > This SF.net email is sponsored by Windows:
>>>>> >
>>>>> > Build for Windows Store.
>>>>> >
>>>>> >
>>>>> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
>>>>> > Csound-devel mailing list
>>>>> > Csound-devel@lists.sourceforge.net
>>>>> > https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>> Dr Victor Lazzarini
>>>>> Senior Lecturer
>>>>> Dept. of Music
>>>>> NUI Maynooth Ireland
>>>>> tel.: +353 1 708 3545
>>>>> Victor dot Lazzarini AT nuim dot ie
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> This SF.net email is sponsored by Windows:
>>>>>
>>>>> Build for Windows Store.
>>>>>
>>>>> http://p.sf.net/sfu/windows-dev2dev
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> This SF.net email is sponsored by Windows:
>>>>
>>>> Build for Windows Store.
>>>>
>>>>
>>>> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>  Dr Victor Lazzarini
>>>> Senior Lecturer
>>>> Dept. of Music
>>>> NUI Maynooth Ireland
>>>> tel.: +353 1 708 3545
>>>> Victor dot Lazzarini AT nuim dot ie
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> This SF.net email is sponsored by Windows:
>>>>
>>>> Build for Windows Store.
>>>>
>>>> http://p.sf.net/sfu/windows-dev2dev
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>
>>
>>
>> ------------------------------------------------------------------------------
>> This SF.net email is sponsored by Windows:
>>
>> Build for Windows Store.
>>
>> http://p.sf.net/sfu/windows-dev2dev
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel


Date2013-06-26 03:05
FromMichael Gogins
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
I uninstalled the Csound6 app from my phone, rebuilt it from git head just now, and installed it again. It runs on my phone, and there is audio output, but there are staticky glitches from time to time in some of the test pieces. But I think this may have been happening before. In any event, I'm going to go over the audio driver code pretty soon.

Regards,
Mike


===========================
Michael Gogins
Irreducible Productions
http://michaelgogins.tumblr.com
Michael dot Gogins at gmail dot com


On Mon, Jun 24, 2013 at 12:58 AM, Andres Cabrera <mantaraya36@gmail.com> wrote:
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



Date2013-06-26 03:23
FromAndres Cabrera
SubjectRe: [Cs-dev] Type agnostic ring buffer
AttachmentsNone  None  
Please pull again. This should now be fixed (at least to the state it was some days ago).

Cheers,
Andrés


On Tue, Jun 25, 2013 at 7:05 PM, Michael Gogins <michael.gogins@gmail.com> wrote:
I uninstalled the Csound6 app from my phone, rebuilt it from git head just now, and installed it again. It runs on my phone, and there is audio output, but there are staticky glitches from time to time in some of the test pieces. But I think this may have been happening before. In any event, I'm going to go over the audio driver code pretty soon.

Regards,
Mike


===========================
Michael Gogins
Irreducible Productions
http://michaelgogins.tumblr.com
Michael dot Gogins at gmail dot com


On Mon, Jun 24, 2013 at 12:58 AM, Andres Cabrera <mantaraya36@gmail.com> wrote:
OK done :).

Ring buffer should now be type agnostic (and added some test programs for it). I have changed the usage in the android sources to comply with changes, but since I don't build that, please let me know if its' working there fine or not.

Cheers,
Andrés


On Sat, Jun 22, 2013 at 12:26 PM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
Well, if you want to have a go at it, be my guest.

On 22 Jun 2013, at 18:58, Andres Cabrera wrote:

That's true, but on the other hand, if they are not done now, they will need to wait for Csound7...

I have used the lock free ring buffer in port audio, and this one allows any type. I suspect the implementation is not so different and the changes might not be to large.
http://portaudio.com/docs/v19-doxydocs-dev/pa__ringbuffer_8h.html

Cheers,
Andres

On Jun 22, 2013 1:20 AM, "Victor Lazzarini" <Victor.Lazzarini@nuim.ie> wrote:
It might be possible, but I am not sure. It might not be as efficient for audio. Since we are close to 6.00, I would not be less inclined to
make big changes right now.

Victor
On 22 Jun 2013, at 02:06, Andres Cabrera wrote:

> Would this be possible?
>
> Cheers,
> Andrés
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Windows:
>
> Build for Windows Store.
>
> http://p.sf.net/sfu/windows-dev2dev_______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel