Closed ProxyPlayerHD closed 4 years ago
@ProxyPlayerHD There seems to be an absence of work on this repo now. The best thing that could be done is to try and work on CustomASM yourself.
Ah, sorry for any delay. I think I can relax the requirement for unambiguous tokens after parameters. I'll see what I can do.
On another note, you don't need to use a slice after a binary literal. So for 0b001[2:0]
, you can just use 0b001
and the assembler will infer you want to use 3 bits (the zeroes are important!). Same for hex literals. Also, if you specify the type of an argument (like s16
), you can also omit the slice, and the assembler will assume you want to use the same number of bits as specified in the type.
Ah, sorry for any delay. I think I can relax the requirement for unambiguous tokens after parameters. I'll see what I can do.
thanks!
On another note, you don't need to use a slice after a binary literal. So for
0b001[2:0]
, you can just use0b001
and the assembler will infer you want to use 3 bits (the zeroes are important!). Same for hex literals. Also, if you specify the type of an argument (likes16
), you can also omit the slice, and the assembler will assume you want to use the same number of bits as specified in the type.
well i'll probably change that after i'm done and it's working. currently i just want to get done.
while working on my 68k CPU file, which is getting more and more stressful, i came across this:
this is a problem because that is just how the 68k works. 0x00000000.W is interpreted as a word (16 bit), and 0x00000000.L is interpreted as a long (32 bit)
here the snippet from the CPU file:
the top 6 instructions are the same as the bottom 6, except that the size of the address is forced by the programmer (either .W(ord) or .L(ong)) the bottom 6 automatically use the best address size, if the address fits inside a 16 bit signed integer it uses the .W(ord) addressing mode, if it doesn't fit it uses the .L(ong) addressing mode. (atleast i hope instruction pritory works from top to bottom and that i'm using the s16 and i32 things correctly)
currently my only real way around this is to comment out the forced address sizes and only have the automatically deciding ones. technically the forced ones aren't even nessesary so i don't know if this is worth "fixing".