Circuitry and methods for implementing one or more predicated capability instructions
Abstract
Circuitry and methods for implementing one or more predicated capability instructions are described. In certain examples, a hardware processor (e.g., core) includes a capability management circuit to check a capability for a memory access request for a memory, the capability comprising an address field for an address to be accessed by the memory access request and a bounds field that is to indicate a lower bound and an upper bound of an address space to which the capability authorizes access; a decoder circuit to decode a single instruction into a decoded single instruction, the single instruction comprising a field to indicate the capability, and an opcode to indicate: an operation to be performed for the address, that an execution circuit is to perform a first check that a condition code, that indicates a status from a previous execution of the execution circuit, is a certain value, that the capability management circuit is to perform a second check that the capability authorizes access to the address, and in response to the first check and the second check both passing, cause the execution circuit to perform the operation for the address; and the execution circuit to execute the decoded single instruction according to the opcode.
Interactive Citation Constellation Global Citation Ranking
Interactive SVG Citation Constellation renders in Rust/WebAssembly. Prior art cited: 10 · Forward citations: 0.
Claims (8 — 2 Independent, 6 Dependent)
- Claim 1Independent Claim
An apparatus comprising: a capability management circuit to check a capability for a memory access request for a memory, the capability comprising an address field for an address to be accessed by the memory access request and a bounds field that is to indicate a lower bound and an upper bound of an address space to which the capability authorizes access; a decoder circuit to decode a single instruction into a decoded single instruction, the single instruction comprising a field to indicate the capability, and an opcode to indicate: an operation to be performed for the address, that an execution circuit is to perform a first check that a condition code, that indicates a status from a previous execution of the execution circuit, is a certain value, that the capability management circuit is to perform a second check that the capability authorizes access to the address, and in response to the first check and the second check both passing, cause the execution circuit to perform the operati
- Claim 2Depends on #1
The apparatus of claim 1, wherein the single instruction comprises a second field that indicates a flag register to store the condition code that indicates the status from the previous execution of the execution circuit.
- Claim 3Depends on #1
The apparatus of claim 1, wherein the opcode indicates the certain value.
- Claim 4Depends on #1
The apparatus of claim 1, wherein the execution circuit is to, in response to the first check indicating that the status is not the certain value, cause the single instruction to fault.
- Claim 5Depends on #1
The apparatus of claim 1, wherein the execution circuit is to, in response to a third check indicating that a validity tag of the capability is not set, cause the single instruction to fault.
- Claim 6Depends on #1
The apparatus of claim 1, wherein the first check of the condition code is performed before the second check is performed by the capability management circuit.
- Claim 7Depends on #6
The apparatus of claim 6, wherein the execution circuit is to, in response to the first check indicating that the status is not the certain value, cause the single instruction to fault before the second check is performed by the capability management circuit.
- Claim 8Independent Claim
A method comprising: decoding, by a decoder circuit of a processor, a single instruction into a decoded single instruction, the single instruction comprising: a field to indicate a capability for a memory access request for a memory, the capability comprising an address field for an address to be accessed by the memory access request and a bounds field that is to indicate a lower bound and an upper bound of an address space to which the capability authorizes access, and an opcode to indicate: an operation to be performed for the address, that an execution circuit of the processor is to perform a first check that a condition code, that indicates a status from a previous execution of the execution circuit, is a certain value, that a capability management circuit of the processor is to perform a second check that the capability authorizes access to the address, and in response to the first check and the second check both passing, cause the execution circuit to perform the operation for th
Technical Overview & Description
BACKGROUND A processor, or set of processors, executes instructions from an instruction set, e.g., the instruction set architecture (ISA). The instruction set is the part of the computer architecture related to programming, and generally includes the native data types, instructions, register architecture, addressing modes, memory architecture, interrupt and exception handling, and external input and output (I/O). It should be noted that the term instruction herein may refer to a macro-instruction, e.g., an instruction that is provided to the processor for execution, or to a micro-instruction, e.g., an instruction that results from a processor's decoder decoding macro-instructions. BRIEF DESCRIPTION OF DRAWINGS Various examples in accordance with the present disclosure will be described with reference to the drawings, in which: FIG. 1 illustrates a block diagram of a hardware processor including a capability management circuit and coupled to a memory according to examples of the disclosure. FIG. 2 A illustrates an example format of a capability including a validity tag field, a bounds field, and an address field according to examples of the disclosure. FIG. 2 B illustrates an example format of a capability including a validity tag field, a permission field, an object type field, a bounds field, and an address field according to examples of the disclosure. FIG. 3 illustrates a flow of operations of a predicated capability instruction according to examples of the disclosure. FIG. 4 illustrates a flow of a program that can operate on data whose type is determined at runtime according to examples of the disclosure. FIG. 5 illustrates a flow of a program that can operate on data subject to a software-defined access control policy according to examples of the disclosure. FIG. 6 illustrates a comparison of code with a conditional branch against code that writes the same value to the register (r12) using if-elimination according to examples of the disclosure. FIG. 7 illustra
Cited By — Indexed Forward Citations (0 of 0 total)
No indexed citing patents in this generation yet. Ingest USPTO/PatentsView bulk citation tables via patents-ingest to expand the local forward citation graph.
References Cited — Backward Prior Art (10)
| Patent | Title | Year | Citations |
|---|---|---|---|
| KR 20180089468 A | 다중-방식 결제 모바일 디바이스 및 시스템 | — | 0 |
Non-Patent Literature (10)
- Carruth, C.,
- “
- Speculative Load Hardening: A Spectre Variant #1 Mitigation Technique,
- ”
- Sep. 2018, 17 pages. [Online]. Available: https://llvm.org/docs/SpeculativeLoadHardening.html.
- Cimpanu, C.,
- “
- Chrome: 70% of All Security Bugs are Memory Safety Issues,
- ”
- ZDNet, May 22, 2020, 5 pages. [Online]. Available: https://www.zdnet.com/article/chrome-70-of-all-security-bugs-are-memory-safety-issues/.