aboutsummaryrefslogtreecommitdiff
path: root/riscv
AgeCommit message (Collapse)AuthorFilesLines
2022-10-17Merge branch 'master' into plic_uart_v1plic_uart_v1Andrew Waterman198-6885/+7749
2022-10-16Add interactive mode commands to read clint mtime/mtimecmpJerry Zhao3-0/+27
2022-10-14Add dump memory command to interactive modeJerry Zhao4-0/+29
2022-10-14Support command-line configuration of number of pmpregionsJerry Zhao4-2/+7
2022-10-14Merge pull request #1114 from riscv-software-src/data_optionalScott Johnson4-21/+21
In triggers, use optional<data> instead of {has_data, data}
2022-10-14In triggers, use optional<data> instead of {has_data, data}Andrew Waterman4-16/+17
2022-10-14Report error if an unsupported memory configuration is detectedParshintsev Anatoly1-6/+10
2022-10-13Remove unused field matched_t::dataAndrew Waterman2-5/+4
2022-10-13Merge pull request #1107 from riscv-software-src/simplify-ld-stAndrew Waterman3-179/+123
Simplify handling of load/store/fetch slow-path cases; fix two minor trigger bugs
2022-10-11Set tval on illegal subforms of aes64ks1iAndrew Waterman1-4/+1
h/t @YenHaoChen
2022-10-07Add --dm-no-abstract-fpr option.Tim Newsome2-1/+2
Previously FPRs could always be accessed using abstract commands. I need this to get coverage of some OpenOCD code that I broke. (See https://github.com/riscv/riscv-openocd/pull/745)
2022-10-06Don't use reexecution as the means to implement trigger-afterAndrew Waterman3-10/+7
The scheme was based on the notion that memory accesses are idempotent up until the point the trigger would've been hit, which isn't true in the case of side-effecting loads and data-value triggers. Instead, check the trigger on the next instruction fetch. To keep the perf overhead minimal, perform this check on the I$ refill path, and ensure that path is taken by flushing the I$.
2022-10-06Fix endianness bug in fetch triggersAndrew Waterman1-2/+1
Instruction fetch is always little-endian.
2022-10-06DRY in checking triggersAndrew Waterman2-42/+28
2022-10-06Move uncommon-case fetch functionality into fetch_slow_pathAndrew Waterman2-25/+25
2022-10-06Move all uncommon-case store functionality into store_slow_pathAndrew Waterman2-65/+46
As a side effect, misaligned stores now behave the same as aligned stores with respect to triggers: only the first byte is checked.
2022-10-06Move all uncommon-case load functionality into load_slow_pathAndrew Waterman2-60/+41
As a side effect, misaligned loads now behave the same as aligned loads with respect to triggers: only the first byte is checked.
2022-10-05Remove unused variable to fix buildAndrew Waterman1-1/+0
2022-10-05Merge pull request #1105 from YenHaoChen/pr-trigger-priorityAndrew Waterman4-20/+47
Fix trigger priority
2022-10-04Fixed -Wnon-virtual-dtor warningsJerin Joy2-0/+4
Signed-off-by: Jerin Joy <joy@rivosinc.com>
2022-10-04Fix unused-variable warnings in P-extension instruction definitionsAndrew Waterman1-1/+0
2022-10-04Suppress unused-variable warnings in P-extension macrosAndrew Waterman1-4/+4
2022-10-04Silence unused-variable warnings in auto-generated codeAndrew Waterman1-0/+4
2022-10-04Suppress or fix unused-variable warnings in vector macrosAndrew Waterman1-36/+35
2022-10-04Suppress unused-variable warnings in vector instruction definitionsAndrew Waterman6-10/+0
2022-10-04Suppress unused-variable warnings in AES codeAndrew Waterman1-2/+2
2022-10-04Suppress most unused-variable warningsAndrew Waterman1-3/+3
2022-10-04Silence remaining unused-parameter warningsAndrew Waterman1-0/+4
Suppressing these individually would add too much clutter.
2022-10-04Suppress most unused variable warningsAndrew Waterman17-22/+24
2022-10-04Add UNUSED macro for suppressing unused-parameter/variable warningsAndrew Waterman1-0/+2
2022-10-04Fix unused-function warning on sometimes-used function ctoAndrew Waterman1-1/+1
2022-10-04Delete functions that are actually unusedAndrew Waterman1-4/+0
2022-10-04Fix remaining ignored-qualifiers warningAndrew Waterman2-2/+2
2022-10-04Fix ignored-qualifiers warnings in get_field/set_field macrosAndrew Waterman1-2/+6
2022-10-04Rewrite READ_REG macro to avoid GNU statement expression extensionAndrew Waterman1-1/+1
This way, it can be used as an expression within a template argument.
2022-10-04Rewrite require macro so it can be used as an expressionAndrew Waterman1-1/+1
2022-10-04Fix trigger mcontrol.chain match issue #599 #627 (#1083)YenHaoChen1-1/+1
The variable chain_ok is used to indicate if the current trigger is suppressed by the trigger chain. A true value means the trigger is either un-chained or matches all previous triggers in the chain, and a false value means the trigger is chained and mismatches previous triggers. A false condition of variable chain_ok is missing. The false condition should be mcontrol.chain=1 and not matching; otherwise, the chain_ok=true (including initialization). The bug results in issues #559 and #627. Related issues: - https://github.com/riscv-software-src/riscv-isa-sim/issues/599 - https://github.com/riscv-software-src/riscv-isa-sim/issues/627 This PR fixes the issues #559 and #627.
2022-10-03Fix newly introduced Clang warningsAndrew Waterman1-7/+12
2022-10-03Merge pull request #1099 from XiaJin-RiVAI/masterAndrew Waterman1-16/+189
support arrow/home/end keys in debug mode
2022-09-30Check trigger only with actually_storeYenHaoChen1-5/+7
The data value of the function store_slow_path() is meaningful only when the actually_store=true. Otherwise, the data value is a hollow value of 0, which may result in unintended trigger matching.
2022-09-30Fix priority of mcontrol trigger store address/data beforeYenHaoChen2-2/+9
The spec defines that the mcontrol store address/data has a higher priority over page fault and address misalignment (Debug spec, Table 5.2). Thus, the trigger checking should be before the translation and alignment checking. The previous implementation checks the trigger after the translation and alignment, resulting in incorrect priority. For instance, when page fault and trigger occur on the same instruction, the previous implementation will choose to raise the page fault, which contradicts the priority requirement. This commit moves the trigger checking before the misaligned checking and translation. The trigger will fire on the instruction instead of the page fault in the above case.
2022-09-30Fix priority of mcontrol trigger load address beforeYenHaoChen2-0/+12
The spec defines the mcontrol load address has a higher priority over page fault and address misaligned (Debug spec, Table 5.2). Thus, the trigger checking should be before the translation and alignment checking. The previous implementation checks the trigger after the translation and alignment, resulting in incorrect priority. For instance, when page fault and trigger occur on the same instruction, the previous implementation will choose to raise the page fault, which contradicts the priority requirement. This commit adds an address-only trigger checking before the misaligned checking and translation. The trigger will fire on the instruction instead of the page fault in the above case.
2022-09-30Fix priority of mcontrol trigger execute address beforeYenHaoChen1-2/+6
The spec defines the mcontrol execute address has a higher priority over page fault (Debug spec, Table 5.2). Thus, the trigger checking should be before the translation. The previous implementation checks the trigger after the translation, resulting in incorrect priority. For instance, when page fault and trigger occur on the same instruction, the previous implementation will choose to raise the page fault, which contradicts the priority requirement. This commit adds an address-only trigger checking before the translation. The trigger will fire on the instruction instead of the page fault in the above case.
2022-09-30Add has_data argument to trigger checking functionsYenHaoChen4-13/+15
The mcontrol trigger can select either address or data for checking. The The selection decides the priority of the trigger. For instance, the address trigger has a higher priority over the page fault, and the page fault has a higher priority over the data trigger. The previous implementation only has the checking functions for data trigger, which results in incorrect priority of address trigger. This commit adds a has_data argument to indicate address trigger and the priority of the trigger.
2022-09-28Merge pull request #1103 from riscv-software-src/vmv_x_s_rv32Andrew Waterman1-8/+9
Fix vmv.x.s for RV32
2022-09-28Fix vmv.x.s for RV32Andrew Waterman1-8/+9
The Spike internals require that, when XLEN is narrower than reg_t, values be sign-extended to the width of reg_t.
2022-09-26Update interactive.ccXiaJin-RiVAI1-16/+189
support arrow/home/end keys in debug mode support the arrow/home/end keys to move the cursor and trace back the history command in the debug mode
2022-09-23Build and install lib and header dependencies for HammerJerin Joy1-1/+31
https://github.com/rivosinc/hammer Signed-off-by: Jerin Joy <joy@rivosinc.com>
2022-09-20Merge pull request #1085 from ImanHosseini/patch1Andrew Waterman1-0/+1
Detect loading isa-incompatible code
2022-09-20Merge pull request #1036 from plctlab/plct-sscofpmf-devAndrew Waterman6-7/+67
add support for sscofpmf extension v0.5.2