Need ideas about ntoskrnl (WITH ideas)

Alexandre Julliard julliard at winehq.org
Thu Sep 8 05:06:42 CDT 2005


Mike McCormack <mike at codeweavers.com> writes:

> Wine used to have function call tables like this about 5 years, and 
> typed handles about a year ago.  Those things have been removed on purpose.
>
> You can't store function pointers in the wineserver, as each process may 
> have those functions at a different address.
>
> It looks like Alexandre has made the design decision to live with a file 
> handle mapping to a single Unix file descriptor a while back.  That 
> makes things difficult for people who want to write code to load and use 
> device drivers in any consistent fashion.

The problem is that our I/O performance sucks, and we need to improve
it by having a faster mechanism to map from handle to file
descriptor. That doesn't mean we cannot have a special case for
drivers, but it needs to be done in a way that doesn't impact normal
I/O. This means that for instance doing a system call to retrieve the
handle type is not an option. There are other possible ways though,
for example by having the mapping return some sort of magic file
descriptor that can somehow be identified as belonging to a device
(details left as an exercise for the reader ;-)

Then we could imagine a generic mechanism to redirect I/O calls for
specific devices to the wineserver, which could then either handle
them directly or forward them to ntoskrnl for the case of a native
driver. If done right, such a mechanism could probably also be used to
fix the async I/O support, which is currently in pretty bad shape.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list