Patent ID: 8132023

Claim:
An apparatus, configured to perform a hash operation, the apparatus comprising: an x86-compatible microprocessor, configured to execute an application program that is fetched from a memory, and configured to execute a single, atomic hash instruction within said application program that directs said x86-compatible microprocessor to perform the hash operation, wherein said single, atomic hash instruction specifies one of a plurality of hash algorithms, and wherein the hash operation comprises indicating whether the hash operation has been interrupted by an interrupting event, said single, atomic hash instruction comprising: an opcode field, configured to prescribe that the x86-compatible microprocessor accomplish the hash operation; and a repeat prefix field, coupled to said opcode field, configured to indicate that the hash operation prescribed by said single, atomic hash instruction is to be accomplished on one or more message blocks; said x86-compatible microprocessor comprising: a hash unit, configured to execute a plurality of hash computations on each of said one or more message blocks to generate a corresponding intermediate hash value, wherein a last intermediate hash value that is computed for a last message block after processing all previous message blocks comprises a message digest corresponding to said one or more message blocks, and wherein said corresponding intermediate hash value is stored to memory prior to allowing a pending interrupt to proceed, and wherein said hash unit executes a first plurality of micro instructions generated by translation of said single, atomic hash instruction; and an x86 integer unit, wherein said hash unit operates in parallel with said x86 integer unit to accomplish the hash operation, and wherein said x86 integer unit executes a second plurality of micro instructions generated by translation of said single, atomic cryptographic instruction to test a bit in a flags register, to update text pointer registers, and to process interrupts during execution of the hash operation.