Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[dsdp-tcf-dev] [Bug 284873] [tcf][agent] Zerocopy splice from file descriptor

https://bugs.eclipse.org/bugs/show_bug.cgi?id=284873  
Product/Component: Target Management / TCF

Michael Sills-Lavoie <michael.sills.lavoie@xxxxxxxxx> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |




--- Comment #3 from Michael Sills-Lavoie <michael.sills.lavoie@xxxxxxxxx>  2009-08-05 16:05:57 -0400 ---
I have tested the patch applied for this bug and there is a small problem that
we need to correct.

We need to be able to specify the offset of the file where we read the data in
the splice call to be able to read without changing the input pointer of the
file descriptor. This is something that we need in order to be able to read
pseudo-file that map kernel memory onto the disk. (this is what we do for our
kernel tracer)

I created a quick fix for this problem that add the offset as a parameter to
the splice_block_stream and tcp_splice_block_stream function. I also created a
json_splice_binary_offset function and modified the json_splice_binary to call
it. (See attachment 143552)

The problem is that the offset is ignore if the client/architecture doesn't
support ZeroCopy and Splice.

I thought of using the pread function instead of read to read the data from the
file descriptor in json_splice_binary_offset and tcp_splice_block_stream, but
this function exist only on Unix.

What do you think we could do to improve that? Maybe we could offer the splice
functions only to Unix systems instead of all systems?

Thanks

Legal Message: I, Michael Sills-Lavoie, declare that I developed attached code
from scratch, without referencing any 3rd party materials except material
licensed under the EPL and EDL. I am authorized by my employer, École
Polytechnique de Montréal, to make this contribution under the EPL and EDL.

The École Polytechnique de Montréal is a member of the Eclipse Associate and
Eclipse Membership At Large communities.


-- 
Configure bugmail: https://bugs.eclipse.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.

Back to the top