Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It all depends on the CPU architecture, if it supports something like out-of-order execution then both parts of the CPU could be in use at the same time to execute different instructions. Realistically any CPU with that level of complexity doesn't care about SUB vs XOR though.


In an OoO CPU it won't even hit an execution unit because it's handled as a dependency chain break.


Also, because SUB is implemented internally with XOR, so it's normally the same gates, with different signals selecting a different function.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: