Re: TUN/TAP/character device read()/write() performance

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi, Hayim =)

Great!  That sounds interesting.. If it's not too much trouble, I'd love
if you could manage to locate the paper..  Or even the title of the
paper, might be able to find it from scholar.google, too.

Thanks for the support - it's much appreciated =)

The project's currently sitting at
http://www.csse.monash.edu.au/~mtyson, if you were interested.. Alas,
it's a dull CS honours project, but if it looks promising, I might
continue it afterwards in the real world.  Perhaps =)

Cheers =)

Mike

Hayim Shaul wrote:
> 
> I once read a paper by some Intel guys that experimented with this.
> They claimed that no-copy network access improves performance by ~10%.
> 
> I need to find this paper in my room, if you'd like.
> 
> I also tried to pull such a trick few months ago.
> It worked OK most of the time, and I didn't have the time yet to solve
> the problems.
> 
> I'll be happy to hear more about your project, help if I can and learn
> about your adventures.
> 
> Hayim.
> 
> On Thu, 16 Jun 2005, Mike Tyson wrote:
> 
> Hi!
> 
> I'm building an ad-hoc network driver that consists of a user-space
> daemon, and a kernel module to provide access for the daemon.
> 
> I'm trying to decide whether to continue with my prior plan to use a
> bunch of mmap()'d memory to pass packets around, through a character
> device, or whether to instead use read/write operations on the character
> device.
> 
> Using mmap()'d memory is presumably more efficient, because no memory
> copying has to be done, but in order to implement it, I'd imagine I have
> to write my own 'memory management' system, to allocate memory to packet
> buffers within the shared memory area, and I have to implement a shared
> kernel/userspace mutex (which is the cause of my current headache).
> That sounds like a lot of work.
> 
> Using just read/write operations means I don't have to muck around with
> all that messy synchronisation/memory management/signalling, and can
> just pass data in the same was that tun/tap does.
> 
> So, my question is this: How well does tun/tap perform, generally?  Is
> it indeed the bottleneck I've previously been led to believe?
> Does anyone know what kind of throughput I can expect from a character
> device through read/write operations?
> 
> If it's likely to be a bottleneck, I may just continue with the mmap()
> idea, but if there's good reason to believe it won't degrade
> performance, then I might just give up this folly and use read/write
> ops =)
> 
> Cheers,
> 
> Mike
> 
> 
> --
> Mike Tyson <mike@xxxxxxxxxxxxx>
> M: (+61) 0407 754 124
> W: http://tzidesign.com
> 
>>
- --
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/
>>
>>
+++++++++++++++++++++++++++++++++++++++++++
This Mail Was Scanned By Mail-seCure System
at the Tel-Aviv University CC.
>>

- --
Mike Tyson <mike@xxxxxxxxxxxxx>
M: (+61) 0407 754 124
W: http://tzidesign.com

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)

iD8DBQFCshCI/eih+gEb7pQRAl/9AKCq+xmDo1aQXkO967rbxBBXCq9LEgCg/QiS
ro2dv4y4o/sfENB4ofkOPQY=
=PuU+
-----END PGP SIGNATURE-----

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux