Skip to content
Low-level programming · Higher-level thinking
Login Register
Forum / Requests and Feedback

Augmented assignment

A community discussion post from the original code:zIRON forum.

Replies

Colin admin
Posts
928
Threads
49
Location
Bulgaria

Yes, i understand, but what is the underlying output you want? I just want to be sure I understood you correctly.

0CodErr member
Posts
201
Threads
37
Location
Unknown

Output should be with

setc 

I think.

Also, it can be useful to translate

ax = CF;
eax = CF;
rax = CF;

with

setc + movzx|movsx
Colin admin
Posts
928
Threads
49
Location
Bulgaria

OK, I have added support the following for next release:

al = CF;
dl = CF;
dl = PF;
dl = ZF;
dl = SF;

including modifiers ~ ! and -

al = ~CF;
al = -CF;

I have also added movzx and movsx dependant on signed status of register being assigned to.

eax = CF;

-Colin

Colin admin
Posts
928
Threads
49
Location
Bulgaria

There was a small mistake on current release regarding ! modifier.

Next release, the following applies:

al = CF;   // setc al
al = !CF;  // setnc al
al = PF;   // setp al
al = !PF;  // setnp al

// etc