5 ms·
Unintended Instructions on x86
- userbinator 5y agoI believe this is more commonly known as "overlapping instructions/opcodes"; and it was a relatively common technique for size optimisation or obfuscation in the 80s and early 90s, when Asm was the norm for PC software. To my knowledge, there are no tools which do a good job of presenting the parallel execution streams. Instead, the typical flow requires the human to iterate through attempting disassembly at different offsets. I remember seeing one (tracing) disassembler which does this, presenting the different streams side-by-side until they realign again. No doubt cracking groups probably have their own private versions of such tools.
- adrian_b 5y agoYes, indeed, this technique was frequently used in ancient programs. For example, many decades ago I have disassembled many Microsoft programs, like the MS-DOS Basic interpreter or Fortran compiler. In all those Microsoft programs, there were many loops where the jump at the end of the loop jumped in the middle of the initial instruction. Thus the first execution of the loop executed different instructions than the next executions, which was used, e.g., for the loop initialization. There were also many if-then-else structures where one of the branches ended with a jump towards the middle of some instruction, so that depending on which was the value of the condition different instructions were executed. The instructions whose middle position was the target of a jump were usually instructions with immediate operands, so that when executed from the beginning the immediate value was treated as data, while when reached through a jump in the middle of the instruction, the immediate data was treated as an instruction opcode.
- dataking 5y agoThe term unintended instructions is common in the infosec community and was (as far as I know) popularized by the seminal paper on ROP https://hovav.net/ucsd/dist/geometry.pdf https://hovav.net/ucsd/dist/geometry.pdf I'm sure different terms are used in other communities.
- exikyut 5y agoI wonder which unintended instruction streams decode to the highest number of decodable partial instructions/instruction sequences, and then I wonder how useful those sequences might be in, say, a 4k or 1k demo....
- optimalsolver 5y agoAlternate instructions here :-) https://paws.kettering.edu/~jhuggins/humor/opcodes.html https://paws.kettering.edu/~jhuggins/humor/opcodes.html
- Doxin 5y agoThe redcode assembly language for the corewars game has a branch-both-ways instruction, though there it gets called split. https://vyznev.net/corewar/guide.html#start_instr https://vyznev.net/corewar/guide.html#start_instr
- nathell 5y agoThat's clearly wrong. It lists Halt and Catch Fire with the mnemonic HACF, instead of the canonical HCF.
- mhh__ 5y agoI don't hate X86, but I hope to god it finally goes, and I know I won't miss it.
- deleted 5y ago[deleted]
- raptorxp 5y agox86-64 isn't going anywhere. Not in the next decade or two anyway.
- danielheath 5y agoI don't know about "gone", but "reduced to legacy support roles within 10 years" seems like a pretty uncontroversial statement.
- fogihujy 5y agoI'd be surprised if that turned out to be true, but I truly hope that I'm wrong and you're right. :D
- danielheath 5y agoThe story so far: ARM chips last longer on battery, and every high volume laptop manufacturer had an ARM model. Every smartphone is already arm. ARM already has mainline support from every major OS vendor. Every videogame engine builds for ARM targets. In AWS, Graviton2 instances are 40% cheaper for cpu bound workloads vs x86. Next time our reserved instances expire we will switch.
- fogihujy 5y agoMeanwhile, people are clinging to decade-old Thinkpads like they were made of gold. Most laptops and pretty much all desktops are x86-64, as are both major home consoles. Sure, ARM is dominant on mobile, and it's definitely going to grab a share of the laptop market now that Apple is going that route. Eventually we might also see ARM based desktop computers again, but having them grab the majority of sales will take time. I'm sure it'll happen - just not within a decade.
- hoseja 5y agoSounds like multiple frames for DNA translation.