Closed sjoerdvankreel closed 4 months ago
I'm not a bitwig dev, so grain of salt.
One thought: Is your runtime different and somehow conflicting in release mode on win 11? Are you using a static or a dynamic runtime? Or does your release build set the char set differently? I"m assuming you are using MSVC but wonder if you have a DebugStatic vs ReleaseDynamic problem in your clap assembly somewhere?
Does clap-info load your win11-release-binary plugin properly and print all the values you expect also? That may be another good test?
Paul! Always the first to help. Thanks a bunch. I'm about to get burninated on SO once more https://stackoverflow.com/questions/78673717/how-to-debug-a-cmake-built-binary-that-crashes-in-release-mode-but-not-in-debug :)
<< Are you using a static or a dynamic runtime << I"m assuming you are using MSVC but wonder if you have a DebugStatic vs ReleaseDynamic problem in your clap assembly somewhere? MSVC + Dynamic all the way, both debug/release, although, that may be part of the problem. I might try a static link.
<< Or does your release build set the char set differently? Definately not, no.
<< Does clap-info load your win11-release-binary plugin properly Will try! That one I hadn't thought of. I kinda tend to use reaper as "single source of truth", for better or worse.
Yeah we are MSVC plusstatic everywhere ourselves - I would try that first just to be sure
The only reason I went with dynamic is because of some (maybe ancient) narrative from microsoft which said something along the lines of "statically linked plugins have a maximum of N per process." I recall there was an "official" microsoft document at one point, but i cannot find it anymore. However there's some (old! 5.2.1) juce material on the subject: https://github.com/WeAreROLI/JUCE-fork/blob/master/BREAKING_CHANGES.md.
"In a recent update to Windows 10, Microsoft has limited the number of fiber local storage (FLS) slots per process. Effectively, this limits how many plug-ins with static runtime linkage can be loaded into a DAW. In the worst case, this limits the total number of plug-ins to a maximum of 64 plug-ins."
I find it sort-of confusing that this talks about FLS rather than TLS, but, I'd better trust the JUCE devs on this. Any idea if that thing is still a problem in the present day?
@baconpaul jup, that did it. Static link MSVCRT, problems are gone. And if it's good enough for Surge, then its good enough for me. Still have to find a way to convince VST3 SDK Cmake stuff to static link, but that's for another day.
This does raise some questions though:
Also @abique : I'll just go with static for Windows, but I'm still not sure if there may be a bug lurking here somewhere ?
Mac you don't have to. You can set the macos target os version and you are guaranteed a libc that matches and if you use something newer you get a compiler error.
Linux is a nightmare. Binary distribution is basically not possible reliably for all the distress. Build on ubuntu18 and pray is the best advice people seem to have.
Closing, problem turned out to be on my end as expected (out of bounds read). Only after updating visual studio, only with dynamic link, only in Bitwig, only with release build, not even RelWithDebInfo. Great fun.
Closing, problem turned out to be on my end as expected (out of bounds read). Only after updating visual studio, only with dynamic link, only in Bitwig, only with release build, not even RelWithDebInfo. Great fun.
Those are the best. It really makes you realize that we definitely got this "how to program a computer" thing 100% correct as a species. LOL
Glad it got sorted.
I get the above error message when trying to load my plugin in bitwig 5.1.9, windows 11, x64. Just to be clear, this is probably a "me" problem, not a bitwig problem, but I'm having a hard time trying to figure out whats going on.
I released version 1.7.8 of my plugin a couple weeks ago, and those distributed binaries are working fine in bitwig 5.1.9. Those were compiled on windows 10, and i have since switched to a new laptop running windows 11, and when I re-build the same plugin version (from github tag), bitwig freaks out.
Here's some stuff I tried:
Now obviously the fact that debug works and release does not is a strong hint the problem is on my side. However reaper behaves without problems (as does bitwig+vst3) with release-mode plugin and the fact that the only change is a change of platform used for compilation makes this a bit hard to debug.
Bitwig's engine.log says the following:
Which seems to imply troubles with character encoding but i fail to see how a toolchain update can cause that, or how debug/release mode should make a difference. So I'm just throwing it out here. Any thoughts? Maybe msvcrt version or whatever? Or maybe, is there invalid utf8 data stored in "60f5ec75-82a5-4658-8230-160afaede760.clap-preset" (whatever that may be)?