This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gcc and x86 condition codes


Hi

I am working on transforming x86 binaries generated with gcc and
wanted to know whether gcc treats the eflags register as a single unit
when generating code or actually tracks individual flags.

My question is motivated by an optimisation I am making in my tool
that assumes that any instruction that writes to the eflags register
kills it and no subsequent instructions can try to access any flags
not written by this instruction. Is this assumption correct in current
gcc (>= 4.0.0). A search led me to this message
http://gcc.gnu.org/ml/gcc/2005-11/msg00206.html
which says that it is true, or at least was true back then.

Cheers
-Amitabha


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]