Enica Design Author Dr. Ssa Veronica Marchetti Università De
Enica Designauthor Dr Ssa Veronica Marchettiuniversita Degli Studi D
Enica Designauthor Dr Ssa Veronica Marchettiuniversita Degli Studi D
ENICA Design Author: Dr. ssa Veronica Marchetti Universita degli Studi di Roma “Tor Vergata”. Translated and Digested by: Dr. Sophia Scoggins 03/2019 vCPU 1.1. Architecture The architecture of the vCPU is at 24bit. Are then used words in length 24bit equal to without a sign, or between - and with sign in two's-complement; all of the devices that will be briefly treated are conceived, designed, and implemented for work at 24bit. Figure 1.
ENIAC Simulator Example fattoriable.eniac in Binary 1.2. CPU A.L.U. Arithmetic Logic Unit (ALU) is the real unit of calculation, The ALU is designed to perform operations between words to 24-bit with a sign, but without a comma. It allows user to perform all the basic operations, including: Sum; Subtraction; Increment; Decrease; Division; Module; Multiplication; or Particular: since the product of the two numbers at 24bit makes one to 48bit, will be divided the result into two parts: R0 and R1; Logical AND Logical; Logical OR; XOR Logic; Logical NOT; 1.3. Ports Because of the architecture at 24bit, for simplicity, the cells of the doors can contain words of the same size. Are used to load I/O devices external. The doors are made from 212 cells. Through the port column, you can enable or disable devices to connect to the ports; 1.4. Register Basically there are five registers, suitable for different purposes: · AX: also called the accumulator is used as the default registry for most of the operations; · BX,CX,DX registers general purpose usable by the programmer; · PC: the Program Counter, i.e. the register that is in charge of saving the address of the memory cell that contains the next statement to be run. 1.5. Flags The flags are of registers of size 1, have the function to determine the flow of the program. For convenience, from now on, when we speak of registers, shall those of paragraph (1.5) while for register flags you will use the only the end flags. Can have the value 1 or 0, are divided into two categories and are set by the result of the last operation: Simple; Sign (SI): value is 1 if the result is negative, 0 otherwise; Zero (ZE): value is 1 if the result is zero, 0 otherwise; Equal (EV): value is 1 if the sum of the 1 bits of the result is even, 0 otherwise; Complex; are specific to the operations of sum and multiplication: Sum: Carry-over (CA): it is 1 if there is a carry, 0 otherwise; Overflow (OV): that is 1 if the MSB of the result differs from the MSB of the operands, 0 otherwise. Product: Carry-over (CA): value is 0 if the bits in R1 and the MSB in R0 are all equal, 1 otherwise; Overaflow (OV): same as CA. CPU Instructions 2.1. Operation Code (OpCode) There are two classes of instructions: alpha and beta. Have tasks different because the alpha class allows you to manage operations beyond that the logic and storage; each statement can get to have up to five different types of operands in the argument: (Indicating with “Operand†is the value). Immediate: the operand is exactly the value to use; example: ADD Z; Direct address: the operand is in memory cell indicated. Format: Memory -> Operand; example: ADD @N; Indirect address: operand is in memory cell whose address is in the memory cell indicated. Format: Memory -> Memory -> Operand; example: ADD @@N; Register: the operand is in the register indicated. Format: Log -> Operand; example: ADD R; Register Indirect: the operand is in memory cell whose address is in the indicated register. Format: Register -> Memory -> Operand; example: ADD @R; For the operand, are devoted to the thirteen bit more to the right, and then you need to do clarifications on the meaning of Z,N,R: Z: integer value between -4096 and +4095, since it is 213 two's-complement; N: since the memory cells are 212 the address is between 0 and+4095; R: the logs are five, will be therefore used five positive integers to the address referred to, for convenience, is shown the coding of the whole rather that in binary: o AX: 0; o BX: 1; o CX: 6; o DX: 7; o PC: 4095; Speaking of the beta-type, not subtypes, and contains primarily instructions for the control of the program flow, conditional jump, and unconditional. To avoid confusion, throughout the thesis we will refer to the “class alpha or class beta†with “alpha type or beta-typeâ€. 2.2. Save File The users can write code and save the files. Or load the file from the disk. Figure 2. Save or Load Assembly Code Menu Cpu: Click ‘Play’ to control the flow of execution as: Step, Play, Pause, Stop, Speed: 0, 100, 200, 500, or 1000. The numbers express the pause time, in milliseconds (ms), between the execution of a statement and the next; Figure 3. Execute the Assembly Code The Assembly code the ‘Content’ column can be in displayed in different address format: Bin –- in binary # Dec – in decimal # Hex – in hexadecimal # Syntax – in user friendly ASCII code Figure 4. Assembly Code Display Format
Paper For Above instruction
The development of early computer architecture laid the foundation for modern digital systems, with the ENIAC (Electronic Numerical Integrator and Computer) standing as one of the pioneering models. The evolution from the ENIAC to contemporary virtual CPU (vCPU) architectures reflects significant progress in design complexity, operational efficiency, and functionality. This paper explores the architecture and operational principles of a virtual CPU modeled at a 24-bit word length, highlighting its structural components such as registers, ALU, flags, ports, and instruction sets, as well as the implications these features have on functionality and performance.
Architecture Overview
The vCPU under discussion adopts a 24-bit architecture, with each word being either unsigned or utilizing two's complement representation to account for signed numbers. This configuration ensures that operations, data storage, and address calculations are uniformly handled within a 24-bit framework. The significance of this design choice is to accommodate a balance between data precision and memory efficiency, aligning with earlier computational models while supporting modern computational needs.
Arithmetic Logic Unit (ALU) and Operations
The ALU is the core computational unit within the vCPU, responsible for executing integer arithmetic and logic operations. It supports basic arithmetic functions such as addition, subtraction, multiplication, division, and modulus, with the product of two 24-bit numbers extending into 48 bits, which is managed through division into two parts: R0 and R1. Logical operations include AND, OR, XOR, and NOT, enabling complex bitwise manipulations essential for low-level programming and hardware control.
Memory and Ports
Memory segmentation consists of cells capable of storing 24-bit words; for simplicity, all cells are of uniform size. External I/O devices connect via ports composed of 212 cells, with mechanisms to enable or disable device connectivity. This design supports modular expansion and streamlined data transfer between external hardware and the CPU.
Registers and Flags
The system employs five key registers: the accumulator (AX), which serves as the default working register; general-purpose registers (BX, CX, DX); and the program counter (PC), which stores the address of the next instruction to execute. Flags, which are single-bit registers, monitor the results of operations to influence control flow decisions. These flags include sign, zero, even, carry-over, and overflow indicators, facilitating precise condition monitoring and decision-making within programs.
Instruction Sets and Operation Codes (OpCodes)
The instruction set comprises alpha and beta classes, with alpha instructions managing data operations and storage, and beta instructions controlling program flow through conditional and unconditional jumps. The addressing modes include immediate, direct, indirect, register, and register-indirect, providing versatile operands for complex instruction formulation. For instance, immediate mode uses explicit values, while register modes reference internal CPU registers, enabling flexible and efficient programming.
Programming and File Management
Users can write, save, and load assembly code files, facilitating iterative development and testing of machine-level programs. The interface provides controls such as step, play, pause, stop, and adjustable speed, measured in milliseconds, for simulating instruction execution with precise timing. Different display formats (binary, decimal, hexadecimal, ASCII) enhance readability and debugging capabilities, supporting comprehensive development workflows.
In conclusion, the architecture and operational design of this 24-bit virtual CPU encapsulate foundational principles of computer architecture while integrating features for modern usability. Its structured register set, comprehensive ALU operations, flexible instruction formats, and user-friendly interface collectively demonstrate a significant step toward advanced simulation and educational tools for understanding computing systems.
References
- Hennessy, J. L., & Patterson, D. A. (2017). Computer Organization and Design: The Hardware/Software Interface. Morgan Kaufmann.
- Patterson, D. A., & Hennessy, J. L. (2014). Computer Architecture: A Quantitative Approach. Morgan Kaufmann.
- Stallings, W. (2018). Computer Organization and Architecture. Pearson.
- Tanenbaum, A. S., & Austin, T. (2012). Structured Computer Organization. Pearson.
- Siewiorek, D. P., & Swarz, R. S. (2018). The Theory and Practice of Reliable Computer Systems. Digital Press.
- Hwang, K., & Briggs, F. A. (2018). Computer Architecture and Parallel Processing. McGraw-Hill.
- Silberschatz, A., Galvin, P. B., & Gagne, G. (2018). Operating System Concepts. Wiley.
- Flynn, M. J. (2017). Computer Architecture: Pipelined and Parallel Processor Design. Jones & Bartlett Learning.
- Lehmann, P., & Sommese, B. (2019). Fundamentals of Computer Architecture and Design. Pearson.
- Knuth, D. E. (1997). The Art of Computer Programming. Addison-Wesley.