SpecBAS icon indicating copy to clipboard operation
SpecBAS copied to clipboard

Hang in Direct Command

Open ASH-II opened this issue 5 years ago • 11 comments

SpecBas will hang after about 15-20 min's but only when I am using the direct command window.

so running and editing is fine but after a while when I use the direct command window it will freeze and I have to restart Specbas. luckily it stores the listing but sometimes it will freeze on a return press and Specbas will start up blank....Panic....when did I last save :)

It's an issue but I don't know why it's doing it , I can be editing a line or just checking a variable etc but so far it has only crashed when in direct command after about 20 mins.....

p.s. this has only started about a month ago.

ASH-II avatar May 17 '20 08:05 ASH-II

It's a crash due to a race condition, but if I can't reproduce it then I can't fix it. I'm watching out for it and will fix it as soon as I can.

Is it during general editing, or only after pressing ENTER?

ZXDunny avatar May 17 '20 10:05 ZXDunny

both

ASH-II avatar May 17 '20 10:05 ASH-II

Thanks, I'll look out for it.

ZXDunny avatar May 17 '20 10:05 ZXDunny

I may have discovered the reason for this - but no fix as yet.

ZXDunny avatar Jun 22 '20 22:06 ZXDunny

Cool...did it stop on you?

ASH-II avatar Jun 23 '20 17:06 ASH-II

I found that, during the keyboard rewrite, if we don't wait for vsync during the keyboard scanning loop, it will crash. This seems to be a speed thing - my PC is insanely fast so it doesn't crash for me when vsync is in, but slower PCs might.

So I know where to look :)

ZXDunny avatar Jun 23 '20 18:06 ZXDunny

Possibly fixed, could very well be some threads trying to access the same resource at the same time. Testing needed :)

ZXDunny avatar Jun 29 '20 22:06 ZXDunny

will do , I'll give it a blast at the weekend.

ASH-II avatar Jun 30 '20 20:06 ASH-II

having a go and still locking up after about 40mins , I was deleting code in the comand window.

ASH-II avatar Jul 11 '20 15:07 ASH-II

OK, I think this is to do with the undo buffer getting full (it should auto-extend as necessary) so I'm adding limits and resets. I'll commit that in a moment.

ZXDunny avatar Jul 11 '20 15:07 ZXDunny

New commit, go grab the exe from the front page and see if that helps.

ZXDunny avatar Jul 11 '20 15:07 ZXDunny