草庐IT

involuntary

全部标签

c++ - "high involuntary context"开关是什么意思?

我用C语言重新编写了一部分代码。在使用getrusage(2)记录资源使用情况进行测试时CAPI。更改代码之前:usertime(ms):21503systemtime(ms):372involuntarycontextswitches:20更改后:usertime(ms):25589systemtime(ms):80732involuntarycontextswitches:821我看到我重写的代码中有很多非自愿上下文切换。我的问题不是关于如何减少上下文切换。但是..当“非自愿上下文切换”更多时会发生什么?会对系统产生什么影响?P.S:磁盘上没有任何事件,因为没有写入任何内容。它只是

c++ - "high involuntary context"开关是什么意思?

我用C语言重新编写了一部分代码。在使用getrusage(2)记录资源使用情况进行测试时CAPI。更改代码之前:usertime(ms):21503systemtime(ms):372involuntarycontextswitches:20更改后:usertime(ms):25589systemtime(ms):80732involuntarycontextswitches:821我看到我重写的代码中有很多非自愿上下文切换。我的问题不是关于如何减少上下文切换。但是..当“非自愿上下文切换”更多时会发生什么?会对系统产生什么影响?P.S:磁盘上没有任何事件,因为没有写入任何内容。它只是