Coder Social home page Coder Social logo

Comments (1)

klauspost avatar klauspost commented on May 22, 2024

Threads Per Core is not going to be accurate.

But it does seem like there is something fishy with the latest Intels:

=== RUN   TestMocks/GenuineIntel00B06A2_RaptorLakeP_04_CPUID.txt
    mockcpu_test.go:180: Opening GenuineIntel00B06A2_RaptorLakeP_04_CPUID.txt
    mockcpu_test.go:183: Name: 13th Gen Intel(R) Core(TM) i9-13900H
    mockcpu_test.go:185: Max Function:0x20
    mockcpu_test.go:187: Max Extended Function:0x80000008
    mockcpu_test.go:188: VendorString: GenuineIntel
    mockcpu_test.go:189: VendorID: Intel
    mockcpu_test.go:190: PhysicalCores: 10
    mockcpu_test.go:191: ThreadsPerCore: 2
    mockcpu_test.go:192: LogicalCores: 20
    mockcpu_test.go:193: Family 6 Model: 186 Stepping: 2
    mockcpu_test.go:194: Features: ADX,AESNI,AVX,AVX2,AVXVNNI,BHI_CTRL,BMI1,BMI2,CETIBT,CETSS,CLMUL,CMOV,CMPXCHG8,CX16,ERMS,F16C,FLUSH_L1D,FMA3,FSRM,FXSR,FXSROPT,GFNI,HRESET,HTT,HYBRID_CPU,IA32_ARCH_CAP,IA32_CORE_CAP,IBPB,IDPRED_CTRL,KEYLOCKER,LAHF,LZCNT,MD_CLEAR,MMX,MOVBE,MOVDIR64B,MOVDIRI,NX,OSXSAVE,PCONFIG,POPCNT,PSFD,RDRAND,RDSEED,RDTSCP,RRSBA_CTRL,SERIALIZE,SHA,SPEC_CTRL_SSBD,SSE,SSE2,SSE3,SSE4,SSE42,SSSE3,STIBP,STOSB_SHORT,SYSEE,TME,VAES,VMX,VPCLMULQDQ,WAITPKG,X87,XGETBV1,XSAVE,XSAVEC,XSAVEOPT,XSAVES
    mockcpu_test.go:195: Microarchitecture level: 3
    mockcpu_test.go:196: Cacheline bytes: 64
    mockcpu_test.go:197: L1 Instruction Cache: 32768 bytes
    mockcpu_test.go:198: L1 Data Cache: 49152 bytes
    mockcpu_test.go:199: L2 Cache: 1310720 bytes
    mockcpu_test.go:200: L3 Cache: 25165824 bytes
    mockcpu_test.go:201: Hz: 3000000000 Hz
    mockcpu_test.go:202: Boost: 5400000000 Hz
  • Total Cores: 14
  • no of Performance-cores: 6
  • no of Efficient-cores: 8
  • Total Threads: 20

https://www.intel.com/content/www/us/en/products/sku/232135/intel-core-i913900h-processor-24m-cache-up-to-5-40-ghz/specifications.html

Problem seem to be:

func physicalCores() int {
	v, _ := vendorID()
	switch v {
	case Intel:
		return logicalCores() / threadsPerCore()

So some work will have to be put into changing the detection of this, and maybe some additional information on slow/fast cores.

from cpuid.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.