Commit Graph

159 Commits

Author SHA1 Message Date
EDiasAlberto
872d4224f8 classify register type and base register for load/store 2024-06-06 14:28:32 +01:00
EDiasAlberto
1011d7be71 classify load store addressing type 2024-06-06 14:14:10 +01:00
GDBWNV
1440ebd702 single data transfer & load literal 2024-06-06 13:34:14 +01:00
EDiasAlberto
b93ab76b82 generate branch struct from operands (INCOMPLETE) 2024-06-06 13:22:54 +01:00
EDiasAlberto
6177b2f748 assemble branch instructions 2024-06-06 13:01:26 +01:00
GDBWNV
09956c7b2e data processing register 2024-06-06 13:00:27 +01:00
GDBWNV
ce34f27fbd data processing immediate 2024-06-06 12:33:09 +01:00
GDBWNV
b362f46d58 Merge remote-tracking branch 'origin/emulator' into Assembler-G 2024-06-06 10:11:57 +01:00
sBubshait
d73111515e Fix Overflow handling in Subtraction DP Register, w/ T 2024-06-06 00:47:06 +01:00
Themis Demetriades
95c74964b3 Fix movk to not overwrite entire register for large scalars w/ S 2024-06-06 00:35:48 +01:00
sBubshait
7b1e6314a7 Fix Subs handling of carry PSTATE condition code, w/ T 2024-06-05 23:58:56 +01:00
Themis Demetriades
40c5fac9f6 Fixed bug with movk overwriting wrong bits w/ S 2024-06-05 23:43:36 +01:00
sBubshait
a3dd809437 Update execute, implemented the store instrs, w/ T 2024-06-05 23:30:20 +01:00
Themis Demetriades
75a8d79bb4 Changed order of operations for DPR logic instructions w/ S 2024-06-05 23:19:53 +01:00
Themis Demetriades
dd472117aa Add negation for second operand in DPR instructions w/ S 2024-06-05 22:50:04 +01:00
Themis Demetriades
cc62168d43 Remove debugging code w/ S 2024-06-05 22:23:51 +01:00
Themis Demetriades
294b03ddde Added ability to write to zero register (discard) w/ S 2024-06-05 22:21:32 +01:00
sBubshait
14fbb7e4fc Fix Bug: Struct was not being changed because it wasn't a ptr, w/ T 2024-06-05 21:31:41 +01:00
sBubshait
5bb7d86156 Fix syntax, add new line in end of file and # before include, w/ T 2024-06-05 21:30:41 +01:00
sBubshait
b3ccee44bb Change enum values in DP Register to match the spec, w/ T 2024-06-05 21:23:52 +01:00
EDiasAlberto
262fd6219d conditional definition of parser constants 2024-06-05 21:10:31 +01:00
EDiasAlberto
bb0f939539 construct instr IR from label 2024-06-05 21:07:28 +01:00
EDiasAlberto
8931c151f8 removed duped if statement 2024-06-05 21:02:25 +01:00
EDiasAlberto
f28d3b4047 removed alias function temporarily 2024-06-05 21:01:39 +01:00
Themis Demetriades
120b492a48 Added structs to represent labels and directives for assembler 2024-06-05 20:54:22 +01:00
EDiasAlberto
48efdf8284 classify directprocessing instruction type 2024-06-05 20:53:56 +01:00
sBubshait
379dedc6ce Add execution of Multiply DP Register Instructions, w/ T 2024-06-05 20:25:47 +01:00
sBubshait
9ea494acfc Fix branch enum numbering to match the spec, w/ T 2024-06-05 20:14:12 +01:00
Themis Demetriades
024044afc7 Add decode and execute structure for DPI instructions w/ S 2024-06-05 20:11:56 +01:00
Dias Alberto, Ethan
4df768f327 Merge branch 'assembler' into 'assembler-e'
# Conflicts:
#   src/parser.c
2024-06-05 19:01:15 +00:00
Themis Demetriades
8b0bb1888b Changed constant name for 64 bit register type w/ S 2024-06-05 20:00:25 +01:00
EDiasAlberto
1d1089634f add halt command handling 2024-06-05 19:57:51 +01:00
EDiasAlberto
129bdf3954 classify opcode load/store 2024-06-05 19:57:51 +01:00
GDBWNV
07ff159c9b Merge remote-tracking branch 'origin/assembler' into Assembler-G 2024-06-05 19:26:02 +01:00
Themis Demetriades
93031e82e0 Complete decode for DPR instructions and complete their IR 2024-06-05 16:38:13 +01:00
Themis Demetriades
ff25680455 Update names of decode SDT constants to follow style 2024-06-05 14:00:49 +01:00
Themis Demetriades
2402e3d268 Update DPR type instruction IR operand field name 2024-06-04 15:41:58 +01:00
Themis Demetriades
bb6fa95ade Add DPR type instruction data to IR of a64 instructions 2024-06-04 15:09:53 +01:00
EDiasAlberto
0f04ac9e22 rename fileaccess 2024-06-04 14:53:30 +01:00
GDBWNV
67a9c39832 Symbol basic functionality. 2024-06-04 14:02:09 +01:00
Themis Demetriades
d6b551c190 Fix function that updates N and Z flags of processor w/ S 2024-06-04 13:24:31 +01:00
EDiasAlberto
a8a1fd52a9 add to twopassassembly skeleton 2024-06-04 04:31:46 +01:00
EDiasAlberto
ce0f825e1d add halt command handling 2024-06-04 04:24:56 +01:00
EDiasAlberto
13e2cc8c9d classify branch type from opcode 2024-06-04 03:35:06 +01:00
EDiasAlberto
bb3218b535 add detail to assembly skeleton 2024-06-04 03:07:00 +01:00
EDiasAlberto
422b0f3e62 start classifying opcodes and writing skeleton for twopass assembly 2024-06-04 01:30:17 +01:00
EDiasAlberto
cadac4e1bb rename parser funcs for clarity 2024-06-03 23:09:40 +01:00
EDiasAlberto
036e163fe8 classify asm line type, tokenise operands 2024-06-03 23:07:31 +01:00
sBubshait
c6574b72f8 Fix Bug In Unsigned Offset SDT, multiply correctly, w/ T 2024-06-03 22:40:31 +01:00
Themis Demetriades
efc8c087f9 Fixed bug with size of immediate values for emulator w/ S 2024-06-03 22:37:58 +01:00
sBubshait
be6b0cf429 Fix Bug in Print.c to print Hex instead of decimal, w/ T 2024-06-03 22:33:40 +01:00
sBubshait
d290201004 Fix print bug, fix portability issue, w/ T 2024-06-03 22:30:07 +01:00
sBubshait
d9562521ca Fix print format bug, it used to only print lower 32 bits, w/ T 2024-06-03 22:13:46 +01:00
EDiasAlberto
ba1b614fc1 comment code for understanding 2024-06-03 22:02:41 +01:00
sBubshait
900091f798 Fix getBits Bug when wanted bit is last bit, w/ T 2024-06-03 21:47:14 +01:00
EDiasAlberto
43dd6be707 add a64instruction structs from emulator 2024-06-03 21:46:22 +01:00
GDBWNV
d69d3f0d88 Requested upload to ensure no repeated code 2024-06-03 21:38:58 +01:00
EDiasAlberto
1ff18a4fb9 rewrite error exits for consistency 2024-06-03 21:23:18 +01:00
Themis Demetriades
b19649192a Fix bug with execute immediate value not being shifted w/ S 2024-06-03 20:49:21 +01:00
Themis Demetriades
5afcb8ef63 Fix redeclaration of variable in execute w/ S 2024-06-03 20:40:05 +01:00
sBubshait
20557a14eb Fix emulate so not increment PC if branch inst, w/ T 2024-06-03 20:34:14 +01:00
Themis Demetriades
851a54a51e Complete DPI execute function w/ S 2024-06-03 19:35:21 +01:00
Themis Demetriades
d9276899e4 Fixed register print representation and condition func check w/ S 2024-06-03 18:14:04 +01:00
sBubshait
5fd5c512e6 Fix emulate to properly initialise state, w/ T 2024-06-03 17:55:54 +01:00
sBubshait
3a20190f4f Add new line in end of files, w/ T 2024-06-03 17:45:07 +01:00
sBubshait
9c299b3be0 Add execute branch instruction, w/ T 2024-06-03 17:43:21 +01:00
Themis Demetriades
84586b4768 Add function for executing DPI arithm instructions w/ S 2024-06-03 17:38:04 +01:00
Themis Demetriades
679c84a075 Moved WORD_BITS constant to global header w/ S 2024-06-03 17:36:19 +01:00
Themis Demetriades
4c04f44286 Fixed endian-ness of readWord functions w/ S 2024-06-03 17:29:45 +01:00
Themis Demetriades
8b98a0002f Removed repeated definition of WORD_BITS w/ S 2024-06-03 16:17:15 +01:00
sBubshait
736122276b Update print to account for unsigned int, w/ T 2024-06-03 16:14:41 +01:00
sBubshait
14733b9660 Add execute for SDT instructions, w/ T 2024-06-03 14:47:50 +01:00
sBubshait
10d89ecf91 Add read double word utility, w/ T 2024-06-03 14:44:07 +01:00
Themis Demetriades
07b2410a86 Added zero register specifier constant w/ S 2024-06-03 14:38:37 +01:00
Themis Demetriades
63ba75fab6 Add function for executing DPI instructions w/ S 2024-06-03 14:37:59 +01:00
Themis Demetriades
34119916de Added constant for number of bits in a dword w/ S 2024-06-03 14:37:08 +01:00
Themis Demetriades
9af558a831 Updated machine struct to simulate 64bit registers 2024-06-03 13:34:29 +01:00
Themis Demetriades
7224903ea6 Improved style of emulate function w/ S 2024-06-02 21:55:40 +01:00
Themis Demetriades
65ba8339c6 Fixed bug with main emulate loop w/ S 2024-06-02 21:53:42 +01:00
Themis Demetriades
fd3ef3453c Improved style of main emulate loop w/ S 2024-06-02 21:52:14 +01:00
sBubshait
46c1b42c53 Add the overall emulation pipeline, w/ T 2024-06-02 21:46:34 +01:00
sBubshait
78d1f5588f Update read word to be utility func, w/ T 2024-06-02 21:45:57 +01:00
sBubshait
6bc15b7faf Add priting utility for emulator output, w/ T 2024-06-02 21:24:48 +01:00
sBubshait
a0a51f472c Add single transfer decoding, w/ T 2024-06-02 21:06:08 +01:00
sBubshait
4f324da0e9 Update file io to byte addressable, w/ T 2024-06-02 21:02:24 +01:00
sBubshait
480294da62 Update Single Transfer Internal Structure, w/ T 2024-06-02 20:59:33 +01:00
Themis Demetriades
074de73e8e Add decode for DP immediate instructions w/ S# 2024-06-02 20:57:49 +01:00
sBubshait
bfb8bfdace Add internal structure for Single Transfer, w/ T 2024-05-31 17:59:34 +01:00
sBubshait
d7c23e7bf0 Add decode for Branch Instructions, w/ T 2024-05-31 17:45:02 +01:00
Themis Demetriades
23d0e826a4 Add ADS for single transf instructions w/ S 2024-05-31 17:32:03 +01:00
Themis Demetriades
d6148f6d34 Add data structure for DP instructions w/ S 2024-05-31 17:30:19 +01:00
Themis Demetriades
34eee8599e Move register type struct to global header w/ S 2024-05-31 17:25:51 +01:00
sBubshait
2e0668aefd Update decode fix capitalisation, w/ T 2024-05-31 17:13:42 +01:00
Themis Demetriades
d4ff1ee40e Update instruction enums to capital w/ S 2024-05-31 17:11:43 +01:00
sBubshait
3ce2d8d0f2 Add Branch internal structure, w/ T 2024-05-31 16:46:59 +01:00
EDiasAlberto
6203e65bdc add assembly file reading 2024-05-31 16:16:18 +01:00
EDiasAlberto
fa17a7fda3 add inputted filename format checking 2024-05-31 15:53:41 +01:00
EDiasAlberto
61f6fc9506 create binary file write function 2024-05-31 15:42:35 +01:00
sBubshait
94815c838c Add execute.c, w/ T 2024-05-30 15:24:28 +01:00
sBubshait
497cd7ce3b Add instruction type classification to decode, w/ T 2024-05-30 15:21:24 +01:00