delorie.com/djgpp/faq/performance/faster-io.html
|
search
|
What can I do if my application absolutely must use the fastest
possible I/O, and I can't wait until v2.0?
If you have such an application, you'll have to provide your private
transfer buffer and use low-level DOS calls directly. go32
provides DPMI server calls which you can summon to this end. To
implement such a mechanism, one should do at least the following:
- Allocate a 64KB transfer buffer in low (under 640K) memory using
_go32_dpmi_allocate_dos_memory().
- Move data between that buffer and your program using
movedata().
- Call DOS I/O functions using _go32_dpmi_simulate_int().
In addition, it might be necessary to implement your own buffering
mechanism (to provide your application with semi-transparent
stream-like I/O).