No MIDI output on Linux, then freeze

classic Classic list List threaded Threaded
55 messages Options
123
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

No MIDI output on Linux, then freeze

Stevethefiddle
Building Audacity with
../configure --disable-dynamic-loading --with-portaudio=local --enable-debug

I'm detecting no MIDI messages when playing MIDI files.

I've tested with:
Timidity++ / ALSA / PulseAudio
QSynth / Jack
Hardware MIDI device / ALSA

These have all worked previously.

The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
when MIDI messages are sent / received. When sending MIDI messages
from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
the LEDs show that the device is receiving MIDI messages. The device
shows no messages from Audacity.

On clicking the Stop button after attempting to play a Note track,
Audacity freezes.

Steve

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle <[hidden email]> wrote:
Building Audacity with
../configure --disable-dynamic-loading --with-portaudio=local --enable-debug

I'm detecting no MIDI messages when playing MIDI files.

I've tested with:
Timidity++ / ALSA / PulseAudio
QSynth / Jack
Hardware MIDI device / ALSA

These have all worked previously.


Do I understand correctly, that this contrasts with other arguments to configure, which do work?
 
The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
when MIDI messages are sent / received. When sending MIDI messages
from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
the LEDs show that the device is receiving MIDI messages. The device
shows no messages from Audacity.

On clicking the Stop button after attempting to play a Note track,
Audacity freezes.

Can you attach a debugger, interrupt, and get a stack trace?

The tricky thing is that three threads are involved in playback, so there may be thee relevant stack traces.  Or is it even four threads now with MIDI.

PRL

 

Steve

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Stevethefiddle
On 31 July 2017 at 01:16, Paul Licameli <[hidden email]> wrote:

>
>
> On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> Building Audacity with
>> ../configure --disable-dynamic-loading --with-portaudio=local
>> --enable-debug
>>
>> I'm detecting no MIDI messages when playing MIDI files.
>>
>> I've tested with:
>> Timidity++ / ALSA / PulseAudio
>> QSynth / Jack
>> Hardware MIDI device / ALSA
>>
>> These have all worked previously.
>>
>
> Do I understand correctly, that this contrasts with other arguments to
> configure, which do work?

On 21st July I had MIDI playback working with the same build configuration.
I don't know what's changed, other than that I'm now seeing no MIDI
output no matter how hard I try.

>
>>
>> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
>> when MIDI messages are sent / received. When sending MIDI messages
>> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
>> the LEDs show that the device is receiving MIDI messages. The device
>> shows no messages from Audacity.
>>
>> On clicking the Stop button after attempting to play a Note track,
>> Audacity freezes.
>
>
> Can you attach a debugger, interrupt, and get a stack trace?

I don't know how to get debug information while Audacity is frozen.

Steve

>
> The tricky thing is that three threads are involved in playback, so there
> may be thee relevant stack traces.  Or is it even four threads now with
> MIDI.
>
> PRL
>
>
>>
>>
>> Steve
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle <[hidden email]> wrote:
On 31 July 2017 at 01:16, Paul Licameli <[hidden email]> wrote:
>
>
> On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> Building Audacity with
>> ../configure --disable-dynamic-loading --with-portaudio=local
>> --enable-debug
>>
>> I'm detecting no MIDI messages when playing MIDI files.
>>
>> I've tested with:
>> Timidity++ / ALSA / PulseAudio
>> QSynth / Jack
>> Hardware MIDI device / ALSA
>>
>> These have all worked previously.
>>
>
> Do I understand correctly, that this contrasts with other arguments to
> configure, which do work?

On 21st July I had MIDI playback working with the same build configuration.
I don't know what's changed, other than that I'm now seeing no MIDI
output no matter how hard I try.

That suggests you might find a recent commit without the problem and bisect.  Which is tedious, but this could be a show stopping problem.

But let me simplify and suggest commit 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try that one and the commit before.

PRL

 

>
>>
>> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
>> when MIDI messages are sent / received. When sending MIDI messages
>> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
>> the LEDs show that the device is receiving MIDI messages. The device
>> shows no messages from Audacity.
>>
>> On clicking the Stop button after attempting to play a Note track,
>> Audacity freezes.
>
>
> Can you attach a debugger, interrupt, and get a stack trace?

I don't know how to get debug information while Audacity is frozen.

Steve

>
> The tricky thing is that three threads are involved in playback, so there
> may be thee relevant stack traces.  Or is it even four threads now with
> MIDI.
>
> PRL
>
>
>>
>>
>> Steve
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Stevethefiddle
On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:

>
>
> On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> Building Audacity with
>> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> --enable-debug
>> >>
>> >> I'm detecting no MIDI messages when playing MIDI files.
>> >>
>> >> I've tested with:
>> >> Timidity++ / ALSA / PulseAudio
>> >> QSynth / Jack
>> >> Hardware MIDI device / ALSA
>> >>
>> >> These have all worked previously.
>> >>
>> >
>> > Do I understand correctly, that this contrasts with other arguments to
>> > configure, which do work?
>>
>> On 21st July I had MIDI playback working with the same build
>> configuration.
>> I don't know what's changed, other than that I'm now seeing no MIDI
>> output no matter how hard I try.
>
>
> That suggests you might find a recent commit without the problem and bisect.
> Which is tedious, but this could be a show stopping problem.
>
> But let me simplify and suggest commit
> 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try that
> one and the commit before.

Unfortunately I'm not now able to get MIDI playback from Audacity
working with any version of Audacity. I'm not aware of any changes to
my system that would account for this failure, though I'm thinking
that there must be one.

Steve

>
> PRL
>
>
>>
>>
>> >
>> >>
>> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
>> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
>> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> shows no messages from Audacity.
>> >>
>> >> On clicking the Stop button after attempting to play a Note track,
>> >> Audacity freezes.
>> >
>> >
>> > Can you attach a debugger, interrupt, and get a stack trace?
>>
>> I don't know how to get debug information while Audacity is frozen.
>>
>> Steve
>>
>> >
>> > The tricky thing is that three threads are involved in playback, so
>> > there
>> > may be thee relevant stack traces.  Or is it even four threads now with
>> > MIDI.
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> Steve
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Peter Sampson-2
Still working on Mac with SimpleSynth on 31Jul17 nightly.

Losing it on Linux is (more than) a bit of a blow ...

I'd like to be able to do more MIDI testing on more PCs - but
with no nightlies available I'm stymied.

Peter.

On Mon, Jul 31, 2017 at 10:02 AM, Steve the Fiddle <[hidden email]> wrote:
On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:
>
>
> On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> Building Audacity with
>> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> --enable-debug
>> >>
>> >> I'm detecting no MIDI messages when playing MIDI files.
>> >>
>> >> I've tested with:
>> >> Timidity++ / ALSA / PulseAudio
>> >> QSynth / Jack
>> >> Hardware MIDI device / ALSA
>> >>
>> >> These have all worked previously.
>> >>
>> >
>> > Do I understand correctly, that this contrasts with other arguments to
>> > configure, which do work?
>>
>> On 21st July I had MIDI playback working with the same build
>> configuration.
>> I don't know what's changed, other than that I'm now seeing no MIDI
>> output no matter how hard I try.
>
>
> That suggests you might find a recent commit without the problem and bisect.
> Which is tedious, but this could be a show stopping problem.
>
> But let me simplify and suggest commit
> 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try that
> one and the commit before.

Unfortunately I'm not now able to get MIDI playback from Audacity
working with any version of Audacity. I'm not aware of any changes to
my system that would account for this failure, though I'm thinking
that there must be one.

Steve

>
> PRL
>
>
>>
>>
>> >
>> >>
>> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
>> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
>> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> shows no messages from Audacity.
>> >>
>> >> On clicking the Stop button after attempting to play a Note track,
>> >> Audacity freezes.
>> >
>> >
>> > Can you attach a debugger, interrupt, and get a stack trace?
>>
>> I don't know how to get debug information while Audacity is frozen.
>>
>> Steve
>>
>> >
>> > The tricky thing is that three threads are involved in playback, so
>> > there
>> > may be thee relevant stack traces.  Or is it even four threads now with
>> > MIDI.
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> Steve
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli
In reply to this post by Stevethefiddle


On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle <[hidden email]> wrote:
On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:
>
>
> On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> Building Audacity with
>> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> --enable-debug
>> >>
>> >> I'm detecting no MIDI messages when playing MIDI files.
>> >>
>> >> I've tested with:
>> >> Timidity++ / ALSA / PulseAudio
>> >> QSynth / Jack
>> >> Hardware MIDI device / ALSA
>> >>
>> >> These have all worked previously.
>> >>
>> >
>> > Do I understand correctly, that this contrasts with other arguments to
>> > configure, which do work?
>>
>> On 21st July I had MIDI playback working with the same build
>> configuration.
>> I don't know what's changed, other than that I'm now seeing no MIDI
>> output no matter how hard I try.
>
>
> That suggests you might find a recent commit without the problem and bisect.
> Which is tedious, but this could be a show stopping problem.
>
> But let me simplify and suggest commit
> 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try that
> one and the commit before.

Unfortunately I'm not now able to get MIDI playback from Audacity
working with any version of Audacity. I'm not aware of any changes to
my system that would account for this failure, though I'm thinking
that there must be one.

Steve


Does the symptom of freezing after stop bisect to any recent commit?  Are you always without some error dialog to indicate the failure?

PRL

 
>
> PRL
>
>
>>
>>
>> >
>> >>
>> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to indicate
>> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the MidiMan,
>> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> shows no messages from Audacity.
>> >>
>> >> On clicking the Stop button after attempting to play a Note track,
>> >> Audacity freezes.
>> >
>> >
>> > Can you attach a debugger, interrupt, and get a stack trace?
>>
>> I don't know how to get debug information while Audacity is frozen.
>>
>> Steve
>>
>> >
>> > The tricky thing is that three threads are involved in playback, so
>> > there
>> > may be thee relevant stack traces.  Or is it even four threads now with
>> > MIDI.
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> Steve
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Stevethefiddle
On 31 July 2017 at 14:15, Paul Licameli <[hidden email]> wrote:

>
>
> On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]>
>> >> wrote:
>> >> >
>> >> >
>> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> >> > <[hidden email]>
>> >> > wrote:
>> >> >>
>> >> >> Building Audacity with
>> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> >> --enable-debug
>> >> >>
>> >> >> I'm detecting no MIDI messages when playing MIDI files.
>> >> >>
>> >> >> I've tested with:
>> >> >> Timidity++ / ALSA / PulseAudio
>> >> >> QSynth / Jack
>> >> >> Hardware MIDI device / ALSA
>> >> >>
>> >> >> These have all worked previously.
>> >> >>
>> >> >
>> >> > Do I understand correctly, that this contrasts with other arguments
>> >> > to
>> >> > configure, which do work?
>> >>
>> >> On 21st July I had MIDI playback working with the same build
>> >> configuration.
>> >> I don't know what's changed, other than that I'm now seeing no MIDI
>> >> output no matter how hard I try.
>> >
>> >
>> > That suggests you might find a recent commit without the problem and
>> > bisect.
>> > Which is tedious, but this could be a show stopping problem.
>> >
>> > But let me simplify and suggest commit
>> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try
>> > that
>> > one and the commit before.
>>
>> Unfortunately I'm not now able to get MIDI playback from Audacity
>> working with any version of Audacity. I'm not aware of any changes to
>> my system that would account for this failure, though I'm thinking
>> that there must be one.
>>
>> Steve
>>
>
> Does the symptom of freezing after stop bisect to any recent commit?  Are
> you always without some error dialog to indicate the failure?

I've done about a dozen random builds going back as far as
6d47a79d3eb2184ef96584dc7916ad80305a4d2a
and symptoms are always the same.

There is no error, just no sign of transmitted MIDI data, and a freeze
when playback of a project containing a Note track stops.
If the project contains one or more audio tracks, then the audio
track(s) can play (and stop) without problem so long as there are no
non-muted Note tracks.

Debugging is very difficult here because my IDE (kdevelop) is not able
to parse the MIDI / Note track code (this is becoming an increasing
problem with much of the new code).

Steve


