Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Triple_Oscillator user-defined waveform selection during playback causes segfault. #2833

Closed
mikobuntu opened this issue Jun 9, 2016 · 3 comments
Assignees
Labels

Comments

@mikobuntu
Copy link
Contributor

mikobuntu commented Jun 9, 2016

Running the current master branch on Ubuntu 16.04 ( 64bit )

  • Steps to reproduce
  1. Open a new song.
  2. Add a few notes into the default Triple_Osc Piano roll.
  3. Start by pressing play in the piano roll ( playback will loop now as desired ).
  4. Select the +icon in Triple_Osc ( "use a user-defined waveform for current oscillator" ).
  5. Select any one of the default .flac files. << crash occurs
  • note that this only seems to happen during playback.
  • The bug is not specific to .flac files, crashes with .wav and .ogg also.
@Spekular
Copy link
Member

Spekular commented Jun 9, 2016

Can't reproduce in RC1 on Win 7.

Might have reproduced it. Spammed tons of notes, didn't happen. Set temp to 999, still no crash. Duplicated the Triple Oscillator ten times, then it worked.

i5-4590 with LMMS on an SSD, that might affect it?

@mikobuntu
Copy link
Contributor Author

@Spekular Interesting, I have now found that it wont crash on every single occasion the way it seemed to when I 1st reported the issue. Can you stress test it a bit further by double clicking fast on different .flac files and re-choosing the +icon to search again and report back. thanks :)

@Umcaruje Umcaruje added the bug label Jun 9, 2016
@Umcaruje
Copy link
Member

Umcaruje commented Jun 9, 2016

It took me about 10 or more waveform changes to reproduce this, but it happens on freshly built master, elementary OS Freya x64.

bt full:

Program received signal SIGFPE, Arithmetic exception.
[Switching to Thread 0x7fffa6624700 (LWP 15299)]
0x000000000050326b in SampleBuffer::userWaveSample (this=0x7fffeaf07520, _sample=2,77099609)
    at /home/kapilar/github/lmms/include/SampleBuffer.h:247
247         f_cnt_t f1 = static_cast<f_cnt_t>( frame ) % m_frames;
(gdb) bt full
#0  0x000000000050326b in SampleBuffer::userWaveSample (this=0x7fffeaf07520, _sample=2,77099609)
    at /home/kapilar/github/lmms/include/SampleBuffer.h:247
        frame = 0
        f1 = 5140224
#1  0x000000000052b84e in Oscillator::userWaveSample (this=0x7fffeaf14560, _sample=2,77099609)
    at /home/kapilar/github/lmms/include/Oscillator.h:153
No locals.
#2  0x000000000052bb10 in Oscillator::getSample<(Oscillator::WaveShapes)7> (this=0x7fffeaf14560, 
    _sample=2,77099609) at /home/kapilar/github/lmms/src/core/Oscillator.cpp:548
No locals.
#3  0x000000000052da02 in Oscillator::updateMix<(Oscillator::WaveShapes)7> (this=0x7fffeaf14560, 
    _ab=0x7fffeaefe8a0, _frames=256, _chnl=0 '\000')
    at /home/kapilar/github/lmms/src/core/Oscillator.cpp:420
        frame = 0
        osc_coeff = 0,00997732393
#4  0x000000000052b4a1 in Oscillator::updateMix (this=0x7fffeaf14560, _ab=0x7fffeaefe8a0, 
    _frames=256, _chnl=0 '\000') at /home/kapilar/github/lmms/src/core/Oscillator.cpp:230
No locals.
#5  0x000000000052af91 in Oscillator::update (this=0x7fffeaf14560, _ab=0x7fffeaefe8a0, _frames=256, 
    _chnl=0 '\000') at /home/kapilar/github/lmms/src/core/Oscillator.cpp:76
No locals.
---Type <return> to continue, or q <return> to quit---
#6  0x00007fffc021b957 in TripleOscillator::playNote (this=0x7fffeaf06da0, _n=0x7fffeadfcf18, 
    _working_buffer=0x7fffeaefe8a0)
    at /home/kapilar/github/lmms/plugins/triple_oscillator/TripleOscillator.cpp:363
        osc_l = 0x7fffeaf14560
        osc_r = 0x7fffeaf145e0
        frames = 256
        offset = 0
#7  0x00000000006088b4 in InstrumentTrack::playNote (this=0x7fffeaf04960, n=0x7fffeadfcf18, 
    workingBuffer=0x7fffeaefe8a0) at /home/kapilar/github/lmms/src/tracks/InstrumentTrack.cpp:468
No locals.

#8  0x0000000000528bde in NotePlayHandle::play (this=0x7fffeadfcf18, _working_buffer=0x7fffeaefe8a0)
    at /home/kapilar/github/lmms/src/core/NotePlayHandle.cpp:249
        framesThisPeriod = 256
#9  0x0000000000530706 in PlayHandle::doProcessing (this=0x7fffeadfcf18)
    at /home/kapilar/github/lmms/src/core/PlayHandle.cpp:49
No locals.
#10 0x000000000050e539 in ThreadableJob::process (this=0x7fffeadfcf18)
    at /home/kapilar/github/lmms/include/ThreadableJob.h:74
No locals.
#11 0x0000000000524f9f in MixerWorkerThread::JobQueue::run (
    this=0x936120 <MixerWorkerThread::globalJobQueue>)
---Type <return> to continue, or q <return> to quit---
    at /home/kapilar/github/lmms/src/core/MixerWorkerThread.cpp:75
        job = 0x7fffeadfcf18
        i = 0
        processedJob = false
#12 0x00000000005251f9 in MixerWorkerThread::startAndWaitForJobs ()
    at /home/kapilar/github/lmms/src/core/MixerWorkerThread.cpp:148
No locals.
#13 0x0000000000520009 in Mixer::renderNextBuffer (this=0xdd48b0)
    at /home/kapilar/github/lmms/src/core/Mixer.cpp:408
        playModeSupportsMetronome = true
        it_rem = {i = 0x7fff9c001d78}
        fxMixer = 0xde05b0
        last_metro_pos = {<MidiTime> = {m_ticks = -1, static s_ticksPerTact = 192}, 
          m_timeLine = 0x0, m_currentFrame = 0}
        song = 0xddc550
        currentPlayMode = Song::Mode_PlayPattern
        p = {<MidiTime> = {m_ticks = 3, static s_ticksPerTact = 192}, m_timeLine = 0x156ac80, 
          m_currentFrame = 98,75}
#14 0x0000000000521941 in Mixer::fifoWriter::run (this=0x1120bd0)
    at /home/kapilar/github/lmms/src/core/Mixer.cpp:1014
        buffer = 0x7fff9c004340
---Type <return> to continue, or q <return> to quit---
        b = 0xdda180
        frames = 256
#15 0x00007ffff685c6ff in ?? () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#16 0x00007ffff7bc4182 in start_thread (arg=0x7fffa6624700) at pthread_create.c:312
        __res = <optimized out>
        pd = 0x7fffa6624700
        now = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140735984846592, -5804813317956107613, 1, 0, 
                140735984847296, 140735984846592, 5804688907824333475, 5804795164289335971}, 
              mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, 
              cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
        pagesize_m1 = <optimized out>
        sp = <optimized out>
        freesize = <optimized out>
        __PRETTY_FUNCTION__ = "start_thread"
#17 0x00007ffff421047d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111
No locals.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants