Stored Program Concept

A design where program instructions and data are stored in the same memory.

The Stored Program Concept jest fundamentalną zasadą w architekturze komputerów, zapoczątkowaną przez Johna von Neumanna i innych, która dyktuje, że instrukcje komputera (program) są przechowywane w tej samej pamięci co dane, na których program operuje. Jest to sprzeczne z wcześniejszymi elektronicznymi urządzeniami obliczeniowymi, gdzie instrukcje były hardwired lub ustawiane za pomocą fizycznych przełączników i paneli połączeniowych. W komputerze z programem przechowywanym w pamięci, jednostka centralna (CPU) może pobierać instrukcje z pamięci, dekodować je i wykonywać sekwencyjnie. Pozwala to komputerom być maszynami ogólnego przeznaczenia, zdolnymi do wykonywania dowolnego programu, który można przedstawić w formie binarnej i załadować do pamięci. Możliwość modyfikacji programów w pamięci umożliwia również self-modifying code, chociaż praktyka ta jest generalnie odradzana w nowoczesnym programowaniu ze względów bezpieczeństwa i łatwości utrzymania. Architektura von Neumanna, oparta na tej koncepcji, zazwyczaj obejmuje CPU, pamięć (zarówno dla instrukcji, jak i danych), mechanizmy wejścia/wyjścia oraz system bus do komunikacji między tymi komponentami. Ta architektura stanowi podstawę praktycznie wszystkich nowoczesnych komputerów cyfrowych.

        graph LR
  Center["Stored Program Concept"]:::main
  Pre_computer_science["computer-science"]:::pre --> Center
  click Pre_computer_science "/terms/computer-science"
  Rel_advanced_propulsion_systems["advanced-propulsion-systems"]:::related -.-> Center
  click Rel_advanced_propulsion_systems "/terms/advanced-propulsion-systems"
  Rel_file_systems["file-systems"]:::related -.-> Center
  click Rel_file_systems "/terms/file-systems"
  Rel_pointer["pointer"]:::related -.-> Center
  click Rel_pointer "/terms/pointer"
  classDef main fill:#7c3aed,stroke:#8b5cf6,stroke-width:2px,color:white,font-weight:bold,rx:5,ry:5;
  classDef pre fill:#0f172a,stroke:#3b82f6,color:#94a3b8,rx:5,ry:5;
  classDef child fill:#0f172a,stroke:#10b981,color:#94a3b8,rx:5,ry:5;
  classDef related fill:#0f172a,stroke:#8b5cf6,stroke-dasharray: 5 5,color:#94a3b8,rx:5,ry:5;
  linkStyle default stroke:#4b5563,stroke-width:2px;

      

🧠 Sprawdzenie wiedzy

1 / 4

🧒 Wyjaśnij jak 5-latkowi

To jest jak posiadanie książki kucharskiej w swojej kuchni. Zamiast budować nową kuchnię dla każdego posiłku, po prostu mówisz kuchni (komputerowi), którą recepturę (program) ma wykonać z książki, a ona używa składników (danych), które tam znajdzie.

🤓 Expert Deep Dive

The Stored Program Concept, embodied by the von Neumann architecture, revolutionized computing by decoupling instruction logic from hardware configuration. The core innovation lies in treating instructions as data, enabling them to be fetched, processed, and even modified by the CPU itself. This unified memory space, however, leads to the 'von Neumann bottleneck,' where the shared bus between the CPU and memory limits throughput, as instructions and data compete for access. Architectures like the Harvard architecture, which use separate memory spaces and buses for instructions and data, mitigate this bottleneck but sacrifice the flexibility of unified memory. The concept's significance lies in its enabling of programmability, leading to the development of operating systems, compilers, and the vast software ecosystem we rely on today. Its theoretical underpinnings relate to Turing completeness and the universality of computation.

🔗 Powiązane terminy

Wymagana wiedza:

📚 Źródła