F800上的CPU有多少个core?

本来想看看F800的一个节点上,每个core的cpu的使用情况。使用下面的命令,可以进行查看:

top –P


从命令输出来看,好像是有32个core嘛。

image


使用下面的命令可以看到具体的CPU的信息。

dmidecode

image


明明写的是16个core啊,但是注意, thread count是32. 这是怎么回事呢?

因为CPU使用一种叫做Hyper-threading (Hyper-Threading Technology, HTT)的技术。维基百科介绍如下:

For each processor core that is physically present, the operating system addresses two virtual (logical) cores and shares the workload between them when possible. The main function of hyper-threading is to increase the number of independent instructions in the pipeline; it takes advantage of superscalar architecture, in which multiple instructions operate on separate data in parallel. With HTT, one physical core appears as two processors to the operating system, allowing concurrent scheduling of two processes per core. In addition, two or more processes can use the same resources: if resources for one process are not available, then another process can continue if its resources are available.


使用HTT技术之后,一个物理的core在操作系统中会展现为两个processor,所以我们就看到了F800的top -P命令输出里的32个CPU了。


参考资料

==============

Hyper-threading

https://en.wikipedia.org/wiki/Hyper-threading

posted on 2018-05-18 10:58  中道学友  阅读(293)  评论(2编辑  收藏  举报

导航

技术追求准确,态度积极向上