>
> PRL
>
>
>>
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> >
>> >> >>
>> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
>> >> >> indicate
>> >> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
>> >> >> MidiMan,
>> >> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> >> shows no messages from Audacity.
>> >> >>
>> >> >> On clicking the Stop button after attempting to play a Note track,
>> >> >> Audacity freezes.
>> >> >
>> >> >
>> >> > Can you attach a debugger, interrupt, and get a stack trace?
>> >>
>> >> I don't know how to get debug information while Audacity is frozen.
>> >>
>> >> Steve
>> >>
>> >> >
>> >> > The tricky thing is that three threads are involved in playback, so
>> >> > there
>> >> > may be thee relevant stack traces.  Or is it even four threads now
>> >> > with
>> >> > MIDI.
>> >> >
>> >> > PRL
>> >> >
>> >> >
>> >> >>
>> >> >>
>> >> >> Steve
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >> ------------------------------------------------------------------------------
>> >> >> Check out the vibrant tech community on one of the world's most
>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> >> _______________________________________________
>> >> >> audacity-devel mailing list
>> >> >> [hidden email]
>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > ------------------------------------------------------------------------------
>> >> > Check out the vibrant tech community on one of the world's most
>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> > _______________________________________________
>> >> > audacity-devel mailing list
>> >> > [hidden email]
>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle <[hidden email]> wrote:
On 31 July 2017 at 14:15, Paul Licameli <[hidden email]> wrote:
>
>
> On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]>
>> >> wrote:
>> >> >
>> >> >
>> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> >> > <[hidden email]>
>> >> > wrote:
>> >> >>
>> >> >> Building Audacity with
>> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> >> --enable-debug
>> >> >>
>> >> >> I'm detecting no MIDI messages when playing MIDI files.
>> >> >>
>> >> >> I've tested with:
>> >> >> Timidity++ / ALSA / PulseAudio
>> >> >> QSynth / Jack
>> >> >> Hardware MIDI device / ALSA
>> >> >>
>> >> >> These have all worked previously.
>> >> >>
>> >> >
>> >> > Do I understand correctly, that this contrasts with other arguments
>> >> > to
>> >> > configure, which do work?
>> >>
>> >> On 21st July I had MIDI playback working with the same build
>> >> configuration.
>> >> I don't know what's changed, other than that I'm now seeing no MIDI
>> >> output no matter how hard I try.
>> >
>> >
>> > That suggests you might find a recent commit without the problem and
>> > bisect.
>> > Which is tedious, but this could be a show stopping problem.
>> >
>> > But let me simplify and suggest commit
>> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try
>> > that
>> > one and the commit before.
>>
>> Unfortunately I'm not now able to get MIDI playback from Audacity
>> working with any version of Audacity. I'm not aware of any changes to
>> my system that would account for this failure, though I'm thinking
>> that there must be one.
>>
>> Steve
>>
>
> Does the symptom of freezing after stop bisect to any recent commit?  Are
> you always without some error dialog to indicate the failure?

I've done about a dozen random builds going back as far as
6d47a79d3eb2184ef96584dc7916ad80305a4d2a
and symptoms are always the same.

There is no error, just no sign of transmitted MIDI data, and a freeze
when playback of a project containing a Note track stops.
If the project contains one or more audio tracks, then the audio
track(s) can play (and stop) without problem so long as there are no
non-muted Note tracks.

Debugging is very difficult here because my IDE (kdevelop) is not able
to parse the MIDI / Note track code (this is becoming an increasing
problem with much of the new code).

Steve


So of course something must have changed on your system, but we don't know what.

I speculate that some error codes from Portmidi are being ignored by AudioIO.cpp.  I might be able to figure out deductively why the code might be hanging when you stop.  I am guessing the infinite loop is here, where the main thread is waiting for another thread to make an acknowledgment that never happens:

      while (mMidiThreadFillBuffersLoopActive) {

         wxMilliSleep(1);

      }


PRL



>
> PRL
>
>
>>
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> >
>> >> >>
>> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
>> >> >> indicate
>> >> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
>> >> >> MidiMan,
>> >> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> >> shows no messages from Audacity.
>> >> >>
>> >> >> On clicking the Stop button after attempting to play a Note track,
>> >> >> Audacity freezes.
>> >> >
>> >> >
>> >> > Can you attach a debugger, interrupt, and get a stack trace?
>> >>
>> >> I don't know how to get debug information while Audacity is frozen.
>> >>
>> >> Steve
>> >>
>> >> >
>> >> > The tricky thing is that three threads are involved in playback, so
>> >> > there
>> >> > may be thee relevant stack traces.  Or is it even four threads now
>> >> > with
>> >> > MIDI.
>> >> >
>> >> > PRL
>> >> >
>> >> >
>> >> >>
>> >> >>
>> >> >> Steve
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >> ------------------------------------------------------------------------------
>> >> >> Check out the vibrant tech community on one of the world's most
>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> >> _______________________________________________
>> >> >> audacity-devel mailing list
>> >> >> [hidden email]
>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > ------------------------------------------------------------------------------
>> >> > Check out the vibrant tech community on one of the world's most
>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> > _______________________________________________
>> >> > audacity-devel mailing list
>> >> > [hidden email]
>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]> wrote:


On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle <[hidden email]> wrote:
On 31 July 2017 at 14:15, Paul Licameli <[hidden email]> wrote:
>
>
> On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle <[hidden email]>
> wrote:
>>
>> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]> wrote:
>> >
>> >
>> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]>
>> >> wrote:
>> >> >
>> >> >
>> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>> >> > <[hidden email]>
>> >> > wrote:
>> >> >>
>> >> >> Building Audacity with
>> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
>> >> >> --enable-debug
>> >> >>
>> >> >> I'm detecting no MIDI messages when playing MIDI files.
>> >> >>
>> >> >> I've tested with:
>> >> >> Timidity++ / ALSA / PulseAudio
>> >> >> QSynth / Jack
>> >> >> Hardware MIDI device / ALSA
>> >> >>
>> >> >> These have all worked previously.
>> >> >>
>> >> >
>> >> > Do I understand correctly, that this contrasts with other arguments
>> >> > to
>> >> > configure, which do work?
>> >>
>> >> On 21st July I had MIDI playback working with the same build
>> >> configuration.
>> >> I don't know what's changed, other than that I'm now seeing no MIDI
>> >> output no matter how hard I try.
>> >
>> >
>> > That suggests you might find a recent commit without the problem and
>> > bisect.
>> > Which is tedious, but this could be a show stopping problem.
>> >
>> > But let me simplify and suggest commit
>> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just try
>> > that
>> > one and the commit before.
>>
>> Unfortunately I'm not now able to get MIDI playback from Audacity
>> working with any version of Audacity. I'm not aware of any changes to
>> my system that would account for this failure, though I'm thinking
>> that there must be one.
>>
>> Steve
>>
>
> Does the symptom of freezing after stop bisect to any recent commit?  Are
> you always without some error dialog to indicate the failure?

I've done about a dozen random builds going back as far as
6d47a79d3eb2184ef96584dc7916ad80305a4d2a
and symptoms are always the same.

There is no error, just no sign of transmitted MIDI data, and a freeze
when playback of a project containing a Note track stops.
If the project contains one or more audio tracks, then the audio
track(s) can play (and stop) without problem so long as there are no
non-muted Note tracks.

Debugging is very difficult here because my IDE (kdevelop) is not able
to parse the MIDI / Note track code (this is becoming an increasing
problem with much of the new code).

Steve


So of course something must have changed on your system, but we don't know what.

I speculate that some error codes from Portmidi are being ignored by AudioIO.cpp.  I might be able to figure out deductively why the code might be hanging when you stop.  I am guessing the infinite loop is here, where the main thread is waiting for another thread to make an acknowledgment that never happens:

      while (mMidiThreadFillBuffersLoopActive) {

         wxMilliSleep(1);

      }


PRL

Can you test this hypothesis with the debugger:

When the stop button hangs, there is an infinite loop in the while() in AudioIO::FillMidiBuffers.

PRL




>
> PRL
>
>
>>
>> >
>> > PRL
>> >
>> >
>> >>
>> >>
>> >> >
>> >> >>
>> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
>> >> >> indicate
>> >> >> when MIDI messages are sent / received. When sending MIDI messages
>> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
>> >> >> MidiMan,
>> >> >> the LEDs show that the device is receiving MIDI messages. The device
>> >> >> shows no messages from Audacity.
>> >> >>
>> >> >> On clicking the Stop button after attempting to play a Note track,
>> >> >> Audacity freezes.
>> >> >
>> >> >
>> >> > Can you attach a debugger, interrupt, and get a stack trace?
>> >>
>> >> I don't know how to get debug information while Audacity is frozen.
>> >>
>> >> Steve
>> >>
>> >> >
>> >> > The tricky thing is that three threads are involved in playback, so
>> >> > there
>> >> > may be thee relevant stack traces.  Or is it even four threads now
>> >> > with
>> >> > MIDI.
>> >> >
>> >> > PRL
>> >> >
>> >> >
>> >> >>
>> >> >>
>> >> >> Steve
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >> ------------------------------------------------------------------------------
>> >> >> Check out the vibrant tech community on one of the world's most
>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> >> _______________________________________________
>> >> >> audacity-devel mailing list
>> >> >> [hidden email]
>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > ------------------------------------------------------------------------------
>> >> > Check out the vibrant tech community on one of the world's most
>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> > _______________________________________________
>> >> > audacity-devel mailing list
>> >> > [hidden email]
>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >> >
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> Check out the vibrant tech community on one of the world's most
>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> >> _______________________________________________
>> >> audacity-devel mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>> >
>> >
>> >
>> > ------------------------------------------------------------------------------
>> > Check out the vibrant tech community on one of the world's most
>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> > _______________________________________________
>> > audacity-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>> >
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> audacity-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Stevethefiddle
It looks to me like it gets stuck in the while loop in
AudioIO::StopStream() around line 2316:

#ifdef EXPERIMENTAL_MIDI_OUT
   /* Stop Midi playback */
   if ( mMidiStream ) {
      mMidiStreamActive = false;
      mMidiThreadFillBuffersLoopRunning = false; // stop output to stream
      // but output is in another thread. Wait for output to stop...
      while (mMidiThreadFillBuffersLoopActive) {
         wxMilliSleep(1);
      }

If I play a MIDI track that has fairly sparse events and I don't let
it play too long (note that it is not actually "playing" anything),
then on Stop, Audacity does not freeze. I don't fully understand the
code, but it appears that Audacity is filling buffers with MIDI data,
and if they become full because data is going in and not coming out),
then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
Audacity to get stuck in the "while" loop on Stop.

Steve

On 31 July 2017 at 20:07, Paul Licameli <[hidden email]> wrote:

>
>
> On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]>
> wrote:
>>
>>
>>
>> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
>> <[hidden email]> wrote:
>>>
>>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]> wrote:
>>> >
>>> >
>>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
>>> > <[hidden email]>
>>> > wrote:
>>> >>
>>> >> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]>
>>> >> wrote:
>>> >> >
>>> >> >
>>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
>>> >> > <[hidden email]>
>>> >> > wrote:
>>> >> >>
>>> >> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]>
>>> >> >> wrote:
>>> >> >> >
>>> >> >> >
>>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>>> >> >> > <[hidden email]>
>>> >> >> > wrote:
>>> >> >> >>
>>> >> >> >> Building Audacity with
>>> >> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
>>> >> >> >> --enable-debug
>>> >> >> >>
>>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
>>> >> >> >>
>>> >> >> >> I've tested with:
>>> >> >> >> Timidity++ / ALSA / PulseAudio
>>> >> >> >> QSynth / Jack
>>> >> >> >> Hardware MIDI device / ALSA
>>> >> >> >>
>>> >> >> >> These have all worked previously.
>>> >> >> >>
>>> >> >> >
>>> >> >> > Do I understand correctly, that this contrasts with other
>>> >> >> > arguments
>>> >> >> > to
>>> >> >> > configure, which do work?
>>> >> >>
>>> >> >> On 21st July I had MIDI playback working with the same build
>>> >> >> configuration.
>>> >> >> I don't know what's changed, other than that I'm now seeing no MIDI
>>> >> >> output no matter how hard I try.
>>> >> >
>>> >> >
>>> >> > That suggests you might find a recent commit without the problem and
>>> >> > bisect.
>>> >> > Which is tedious, but this could be a show stopping problem.
>>> >> >
>>> >> > But let me simplify and suggest commit
>>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just
>>> >> > try
>>> >> > that
>>> >> > one and the commit before.
>>> >>
>>> >> Unfortunately I'm not now able to get MIDI playback from Audacity
>>> >> working with any version of Audacity. I'm not aware of any changes to
>>> >> my system that would account for this failure, though I'm thinking
>>> >> that there must be one.
>>> >>
>>> >> Steve
>>> >>
>>> >
>>> > Does the symptom of freezing after stop bisect to any recent commit?
>>> > Are
>>> > you always without some error dialog to indicate the failure?
>>>
>>> I've done about a dozen random builds going back as far as
>>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
>>> and symptoms are always the same.
>>>
>>> There is no error, just no sign of transmitted MIDI data, and a freeze
>>> when playback of a project containing a Note track stops.
>>> If the project contains one or more audio tracks, then the audio
>>> track(s) can play (and stop) without problem so long as there are no
>>> non-muted Note tracks.
>>>
>>> Debugging is very difficult here because my IDE (kdevelop) is not able
>>> to parse the MIDI / Note track code (this is becoming an increasing
>>> problem with much of the new code).
>>>
>>> Steve
>>>
>>
>> So of course something must have changed on your system, but we don't know
>> what.
>>
>> I speculate that some error codes from Portmidi are being ignored by
>> AudioIO.cpp.  I might be able to figure out deductively why the code might
>> be hanging when you stop.  I am guessing the infinite loop is here, where
>> the main thread is waiting for another thread to make an acknowledgment that
>> never happens:
>>
>>       while (mMidiThreadFillBuffersLoopActive) {
>>
>>          wxMilliSleep(1);
>>
>>       }
>>
>>
>> PRL
>
>
> Can you test this hypothesis with the debugger:
>
> When the stop button hangs, there is an infinite loop in the while() in
> AudioIO::FillMidiBuffers.
>
> PRL
>
>>
>>
>>>
>>> >
>>> > PRL
>>> >
>>> >
>>> >>
>>> >> >
>>> >> > PRL
>>> >> >
>>> >> >
>>> >> >>
>>> >> >>
>>> >> >> >
>>> >> >> >>
>>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
>>> >> >> >> indicate
>>> >> >> >> when MIDI messages are sent / received. When sending MIDI
>>> >> >> >> messages
>>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
>>> >> >> >> MidiMan,
>>> >> >> >> the LEDs show that the device is receiving MIDI messages. The
>>> >> >> >> device
>>> >> >> >> shows no messages from Audacity.
>>> >> >> >>
>>> >> >> >> On clicking the Stop button after attempting to play a Note
>>> >> >> >> track,
>>> >> >> >> Audacity freezes.
>>> >> >> >
>>> >> >> >
>>> >> >> > Can you attach a debugger, interrupt, and get a stack trace?
>>> >> >>
>>> >> >> I don't know how to get debug information while Audacity is frozen.
>>> >> >>
>>> >> >> Steve
>>> >> >>
>>> >> >> >
>>> >> >> > The tricky thing is that three threads are involved in playback,
>>> >> >> > so
>>> >> >> > there
>>> >> >> > may be thee relevant stack traces.  Or is it even four threads
>>> >> >> > now
>>> >> >> > with
>>> >> >> > MIDI.
>>> >> >> >
>>> >> >> > PRL
>>> >> >> >
>>> >> >> >
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> Steve
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> ------------------------------------------------------------------------------
>>> >> >> >> Check out the vibrant tech community on one of the world's most
>>> >> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> >> _______________________________________________
>>> >> >> >> audacity-devel mailing list
>>> >> >> >> [hidden email]
>>> >> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> > ------------------------------------------------------------------------------
>>> >> >> > Check out the vibrant tech community on one of the world's most
>>> >> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> > _______________________________________________
>>> >> >> > audacity-devel mailing list
>>> >> >> > [hidden email]
>>> >> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >> >
>>> >> >>
>>> >> >>
>>> >> >>
>>> >> >>
>>> >> >> ------------------------------------------------------------------------------
>>> >> >> Check out the vibrant tech community on one of the world's most
>>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> _______________________________________________
>>> >> >> audacity-devel mailing list
>>> >> >> [hidden email]
>>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >
>>> >> >
>>> >> >
>>> >> >
>>> >> >
>>> >> > ------------------------------------------------------------------------------
>>> >> > Check out the vibrant tech community on one of the world's most
>>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> > _______________________________________________
>>> >> > audacity-devel mailing list
>>> >> > [hidden email]
>>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >
>>> >>
>>> >>
>>> >>
>>> >> ------------------------------------------------------------------------------
>>> >> Check out the vibrant tech community on one of the world's most
>>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> _______________________________________________
>>> >> audacity-devel mailing list
>>> >> [hidden email]
>>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >
>>> >
>>> >
>>> >
>>> > ------------------------------------------------------------------------------
>>> > Check out the vibrant tech community on one of the world's most
>>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> > _______________________________________________
>>> > audacity-devel mailing list
>>> > [hidden email]
>>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> _______________________________________________
>>> audacity-devel mailing list
>>> [hidden email]
>>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>
>>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <[hidden email]> wrote:
It looks to me like it gets stuck in the while loop in
AudioIO::StopStream() around line 2316:

#ifdef EXPERIMENTAL_MIDI_OUT
   /* Stop Midi playback */
   if ( mMidiStream ) {
      mMidiStreamActive = false;
      mMidiThreadFillBuffersLoopRunning = false; // stop output to stream
      // but output is in another thread. Wait for output to stop...
      while (mMidiThreadFillBuffersLoopActive) {
         wxMilliSleep(1);
      }

If I play a MIDI track that has fairly sparse events and I don't let
it play too long (note that it is not actually "playing" anything),
then on Stop, Audacity does not freeze. I don't fully understand the
code, but it appears that Audacity is filling buffers with MIDI data,
and if they become full because data is going in and not coming out),
then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
Audacity to get stuck in the "while" loop on Stop.

Steve

I thought that there would be an infinite loop there, in the main thread, but I also suspect that you are concurrently stuck in another infinite loop too, in another thread.  That is the while-loop in AudioIO::FillMidiBuffer().  If you find a way to confirm that guess, then single-stepping that other thread could give more clues.

I know that when you play ordinary audio, two other threads cooperate with the main thread.  (I had to figure that out to make scrubbing work.)  When you play Midi, there is a fourth thread.  MidiThread::Entry() is its main function.  That is where should mMidiThreadFillBuffersLoopActive become false.

If you fail to find evidence of the other infinite loop, then another possibility is that the writing of the flag by one thread and the reading of the flag by the other thread are not properly synchronized, despite the use of volatile in its declaration.  Perhaps a more proper solution would use wxAtomicInt or a condition variable or some such thing.

PRL

 

On 31 July 2017 at 20:07, Paul Licameli <[hidden email]> wrote:
>
>
> On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]>
> wrote:
>>
>>
>>
>> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
>> <[hidden email]> wrote:
>>>
>>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]> wrote:
>>> >
>>> >
>>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
>>> > <[hidden email]>
>>> > wrote:
>>> >>
>>> >> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]>
>>> >> wrote:
>>> >> >
>>> >> >
>>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
>>> >> > <[hidden email]>
>>> >> > wrote:
>>> >> >>
>>> >> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]>
>>> >> >> wrote:
>>> >> >> >
>>> >> >> >
>>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
>>> >> >> > <[hidden email]>
>>> >> >> > wrote:
>>> >> >> >>
>>> >> >> >> Building Audacity with
>>> >> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
>>> >> >> >> --enable-debug
>>> >> >> >>
>>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
>>> >> >> >>
>>> >> >> >> I've tested with:
>>> >> >> >> Timidity++ / ALSA / PulseAudio
>>> >> >> >> QSynth / Jack
>>> >> >> >> Hardware MIDI device / ALSA
>>> >> >> >>
>>> >> >> >> These have all worked previously.
>>> >> >> >>
>>> >> >> >
>>> >> >> > Do I understand correctly, that this contrasts with other
>>> >> >> > arguments
>>> >> >> > to
>>> >> >> > configure, which do work?
>>> >> >>
>>> >> >> On 21st July I had MIDI playback working with the same build
>>> >> >> configuration.
>>> >> >> I don't know what's changed, other than that I'm now seeing no MIDI
>>> >> >> output no matter how hard I try.
>>> >> >
>>> >> >
>>> >> > That suggests you might find a recent commit without the problem and
>>> >> > bisect.
>>> >> > Which is tedious, but this could be a show stopping problem.
>>> >> >
>>> >> > But let me simplify and suggest commit
>>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so just
>>> >> > try
>>> >> > that
>>> >> > one and the commit before.
>>> >>
>>> >> Unfortunately I'm not now able to get MIDI playback from Audacity
>>> >> working with any version of Audacity. I'm not aware of any changes to
>>> >> my system that would account for this failure, though I'm thinking
>>> >> that there must be one.
>>> >>
>>> >> Steve
>>> >>
>>> >
>>> > Does the symptom of freezing after stop bisect to any recent commit?
>>> > Are
>>> > you always without some error dialog to indicate the failure?
>>>
>>> I've done about a dozen random builds going back as far as
>>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
>>> and symptoms are always the same.
>>>
>>> There is no error, just no sign of transmitted MIDI data, and a freeze
>>> when playback of a project containing a Note track stops.
>>> If the project contains one or more audio tracks, then the audio
>>> track(s) can play (and stop) without problem so long as there are no
>>> non-muted Note tracks.
>>>
>>> Debugging is very difficult here because my IDE (kdevelop) is not able
>>> to parse the MIDI / Note track code (this is becoming an increasing
>>> problem with much of the new code).
>>>
>>> Steve
>>>
>>
>> So of course something must have changed on your system, but we don't know
>> what.
>>
>> I speculate that some error codes from Portmidi are being ignored by
>> AudioIO.cpp.  I might be able to figure out deductively why the code might
>> be hanging when you stop.  I am guessing the infinite loop is here, where
>> the main thread is waiting for another thread to make an acknowledgment that
>> never happens:
>>
>>       while (mMidiThreadFillBuffersLoopActive) {
>>
>>          wxMilliSleep(1);
>>
>>       }
>>
>>
>> PRL
>
>
> Can you test this hypothesis with the debugger:
>
> When the stop button hangs, there is an infinite loop in the while() in
> AudioIO::FillMidiBuffers.
>
> PRL
>
>>
>>
>>>
>>> >
>>> > PRL
>>> >
>>> >
>>> >>
>>> >> >
>>> >> > PRL
>>> >> >
>>> >> >
>>> >> >>
>>> >> >>
>>> >> >> >
>>> >> >> >>
>>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
>>> >> >> >> indicate
>>> >> >> >> when MIDI messages are sent / received. When sending MIDI
>>> >> >> >> messages
>>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
>>> >> >> >> MidiMan,
>>> >> >> >> the LEDs show that the device is receiving MIDI messages. The
>>> >> >> >> device
>>> >> >> >> shows no messages from Audacity.
>>> >> >> >>
>>> >> >> >> On clicking the Stop button after attempting to play a Note
>>> >> >> >> track,
>>> >> >> >> Audacity freezes.
>>> >> >> >
>>> >> >> >
>>> >> >> > Can you attach a debugger, interrupt, and get a stack trace?
>>> >> >>
>>> >> >> I don't know how to get debug information while Audacity is frozen.
>>> >> >>
>>> >> >> Steve
>>> >> >>
>>> >> >> >
>>> >> >> > The tricky thing is that three threads are involved in playback,
>>> >> >> > so
>>> >> >> > there
>>> >> >> > may be thee relevant stack traces.  Or is it even four threads
>>> >> >> > now
>>> >> >> > with
>>> >> >> > MIDI.
>>> >> >> >
>>> >> >> > PRL
>>> >> >> >
>>> >> >> >
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> Steve
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >>
>>> >> >> >> ------------------------------------------------------------------------------
>>> >> >> >> Check out the vibrant tech community on one of the world's most
>>> >> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> >> _______________________________________________
>>> >> >> >> audacity-devel mailing list
>>> >> >> >> [hidden email]
>>> >> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> >
>>> >> >> > ------------------------------------------------------------------------------
>>> >> >> > Check out the vibrant tech community on one of the world's most
>>> >> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> > _______________________________________________
>>> >> >> > audacity-devel mailing list
>>> >> >> > [hidden email]
>>> >> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >> >
>>> >> >>
>>> >> >>
>>> >> >>
>>> >> >>
>>> >> >> ------------------------------------------------------------------------------
>>> >> >> Check out the vibrant tech community on one of the world's most
>>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> >> _______________________________________________
>>> >> >> audacity-devel mailing list
>>> >> >> [hidden email]
>>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >
>>> >> >
>>> >> >
>>> >> >
>>> >> >
>>> >> > ------------------------------------------------------------------------------
>>> >> > Check out the vibrant tech community on one of the world's most
>>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> > _______________________________________________
>>> >> > audacity-devel mailing list
>>> >> > [hidden email]
>>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >> >
>>> >>
>>> >>
>>> >>
>>> >> ------------------------------------------------------------------------------
>>> >> Check out the vibrant tech community on one of the world's most
>>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> >> _______________________________________________
>>> >> audacity-devel mailing list
>>> >> [hidden email]
>>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >
>>> >
>>> >
>>> >
>>> > ------------------------------------------------------------------------------
>>> > Check out the vibrant tech community on one of the world's most
>>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> > _______________________________________________
>>> > audacity-devel mailing list
>>> > [hidden email]
>>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>> >
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> _______________________________________________
>>> audacity-devel mailing list
>>> [hidden email]
>>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>>
>>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Henric Jungheim


