[Vm-dev] Reproducible VM crash on Win32 with callbacks

Nicolas Cellier nicolas.cellier.aka.nice at gmail.com
Wed Jan 16 22:25:09 UTC 2019


Le mer. 16 janv. 2019 à 12:21, Guillermo Polito <guillermopolito at gmail.com>
a écrit :

>
> Hi all,
>
> I've tested using the volatile keyword in all variables in the function
> and the problem is still there.
> So while I get some time to look at the asm outputs I've issued a PR with
> the discussed solution in here:
> https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/353
>
> @Nicolas, I was able to compile and debug win64 almost out of the box.
> However, I could not make the visual studio code debugging extension work
> for the 32bit version.
> Where you compiling on clang with just the makefiles or you have used
> visual studio for that?
> Also, could you share your visual studio project files? I'd like to try
> debugging with it :)
>
> Tx all,
> Guille
>
>
Hi Guile,
Sure, I can give you the visual studio project files, just unzip the
build.msvc under opensmalltalk-vm root dir.
But they are not of great value, because they are configured for MSVC
compiler., 64bits and Squeak (less dependencies than Pharo...)
And despite the entry being marked as fixed, MSVC still suffer from this
preprocessor bug
https://developercommunity.visualstudio.com/content/problem/62402/vc-codegenerationbug-when-compiling-smalltalk-vm.html?childToView=398928#comment-398928
I cannot test MSVC code generation yet, just use the IDE for navigating in
code, and reviewing compiler warnings so far.
Also, I have not maintained the 32bit version, maybe I have an obsolete one
in the branch that I used for the bug report. No time to dig...

The bug can be easily produced with minheadless I presume, so isn't using
CMake for generating a VS or VSC project an option?
I did this old style cmd for 64bits MSVC backend:

set PATH=%PATH%C:\Program Files\CMake\Bin;
set PATH=%PATH%C:\Program Files (x86)\Microsoft Visual
Studio\2017\Community\MSBuild\15.0\Bin;
cmake ../../../.. -G "Visual Studio 15 Win64" -DCMAKE_BUILD_TYPE="debug"
-DPHARO_BRANDING=On -DSPUR_OBJECT_MODEL=On -DCOG_JIT=On

But I'm quite sure that we can just use the VSC UI to import the CMake list
like shown here:
https://www.40tude.fr/blog/compile-cpp-code-with-vscode-clang/

I've not played much with VSC, maybe it's time to inquire...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20190116/42eda995/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: build.msvc.zip
Type: application/zip
Size: 74222 bytes
Desc: not available
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20190116/42eda995/attachment-0001.zip>


More information about the Vm-dev mailing list