I forgot to say something. It has to be DOS compatible source code. It's for my new OS. I need it to be multi-tasking/threading. The OS will use DOS as a base to start the PC and then DOS will run my OS which will start the OS's GUI system. But first, DOS multi-tasking samples are needed.
Designer/Programmer of the Comtech Operating System(CTOS)
I know. I've done MASSIVE amounts of research, but it seems very complicated. I've found a sample called "Micro-thread". It says it may crash, it's not mean't for big high-performance programs(Or operating systems?), and that it needs some work. I have however found something multi-tasking with a scheduler built-in. It seems good. I works as follows:
1) Do thread1 until 1 clock tick has passed.
2) Suspend the thread, run thread2 for 1 clk pulse.
3) Suspend thread2, and run thread3 for 1 clk pulse.
4) Suspend thread3, and resume thread1. Go back to beginning.
It seems to be good. Here, I'll give it to you guys so you can check it. I found it on www.programmersheaven.com
Please add stuff to it. If you have another sample or a better sample, PLEASE post it. The sample says that DOS is non-reentrant. What the h*** is that? It also says that you can't use calls like int86 and int86x while the threading is running. It also says there is a way to fix it. Can someone please help???
Designer/Programmer of the Comtech Operating System(CTOS)
Honestly I dont know much of C/C++. But I read somewhere that Multiplexer Interrupt could be handled such that task switching is more stable. And can also make your program re-entrant.
Any way I'm Not Sure.
Can Anyone tell me which powerful language to use to create standalone, efficient and faster EXEs.
Really? So far, it's not much... It'll have some options that MS forgot about(shhhhh... don't tell them ). Here's a good one... You all know what a CMOS chip is(I hope). It's a chip that holds info on the hardware settings and stuff and it's battery powered(uh-oh...). If these batteries die, that chip loses it's data, and then you have to reset all of the configs... Believe me, It's not fun CTOS will be able to get the CMOS settings and save them to a file. If the CMOS battery dies, just type in the CMOS settings you think will work, load CTOS and tell it to restore the CMOS settings. It's something a genious would think about!!! That's only 1 small thing that's easy to work out(The CMOS saver/loader is finished).
Now I've got multi-tasking to worry about. This is HARD SH*T!!! I have to synchronize all of CTOS's routines together, seemlessly, like Windows... uh... not like Windows, I don't like the crashes.
For the multi-threading, I'll need a thread for the VMem system, a thread for the GUI drawing routines. In win, it's GDI for drawing. Kernel32.dll does most of the multi-tasking/multi-processing jobs.
At this rate, we'll be able to see an early version of CTOS shortly(A couple months). With more help, we can get it done faster.
People, bring me some assembly code for the routines you feel should be done quickly(Multi-tasking & Low level mem routines). I'll be able to use it now that I'm using BorlandC 5.0 instead of PowerC.
KrishnaSantosh, could you please find that document? It would prove useful!
BTW: I am happy to hear that people are looking forward to this. If you have more questions on CTOS, please reply in my thread in the "Project Request" forum. Thankyou.
Designer/Programmer of the Comtech Operating System(CTOS)