-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: please add support for Global EMM Import Specification (GEMMIS) #5
Comments
I agree with adding support for GEMMIS too, which is pretty useful. As mentioned above DOSBox already has a GEMMIS implementation. In fact, you can see the changes in DOSBox's ems.cpp directly related to GEMMIS support here: https://sourceforge.net/p/dosbox/code-0/2601/ The actual change for GEMMIS support is apparently smaller than one might think, so I think it can be done for JEMM386 too. |
@Baron-von-Riedesel How feasible do you think it would be to implement this in Jemm? In case the DOSBox commit that @Wengier linked to doesn't provide you with enough context, here is an old article from Dr. Dobb's Journal in which someone documented the specification in detail, after he reverse-engineered it himself, including code examples: Dr. Dobb's _ Undocumented Corner _ September 01, 1994.pdf The direct link to the article is https://www.drdobbs.com/windows/undocumented-corner/184409317, but for some reason, the layout on that site is messed up and makes it difficult to read. Also the print icon on that page is hidden in modern web browsers, unless you have the NoScript browser add-on enabled. Anyway, from what I understand from the article, implementing this handover mechanism doesn't seem too complicated. But you can judge that far better than I can. What do you think? |
Hello. |
@HyabusaBadge It begs the question though, would it really be worth the effort implementing GEMMIS in the older EMM386 implementation? Wouldn't the effort be much better spent on porting JEMM to the NEC PC-9800 platform, as well as adding GEMMIS support to that? Perhaps the differences between FreeDOS for IBM PC clones and FreeDOS 98 are so small, that porting JEMM to the latter might be fairly trivial? I know this is an open source project, and we shouldn't have any expectations, but I'm curious to hear from @Baron-von-Riedesel about his opinion on how challenging it would be to implement GEMMIS support, whether to JEMM or the older FreeDOS EMM386. And perhaps other people reading this have the expertise to help him with it? I'm only just getting started with serious assembly language programming, dabbling with it during my spare time. Perhaps eventually, once I've gained enough experience with it, I'll be able to help with this, but until then, I believe this is beyond my skills. |
I admit that I'm not very interested in this GEMMIS. I fail to see why it should be useful. |
Its usefulness would be that JEMM386/JEMMEX could be a 100% drop-in replacement for MS-DOS EMM386, in all its documented and undocumented cases (such as the ability to run Windows in 386-enhanced mode), which aligns with the goal of FreeDOS, that is to be a 100% drop-in replacement for MS-DOS |
Well said @bugnano! I wanted to use JEMM386 as a free replacement for EMM386 in MS-DOS, but for this reason alone it apparently cannot replace EMM386 which works with Windows 3.1 much better because of this support. |
Well, first of all, I absolutely respect that JEMM is something you work on voluntarily and as a hobby. and it would be unreasonable and pointless to demand of you to implement this. JEMM already is a cool and useful project for many people as it is, and we're thankful that you've shared it with the world. It all comes down to the lack of GEMMIS being a remaining unchecked box towards JEMM being a full replacement for EMM386 and QEMM386. Many people do want to play with Windows 3.x and Windows 9x. It would be great if Windows could work with FreeDOS and JEMM out of the box. Lack of GEMMIS support (I believe) is the one thing preventing that from working right now. (Anyone feel free to correct me if that's not to case!) Yeah, Windows 3.x/9x might still work with FreeDOS if you rebooted without JEMM being loaded, but that's a bit of a hassle, espcially if you have to reboot again afterwards. GEMMIS support makes all of this much more seamless. But if you don't feel inspired to work on this functionality, would you be open to accepting pull requests for this from others? |
My experiences - so far - with patches from unknown people are "mixed". So I'm rather sceptical. |
Would it really be that disruptive to add, though? Even if you don't care about the feature much, it's basically a control handover protocol, so it wouldn't require any drastic changes to the overall architecture of JEMM, right? I'm sure a lot of FreeDOS users would really appreciate this functionality. |
Would this just fix Win 3.1? or would it fix other things too? Andreas, Regardless of your decision on this thanks for all your work on this an your other projects (I use most of them). I'm no programmer so I don't want to make unreasonable demands. |
@t9999clint GEMMIS is specifially for being able to start Windows 3.x (in its optimal 386 Enhanced Mode) and Windows 9x from (Free)DOS with JEMM loaded and returning back to DOS when you exit Windows. When you have an EMM loaded that puts DOS in the V86 mode supported by 386 CPUs, but doesn't support GEMMIS, you would have to reboot the computer without the EMM first before being able to start Windows (unless you're running Windows 3.x in Standard mode or Real mode, which gives you reduced functionality and performance). And then after exiting Windows, you'd have to reboot again, if you were to require the EMM for other DOS software. GEMMIS is supported by both the standard EMM386 versions that come with later versions of MS-DOS, as well as by Quarterdeck's QEMM386. Microsoft only shared the specification with a select number of software companies, but it was later reverse-engineered and documented in the Dr. Dobb's Journal article that I shared in this earlier comment further above. |
Oh, so it's just for Windows. Sorry for the pointless post then. On a sidenote I opened a feature request ticket with FreeDOS to add unloading of emm386 to make it easier to switch between jemm and emm386 (fdos version). |
Yes, that's also what I know. And IIRC, Win3.1 in enhanced mode, isn't that limited to FAT16 and short filenames? What applications do actually need this ( and won't run in Win95/98?). |
FYI I found a document that could possibly help us implementing GEMMIS: |
Oh wow, that article @bugnano shared is very interesting! In addition to providing extra technical details on how to implement GEMMIS, it also states an additional use for it besides being able to start Windows 3.x/9x from DOS:
So apparently the demo scene was forced to adopt GEMMIS in the development of their demos as well, at least if they wanted to compete at Assembly 95. (I guess simply using a DOS extender instead of taking over full 386 memory management was somehow considered a no-no in this scene?) @Baron-von-Riedesel If you don't care much about implementing this just for the sake of Windows compatibility, perhaps this would be a more compelling argument for you? 🙂 |
Any updates on this? The FreeDOS Manifesto says the intention is to "eventually, create another implementation of MS-DOS," so I'm surprised to see pushback on finally being compatible with MS-DOS. |
@murkyness Hey, I agree that this feature is one of the things required to match full feature parity with MS-DOS. But the developer of Jemm is under no obligation to implement it. This is still a voluntary project, and that's okay. 🙂 |
@volkertb yeah of course, and I hope I didn't sound rude. Just wanted to point out that it aligns with the project goals, so I was confused by the "not interested, fail to see why it would be useful" response. Another solution would be to update the manifesto to eliminate the contradiction. Either way, I still like this project 😁 |
@Baron-von-Riedesel Do you think it would be feasible for someone to extend Jemm with GEMMIS support through a loadable module (JLM)? That way, you wouldn't have to implement it in Jemm proper, and the desired functionality could still be implemented as an open source solution, without having to write another EMM386 implementation from scratch. I don't know if Jemm's modular architecture could facilitate such functionality, but perhaps it could be made more flexible to accommodate that, if need be? |
A bump on this. I personally have tried enabling GEMMIS back in DOS 6.22 days with a very ancient PC through MEMMAKER. I think it's mostly for allowing users to go back and forth between Windows and DOS using a single configuration without rebooting, and not really useful for other stuffs. It doesn't really fix any issues with Windows, as expanded memory managers were never required, it's the DOS kernel that needs to be compatible and has workarounds for certain quirks (see AARD code). GEMMIS needs to additionally reserve about 32KB of memory in the D000 region, I think (in MEMMAKER this is called "Reserved for Windows", specified using the
If you don't have problems with using different sets of configurations for DOS and Windows (which is relatively trivial to do with MS-DOS and FreeDOS), and rebooting to switch to the other, then yes, GEMMIS is completely optional. I personally set up several configurations, with the Windows one loading only the necessary TSRs and without any expanded memory managers installed. On the other hand (off-topic), addressing issues with certain TSRs and games that only works with MS EMM386 should be of higher priority, as MS EMM386 is very dated and does not work with too much RAM (plus, QEMM386 only allows accessing up to 256MB of memory). Don't know if things like I/O port trapping can be made working in a MS EMM386 complaint manner in the future (so existing apps would work). PS: I don't use SoftMPU, but would it also work in Win3.x, if loaded along with MS EMM386 (GEMMIS enabled)? |
Regarding the DOS kernel, the newest FreeDOS kernel is able to make Windows 3.1 work in 386 enhanced mode 😃, so GEMMIS is really not that important after all. |
I haven't got Win3.x working yet. The CI builds were turned out not built with Maybe it's due to other issues, like the amount of RAM I have and the video card. Though for the former, Win3.x's HIMEM.SYS only handles 64MB and works. Still, it doesn't seem to make any difference yet. |
At this point AARD is implemented on FreeDOS. |
DOS 4 is open sourced with MIT License today. |
Thanks for sharing, @roytam1. However, the reason why GEMMIS hasn't been implemented in Jemm yet is not because of a lack of existing open source implementations of it, since DOSBox supports GEMMIS in its integrated EMM as well. But that's written in C, whereas the Jemm source code is written in assembly. Also, even if it was written in the correct language, it wouldn't guarantee that the porting of such code would be trivial. By the way, I wonder if that version of EMM386 (MEMM?) was perhaps too old to support GEMMIS. Didn't Microsoft develop that standard after DOS 4 was released? |
Very few expanded memory managers have support for GEMMIS. That's unfortunate, because it is required for proper compatibility with Windows 3.x and Windows 9x. It's a standard/specification that allows proper memory management handover to Windows when it's started from DOS.
Adding GEMMIS support to Jemm386 and JemmEx would make them more flexible and versatile. Notably, it would allow FreeDOS to run Windows 3.x (even in 386 Enhanced Mode) out of the box.
DOSBox currently has a GEMMIS implementation, so its source code could be studied as a reference for implementing this in Jemm.
The text was updated successfully, but these errors were encountered: