First post, by danoon
@peterfirefly posted this question to me in Some free online sources for things that might help with emulator development? and I decided to answer in a new thread
Running Boxedwine didn't really go well... […]
Running Boxedwine didn't really go well...
Finding the executable was easy.
The GUI is nice. I love that it checks for a Wine and offers to download one for me (Wine 9.0).
Unfortunately, I haven't been able to make it run anything.
I tried installing some of the demos. That didn't go well.
I tried Age of Empires first. I got "alloc64kBlock: failed to commit memory : Cannot allocate memory" and the install failed.
I tried Abiword. It installed but launching it gave me the same error.
I tried Diablo II shareware. Same error, won't even install.
It also seems to be very, very slow.
Quitting Boxedwine by closing the window sorta worked: it took a really long time to react and this was what was printed on the terminal:
€ ./boxedwine
Starting ...
alloc64kBlock: failed to commit memory : Cannot allocate memory
alloc64kBlock: failed to commit memory : Cannot allocate memory
alloc64kBlock: failed to commit memory : Cannot allocate memory
Boxedwine shutdown
Segmentation fault (core dumped)
€
I thought I maybe got the "Normal" CPU, perhaps even without caching of decode blocks.
Seems like BT_FLAGS (in the makefile) isn't used unless I specify 'multiThreaded' on the command line when I run make.
So I tried rebuilding Boxedwine with "CC=gcc-12 CXX=g++-12 make multiThreaded" and doing it again. It still didn't work.
I tried installing Wine 6.0. Still didn't work.
Clicking the close button of the window didn't work anymore. After several minutes, I had to give up by using "killall -9 boxedwine". Just "killall boxedwine" doesn't work for some reason.
The weird thing is that the GUI runs a "please wait" animation flawlessly, so why doesn't it react when I click the "close window" button?Is there a way to get the executable to tell me how it was compiled? Something like uname, /etc/lsb-release, compiler, compiler version, important #define's?
I'm curious about you system.
You can try "make release" to get the Normal CPU core.
And thanks for the reminder, I definitely need to update my docs to say that gcc 12 or later is required to compile.
The normal CPU core without the binary translator on Linux will be slow. In the last year I have been working on the a normal CPU core that supports multi-threading which speeds things up about 50%, but I haven't added that option to the Linux makefile yet. Currently that option is only on Windows and Emscripten/Wasm.
As for the binary translator running out of memory, I have seen that before. Boxedwine's binary translator uses way too much memory, 2GB+. It is on my list of things to do to reduce that memory usage. But it is still surprising to see that error, I haven't tested it in a while, but at one point I was actively testing on the Raspberry Pi which didn't have much memory.
How do you detect instructions > 15 bytes (due to repeated prefixes) so you can generate an exception for that?
I don't handle this since I have never seen a game that does that.
My first question was how you handle the x86 memory model on ARM hosts (only relevant for SMP, of course). A quick glance didn't spot any memory barriers in armv8btAsm.cpp, for example.
I have read a lot on this and from my understanding, I probably don't handle that perfectly. I add "dmb ish" for memory instructions that have the lock prefix
https://github.com/danoon2/Boxedwine/blob/21c … 587C18-L1587C35