Reputation: 827
Is there any header present reliably across all "standard" (assuming its designed to be executed normally through some common computing platform) executable binaries that I can use to identify whether I'm looking at a CISC or RISC instruction set?
Or do I have to use contextual knowledge of the system the executable exists on to assume the instruction architecture?
Upvotes: 0
Views: 327
Reputation: 366016
No. One counterexample is DOS .com
executables: there is no metadata, just the bare machine code. ROM images of firmware might similarly have no metadata.
If you're talking about ELF executables, they indicate what ISA they're for, but don't classify that ISA as RISC vs. CISC. So you'd need a table of all RISC ISAs and all CISC ISAs.
There are some ISAs that even blur that line, like ARM which has some CISCy features like load-multiple, or (on paper only) ForwardCom which its architect describes as neither RISC nor CISC, but combining ideas from each.
Upvotes: 3