<div>In my last post, I wrote about the switch from Travis CI to GitHub Actions (C++ Insights: From Travis CI to GitHub Actions. In the what's next section, I dreamed a little about getting code coverage information from the Windows build. Here is with I ended up with.</div><div></div><div></div><div></div><div></div><div></div><div>gta san andreas mod download for pc windows 11</div><div></div><div>DESCARGAR:
https://lpoms.com/2yONIc </div><div></div><div></div><div>While MSVC offers code coverage analysis, I couldn't get that information out in a gcov-like format. My next attempt was to use what I already know, Clang. Clang is able to perform code coverage analysis on Linux and macOS. It seemed like a logical choice to use it on Windows as well. The idea was fueled by this article code-coverage-with-clang-on-windows.html. Under Windows, clang-cl.exe got a new option --coverage. Exactly what I was looking for and in a single flag. What else could I dream of? Adding --coverage in the CMakeLists.txt was a piece of cake. I also went crazy and added the flag only for the Windows platform. Yes, I know that was a little overstating, but I was happy.</div><div></div><div></div><div>Ok, I stopped being so happy after the first compilation attempt. MSVC or better, MSBuild told me that it doesn't know the option /-coverage. It seems reasonable. I don't know it either. I concluded that due to the crazy setup on Windows, using MSBuild together with clang-cl.exe to invoke the Clang-compiler but map and filter all the Windows options, passing --coverage was not supported. I also tried to pass clang-cl.exe as a linker to CMake. No success. Should you know better, please let me know!</div><div></div><div></div><div>As the road with MSBuild turned out to be a dead-end, I came up with the brilliant idea to use only clang-cl. Ok, it turned out that I used MSBuild for a reason. It was the easiest to setup. It took me a couple of attempts to figure out how I have to configure clang-cl to work without MSBuild and which flags I have to pass to generate code coverage information. It compiled!</div><div></div><div></div><div>Now, success was in the air. I was so certain that I was only minutes away from pushing this great change to GitHub. Boy, was I wrong! I always remind my students that there is another step after compiling, linking! The beloved lld-link.exe told me at the end of the build:</div><div></div><div></div><div></div><div></div><div></div><div></div><div>As always, the linker was right. That file didn't exist. Not even the path lib/windows was there. This is probably the time to tell you more about the difficulties of the Windows build for a clang-AST-based tool.</div><div></div><div></div><div>The official Clang binaries for Windows do ship without the necessary libraries and programs to create a clang-AST based tool. It does not have the AST libraries as Linux and macOS do. It also misses llvm-config, which is needed to configure C++ Insights to link properly with the LLVM libraries. Back when Windows support was added by grishavanika and when adding AppVeyor to the CI pipeline, I started using the ZigLang binaries. I'm grateful that they do a Windows build with llvm-config and the AST libraries.</div><div></div><div></div><div>Luckily, thanks to the good architecture of LLVM, it is possible to compile compiler-rt for an existing Clang build, as long as there is llvm-config to configure the project accordingly. And ZigLang provides this! So I ended up setting up another GitHub Action building compiler-rt for the ZigLang binaries.</div><div></div><div></div><div>This time I decided to try it out with a smaller example. I successfully compiled the code Marco showed in his post. And it worked!!! Fantastic! I once more was convinced that pushing this incredible change was now a matter of minutes! I mean, what can go wrong at this point?</div><div></div><div></div><div>Luckily I had the answer in front of me all the time. Remember Marco Castelluccio's post? In it here explained a tool called grcov developed in Rust for Firefox's code coverage analysis. It is available for Windows and did work like a charm!</div><div></div><div></div><div>There is one more thing I like to mention, that is
codecov.io. I don't remember why I chose them at the time, by I'm still happy with my decision. When I was thinking about code coverage from the Windows build, I also thought about how to see which platform did contribute to which coverage, or better on which platform is the statement not covered by a test.</div><div></div><div></div><div>I was and still am surprised about how little
codecov.io talks about that. Initially, I wasn't sure they'd support it after all. All I found mentioned was that multiple uploads from the same build are merged by
codecov.io. The is already a good thing, but how to know which platform lacks a test? The, to me, relatively hidden answer was flags. I, and of course you, can add a flag to a coverage report when uploading it. These flags appear in the Build tab (here for an example). The default is that the aggregated result from all uploads from a build is shown. When looking at an individual file, there are now the flags at the top right of the diff-view. All are on by default, but we can enable and disable them to see the individual platform. For C++ Insights, you can, for example, see that Insights.cpp shows not 100% coverage. Playing with the filters you see, that the line if(gUseLibCpp) is used only on Linux.</div><div></div><div></div><div>Hello! I'm Andreas Fertig, a C++ trainer, and developer. I enjoy exploring the depth of the language and sharing my knowledge. Check out my training classes. Furthermore, I'm the creator of
cppinsights.io.</div><div></div><div>This is the place where I share my thoughts and announce my public talks and training classes.</div><div></div><div></div><div>If you mean a BSOD, neither DxWnd nor any game have the power to crash the operating system, so the problem should be in some hardware driver (like the video or the sound drivers) that have some bug and that are stressed by the game+DxWnd combination.</div><div></div><div>You should try to update your drivers, or check the release notes and maybe downgrade them: not always the most recent is the best!</div><div></div><div>Otherwise, if the computer still reacts to some commands (like Ctrl-Alt-Cancel) it could be interesting to see the DxWnd logs ....</div><div></div><div></div><div>Regarding the freezing:</div><div></div><div>If the system itself is not frozen then one way to recover without needing to hard reset in my experience has been to use the Windows task view feature. (Available only in Win10 and 11)</div><div></div><div></div><div>Log files can be very large, but usually they can be compressed in much smaller files, if you'll have to repeat the logs capture this is a good advice.</div><div></div><div>Sadly, the log doesn't show anything related to DxWnd hooped operations, there are no errors. The log ends with this failed operation:</div><div></div><div></div><div>but I doubt that this could be tha cause of the crash, more likely is a failed attempt to pack some diagnostic data about the crash before termination.</div><div></div><div>Since there seems to be no error about Direct3D9 operations, the problem must be elsewhere. You may try to set the "Compat. / Handle exceptions" flag. If the best case it may intercept and fix the error, but in the worst case it should at least write something in the log. Better set also "Sound / Hood DirectSound" and "Logs / Sound" just in case the trouble could come from the sound system.</div><div></div><div></div><div>You can set the flag "Logs / Circular" mode. This way DxWnd will cycle the logs through two log files (see the help for details) deleting the old data before adding new ones, so the log size would be always limited in size. But this way you will have to compress and post both log files (dxwnd,log and dxwnd.0.log, if I remember correctly).</div><div></div><div></div><div>Overwrite is named as such because it writes the log in dxwnd.log and if that log file is already in the game folder it will be overwritten by the new log. It will continue writing to that single file until the game crashes or is terminated.</div><div></div><div></div><div>Circular writes a log named dxwnd.log and keeps writing to it until a certain size limit is reached (50000 messages). After this it starts writing to a new dxwnd0.log file until the size limit is again reached. It then goes back to dxwnd.log (overwriting the old one) hence the "circular" naming.</div><div></div><div></div><div>The benefit of the circular mode is that it outputs smaller log files which is good when you can not precisely pinpoint where the game will crash. This way you will not end up with one gigantic log file like with the basic "overwrite" method.</div><div></div><div></div><div>Thank you for the explanation :) . As I wrote above, I'll wait until the game crashes again and upload new logs here, but this time in Circuite mode. I'm also attaching a screenshot here now, where you can see what all I have enabled in the logs (for writing).</div><div></div><div></div><div>Sorry, it's a huge log but there's no trace of any error, exception or unusual operation.</div><div></div><div>Whatever is happening to the game seems out of DxWnd control.</div><div></div><div>Anyway the game stayed alive for 3529 seconds (almost 1 hour), not too bad.</div><div></div><div>I don't think we can get anything more from dxwnd logs. Maybe you could run the task monitor and keep an eye to the used resources, maybe the game (or the game + DxWnd) has some leakage, though this should also downgrade the game speed instead of giving a sudden crash. Also the system log could provide some clue (don't ask me how to read it, there should be some info on the web).</div><div></div><div></div><div>I've noticed that when windows crashes and I spam ctrl+alt+delete, I get a blackscreen. The game sounds don't work either. When I restart the PC, I get a notification in the notifications that says "application has been blocked from accessing graphics driver" and underneath that is "Microsoft Operating System". However, today there was another message (also from blocking) "obs64.exe".</div><div></div><div></div><div>Random crashes are the hardest to track down and in this case it would seem that the crash is happening on the system level. One could try different GPU driver versions or even running system file checker "sfc /scannow". It could also be a hardware fault in the power supply, RAM or GPU for example that causes the crash when under enough stress.</div><div></div><div></div><div>When I make changes in OpenStreetMap, I often need to extract the object colour from a picture or a video, as example for a building, bench or a roof. This collides with a feature in KDE which I really like: Dim Inactive Windows.</div><div></div><div></div><div>The setting is in the KDE settings, under Desktop Effects -> Dim Inactive. As the name implies, it dims (makes them a bit more dark) all non-active windows - which makes it visually clear which window is currently active. Quite useful.</div><div></div><div> d3342ee215</div>