HISE Logo Forum
    • Categories
    • Register
    • Login

    Debug in VS2022

    Scheduled Pinned Locked Moved General Questions
    50 Posts 6 Posters 2.5k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • DanHD
      DanH @Lindon
      last edited by

      @Lindon thanks, I found the culprit and now have an open app in VS :thumbs_up:

      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
      https://dhplugins.com/ | https://dcbreaks.com/
      London, UK

      LindonL 1 Reply Last reply Reply Quote 1
      • LindonL
        Lindon @DanH
        last edited by

        @DanH said in Debug in VS2022:

        @Lindon thanks, I found the culprit and now have an open app in VS :thumbs_up:

        yes - so now the fun begins....

        HISE Development for hire.
        www.channelrobot.com

        DanHD 1 Reply Last reply Reply Quote 0
        • DanHD
          DanH @Lindon
          last edited by

          @Lindon indeed! So when playing notes on my instrument the console spits out messages like the below - anything to worry about?!

          The thread 0x206c has exited with code 0 (0x0).
          The thread 0x20f4 has exited with code 0 (0x0).
          The thread 0xbdc has exited with code 0 (0x0).
          The thread 0x468 has exited with code 0 (0x0).
          

          DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
          https://dhplugins.com/ | https://dcbreaks.com/
          London, UK

          DanHD 1 Reply Last reply Reply Quote 0
          • DanHD
            DanH @DanH
            last edited by DanH

            @Lindon @d-healey @Christoph-Hart

            Ok I'm pretty sure the below is the bug I'm trying to locate. It happens very occasionally when switching presets via the usual browser (can be any preset). I have no idea what this is telling me so please let me know if you do! :)

            The instrument contains a couple of samplers, Waveform Gens, Sine Wav Gen too....

            ### Loading user preset BA        2010
            
            Assertion failed!
            
            Program: D:\HALO-2\Binaries\Compiled\App\HALO-2 Debug.exe
            File: C:\Users\Admin\Desktop\HISE-develop...\readerw...queue.h
            Line: 566
            
            Expression: !inSection && "ReaderWriterQueue does not support enqueuing or dequeuing elements from other elements' ctors and dtors"
            

            IMG_8901.JPG

            DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
            https://dhplugins.com/ | https://dcbreaks.com/
            London, UK

            d.healeyD 1 Reply Last reply Reply Quote 0
            • d.healeyD
              d.healey @DanH
              last edited by

              @DanH Why are you taking photos of your screen instead of screenshots?

              Libre Wave - Freedom respecting instruments and effects
              My Patreon - HISE tutorials
              YouTube Channel - Public HISE tutorials

              DanHD 1 Reply Last reply Reply Quote 0
              • DanHD
                DanH @d.healey
                last edited by

                @d-healey it's not my main machine and the internet is dodgy on there at the mo

                DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                https://dhplugins.com/ | https://dcbreaks.com/
                London, UK

                d.healeyD 1 Reply Last reply Reply Quote 1
                • d.healeyD
                  d.healey @DanH
                  last edited by

                  @DanH Ok, just checking your sanity, I thought the debugging might have got to you :D

                  Libre Wave - Freedom respecting instruments and effects
                  My Patreon - HISE tutorials
                  YouTube Channel - Public HISE tutorials

                  DanHD 1 Reply Last reply Reply Quote 0
                  • DanHD
                    DanH @d.healey
                    last edited by

                    @d-healey I suspect it will, given time!

                    Screenshot below!

                    Screenshot 2023-02-02 170544.png

                    DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                    https://dhplugins.com/ | https://dcbreaks.com/
                    London, UK

                    DanHD 1 Reply Last reply Reply Quote 0
                    • DanHD
                      DanH @DanH
                      last edited by

                      @DanH so a quick google suggests this might have to do with the queuing and de-queuing of threads. What kind of threads should I have going on normally...?

                      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                      https://dhplugins.com/ | https://dcbreaks.com/
                      London, UK

                      Christoph HartC 1 Reply Last reply Reply Quote 0
                      • Christoph HartC
                        Christoph Hart @DanH
                        last edited by

                        That‘s just an assertion that is telling you that the UI notification queue is full (which might happen if the user preset restores multiple hundred controls). It‘s not an critical error though so if it keeps appearing, just remove that line and rebuild to silence the message.

                        DanHD 2 Replies Last reply Reply Quote 0
                        • DanHD
                          DanH @Christoph Hart
                          last edited by

                          @Christoph-Hart Ok thank you for looking! This is what came up with the crash and the call stack is the same as when the plugin crashes (in the error report).... Could this lead to the source of the crash?

                          DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                          https://dhplugins.com/ | https://dcbreaks.com/
                          London, UK

                          1 Reply Last reply Reply Quote 0
                          • DanHD
                            DanH @Christoph Hart
                            last edited by

                            @Christoph-Hart been running the project again and run into this twice now:

                            void PoolBase::DataProvider::Compressor::create(MemoryInputStream* mis, ValueTree* data) const
                            {
                            	ScopedPointer<MemoryInputStream> scopedInput = mis;
                            	
                            	static zstd::ZCompressor<SampleMapDictionaryProvider> dec;
                            	MemoryBlock mb;
                            	mis->readIntoMemoryBlock(mb);
                            	dec.expand(mb, *data);
                            	jassert(data->isValid());
                            

                            Screenshot 2023-02-03 153849.png

                            DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                            https://dhplugins.com/ | https://dcbreaks.com/
                            London, UK

                            DanHD 1 Reply Last reply Reply Quote 0
                            • DanHD
                              DanH @DanH
                              last edited by

                              @DanH in XCode I'm getting this:

                              	if (mc->getKillStateHandler().isAudioRunning())
                              	{
                              		if (mc->getJavascriptThreadPool().isCurrentlySleeping())
                              			return true;
                              
                              		// The audio engine is not suspended. Wrap this call
                              		// into a killVoicesAndCall lambda.
                              		jassertfalse;
                              
                              		return false;
                              	}
                              

                              Screenshot 2023-02-03 at 16.48.11.png

                              If anyone has any advice at all about errors or debugging please let me know!!

                              DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                              https://dhplugins.com/ | https://dcbreaks.com/
                              London, UK

                              d.healeyD 1 Reply Last reply Reply Quote 0
                              • d.healeyD
                                d.healey @DanH
                                last edited by

                                @DanH Try stepping through the code (also going back through the call stack) to try to figure out the root of the issue. Does this actually cause a problem in a release build or is it just showing up in a debug build?

                                Try to recreate the issue in a minimal project.

                                Libre Wave - Freedom respecting instruments and effects
                                My Patreon - HISE tutorials
                                YouTube Channel - Public HISE tutorials

                                DanHD 1 Reply Last reply Reply Quote 0
                                • DanHD
                                  DanH @d.healey
                                  last edited by DanH

                                  @d-healey so the issue is crashing when switching presets. It could be any preset at any time. So rather than click through every preset (which I've done a lot of!) I made a timer which selects the next preset in the list every 2 seconds.

                                  • it's least stable running the debug within XCode / VS2022. I get call stacks I haven't seen before here.

                                  • The issue appears in release as well - hence the debugging.

                                  • So the error could be in the call stack and not necessarily the final file it points at?

                                  • In standalone builds the debug and release crash in the same thread (JUCE Message Thread Dispatch queue). The crash reports look different - I don't know how to reconcile this, in the sense that the numbers (e.g 0x10a2d7084) are different, but it's my assumption they are pointing at the same thing?

                                  DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                  https://dhplugins.com/ | https://dcbreaks.com/
                                  London, UK

                                  d.healeyD 1 Reply Last reply Reply Quote 0
                                  • d.healeyD
                                    d.healey @DanH
                                    last edited by

                                    @DanH Remove half of your presets and see if the problem is still there. If it is, remove half of the remaining presets and test again. Once you figure out which group of presets the problem one (or more than one) is keep repeating this process on that group until you find the culprit.

                                    I suspect the problem isn't a specific preset though and something to do with the way your project handles one of the controls that the preset is restoring.

                                    Yes the root cause of the issue isn't necessarily at the last point the call stack made it to. This is why you need to set break points and step through the code.

                                    Libre Wave - Freedom respecting instruments and effects
                                    My Patreon - HISE tutorials
                                    YouTube Channel - Public HISE tutorials

                                    DanHD 1 Reply Last reply Reply Quote 0
                                    • DanHD
                                      DanH @d.healey
                                      last edited by

                                      @d-healey Yes I don't think it's specific presets as it does seem random.

                                      Ok how do I set break points?!

                                      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                      https://dhplugins.com/ | https://dcbreaks.com/
                                      London, UK

                                      d.healeyD 1 Reply Last reply Reply Quote 0
                                      • d.healeyD
                                        d.healey @DanH
                                        last edited by

                                        @DanH

                                        The same way you do in HISE ;)

                                        Now is the time for you to go to YouTube and search for Debugging in Visual Studio.

                                        Libre Wave - Freedom respecting instruments and effects
                                        My Patreon - HISE tutorials
                                        YouTube Channel - Public HISE tutorials

                                        DanHD 1 Reply Last reply Reply Quote 0
                                        • DanHD
                                          DanH @d.healey
                                          last edited by

                                          @d-healey you mean set break points in the source code?

                                          DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                          https://dhplugins.com/ | https://dcbreaks.com/
                                          London, UK

                                          d.healeyD 1 Reply Last reply Reply Quote 0
                                          • d.healeyD
                                            d.healey @DanH
                                            last edited by

                                            @DanH I'm not sure what you mean. Break points are a feature of the IDE. You add them by clicking in the margin (I have a video on Patreon about HISE breakpoints).

                                            Libre Wave - Freedom respecting instruments and effects
                                            My Patreon - HISE tutorials
                                            YouTube Channel - Public HISE tutorials

                                            DanHD 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            21

                                            Online

                                            1.8k

                                            Users

                                            11.9k

                                            Topics

                                            104.0k

                                            Posts