0% found this document useful (0 votes)
27 views14 pages

Protocol Implementation: An Engineering Approach To Computer Networking

The document discusses different approaches to implementing computer network protocols. It covers partitioning functionality between the user and kernel space, separating layer processing through interfaces, and how the environment around data copy costs, interrupt overhead, and memory access latency impact design. It then examines specific strategies like monolithic in kernel space, monolithic in user space, and per-process in user space. Finally, it provides examples of interface strategies like single-context, tasks, and upcalls as well as performance numbers and design rules of thumb.

Uploaded by

shreelata
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views14 pages

Protocol Implementation: An Engineering Approach To Computer Networking

The document discusses different approaches to implementing computer network protocols. It covers partitioning functionality between the user and kernel space, separating layer processing through interfaces, and how the environment around data copy costs, interrupt overhead, and memory access latency impact design. It then examines specific strategies like monolithic in kernel space, monolithic in user space, and per-process in user space. Finally, it provides examples of interface strategies like single-context, tasks, and upcalls as well as performance numbers and design rules of thumb.

Uploaded by

shreelata
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 14

Protocol Implementation

An Engineering Approach to Computer Networking


Protocol implementation
 Depends on structure and environment
 Structure
 partitioning of functionality between user and kernel
 separation of layer processing (interface)
 Environment
 data copy cost
 interrupt overhead
 context switch time
 latency in accessing memory
 cache effects
Partitioning strategies

 How much to put in user space, and how much in kernel space?
 tradeoff between
 software engineering

 customizability

 security

 performance

 Monolithic in kernel space


 Monolithic in user space
 Per-process in user space
Interface strategies

 Single-context
 Tasks
 Upcalls
Monolithic in kernel
Monolithic in user space
Per-process in user space
Interfaces
 Single-context
 Tasks
 Upcalls
Single context
Tasks
Upcalls
Protocol implementation
Some numbers
 10 Kbps 400 ms
 100 Kbps, 40 ms
 1 Mbps, 4 ms
 100 Mbps, 40 µs
 User-to-kernel context switch ~40 µs
 Copying the packet ~25 µs
 Checksum in software ~40 µs
 Scheduling delays ~150 µs (depends on workload)
 Interrupt handling ~10-50 µs (depends on the bus)
 Protocol processing ~15 -100 µs (depends on protocol
complexity)
Rules of thumb
 Optimize common case
 Watch out for bottlenecks
 Fine tune inner loops
 Choose good data structures
 Beware of data touching
 Minimize # packets sent
 Send largest packets possible
 Cache hints
 Use hardware
 Exploit application properties

You might also like