On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:

> On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <[hidden email]>
> wrote:
>
> > It looks to me like it gets stuck in the while loop in
> > AudioIO::StopStream() around line 2316:
> >
> > #ifdef EXPERIMENTAL_MIDI_OUT
> >    /* Stop Midi playback */
> >    if ( mMidiStream ) {
> >       mMidiStreamActive = false;
> >       mMidiThreadFillBuffersLoopRunning = false; // stop output to stream
> >       // but output is in another thread. Wait for output to stop...
> >       while (mMidiThreadFillBuffersLoopActive) {
> >          wxMilliSleep(1);
> >       }
> >
> > If I play a MIDI track that has fairly sparse events and I don't let
> > it play too long (note that it is not actually "playing" anything),
> > then on Stop, Audacity does not freeze. I don't fully understand the
> > code, but it appears that Audacity is filling buffers with MIDI data,
> > and if they become full because data is going in and not coming out),
> > then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
> > Audacity to get stuck in the "while" loop on Stop.
> >
> > Steve
> >
>
> I thought that there would be an infinite loop there, in the main thread,
> but I also suspect that you are concurrently stuck in another infinite loop
> too, in another thread.  That is the while-loop in
> AudioIO::FillMidiBuffer().  If you find a way to confirm that guess, then
> single-stepping that other thread could give more clues.
>
> I know that when you play ordinary audio, two other threads cooperate with
> the main thread.  (I had to figure that out to make scrubbing work.)  When
> you play Midi, there is a fourth thread.  MidiThread::Entry() is its main
> function.  That is where should mMidiThreadFillBuffersLoopActive become
> false.
>
> If you fail to find evidence of the other infinite loop, then another
> possibility is that the writing of the flag by one thread and the reading
> of the flag by the other thread are not properly synchronized, despite the
> use of volatile in its declaration.  Perhaps a more proper solution would
> use wxAtomicInt or a condition variable or some such thing.

Use std::atomic or wxAtomic* or something like that.  Where
possible, use higher-level synchronization primitives.

"volatile" usually doesn't do what people expect:
   https://software.intel.com/en-us/blogs/2007/11/30/volatile-almost-useless-for-multi-threaded-programming


>
> PRL
>
>
>
> >
> > On 31 July 2017 at 20:07, Paul Licameli <[hidden email]> wrote:
> > >
> > >
> > > On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]
> > >
> > > wrote:
> > >>
> > >>
> > >>
> > >> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
> > >> <[hidden email]> wrote:
> > >>>
> > >>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]>
> > wrote:
> > >>> >
> > >>> >
> > >>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
> > >>> > <[hidden email]>
> > >>> > wrote:
> > >>> >>
> > >>> >> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]>
> > >>> >> wrote:
> > >>> >> >
> > >>> >> >
> > >>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
> > >>> >> > <[hidden email]>
> > >>> >> > wrote:
> > >>> >> >>
> > >>> >> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]
> > >
> > >>> >> >> wrote:
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
> > >>> >> >> > <[hidden email]>
> > >>> >> >> > wrote:
> > >>> >> >> >>
> > >>> >> >> >> Building Audacity with
> > >>> >> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
> > >>> >> >> >> --enable-debug
> > >>> >> >> >>
> > >>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
> > >>> >> >> >>
> > >>> >> >> >> I've tested with:
> > >>> >> >> >> Timidity++ / ALSA / PulseAudio
> > >>> >> >> >> QSynth / Jack
> > >>> >> >> >> Hardware MIDI device / ALSA
> > >>> >> >> >>
> > >>> >> >> >> These have all worked previously.
> > >>> >> >> >>
> > >>> >> >> >
> > >>> >> >> > Do I understand correctly, that this contrasts with other
> > >>> >> >> > arguments
> > >>> >> >> > to
> > >>> >> >> > configure, which do work?
> > >>> >> >>
> > >>> >> >> On 21st July I had MIDI playback working with the same build
> > >>> >> >> configuration.
> > >>> >> >> I don't know what's changed, other than that I'm now seeing no
> > MIDI
> > >>> >> >> output no matter how hard I try.
> > >>> >> >
> > >>> >> >
> > >>> >> > That suggests you might find a recent commit without the problem
> > and
> > >>> >> > bisect.
> > >>> >> > Which is tedious, but this could be a show stopping problem.
> > >>> >> >
> > >>> >> > But let me simplify and suggest commit
> > >>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so
> > just
> > >>> >> > try
> > >>> >> > that
> > >>> >> > one and the commit before.
> > >>> >>
> > >>> >> Unfortunately I'm not now able to get MIDI playback from Audacity
> > >>> >> working with any version of Audacity. I'm not aware of any changes
> > to
> > >>> >> my system that would account for this failure, though I'm thinking
> > >>> >> that there must be one.
> > >>> >>
> > >>> >> Steve
> > >>> >>
> > >>> >
> > >>> > Does the symptom of freezing after stop bisect to any recent commit?
> > >>> > Are
> > >>> > you always without some error dialog to indicate the failure?
> > >>>
> > >>> I've done about a dozen random builds going back as far as
> > >>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
> > >>> and symptoms are always the same.
> > >>>
> > >>> There is no error, just no sign of transmitted MIDI data, and a freeze
> > >>> when playback of a project containing a Note track stops.
> > >>> If the project contains one or more audio tracks, then the audio
> > >>> track(s) can play (and stop) without problem so long as there are no
> > >>> non-muted Note tracks.
> > >>>
> > >>> Debugging is very difficult here because my IDE (kdevelop) is not able
> > >>> to parse the MIDI / Note track code (this is becoming an increasing
> > >>> problem with much of the new code).
> > >>>
> > >>> Steve
> > >>>
> > >>
> > >> So of course something must have changed on your system, but we don't
> > know
> > >> what.
> > >>
> > >> I speculate that some error codes from Portmidi are being ignored by
> > >> AudioIO.cpp.  I might be able to figure out deductively why the code
> > might
> > >> be hanging when you stop.  I am guessing the infinite loop is here,
> > where
> > >> the main thread is waiting for another thread to make an acknowledgment
> > that
> > >> never happens:
> > >>
> > >>       while (mMidiThreadFillBuffersLoopActive) {
> > >>
> > >>          wxMilliSleep(1);
> > >>
> > >>       }
> > >>
> > >>
> > >> PRL
> > >
> > >
> > > Can you test this hypothesis with the debugger:
> > >
> > > When the stop button hangs, there is an infinite loop in the while() in
> > > AudioIO::FillMidiBuffers.
> > >
> > > PRL
> > >
> > >>
> > >>
> > >>>
> > >>> >
> > >>> > PRL
> > >>> >
> > >>> >
> > >>> >>
> > >>> >> >
> > >>> >> > PRL
> > >>> >> >
> > >>> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
> > >>> >> >> >> indicate
> > >>> >> >> >> when MIDI messages are sent / received. When sending MIDI
> > >>> >> >> >> messages
> > >>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
> > >>> >> >> >> MidiMan,
> > >>> >> >> >> the LEDs show that the device is receiving MIDI messages. The
> > >>> >> >> >> device
> > >>> >> >> >> shows no messages from Audacity.
> > >>> >> >> >>
> > >>> >> >> >> On clicking the Stop button after attempting to play a Note
> > >>> >> >> >> track,
> > >>> >> >> >> Audacity freezes.
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > Can you attach a debugger, interrupt, and get a stack trace?
> > >>> >> >>
> > >>> >> >> I don't know how to get debug information while Audacity is
> > frozen.
> > >>> >> >>
> > >>> >> >> Steve
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> > The tricky thing is that three threads are involved in
> > playback,
> > >>> >> >> > so
> > >>> >> >> > there
> > >>> >> >> > may be thee relevant stack traces.  Or is it even four threads
> > >>> >> >> > now
> > >>> >> >> > with
> > >>> >> >> > MIDI.
> > >>> >> >> >
> > >>> >> >> > PRL
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> Steve
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> >> Check out the vibrant tech community on one of the world's
> > most
> > >>> >> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> >> _______________________________________________
> > >>> >> >> >> audacity-devel mailing list
> > >>> >> >> >> [hidden email]
> > >>> >> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> > _______________________________________________
> > >>> >> >> > audacity-devel mailing list
> > >>> >> >> > [hidden email]
> > >>> >> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> Check out the vibrant tech community on one of the world's most
> > >>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> _______________________________________________
> > >>> >> >> audacity-devel mailing list
> > >>> >> >> [hidden email]
> > >>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> > _______________________________________________
> > >>> >> > audacity-devel mailing list
> > >>> >> > [hidden email]
> > >>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >>
> > >>> >>
> > >>> >>
> > >>> >> ------------------------------------------------------------
> > ------------------
> > >>> >> Check out the vibrant tech community on one of the world's most
> > >>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> _______________________________________________
> > >>> >> audacity-devel mailing list
> > >>> >> [hidden email]
> > >>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> > ------------------------------------------------------------
> > ------------------
> > >>> > Check out the vibrant tech community on one of the world's most
> > >>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> > _______________________________________________
> > >>> > audacity-devel mailing list
> > >>> > [hidden email]
> > >>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>>
> > >>>
> > >>> ------------------------------------------------------------
> > ------------------
> > >>> Check out the vibrant tech community on one of the world's most
> > >>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> _______________________________________________
> > >>> audacity-devel mailing list
> > >>> [hidden email]
> > >>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>
> > >>
> > >
> > >
> > > ------------------------------------------------------------
> > ------------------
> > > Check out the vibrant tech community on one of the world's most
> > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > _______________________________________________
> > > audacity-devel mailing list
> > > [hidden email]
> > > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > audacity-devel mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >

> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot

> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Mon, Jul 31, 2017 at 7:38 PM, Henric Jungheim <[hidden email]> wrote:


On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:
> On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <[hidden email]>
> wrote:
>
> > It looks to me like it gets stuck in the while loop in
> > AudioIO::StopStream() around line 2316:
> >
> > #ifdef EXPERIMENTAL_MIDI_OUT
> >    /* Stop Midi playback */
> >    if ( mMidiStream ) {
> >       mMidiStreamActive = false;
> >       mMidiThreadFillBuffersLoopRunning = false; // stop output to stream
> >       // but output is in another thread. Wait for output to stop...
> >       while (mMidiThreadFillBuffersLoopActive) {
> >          wxMilliSleep(1);
> >       }
> >
> > If I play a MIDI track that has fairly sparse events and I don't let
> > it play too long (note that it is not actually "playing" anything),
> > then on Stop, Audacity does not freeze. I don't fully understand the
> > code, but it appears that Audacity is filling buffers with MIDI data,
> > and if they become full because data is going in and not coming out),
> > then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
> > Audacity to get stuck in the "while" loop on Stop.
> >
> > Steve
> >
>
> I thought that there would be an infinite loop there, in the main thread,
> but I also suspect that you are concurrently stuck in another infinite loop
> too, in another thread.  That is the while-loop in
> AudioIO::FillMidiBuffer().  If you find a way to confirm that guess, then
> single-stepping that other thread could give more clues.
>
> I know that when you play ordinary audio, two other threads cooperate with
> the main thread.  (I had to figure that out to make scrubbing work.)  When
> you play Midi, there is a fourth thread.  MidiThread::Entry() is its main
> function.  That is where should mMidiThreadFillBuffersLoopActive become
> false.
>
> If you fail to find evidence of the other infinite loop, then another
> possibility is that the writing of the flag by one thread and the reading
> of the flag by the other thread are not properly synchronized, despite the
> use of volatile in its declaration.  Perhaps a more proper solution would
> use wxAtomicInt or a condition variable or some such thing.

