From: Gal R. <GA...@il...> - 2011-05-04 11:38:59
|
I started my implementation with the high level, then I moved to the low level in order to make read/write asynchronous, using single thread. Then I notice that even if I make it all async in the user space, it still synchronous in the fuse module in the kernel per file, because per file the module put the request on a list, set the appropriate state, and wait for it to finish, only then it put the next request. So I made some changes to the module in order to be able to send requests in parallel per file, using the background function. I made some tests and it shows very good improvement in performance. Then I started to think in read operation I allocated the buffer myself, so there shouldn't be a problem, but in write, am I not overriding the data, because I release the synchronous barrier in the kernel, and as I understand there is only one buffer for accepting the request in user space (4K or 128K in big_writes, plus 4K header), this includes the data, and as I also understand there is no copy of the data buffer anywhere, am I right ? If this is the case, even without my changes, if one is working with multiple files with single thread then the data is override. Gal. |------------> | From: | |------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| |Miklos Szeredi <mi...@sz...> | >--------------------------------------------------------------------------------------------------------------------------------------------------| |------------> | To: | |------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| |Gal Rosen/Haifa/IBM@IBMIL | >--------------------------------------------------------------------------------------------------------------------------------------------------| |------------> | Cc: | |------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| |fus...@li... | >--------------------------------------------------------------------------------------------------------------------------------------------------| |------------> | Date: | |------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| |05/04/2011 01:54 PM | >--------------------------------------------------------------------------------------------------------------------------------------------------| |------------> | Subject: | |------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| |Re: [fuse-devel] read/write allocation asymetric | >--------------------------------------------------------------------------------------------------------------------------------------------------| Gal Rosen <GA...@il...> writes: > I am trying to understand why in WRITE opcode the data buffer is > pre-allocated in the library, actually for any request the fuse > library is using a pre-allocated buffer which include the header and > data, and in the READ opcode the allocation of space for the read data > is done in the implementation of the file system. In the high level interface buffer is allocated for both read and write. In the low level interface letting the filesystem allocate the buffer for read is for making the interface more flexible. Why is this a problem? Thanks, Miklos ------------------------------------------------------------------------------ WhatsUp Gold - Download Free Network Management Software The most intuitive, comprehensive, and cost-effective network management toolset available today. Delivers lowest initial acquisition cost and overall TCO of any competing solution. http://p.sf.net/sfu/whatsupgold-sd _______________________________________________ fuse-devel mailing list fus...@li... https://lists.sourceforge.net/lists/listinfo/fuse-devel |