Knowledge base
  • Goal of knowledge base
  • Linux & core
    • Linux
      • Record SSH session for reporting
      • Compress / Decompress files
      • Colorize logs
      • Cron output & logging
      • Signal
      • Break out and escape SSH session
      • Mount volume permanently
      • Show processes most consuming CPU & MEM
      • Improve and optimize battery life on Linux
      • File ownership & groups in linux
      • Automatic security update/patch on Ubuntu
      • Clean buffers and cached on linux
      • Bash completion on Linux/Mac
    • Core services
      • Nginx reload
      • OpenVPN Split tunneling
      • Nmap commands
    • Hardware
      • CPU Architecture fundamental
  • Database
    • MySQL
      • InnoDB - innodb_file_per_table parameter
      • MySQL - enable slow query log
      • MySQL - export large tables
    • MongoDB
  • Container
    • Docker
      • ADD or COPY in Dockerfile
        • Clean data of docker completely
    • Podman
  • Automation
    • Ansible
      • Output format
  • Build & Deployment
    • Jenkins
      • Jenkins - force exit pipeline when failure
  • Language & Toolset
    • PHP
      • Composer
      • php-redis & php-igbinary
  • Mindset
    • Technical based
      • Writing well
      • Reinvent The Wheel
      • Approach a new system
      • Backup philosophy
      • Mindset for building HA and scalable system
      • GitLab database incident
    • Non-technical based
      • How to read news efficiency?
      • How long should you nap?
      • Assume good faith
  • Reference & learning source
    • Books
      • Sysadmin/SRE
      • Mindsets
      • Software fundamentals
    • English
Powered by GitBook
On this page
  • Terminology
  • Example
  • Reference
  1. Linux & core
  2. Hardware

CPU Architecture fundamental

PreviousHardwareNextMySQL

Last updated 6 years ago

Terminology

  • Processor: the physical chip that plugs into a socket on the system or processor board and contains one or more CPUs implemented as cores or hardware threads.

  • Core: an independent CPU instance on a multicore processor. The use of cores is a way to scale processors, called chip-level multiprocessing (CMP).

  • Hardware thread: a CPU architecture that supports executing multiple threads in parallel on a single core (including Intel’s Hyper-Threading Technology), where each thread is an independent CPU instance. One name for this scaling approach is multithreading.

  • CPU instruction: a single CPU operation, from its instruction set. There are instructions for arithmetic operations, memory I/O, and control logic.

  • Logical CPU: also called a virtual processor (vCPU), an operating system CPU instance (a schedulable CPU entity). This may be implemented by the processor as a hardware thread (in which case it may also be called a virtual core), a core, or a single-core processor.

  • Scheduler: the kernel subsystem that assigns threads to run on CPUs.

  • Run queue: a queue of runnable threads that are waiting to be serviced by CPUs. For Solaris, it is often called a dispatcher queue.

Example

Intel® Core™ Processor on Macbook pro: 2 cores, 4 threads

sysctl -n hw.ncpu # = 4
sysctl -n hw.physicalcpu # = 2
sysctl -n hw.logicalcpu # = 4

Reference

Chapter 6: CPUs in

i7-5557U
http://www.brendangregg.com/sysperfbook.html