Use std::atomic or wxAtomic* or something like that.  Where
possible, use higher-level synchronization primitives.

"volatile" usually doesn't do what people expect:
   https://software.intel.com/en-us/blogs/2007/11/30/volatile-almost-useless-for-multi-threaded-programming


A very good article.  I am not expert in this stuff, but this summarizes it:  "Sufficient for discussion here is that volatile has nothing to do with memory fences."

It may or may not be the explanation of this bug, but we could even to the heavy-handed thing of wrapping reads and writes of that boolean with locking of a wxMutex, just to see if it cures the symptom or not.

PRL

 

>
> PRL
>
>
>
> >
> > On 31 July 2017 at 20:07, Paul Licameli <[hidden email]> wrote:
> > >
> > >
> > > On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]
> > >
> > > wrote:
> > >>
> > >>
> > >>
> > >> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
> > >> <[hidden email]> wrote:
> > >>>
> > >>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]>
> > wrote:
> > >>> >
> > >>> >
> > >>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
> > >>> > <[hidden email]>
> > >>> > wrote:
> > >>> >>
> > >>> >> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]>
> > >>> >> wrote:
> > >>> >> >
> > >>> >> >
> > >>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
> > >>> >> > <[hidden email]>
> > >>> >> > wrote:
> > >>> >> >>
> > >>> >> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]
> > >
> > >>> >> >> wrote:
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
> > >>> >> >> > <[hidden email]>
> > >>> >> >> > wrote:
> > >>> >> >> >>
> > >>> >> >> >> Building Audacity with
> > >>> >> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
> > >>> >> >> >> --enable-debug
> > >>> >> >> >>
> > >>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
> > >>> >> >> >>
> > >>> >> >> >> I've tested with:
> > >>> >> >> >> Timidity++ / ALSA / PulseAudio
> > >>> >> >> >> QSynth / Jack
> > >>> >> >> >> Hardware MIDI device / ALSA
> > >>> >> >> >>
> > >>> >> >> >> These have all worked previously.
> > >>> >> >> >>
> > >>> >> >> >
> > >>> >> >> > Do I understand correctly, that this contrasts with other
> > >>> >> >> > arguments
> > >>> >> >> > to
> > >>> >> >> > configure, which do work?
> > >>> >> >>
> > >>> >> >> On 21st July I had MIDI playback working with the same build
> > >>> >> >> configuration.
> > >>> >> >> I don't know what's changed, other than that I'm now seeing no
> > MIDI
> > >>> >> >> output no matter how hard I try.
> > >>> >> >
> > >>> >> >
> > >>> >> > That suggests you might find a recent commit without the problem
> > and
> > >>> >> > bisect.
> > >>> >> > Which is tedious, but this could be a show stopping problem.
> > >>> >> >
> > >>> >> > But let me simplify and suggest commit
> > >>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so
> > just
> > >>> >> > try
> > >>> >> > that
> > >>> >> > one and the commit before.
> > >>> >>
> > >>> >> Unfortunately I'm not now able to get MIDI playback from Audacity
> > >>> >> working with any version of Audacity. I'm not aware of any changes
> > to
> > >>> >> my system that would account for this failure, though I'm thinking
> > >>> >> that there must be one.
> > >>> >>
> > >>> >> Steve
> > >>> >>
> > >>> >
> > >>> > Does the symptom of freezing after stop bisect to any recent commit?
> > >>> > Are
> > >>> > you always without some error dialog to indicate the failure?
> > >>>
> > >>> I've done about a dozen random builds going back as far as
> > >>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
> > >>> and symptoms are always the same.
> > >>>
> > >>> There is no error, just no sign of transmitted MIDI data, and a freeze
> > >>> when playback of a project containing a Note track stops.
> > >>> If the project contains one or more audio tracks, then the audio
> > >>> track(s) can play (and stop) without problem so long as there are no
> > >>> non-muted Note tracks.
> > >>>
> > >>> Debugging is very difficult here because my IDE (kdevelop) is not able
> > >>> to parse the MIDI / Note track code (this is becoming an increasing
> > >>> problem with much of the new code).
> > >>>
> > >>> Steve
> > >>>
> > >>
> > >> So of course something must have changed on your system, but we don't
> > know
> > >> what.
> > >>
> > >> I speculate that some error codes from Portmidi are being ignored by
> > >> AudioIO.cpp.  I might be able to figure out deductively why the code
> > might
> > >> be hanging when you stop.  I am guessing the infinite loop is here,
> > where
> > >> the main thread is waiting for another thread to make an acknowledgment
> > that
> > >> never happens:
> > >>
> > >>       while (mMidiThreadFillBuffersLoopActive) {
> > >>
> > >>          wxMilliSleep(1);
> > >>
> > >>       }
> > >>
> > >>
> > >> PRL
> > >
> > >
> > > Can you test this hypothesis with the debugger:
> > >
> > > When the stop button hangs, there is an infinite loop in the while() in
> > > AudioIO::FillMidiBuffers.
> > >
> > > PRL
> > >
> > >>
> > >>
> > >>>
> > >>> >
> > >>> > PRL
> > >>> >
> > >>> >
> > >>> >>
> > >>> >> >
> > >>> >> > PRL
> > >>> >> >
> > >>> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
> > >>> >> >> >> indicate
> > >>> >> >> >> when MIDI messages are sent / received. When sending MIDI
> > >>> >> >> >> messages
> > >>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
> > >>> >> >> >> MidiMan,
> > >>> >> >> >> the LEDs show that the device is receiving MIDI messages. The
> > >>> >> >> >> device
> > >>> >> >> >> shows no messages from Audacity.
> > >>> >> >> >>
> > >>> >> >> >> On clicking the Stop button after attempting to play a Note
> > >>> >> >> >> track,
> > >>> >> >> >> Audacity freezes.
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > Can you attach a debugger, interrupt, and get a stack trace?
> > >>> >> >>
> > >>> >> >> I don't know how to get debug information while Audacity is
> > frozen.
> > >>> >> >>
> > >>> >> >> Steve
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> > The tricky thing is that three threads are involved in
> > playback,
> > >>> >> >> > so
> > >>> >> >> > there
> > >>> >> >> > may be thee relevant stack traces.  Or is it even four threads
> > >>> >> >> > now
> > >>> >> >> > with
> > >>> >> >> > MIDI.
> > >>> >> >> >
> > >>> >> >> > PRL
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> Steve
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> >> Check out the vibrant tech community on one of the world's
> > most
> > >>> >> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> >> _______________________________________________
> > >>> >> >> >> audacity-devel mailing list
> > >>> >> >> >> [hidden email]
> > >>> >> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> > _______________________________________________
> > >>> >> >> > audacity-devel mailing list
> > >>> >> >> > [hidden email]
> > >>> >> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> Check out the vibrant tech community on one of the world's most
> > >>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> _______________________________________________
> > >>> >> >> audacity-devel mailing list
> > >>> >> >> [hidden email]
> > >>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> > _______________________________________________
> > >>> >> > audacity-devel mailing list
> > >>> >> > [hidden email]
> > >>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >>
> > >>> >>
> > >>> >>
> > >>> >> ------------------------------------------------------------
> > ------------------
> > >>> >> Check out the vibrant tech community on one of the world's most
> > >>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> _______________________________________________
> > >>> >> audacity-devel mailing list
> > >>> >> [hidden email]
> > >>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> > ------------------------------------------------------------
> > ------------------
> > >>> > Check out the vibrant tech community on one of the world's most
> > >>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> > _______________________________________________
> > >>> > audacity-devel mailing list
> > >>> > [hidden email]
> > >>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>>
> > >>>
> > >>> ------------------------------------------------------------
> > ------------------
> > >>> Check out the vibrant tech community on one of the world's most
> > >>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> _______________________________________________
> > >>> audacity-devel mailing list
> > >>> [hidden email]
> > >>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>
> > >>
> > >
> > >
> > > ------------------------------------------------------------
> > ------------------
> > > Check out the vibrant tech community on one of the world's most
> > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > _______________________________________________
> > > audacity-devel mailing list
> > > [hidden email]
> > > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > audacity-devel mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >

> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot

> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Paul Licameli


On Mon, Jul 31, 2017 at 10:50 PM, Paul Licameli <[hidden email]> wrote:


On Mon, Jul 31, 2017 at 7:38 PM, Henric Jungheim <[hidden email]> wrote:


On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:
> On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <[hidden email]>
> wrote:
>
> > It looks to me like it gets stuck in the while loop in
> > AudioIO::StopStream() around line 2316:
> >
> > #ifdef EXPERIMENTAL_MIDI_OUT
> >    /* Stop Midi playback */
> >    if ( mMidiStream ) {
> >       mMidiStreamActive = false;
> >       mMidiThreadFillBuffersLoopRunning = false; // stop output to stream
> >       // but output is in another thread. Wait for output to stop...
> >       while (mMidiThreadFillBuffersLoopActive) {
> >          wxMilliSleep(1);
> >       }
> >
> > If I play a MIDI track that has fairly sparse events and I don't let
> > it play too long (note that it is not actually "playing" anything),
> > then on Stop, Audacity does not freeze. I don't fully understand the
> > code, but it appears that Audacity is filling buffers with MIDI data,
> > and if they become full because data is going in and not coming out),
> > then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
> > Audacity to get stuck in the "while" loop on Stop.
> >
> > Steve
> >
>
> I thought that there would be an infinite loop there, in the main thread,
> but I also suspect that you are concurrently stuck in another infinite loop
> too, in another thread.  That is the while-loop in
> AudioIO::FillMidiBuffer().  If you find a way to confirm that guess, then
> single-stepping that other thread could give more clues.
>
> I know that when you play ordinary audio, two other threads cooperate with
> the main thread.  (I had to figure that out to make scrubbing work.)  When
> you play Midi, there is a fourth thread.  MidiThread::Entry() is its main
> function.  That is where should mMidiThreadFillBuffersLoopActive become
> false.
>
> If you fail to find evidence of the other infinite loop, then another
> possibility is that the writing of the flag by one thread and the reading
> of the flag by the other thread are not properly synchronized, despite the
> use of volatile in its declaration.  Perhaps a more proper solution would
> use wxAtomicInt or a condition variable or some such thing.

Use std::atomic or wxAtomic* or something like that.  Where
possible, use higher-level synchronization primitives.

"volatile" usually doesn't do what people expect:
   https://software.intel.com/en-us/blogs/2007/11/30/volatile-almost-useless-for-multi-threaded-programming


A very good article.  I am not expert in this stuff, but this summarizes it:  "Sufficient for discussion here is that volatile has nothing to do with memory fences."

It may or may not be the explanation of this bug, but we could even to the heavy-handed thing of wrapping reads and writes of that boolean with locking of a wxMutex, just to see if it cures the symptom or not.

PRL


And that article was by an important architect of TBB.  Henric, do you think that library is still a good choice?  I know I toyed with the idea of using some task-based multi-threaded programming for some things like anticipatory rendering of spectrograms as the playback display scrolls.  But many other things bubble up in my priority queue.

PRL

 
 

