box86 icon indicating copy to clipboard operation
box86 copied to clipboard

error creating window

Open olevenets2 opened this issue 2 years ago • 17 comments

Hello, after one of the recent updates, the .exe files that installs patches for games stopped working for me.
I am getting an error when creating the window even though this worked fine before. I created logs, maybe this will help something for the problem

trace.gz

https://paste.ee/p/nqJ1N

olevenets2 avatar Mar 31 '23 14:03 olevenets2

I don't see anything on this log. it may create a SEGFAULT or something like that, but it's not showing. Try to add BOX86_SHOWSEGV=1 to show them.

If you how to use git bisect, that would help a lot also.

ptitSeb avatar Mar 31 '23 14:03 ptitSeb

with segfault trace2.tar.gz

olevenets2 avatar Mar 31 '23 14:03 olevenets2

I checked, and I see absolutly no error, no missing libs :( I don't see anything wrong.

Can you try some git bisect on box86 to find at what commit it broken?

ptitSeb avatar Mar 31 '23 15:03 ptitSeb

I don't know how to use git bisect, but this definitely works with Box86 with Dynarec v0.2.9 8563ba8b built on Feb 26 2023 01:19:48 and breaks on newer builds

olevenets2 avatar Mar 31 '23 18:03 olevenets2

This archive is causing me the problem rtcw.exe.gz

olevenets2 avatar Apr 02 '23 00:04 olevenets2

@xuewei1985 you have not finished the git bisect? It is supposed to end up giving the 1st bad commit but I don't see it on your copy?

ptitSeb avatar Jun 01 '23 06:06 ptitSeb

@xuewei1985 you have not finished the git bisect? It is supposed to end up giving the 1st bad commit but I don't see it on your copy?

I'm sorry, there were some issues with the previous test, and I didn't complete the bisect. I am currently performing the bisect step by step and will provide the operation log later.

xuewei1985 avatar Jun 01 '23 06:06 xuewei1985

@xuewei1985 you have not finished the git bisect? It is supposed to end up giving the 1st bad commit but I don't see it on your copy?

I'm sorry, there were some issues with the previous test, and I didn't complete the bisect. I am currently performing the bisect step by step and will provide the operation log later.

Below are the commits I located after completing the git bisect.

a4752afacfc51d6005a6fc0cf313fd5cbd2f99c2 is the first bad commit
commit a4752afacfc51d6005a6fc0cf313fd5cbd2f99c2
Author: ptitSeb <[email protected]>
Date:   Tue Mar 7 22:02:59 2023 +0100

    [DYNAREC] Added BOX86_DYNAREC_FORWARD parameter, with a default value to 128 (unfortunatly, it doesn't seems to help performances much on box86)

 docs/USAGE.md                     |  5 +++++
 src/dynarec/dynarec_arm.c         |  9 +++++---
 src/dynarec/dynarec_arm_pass.c    | 47 ++++++++++++++++++++++++++++++++-------
 src/dynarec/dynarec_arm_pass0.h   |  2 +-
 src/dynarec/dynarec_arm_private.h |  4 ++++
 src/include/debug.h               |  1 +
 src/main.c                        | 13 +++++++++++
 src/tools/rcfile.c                |  9 ++++++++
 system/box86.box86rc              | 17 ++++++++++++++
 9 files changed, 95 insertions(+), 12 deletions(-)

xuewei1985 avatar Jun 01 '23 06:06 xuewei1985

I tried setting "BOX86_DYNAREC_FORWARD=0" and the "Error creating window" message no longer appears.

xuewei1985 avatar Jun 01 '23 06:06 xuewei1985

so setting forward to 0 fix your issue? as a workaround (until I found the root cause, wich might take a long time), you can add an entry in box86.box86rc database with your binary name. You can do a PR with that also, so everyone can benefit from it.

ptitSeb avatar Jun 01 '23 07:06 ptitSeb

I simply attempted to set this environment variable, and after setting it to 0, the "Error creating window" message no longer appears. However, I'm uncertain if this setting may cause any other issues?

xuewei1985 avatar Jun 01 '23 07:06 xuewei1985

this setting simply remove an optimisation.

ptitSeb avatar Jun 01 '23 08:06 ptitSeb

Okay, but I have tested a large number of applications here, and they all seem to encounter this error. It doesn't seem practical to add them all to the box86rc database.

xuewei1985 avatar Jun 01 '23 08:06 xuewei1985

Are they linux app or windows app?

ptitSeb avatar Jun 01 '23 08:06 ptitSeb

windwos app

xuewei1985 avatar Jun 01 '23 08:06 xuewei1985

what wine version are you using?

ptitSeb avatar Jun 01 '23 08:06 ptitSeb

8.0.1

xuewei1985 avatar Jun 01 '23 08:06 xuewei1985