Author Topic: MARKEXE vs EXECMODE - differences?  (Read 840 times)

Dariusz Piatkowski

  • Hero Member
  • *****
  • Posts: 1200
  • Karma: +25/-0
    • View Profile
MARKEXE vs EXECMODE - differences?
« on: October 15, 2022, 05:47:06 pm »
Hi everyone,

I've had a persistent problem with some apps putting a complete soft-lock of my machine. This normally happens during application start-up, but occasionally it would also happen throughout execution. I know, it sounds weird, but it's absolutely consistent and in appears to be related to an underlying component DLL, although I'm still working through pegging that detail.

Anyways, so to avoid that dreaded outcome I found that the best way to deal with this problem is to start up the "offending" app with all CPU cores but core_0 disabled. I do this with the handy setproc utiility.

Alright...but doing this manually is a PITA, so I have a quick SMPOFF/ON wrapper *.cmd template that I have been using for such apps.

However, it would seem to me that perhaps flagging to offending EXE as SMP-unsafe would provide a better result. Well, I tried this but with rather bleak results, or to be more precise, no results. The lock still occurs, and maybe it's because it's a DLL issue as opposed to the main EXE (therefore parent vs child execution path issue).

But...if my understanding of how these two utilities control the SMP flags is incorrect, well, that may have a key bearing on what I'm seeing.

They both enable you to flag a particular EXE as MPU unsafe, and yet for exmaple flagging a sample EXE with execmode doesn't seem to show the correct status when querying it up in markexe, so what gives?

I've got some examples here to illustarte this, but for starters I'm looking for a general understanding of what's different in terms of how these two utilities mark a EXE?

Andreas Schnellbacher

  • Hero Member
  • *****
  • Posts: 827
  • Karma: +14/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #1 on: October 15, 2022, 07:19:31 pm »
BTW: Already in the later eCS versions, I found that the Clock Synchronization program object locks the WPS for its delay time. That isn't reproducible on other installations. Additionally, sometimes NewView causes a delay before it comes up with a file, but only on that partition. And trying to restart the WPS fails for that partition. WPS program objects (xCenter objects) often don't update anymore and stop working.

That happens on one installation only. As far as I can't reproduce it, it's useless to file a bug.

To your basic question: Both execmode.exe and markexe.exe change the same bit in an executable, nothing more. You can also do that manually. Where they differ, is how they report their work. IIRC vpc.exe was reported to be processed by markexe.exe, but it wasn't. The message from execmode.exe was more reliable on that: IIRC it just failed.

Doug Bissett

  • Hero Member
  • *****
  • Posts: 1567
  • Karma: +4/-2
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #2 on: October 15, 2022, 08:15:00 pm »
There is no difference with what those two programs do, The main difference is that EXEMODE is supplied with OS/2, while MARKEXE is only in the DDK toolkit. Everybody gets EXEMODE.

As for your problem, I have been having hangs sometimes. Usually when some program (different programs) fails to shut down properly (it looks like it did, but some time later, I find that it is still open, and can't be closed). Some other indications point to memory overlay. I have found that using a JFS cache, of more than 132000 K is one of the triggers, but it seems that using MEMLIMIT to reduce available system memory by 3 or 4 MB is far more effective. One other thing, that seems to cause the problem, is to use VirtualAddressLimit greater than 2560 (this may be machine dependent).

Dave Yeo

  • Hero Member
  • *****
  • Posts: 4012
  • Karma: +81/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #3 on: October 16, 2022, 02:07:05 am »
One other thing, that seems to cause the problem, is to use VirtualAddressLimit greater than 2560 (this may be machine dependent).

It is machine dependent, and dependent on things like the graphic card. The PCI address space is at the top of memory, including graphics memory and I believe if the VirtualAddressLimit is too high, they can overlap causing instability and crashes.
I currently have it set at 3072 and just went over 500 hours of uptime with SeaMonkey running most of that time steadily, Thunderbird much of the time and Dooble at times. It finally locked up hard when opening a QT4 card game.

Andi B.

  • Hero Member
  • *****
  • Posts: 711
  • Karma: +10/-1
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #4 on: October 16, 2022, 09:59:55 am »
I can't go above VIRTUALADDRESSLIMIT=2816 with this system. Otherwise AOO can't open some dlls anymore. But it also depends on other settings.

I've solid hangs a while after I start Thunderbird (beside SM) with my different calendars located at different sites. On my older system I had solid hangs often when playing videos. No clue if audio or video related.

Roderick Klein

  • Hero Member
  • *****
  • Posts: 547
  • Karma: +14/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #5 on: October 21, 2022, 08:26:29 pm »
I can't go above VIRTUALADDRESSLIMIT=2816 with this system. Otherwise AOO can't open some dlls anymore. But it also depends on other settings.

I've solid hangs a while after I start Thunderbird (beside SM) with my different calendars located at different sites. On my older system I had solid hangs often when playing videos. No clue if audio or video related.

This happens with SNAP or Panroama I seem to recall this virtualaddresslimit issue's with SNAP ?

Roderick

Roderick Klein

  • Hero Member
  • *****
  • Posts: 547
  • Karma: +14/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #6 on: October 21, 2022, 08:40:48 pm »
One other thing, that seems to cause the problem, is to use VirtualAddressLimit greater than 2560 (this may be machine dependent).

It is machine dependent, and dependent on things like the graphic card. The PCI address space is at the top of memory, including graphics memory and I believe if the VirtualAddressLimit is too high, they can overlap causing instability and crashes.
I currently have it set at 3072 and just went over 500 hours of uptime with SeaMonkey running most of that time steadily, Thunderbird much of the time and Dooble at times. It finally locked up hard when opening a QT4 card game.

I think the PCI address space does not interfere with the virtual address limit. I think the issue with the graphics memory and virtual address limit only occurs with SNAP and not Panroama, but I could be wrong.

Roderick

Dave Yeo

  • Hero Member
  • *****
  • Posts: 4012
  • Karma: +81/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #7 on: October 21, 2022, 08:51:29 pm »
Snap does seem to be worse. While 3072 is stable here with Panorama, I had to reduce it to 2816 on a Snap install to be stable.
I also tried installing a recent beta on my sons system, all kinds of weird problems until I reduced the graphics memory from a couple of GB IIRC to 64 Kb or might have been 264kb. IN 32bit mode, there is only so much address space and that graphics memory has to go somewhere. With a video card perhaps it is bank switched or similar whereas with builtin graphics, it seems to need the address space.

Roderick Klein

  • Hero Member
  • *****
  • Posts: 547
  • Karma: +14/-0
    • View Profile
Re: MARKEXE vs EXECMODE - differences?
« Reply #8 on: October 21, 2022, 10:20:38 pm »
Hi everyone,

I've had a persistent problem with some apps putting a complete soft-lock of my machine. This normally happens during application start-up, but occasionally it would also happen throughout execution. I know, it sounds weird, but it's absolutely consistent and in appears to be related to an underlying component DLL, although I'm still working through pegging that detail.

If you could make a list of these apps and if they are tha letst version see if you make memory dump by pressing CTRL ALT F10 key combination twice.  With a memory dump it might be possible to determine why the hang occurs.


Roderick