Alina malik
Alina malik

Reputation: 23

Size of main memory in Wobmat?

What is size of main memory in Wombat. And what is size of main memory in MARIE. Is it 4K×16 for both. But isn't word size In Marie is 8 bit . and 16 in wombat?

Upvotes: 1

Views: 30

Answers (1)

trincot
trincot

Reputation: 350310

What is size of main memory in Wombat?

Quoting the documentation at https://mirkwood.cs.edinboro.edu/~bennett/wombat/manual/document.html from section 2.1 Harware Description:

The instruction set consists of 15 instructions, requiring an opcode of 4 bits, with 12 bits of the 16 bit word remaining for operands. This limits the addressable memory to 212 bytes.

Memory is byte addressable, but all instructions must be word aligned. Furthermore all data access is performed on word aligned boundaries on word sized data.

This means we have 212 x 8 bit of memory in Wombat-1. The constraint on word alignment seems to imply that the least significant bit of address-operands, and of the program counter must be 0. And yes, the program counter is said to increase with steps of 2, as indicated in section 2.1.1 of the same document:

Initialized to 0, this register supports increment by two.

And to your second question:

What is size of main memory in MARIE?

The documentation for MARIE.js on GitHub has:

...a memory cell may represent as data 0000...

So MARIE's addressing is word based, which is also evident when using the MARIE.js implementation. Just like Wombat-1, there are 12 bits available for addressing, giving access to 212 words (16-bit).

Note: all this evolves over time and simulators may behave slightly different from original specifications.

Upvotes: 0

Related Questions