>
> PRL
>
>
>
> >
> > On 31 July 2017 at 20:07, Paul Licameli <[hidden email]> wrote:
> > >
> > >
> > > On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <[hidden email]
> > >
> > > wrote:
> > >>
> > >>
> > >>
> > >> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
> > >> <[hidden email]> wrote:
> > >>>
> > >>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]>
> > wrote:
> > >>> >
> > >>> >
> > >>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
> > >>> > <[hidden email]>
> > >>> > wrote:
> > >>> >>
> > >>> >> On 31 July 2017 at 02:32, Paul Licameli <[hidden email]>
> > >>> >> wrote:
> > >>> >> >
> > >>> >> >
> > >>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
> > >>> >> > <[hidden email]>
> > >>> >> > wrote:
> > >>> >> >>
> > >>> >> >> On 31 July 2017 at 01:16, Paul Licameli <[hidden email]
> > >
> > >>> >> >> wrote:
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
> > >>> >> >> > <[hidden email]>
> > >>> >> >> > wrote:
> > >>> >> >> >>
> > >>> >> >> >> Building Audacity with
> > >>> >> >> >> ../configure --disable-dynamic-loading --with-portaudio=local
> > >>> >> >> >> --enable-debug
> > >>> >> >> >>
> > >>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
> > >>> >> >> >>
> > >>> >> >> >> I've tested with:
> > >>> >> >> >> Timidity++ / ALSA / PulseAudio
> > >>> >> >> >> QSynth / Jack
> > >>> >> >> >> Hardware MIDI device / ALSA
> > >>> >> >> >>
> > >>> >> >> >> These have all worked previously.
> > >>> >> >> >>
> > >>> >> >> >
> > >>> >> >> > Do I understand correctly, that this contrasts with other
> > >>> >> >> > arguments
> > >>> >> >> > to
> > >>> >> >> > configure, which do work?
> > >>> >> >>
> > >>> >> >> On 21st July I had MIDI playback working with the same build
> > >>> >> >> configuration.
> > >>> >> >> I don't know what's changed, other than that I'm now seeing no
> > MIDI
> > >>> >> >> output no matter how hard I try.
> > >>> >> >
> > >>> >> >
> > >>> >> > That suggests you might find a recent commit without the problem
> > and
> > >>> >> > bisect.
> > >>> >> > Which is tedious, but this could be a show stopping problem.
> > >>> >> >
> > >>> >> > But let me simplify and suggest commit
> > >>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect, so
> > just
> > >>> >> > try
> > >>> >> > that
> > >>> >> > one and the commit before.
> > >>> >>
> > >>> >> Unfortunately I'm not now able to get MIDI playback from Audacity
> > >>> >> working with any version of Audacity. I'm not aware of any changes
> > to
> > >>> >> my system that would account for this failure, though I'm thinking
> > >>> >> that there must be one.
> > >>> >>
> > >>> >> Steve
> > >>> >>
> > >>> >
> > >>> > Does the symptom of freezing after stop bisect to any recent commit?
> > >>> > Are
> > >>> > you always without some error dialog to indicate the failure?
> > >>>
> > >>> I've done about a dozen random builds going back as far as
> > >>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
> > >>> and symptoms are always the same.
> > >>>
> > >>> There is no error, just no sign of transmitted MIDI data, and a freeze
> > >>> when playback of a project containing a Note track stops.
> > >>> If the project contains one or more audio tracks, then the audio
> > >>> track(s) can play (and stop) without problem so long as there are no
> > >>> non-muted Note tracks.
> > >>>
> > >>> Debugging is very difficult here because my IDE (kdevelop) is not able
> > >>> to parse the MIDI / Note track code (this is becoming an increasing
> > >>> problem with much of the new code).
> > >>>
> > >>> Steve
> > >>>
> > >>
> > >> So of course something must have changed on your system, but we don't
> > know
> > >> what.
> > >>
> > >> I speculate that some error codes from Portmidi are being ignored by
> > >> AudioIO.cpp.  I might be able to figure out deductively why the code
> > might
> > >> be hanging when you stop.  I am guessing the infinite loop is here,
> > where
> > >> the main thread is waiting for another thread to make an acknowledgment
> > that
> > >> never happens:
> > >>
> > >>       while (mMidiThreadFillBuffersLoopActive) {
> > >>
> > >>          wxMilliSleep(1);
> > >>
> > >>       }
> > >>
> > >>
> > >> PRL
> > >
> > >
> > > Can you test this hypothesis with the debugger:
> > >
> > > When the stop button hangs, there is an infinite loop in the while() in
> > > AudioIO::FillMidiBuffers.
> > >
> > > PRL
> > >
> > >>
> > >>
> > >>>
> > >>> >
> > >>> > PRL
> > >>> >
> > >>> >
> > >>> >>
> > >>> >> >
> > >>> >> > PRL
> > >>> >> >
> > >>> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has LEDs to
> > >>> >> >> >> indicate
> > >>> >> >> >> when MIDI messages are sent / received. When sending MIDI
> > >>> >> >> >> messages
> > >>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html) to the
> > >>> >> >> >> MidiMan,
> > >>> >> >> >> the LEDs show that the device is receiving MIDI messages. The
> > >>> >> >> >> device
> > >>> >> >> >> shows no messages from Audacity.
> > >>> >> >> >>
> > >>> >> >> >> On clicking the Stop button after attempting to play a Note
> > >>> >> >> >> track,
> > >>> >> >> >> Audacity freezes.
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > Can you attach a debugger, interrupt, and get a stack trace?
> > >>> >> >>
> > >>> >> >> I don't know how to get debug information while Audacity is
> > frozen.
> > >>> >> >>
> > >>> >> >> Steve
> > >>> >> >>
> > >>> >> >> >
> > >>> >> >> > The tricky thing is that three threads are involved in
> > playback,
> > >>> >> >> > so
> > >>> >> >> > there
> > >>> >> >> > may be thee relevant stack traces.  Or is it even four threads
> > >>> >> >> > now
> > >>> >> >> > with
> > >>> >> >> > MIDI.
> > >>> >> >> >
> > >>> >> >> > PRL
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> Steve
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >>
> > >>> >> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> >> Check out the vibrant tech community on one of the world's
> > most
> > >>> >> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> >> _______________________________________________
> > >>> >> >> >> audacity-devel mailing list
> > >>> >> >> >> [hidden email]
> > >>> >> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> >
> > >>> >> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> > _______________________________________________
> > >>> >> >> > audacity-devel mailing list
> > >>> >> >> > [hidden email]
> > >>> >> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >> >
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >>
> > >>> >> >> ------------------------------------------------------------
> > ------------------
> > >>> >> >> Check out the vibrant tech community on one of the world's most
> > >>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> >> _______________________________________________
> > >>> >> >> audacity-devel mailing list
> > >>> >> >> [hidden email]
> > >>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> >
> > >>> >> > ------------------------------------------------------------
> > ------------------
> > >>> >> > Check out the vibrant tech community on one of the world's most
> > >>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> > _______________________________________________
> > >>> >> > audacity-devel mailing list
> > >>> >> > [hidden email]
> > >>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >> >
> > >>> >>
> > >>> >>
> > >>> >>
> > >>> >> ------------------------------------------------------------
> > ------------------
> > >>> >> Check out the vibrant tech community on one of the world's most
> > >>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> >> _______________________________________________
> > >>> >> audacity-devel mailing list
> > >>> >> [hidden email]
> > >>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>> >
> > >>> >
> > >>> >
> > >>> > ------------------------------------------------------------
> > ------------------
> > >>> > Check out the vibrant tech community on one of the world's most
> > >>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> > _______________________________________________
> > >>> > audacity-devel mailing list
> > >>> > [hidden email]
> > >>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>> >
> > >>>
> > >>>
> > >>> ------------------------------------------------------------
> > ------------------
> > >>> Check out the vibrant tech community on one of the world's most
> > >>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > >>> _______________________________________________
> > >>> audacity-devel mailing list
> > >>> [hidden email]
> > >>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >>
> > >>
> > >
> > >
> > > ------------------------------------------------------------
> > ------------------
> > > Check out the vibrant tech community on one of the world's most
> > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > > _______________________________________________
> > > audacity-devel mailing list
> > > [hidden email]
> > > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> > >
> >
> > ------------------------------------------------------------
> > ------------------
> > Check out the vibrant tech community on one of the world's most
> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> > _______________________________________________
> > audacity-devel mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >

> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot

> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
rbd
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

rbd
In reply to this post by Paul Licameli
Mutex can be dangerous too: Since MIDI processing and audio processing
are generally running at different priorities from other threads, locks
can cause priority inversion. I don't think there's a safe
cross-platform Linux/Win/OSX way to use locks to synchronize threads at
different priorities. I can explain more if this doesn't make sense. -Roger


On 7/31/17 10:50 PM, Paul Licameli wrote:
> It may or may not be the explanation of this bug, but we could even to
> the heavy-handed thing of wrapping reads and writes of that boolean
> with locking of a wxMutex, just to see if it cures the symptom or not.
>


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Henric Jungheim

Using multiple locks in an unstructured way can also easily
lead to deadlocks.  For example, thread 1 holds lock A and
is waiting for lock B to become available.  At the same
time, thread 2 holds lock B while waiting for lock A to
become available.

An analogy can be made to the movie cliche where character 1
is holding a gun on character 2 and character 2 is holding a
gun on character 1.  Neither wants to stop pointing at the
other until the other has stopped pointing the gun at them.

This is one of the first things that popped up on a web
search, but seems to be a pretty good explanation, is
concise, and is in written in terms of C++11:
   https://www.classes.cs.uchicago.edu/archive/2013/spring/12300-1/labs/lab6/

I haven't had a chance to look at the particular code in
question, but my guess is the most straight-forward fix
would involve either std::condition_variable:
   http://en.cppreference.com/w/cpp/thread/condition_variable
or (and?) std::async:
   http://en.cppreference.com/w/cpp/thread/async


On Mon, Jul 31, 2017 at 11:44:33PM -0400, Roger Dannenberg wrote:

> Mutex can be dangerous too: Since MIDI processing and audio processing
> are generally running at different priorities from other threads, locks
> can cause priority inversion. I don't think there's a safe
> cross-platform Linux/Win/OSX way to use locks to synchronize threads at
> different priorities. I can explain more if this doesn't make sense. -Roger
>
>
> On 7/31/17 10:50 PM, Paul Licameli wrote:
> > It may or may not be the explanation of this bug, but we could even to
> > the heavy-handed thing of wrapping reads and writes of that boolean
> > with locking of a wxMutex, just to see if it cures the symptom or not.
> >
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Henric Jungheim
In reply to this post by Paul Licameli
On Mon, Jul 31, 2017 at 10:56:19PM -0400, Paul Licameli wrote:

