DesktopGL: GLSL shaders incorrect when using source

Development platform: Windows 10 x64, Visual Studio 2019.
Template: DesktopGL (tested on the development platform)

When I compile MonoGame from source, some of my shaders behave really weird. I have tried both the latest commit as well as the original 3.8 release. When I add the nuget packages instead, everything works as expected regardless of MonoGame version (tested both 3.8 and the latest development version).

An example shader/project that works fine with the nuget release, but not with the source, is GitHub - Kosmonaut3d/BloomFilter-for-Monogame-and-XNA: A bloom filter module, which can easily be added to existing applications. Solution includes sample.

I followed the steps in Setting up your development environment for Windows | MonoGame Documentation when preparing the source. I encountered no errors or issues with this process (up until the incorrect shaders).

Has anyone else had this problem?

Edit: I now realize that it only happens when monogame has been compiled in a debug-mode. Both the debug and release have the same compilation symbols though.

I just tested to build the 3.8 project on a different machine (also Windows 10 x64) with a fresh Visual Studio 2019 installation, and got the same error.

Edit: I now tested the 3.6 source, and have the same problem. Is there some step/requirement missing in Setting up your development environment for Windows | MonoGame Documentation for the DesktopGL-build?

It was these lines that created the “odd” shading: MonoGame/GraphicsDevice.cs at 5b040f6512c7acc79c7168f7df88ae6de4cb2529 · MonoGame/MonoGame · GitHub.