m-j-w / CpuId.jl

Ask the CPU for cache sizes, SIMD feature support, a running hypervisor, and more.
Other
54 stars 10 forks source link

Detect running in container (non-hypervisor virtualisation) #13

Closed m-j-w closed 7 years ago

m-j-w commented 7 years ago

It appears containers are not hypervisors, but still tamper with cpuid, as observed in #9 on pkglisting. That CPU should have AVX2 and different cache sizes, to say the least.

This applies at least to Vagrant, possibly also to Docker etc.

Intermediate solution: Update the README.md to give a background and specific limitation note.

m-j-w commented 7 years ago

This is actually wrong. The configuration of vagrant on which pkg listing runs simply uses a hypervisor that tries to hide the real cpu information. Hence this is a non-issue and already mentioned in the form of "don't trust hypervisors".