> On Mon, Jul 31, 2017 at 10:50 PM, Paul Licameli <[hidden email]>
> wrote:
>
> >
> >
> > On Mon, Jul 31, 2017 at 7:38 PM, Henric Jungheim <[hidden email]>
> > wrote:
> >
> >>
> >>
> >> On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:
> >> > On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <
> >> [hidden email]>
> >> > wrote:
> >> >
> >> > > It looks to me like it gets stuck in the while loop in
> >> > > AudioIO::StopStream() around line 2316:
> >> > >
> >> > > #ifdef EXPERIMENTAL_MIDI_OUT
> >> > >    /* Stop Midi playback */
> >> > >    if ( mMidiStream ) {
> >> > >       mMidiStreamActive = false;
> >> > >       mMidiThreadFillBuffersLoopRunning = false; // stop output to
> >> stream
> >> > >       // but output is in another thread. Wait for output to stop...
> >> > >       while (mMidiThreadFillBuffersLoopActive) {
> >> > >          wxMilliSleep(1);
> >> > >       }
> >> > >
> >> > > If I play a MIDI track that has fairly sparse events and I don't let
> >> > > it play too long (note that it is not actually "playing" anything),
> >> > > then on Stop, Audacity does not freeze. I don't fully understand the
> >> > > code, but it appears that Audacity is filling buffers with MIDI data,
> >> > > and if they become full because data is going in and not coming out),
> >> > > then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
> >> > > Audacity to get stuck in the "while" loop on Stop.
> >> > >
> >> > > Steve
> >> > >
> >> >
> >> > I thought that there would be an infinite loop there, in the main
> >> thread,
> >> > but I also suspect that you are concurrently stuck in another infinite
> >> loop
> >> > too, in another thread.  That is the while-loop in
> >> > AudioIO::FillMidiBuffer().  If you find a way to confirm that guess,
> >> then
> >> > single-stepping that other thread could give more clues.
> >> >
> >> > I know that when you play ordinary audio, two other threads cooperate
> >> with
> >> > the main thread.  (I had to figure that out to make scrubbing work.)
> >> When
> >> > you play Midi, there is a fourth thread.  MidiThread::Entry() is its
> >> main
> >> > function.  That is where should mMidiThreadFillBuffersLoopActive become
> >> > false.
> >> >
> >> > If you fail to find evidence of the other infinite loop, then another
> >> > possibility is that the writing of the flag by one thread and the
> >> reading
> >> > of the flag by the other thread are not properly synchronized, despite
> >> the
> >> > use of volatile in its declaration.  Perhaps a more proper solution
> >> would
> >> > use wxAtomicInt or a condition variable or some such thing.
> >>
> >> Use std::atomic or wxAtomic* or something like that.  Where
> >> possible, use higher-level synchronization primitives.
> >>
> >> "volatile" usually doesn't do what people expect:
> >>    https://software.intel.com/en-us/blogs/2007/11/30/
> >> volatile-almost-useless-for-multi-threaded-programming
> >>
> >>
> > A very good article.  I am not expert in this stuff, but this summarizes
> > it:  "Sufficient for discussion here is that volatile has nothing to do
> > with memory fences."
> >
> > It may or may not be the explanation of this bug, but we could even to the
> > heavy-handed thing of wrapping reads and writes of that boolean with
> > locking of a wxMutex, just to see if it cures the symptom or not.
> >
> > PRL
> >
> >
> And that article was by an important architect of TBB.  Henric, do you
> think that library is still a good choice?  I know I toyed with the idea of
> using some task-based multi-threaded programming for some things like
> anticipatory rendering of spectrograms as the playback display scrolls.
> But many other things bubble up in my priority queue.

For something that would be rendering a spectrogram in the
background, the standard C++11 thread stuff is probably
sufficient.  Making things more complicated with something
like TBB may not be warranted, at least not without trying
other things first.  Has the internal windowing/FFT/power
math been benchmarked?  How does it compare to FFTW or
Intel's IPP?

