Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yehiasharawy/modified-sic-onepassassembler
The one-pass assembler will read the assembly code, allocate memory, and generate the corresponding relocatable machine code for execution on modi-SIC. It will handle symbol resolution, directive processing, and object code generation (HTE) in a single pass.
https://github.com/yehiasharawy/modified-sic-onepassassembler
java modi-sic modi-sic-assembler sic sic-assembler
Last synced: 6 days ago
JSON representation
The one-pass assembler will read the assembly code, allocate memory, and generate the corresponding relocatable machine code for execution on modi-SIC. It will handle symbol resolution, directive processing, and object code generation (HTE) in a single pass.
- Host: GitHub
- URL: https://github.com/yehiasharawy/modified-sic-onepassassembler
- Owner: YehiaSharawy
- Created: 2023-12-01T15:28:46.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2023-12-16T17:33:48.000Z (about 1 year ago)
- Last Synced: 2025-02-08T19:45:55.458Z (6 days ago)
- Topics: java, modi-sic, modi-sic-assembler, sic, sic-assembler
- Language: Java
- Homepage:
- Size: 37.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Modi-SIC One Pass Assembler
It is a program that performs one-pass assembly for the Modified Simple Instruction Computer (modi-SIC).
The assembler will translate assembly code into machine code compatible with the Modified Simplified Instructional Computer.The modi-SIC architecture retains the instruction set and Format 3 instructions from the original SIC (Simple
Instruction Computer).
It also includes the concept of reserving variables in memory using directives such as
BYTE, WORD, RESB, and RESW.### Key Modifications and Extensions:
• Format 1 Instructions: Modi-SIC extends its capabilities by introducing Format 1 instructions,expanding the range of supported operations.
• Immediate Instructions (Format 3): Modi-SIC introduces immediate instructions, allowing for the handling of immediate values passed as integers. This provides greater flexibility in executing instructions.
• Relocation: The Modi-SIC also supports relocation by using the masking bits in the text records, where 1 denotes memory location that needs modification and 0 otherwise.### Instructions Handling:
The assembler will process the assembly code in a single pass, generating machine code (HTE records) for execution on the modi-SIC. It will consider both the original SIC Format 3 instructions and the newly introduced Format 1 instructions and immediate instructions# Instruction Set
# Instruction Format
## Format 1
|OPCODE (8 Bits)|
|---|## Format 3
All Type 3 instruction could be immediate instructions this is done by a new division of bits of instructions of Type 3 (Format 3) as shown in following table.|OPCODE (7 Bits)|Immediate Flag [i] (1 Bit)|Indexing Flag [x] (1 Bit)|Address (15 Bits)|
|---|---|---|---|The modification applied on the opcode as
- Only opcode is represented as 7 bits (not 8) as in SIC
- The 8th bit of the opcode represents the immediate flag (i) which has two value
a. 0 if the instruction without immediate value (has an address)
b. 1 if the instruction with immediate value# Implementation
### Input
It takes as an input a text file (in.txt) that contains modi-SIC assembly program.
Remember that The modi-SIC program includes Format 1 instruction of SIC/XE.### Output
A generated symbol table file (symbolTable.txt) for all the symbols extracted from the program.
A generated complete HTE records (objectcode.txt) which contain ne header, one or more text records (including masking bits) and one end record.