线程上下文切换的代价并不大。
连接集中器与代理的上下文切换相关联。
The connection concentrator is associated with context switching of agents.
图2展示了上下文切换。
用户空间路由还强制进行至少两次上下文切换。
步骤四:系统调用返回,导致了第4次上下文切换。
Step four: the write system call returns, creating our fourth context switch.
在软件开发这样的复杂任务环境中上下文切换也是个问题。
Context switching in a complex task environment like software development is a major problem.
send系统调用返回,结果导致了第四次的上下文切换。
The send system call returns, creating the fourth context switch.
增加时间切片可减少上下文切换,从而可以提高系统吞吐量。
Increasing the time slice can improve system throughput due to reduced context switching.
首先,就计算时间而言,事务上下文切换是开销相当大的操作。
First, transaction context switches are quite expensive operations in terms of computation time.
然而,我们必须小心,因为随着线程的增加,上下文切换也增加。
However, we had to be careful because, as you increase this number, context switching also increases.
两个内核之间在内部执行上下文切换,但这可以非常快速地完成。
Internally, a context switch is performed between these two kernels, but this can be done quite fast.
send套接字调用引发了从用户模式到内核模式的上下文切换。
The send socket call causes a context switch from user mode to kernel mode.
由于要在线程间进行上下文切换,因此CPU简直变成了超载。
The CPU simply becomes overburdened by context switching between threads.
send() 套接字调用引发了从用户模式到内核模式的上下文切换。
Step three: the write system call causes a context switch from user mode to kernel mode.
另外,如果每个线程都忙于处理网络连接,线程之间的上下文切换会很频繁。
And if each thread (ergo network connection) is busy, then the context switching to each thread can be significant.
Erlang中的进程内存较小,可快速启动和进行上下文切换。
Processes in Erlang are assumed to be small in memory, fast to start, and fast to context-switch.
read调用(参见图2)引发了一次从用户模式到内核模式的上下文切换。
The read call causes a context switch (see Figure 2) from user mode to kernel mode.
由此造成的上下文切换相对于锁保护的少数几条指令来说,会造成相当大的延迟。
The resulting context switches can cause a significant delay relative to the few instructions protected by the lock.
现代操作系统通常在进程调度方面表现得很出色,从而最大程度减少了上下文切换。
Modern operating systems generally do an excellent job of process scheduling, which minimizes context switching.
这要求上下文切换到内核线程,以处理将数据移动到磁盘以及从磁盘移出数据的任务。
This requires a context switch to the kernel thread to handle the task of moving data to and from disk.
这就引起所谓的从“用户空间”到“内核空间”的上下文切换,不过这仅供了解之用。
This causes what is known as a context switch from "user space" to "kernel space," although that's just for you information.
该调用的返回引发了内核模式到用户模式的上下文切换(又一次上下文切换)。
The return from the call causes another context switch from kernel back to user mode.
该调用的返回引发了内核模式到用户模式的上下文切换(又一次上下文切换)。
The return from the call caused a context switch from kernel back to user mode.
read() 调用(参见 图 2)引发了一次从用户模式到内核模式的上下文切换。
Step one: the read system call causes a context switch from user mode to kernel mode.
零拷贝不仅大大地提高了应用程序的性能,而且还减少了内核与用户模式间的上下文切换。
Zero copy greatly improves application performance and reduces the number of context switches between kernel and user mode.
上下文切换包括保存正在运行的任务的上下文和恢复早先保存的另一个任务的上下文。
A context switch involves saving the context of the running ask and restoring the previously-saved context of the other.
VxWorks可以跟踪所有你感兴趣的系统事件,包括上下文切换、同步对象的使用和中断。
VxWorks can be run in a mode where it records a total trace of all interesting system events, including context switches, uses of synchronization objects, and interrupts.
如果上下文切换的值非常高,则增加时间切片可提高性能,但这必须在经过大量分析之后才能实施。
If the value of context switching is very high, increasing the time slice can improve performance, but this should only be done after extensive analysis.
如果不这样做的话,就需要在虚拟处理器上下文切换的过程中保存该虚拟处理器中使用的所有资源。
If not, all resources are used in the virtual processor, saving all of them from a virtual processor context switch.
这样就能够避免网络延迟、进程间通信的开销以及操作系统中的上下文切换,从而进一步提高速度。
This avoids network latency and the overhead of inter-process communication, as well as context switching in the operating system, further contributing to extreme speed.
应用推荐