Some UI vs non-UI code refactoring may be warranted to avoid
more complexity by getting parallel math code mixed up with
the UI.  Both domains are complicated enough on their own.
("Oh, no, that case takes too long, perhaps every 4th
iteration of the computation should unlock the data for a
while to let the UI message pump get a chance to run?")

This sort of thing may become more relevant in a few months
when ARM64-based Windows PCs start showing up--should
Microsoft finally let others play with their ARM64 compiler.
(If the project feels a natively compiled Audacity is worth
the development effort compared to just letting it run as
emulated x86.)
   https://www.theregister.co.uk/2017/05/12/microsofts_windows_10_armtwist_comes_closer_with_first_demonstration/

The performance benefit of math routines tuned to the
specific CPU architecture becomes more noticeable to the end
user when the CPU itself is slower.

>
> PRL
>
>
>
> >
> >
> >>
> >> >
> >> > PRL
> >> >
> >> >
> >> >
> >> > >
> >> > > On 31 July 2017 at 20:07, Paul Licameli <[hidden email]>
> >> wrote:
> >> > > >
> >> > > >
> >> > > > On Mon, Jul 31, 2017 at 12:41 PM, Paul Licameli <
> >> [hidden email]
> >> > > >
> >> > > > wrote:
> >> > > >>
> >> > > >>
> >> > > >>
> >> > > >> On Mon, Jul 31, 2017 at 9:34 AM, Steve the Fiddle
> >> > > >> <[hidden email]> wrote:
> >> > > >>>
> >> > > >>> On 31 July 2017 at 14:15, Paul Licameli <[hidden email]>
> >> > > wrote:
> >> > > >>> >
> >> > > >>> >
> >> > > >>> > On Mon, Jul 31, 2017 at 5:02 AM, Steve the Fiddle
> >> > > >>> > <[hidden email]>
> >> > > >>> > wrote:
> >> > > >>> >>
> >> > > >>> >> On 31 July 2017 at 02:32, Paul Licameli <
> >> [hidden email]>
> >> > > >>> >> wrote:
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> > On Sun, Jul 30, 2017 at 8:54 PM, Steve the Fiddle
> >> > > >>> >> > <[hidden email]>
> >> > > >>> >> > wrote:
> >> > > >>> >> >>
> >> > > >>> >> >> On 31 July 2017 at 01:16, Paul Licameli <
> >> [hidden email]
> >> > > >
> >> > > >>> >> >> wrote:
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> > On Sun, Jul 30, 2017 at 7:04 PM, Steve the Fiddle
> >> > > >>> >> >> > <[hidden email]>
> >> > > >>> >> >> > wrote:
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> Building Audacity with
> >> > > >>> >> >> >> ../configure --disable-dynamic-loading
> >> --with-portaudio=local
> >> > > >>> >> >> >> --enable-debug
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> I'm detecting no MIDI messages when playing MIDI files.
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> I've tested with:
> >> > > >>> >> >> >> Timidity++ / ALSA / PulseAudio
> >> > > >>> >> >> >> QSynth / Jack
> >> > > >>> >> >> >> Hardware MIDI device / ALSA
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> These have all worked previously.
> >> > > >>> >> >> >>
> >> > > >>> >> >> >
> >> > > >>> >> >> > Do I understand correctly, that this contrasts with other
> >> > > >>> >> >> > arguments
> >> > > >>> >> >> > to
> >> > > >>> >> >> > configure, which do work?
> >> > > >>> >> >>
> >> > > >>> >> >> On 21st July I had MIDI playback working with the same build
> >> > > >>> >> >> configuration.
> >> > > >>> >> >> I don't know what's changed, other than that I'm now seeing
> >> no
> >> > > MIDI
> >> > > >>> >> >> output no matter how hard I try.
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> > That suggests you might find a recent commit without the
> >> problem
> >> > > and
> >> > > >>> >> > bisect.
> >> > > >>> >> > Which is tedious, but this could be a show stopping problem.
> >> > > >>> >> >
> >> > > >>> >> > But let me simplify and suggest commit
> >> > > >>> >> > 57e040070c03397ae0396e39348be6691c5f939a by me as suspect,
> >> so
> >> > > just
> >> > > >>> >> > try
> >> > > >>> >> > that
> >> > > >>> >> > one and the commit before.
> >> > > >>> >>
> >> > > >>> >> Unfortunately I'm not now able to get MIDI playback from
> >> Audacity
> >> > > >>> >> working with any version of Audacity. I'm not aware of any
> >> changes
> >> > > to
> >> > > >>> >> my system that would account for this failure, though I'm
> >> thinking
> >> > > >>> >> that there must be one.
> >> > > >>> >>
> >> > > >>> >> Steve
> >> > > >>> >>
> >> > > >>> >
> >> > > >>> > Does the symptom of freezing after stop bisect to any recent
> >> commit?
> >> > > >>> > Are
> >> > > >>> > you always without some error dialog to indicate the failure?
> >> > > >>>
> >> > > >>> I've done about a dozen random builds going back as far as
> >> > > >>> 6d47a79d3eb2184ef96584dc7916ad80305a4d2a
> >> > > >>> and symptoms are always the same.
> >> > > >>>
> >> > > >>> There is no error, just no sign of transmitted MIDI data, and a
> >> freeze
> >> > > >>> when playback of a project containing a Note track stops.
> >> > > >>> If the project contains one or more audio tracks, then the audio
> >> > > >>> track(s) can play (and stop) without problem so long as there are
> >> no
> >> > > >>> non-muted Note tracks.
> >> > > >>>
> >> > > >>> Debugging is very difficult here because my IDE (kdevelop) is not
> >> able
> >> > > >>> to parse the MIDI / Note track code (this is becoming an
> >> increasing
> >> > > >>> problem with much of the new code).
> >> > > >>>
> >> > > >>> Steve
> >> > > >>>
> >> > > >>
> >> > > >> So of course something must have changed on your system, but we
> >> don't
> >> > > know
> >> > > >> what.
> >> > > >>
> >> > > >> I speculate that some error codes from Portmidi are being ignored
> >> by
> >> > > >> AudioIO.cpp.  I might be able to figure out deductively why the
> >> code
> >> > > might
> >> > > >> be hanging when you stop.  I am guessing the infinite loop is here,
> >> > > where
> >> > > >> the main thread is waiting for another thread to make an
> >> acknowledgment
> >> > > that
> >> > > >> never happens:
> >> > > >>
> >> > > >>       while (mMidiThreadFillBuffersLoopActive) {
> >> > > >>
> >> > > >>          wxMilliSleep(1);
> >> > > >>
> >> > > >>       }
> >> > > >>
> >> > > >>
> >> > > >> PRL
> >> > > >
> >> > > >
> >> > > > Can you test this hypothesis with the debugger:
> >> > > >
> >> > > > When the stop button hangs, there is an infinite loop in the
> >> while() in
> >> > > > AudioIO::FillMidiBuffers.
> >> > > >
> >> > > > PRL
> >> > > >
> >> > > >>
> >> > > >>
> >> > > >>>
> >> > > >>> >
> >> > > >>> > PRL
> >> > > >>> >
> >> > > >>> >
> >> > > >>> >>
> >> > > >>> >> >
> >> > > >>> >> > PRL
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> >>
> >> > > >>> >> >>
> >> > > >>> >> >> >
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> The hardware MIDI device is a MidiMan MIDI4x4 and has
> >> LEDs to
> >> > > >>> >> >> >> indicate
> >> > > >>> >> >> >> when MIDI messages are sent / received. When sending MIDI
> >> > > >>> >> >> >> messages
> >> > > >>> >> >> >> from pmidi (http://www.parabola.me.uk/alsa/pmidi.html)
> >> to the
> >> > > >>> >> >> >> MidiMan,
> >> > > >>> >> >> >> the LEDs show that the device is receiving MIDI
> >> messages. The
> >> > > >>> >> >> >> device
> >> > > >>> >> >> >> shows no messages from Audacity.
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> On clicking the Stop button after attempting to play a
> >> Note
> >> > > >>> >> >> >> track,
> >> > > >>> >> >> >> Audacity freezes.
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> > Can you attach a debugger, interrupt, and get a stack
> >> trace?
> >> > > >>> >> >>
> >> > > >>> >> >> I don't know how to get debug information while Audacity is
> >> > > frozen.
> >> > > >>> >> >>
> >> > > >>> >> >> Steve
> >> > > >>> >> >>
> >> > > >>> >> >> >
> >> > > >>> >> >> > The tricky thing is that three threads are involved in
> >> > > playback,
> >> > > >>> >> >> > so
> >> > > >>> >> >> > there
> >> > > >>> >> >> > may be thee relevant stack traces.  Or is it even four
> >> threads
> >> > > >>> >> >> > now
> >> > > >>> >> >> > with
> >> > > >>> >> >> > MIDI.
> >> > > >>> >> >> >
> >> > > >>> >> >> > PRL
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> >>
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> Steve
> >> > > >>> >> >> >>
> >> > > >>> >> >> >>
> >> > > >>> >> >> >>
> >> > > >>> >> >> >>
> >> > > >>> >> >> >>
> >> > > >>> >> >> >> ------------------------------
> >> ------------------------------
> >> > > ------------------
> >> > > >>> >> >> >> Check out the vibrant tech community on one of the
> >> world's
> >> > > most
> >> > > >>> >> >> >> engaging tech sites, Slashdot.org!
> >> http://sdm.link/slashdot
> >> > > >>> >> >> >> _______________________________________________
> >> > > >>> >> >> >> audacity-devel mailing list
> >> > > >>> >> >> >> [hidden email]
> >> > > >>> >> >> >> https://lists.sourceforge.net/
> >> lists/listinfo/audacity-devel
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> >
> >> > > >>> >> >> > ------------------------------
> >> ------------------------------
> >> > > ------------------
> >> > > >>> >> >> > Check out the vibrant tech community on one of the
> >> world's most
> >> > > >>> >> >> > engaging tech sites, Slashdot.org!
> >> http://sdm.link/slashdot
> >> > > >>> >> >> > _______________________________________________
> >> > > >>> >> >> > audacity-devel mailing list
> >> > > >>> >> >> > [hidden email]
> >> > > >>> >> >> > https://lists.sourceforge.net/
> >> lists/listinfo/audacity-devel
> >> > > >>> >> >> >
> >> > > >>> >> >>
> >> > > >>> >> >>
> >> > > >>> >> >>
> >> > > >>> >> >>
> >> > > >>> >> >> ------------------------------
> >> ------------------------------
> >> > > ------------------
> >> > > >>> >> >> Check out the vibrant tech community on one of the world's
> >> most
> >> > > >>> >> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > >>> >> >> _______________________________________________
> >> > > >>> >> >> audacity-devel mailing list
> >> > > >>> >> >> [hidden email]
> >> > > >>> >> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> >
> >> > > >>> >> > ------------------------------------------------------------
> >> > > ------------------
> >> > > >>> >> > Check out the vibrant tech community on one of the world's
> >> most
> >> > > >>> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > >>> >> > _______________________________________________
> >> > > >>> >> > audacity-devel mailing list
> >> > > >>> >> > [hidden email]
> >> > > >>> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >>> >> >
> >> > > >>> >>
> >> > > >>> >>
> >> > > >>> >>
> >> > > >>> >> ------------------------------------------------------------
> >> > > ------------------
> >> > > >>> >> Check out the vibrant tech community on one of the world's most
> >> > > >>> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > >>> >> _______________________________________________
> >> > > >>> >> audacity-devel mailing list
> >> > > >>> >> [hidden email]
> >> > > >>> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >>> >
> >> > > >>> >
> >> > > >>> >
> >> > > >>> >
> >> > > >>> > ------------------------------------------------------------
> >> > > ------------------
> >> > > >>> > Check out the vibrant tech community on one of the world's most
> >> > > >>> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > >>> > _______________________________________________
> >> > > >>> > audacity-devel mailing list
> >> > > >>> > [hidden email]
> >> > > >>> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >>> >
> >> > > >>>
> >> > > >>>
> >> > > >>> ------------------------------------------------------------
> >> > > ------------------
> >> > > >>> Check out the vibrant tech community on one of the world's most
> >> > > >>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > >>> _______________________________________________
> >> > > >>> audacity-devel mailing list
> >> > > >>> [hidden email]
> >> > > >>> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >>
> >> > > >>
> >> > > >
> >> > > >
> >> > > > ------------------------------------------------------------
> >> > > ------------------
> >> > > > Check out the vibrant tech community on one of the world's most
> >> > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > > _______________________________________________
> >> > > > audacity-devel mailing list
> >> > > > [hidden email]
> >> > > > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > > >
> >> > >
> >> > > ------------------------------------------------------------
> >> > > ------------------
> >> > > Check out the vibrant tech community on one of the world's most
> >> > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> > > _______________________________________________
> >> > > audacity-devel mailing list
> >> > > [hidden email]
> >> > > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >> > >
> >>
> >> > ------------------------------------------------------------
> >> ------------------
> >> > Check out the vibrant tech community on one of the world's most
> >> > engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >>
> >> > _______________________________________________
> >> > audacity-devel mailing list
> >> > [hidden email]
> >> > https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >>
> >>
> >> ------------------------------------------------------------
> >> ------------------
> >> Check out the vibrant tech community on one of the world's most
> >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> >> _______________________________________________
> >> audacity-devel mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/audacity-devel
> >>
> >
> >

> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot

> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
rbd
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

rbd

I thought about this some more. I probably wrote this, and I think I can explain what it's doing.

This synchronization with boolean volatile variables is a very simple form of lock-free message passing (!). Before dismissing the use of volatile, yes, I read https://software.intel.com/en-us/blogs/2007/11/30/volatile-almost-useless-for-multi-threaded-programming and the points it makes are that volatile does not guarantee atomicity or memory consistency, but boolean reads and writes are atomic, so that's not a problem, and memory consistency is not a problem either (read on).

Here's the idea: Process 1 wants to make a request to Process 2 and Process 2 wants to send "done" back to Process 1.

The code is:

global request = false, done = false;
Process 1: {
    request = true;
    while (!done) sleep();
}
Process 2: {
    while (!request) sleep();
    done = true;
}

Essentially "request = true" is a message to Process 2, and "done = true" is a message to Process 1. I think this is what the code is doing: to stop MIDI playback you set mMidiStreamActive to false (sending the "I have stopped" message to the MIDIThreadFillBuffersLoop, and eventually MIDIThreadFillBuffersLoop sets MIDIThreadFillBuffersLoopActive to false (sending "I got your message" back.)

One thing that can go wrong is the compiler can optimize out setting one of these booleans (therefore not sending the "message"), but I think volatile takes care of that (a third  use of volatile unmentioned in the Intel blog), and in any case if this works *sometimes* I think it's not a compiler issue. (Do optimization settings have any affect?) The other pitfall is that the compiler could reorder the assignments since there are no explicit dependencies within the code blocks, e.g. "mMidiStreamActive = false;" could be moved after the loop. I think this is unlikely and might even be prevented by volatile, but a super safe thing to do would be put it in a function and make a function call - C compilers do not reorder function calls.

The final thing you might worry about is out-of-order writes (the "memory consistency" problem. If we did something like write a message to a buffer, then signaled another process with "ready = true" expecting the other process to read the buffer, this would be memory consistency problem because there's no guarantee the buffer writes will complete before the other process notices ready==true and reads from the buffer. But there's no memory consistency issue here because we're just sending booleans back and forth -- the boolean *is* the data, and boolean read/writes are atomic.

So what's wrong? The place to look, as noted before is at the "MIDI fill buffers" thread. It should be polling while mMidiThreadFillBuffersLoopActive is true and stopping when mMidiStreamActive becomes false. It's calling Pm_midi_write() or something like that, and if the PortMidi output buffers become full, I think it will block (!), but it should be emptying at 1000 messages per second (for hardware MIDI) and even faster otherwise. You can check if the buffer is full before doing a write, so that might be a good check to add for DEBUG mode - i.e. just print a warning if the MIDI output buffer is ever full before you try doing a write.

I'm out of ideas.

-Roger


On 8/1/17 3:43 AM, Henric Jungheim wrote:
On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:
On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <
[hidden email]>
wrote:

It looks to me like it gets stuck in the while loop in
AudioIO::StopStream() around line 2316:

#ifdef EXPERIMENTAL_MIDI_OUT
   /* Stop Midi playback */
   if ( mMidiStream ) {
      mMidiStreamActive = false;
      mMidiThreadFillBuffersLoopRunning = false; // stop output to
stream
      // but output is in another thread. Wait for output to stop...
      while (mMidiThreadFillBuffersLoopActive) {
         wxMilliSleep(1);
      }

If I play a MIDI track that has fairly sparse events and I don't let
it play too long (note that it is not actually "playing" anything),
then on Stop, Audacity does not freeze. I don't fully understand the
code, but it appears that Audacity is filling buffers with MIDI data,
and if they become full because data is going in and not coming out),
then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
Audacity to get stuck in the "while" loop on Stop.

Steve



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No MIDI output on Linux, then freeze

Stevethefiddle
On 1 August 2017 at 12:59, Roger Dannenberg <[hidden email]> wrote:

> I thought about this some more. I probably wrote this, and I think I can
> explain what it's doing.
>
> This synchronization with boolean volatile variables is a very simple form
> of lock-free message passing (!). Before dismissing the use of volatile,
> yes, I read
> https://software.intel.com/en-us/blogs/2007/11/30/volatile-almost-useless-for-multi-threaded-programming
> and the points it makes are that volatile does not guarantee atomicity or
> memory consistency, but boolean reads and writes are atomic, so that's not a
> problem, and memory consistency is not a problem either (read on).
>
> Here's the idea: Process 1 wants to make a request to Process 2 and Process
> 2 wants to send "done" back to Process 1.
>
> The code is:
>
> global request = false, done = false;
> Process 1: {
>     request = true;
>     while (!done) sleep();
> }
> Process 2: {
>     while (!request) sleep();
>     done = true;
> }
>
> Essentially "request = true" is a message to Process 2, and "done = true" is
> a message to Process 1. I think this is what the code is doing: to stop MIDI
> playback you set mMidiStreamActive to false (sending the "I have stopped"
> message to the MIDIThreadFillBuffersLoop, and eventually
> MIDIThreadFillBuffersLoop sets MIDIThreadFillBuffersLoopActive to false
> (sending "I got your message" back.)
>
> One thing that can go wrong is the compiler can optimize out setting one of
> these booleans (therefore not sending the "message"), but I think volatile
> takes care of that (a third  use of volatile unmentioned in the Intel blog),
> and in any case if this works *sometimes* I think it's not a compiler issue.
> (Do optimization settings have any affect?) The other pitfall is that the
> compiler could reorder the assignments since there are no explicit
> dependencies within the code blocks, e.g. "mMidiStreamActive = false;" could
> be moved after the loop. I think this is unlikely and might even be
> prevented by volatile, but a super safe thing to do would be put it in a
> function and make a function call - C compilers do not reorder function
> calls.
>
> The final thing you might worry about is out-of-order writes (the "memory
> consistency" problem. If we did something like write a message to a buffer,
> then signaled another process with "ready = true" expecting the other
> process to read the buffer, this would be memory consistency problem because
> there's no guarantee the buffer writes will complete before the other
> process notices ready==true and reads from the buffer. But there's no memory
> consistency issue here because we're just sending booleans back and forth --
> the boolean *is* the data, and boolean read/writes are atomic.
>
> So what's wrong? The place to look, as noted before is at the "MIDI fill
> buffers" thread. It should be polling while mMidiThreadFillBuffersLoopActive
> is true and stopping when mMidiStreamActive becomes false. It's calling
> Pm_midi_write() or something like that, and if the PortMidi output buffers
> become full, I think it will block (!),

That appears to be what is happening.
With a 'dense' MIDI file imported, I see it get up to
gAudioIO->FillMidiBuffers();
about 469 times within a second or two, and then it gets stuck at that
point and does not get past that line.

> but it should be emptying at 1000
> messages per second (for hardware MIDI) and even faster otherwise.

but whether using a hardware MIDI device that shows MIDI activity, or
a software synth, or with a software MIDI monitor, I see no MIDI
messages coming out. I can see the ALSA Port start, and I can see it
"subscribed", but that's all - no more messages beyond that point.

So it looks to me like we have two problems:
1) No messages are being sent
2) We keep trying to fill the buffer even when it's full.

> You can
> check if the buffer is full before doing a write,

Where is the buffer?
I can see that we define the size for a MIDI buffer:
#define MAX_MIDI_BUFFER_SIZE 5000
but I don't see that being used anywhere.

Steve

> so that might be a good
> check to add for DEBUG mode - i.e. just print a warning if the MIDI output
> buffer is ever full before you try doing a write.
>
> I'm out of ideas.
>
> -Roger
>
>
> On 8/1/17 3:43 AM, Henric Jungheim wrote:
>
> On Mon, Jul 31, 2017 at 07:05:50PM -0400, Paul Licameli wrote:
>
> On Mon, Jul 31, 2017 at 6:38 PM, Steve the Fiddle <
>
> [hidden email]>
>
> wrote:
>
> It looks to me like it gets stuck in the while loop in
> AudioIO::StopStream() around line 2316:
>
> #ifdef EXPERIMENTAL_MIDI_OUT
>    /* Stop Midi playback */
>    if ( mMidiStream ) {
>       mMidiStreamActive = false;
>       mMidiThreadFillBuffersLoopRunning = false; // stop output to
>
> stream
>
>       // but output is in another thread. Wait for output to stop...
>       while (mMidiThreadFillBuffersLoopActive) {
>          wxMilliSleep(1);
>       }
>
> If I play a MIDI track that has fairly sparse events and I don't let
> it play too long (note that it is not actually "playing" anything),
> then on Stop, Audacity does not freeze. I don't fully understand the
> code, but it appears that Audacity is filling buffers with MIDI data,
> and if they become full because data is going in and not coming out),
> then "mMidiThreadFillBuffersLoopActive" gets stuck as "true", causing
> Audacity to get stuck in the "while" loop on Stop.
>
> Steve
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> audacity-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/audacity-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/audacity-devel
123
Loading...