1. Oct 15, 2022
  2. Sep 30, 2022
  3. Sep 20, 2022
  4. Sep 13, 2022
  5. Sep 03, 2022
  6. Aug 25, 2022
    • Tim Newsome's avatar
      Elaborate on version detection. (#741) · b71e15d4
      Tim Newsome authored
      The side effects only really occur in an extreme corner case.
      
      I think. I don't remember anything about why this section was written,
      and I wonder if I'm forgetting about something.
      b71e15d4
  7. Jul 18, 2022
    • Tim Newsome's avatar
      Remove license from debug_defines.h. (#743) · d749752b
      Tim Newsome authored
      CC BY 4.0 is incompatible with the GPL, meaning the file could not be
      used in GPL projects like OpenOCD. RISC-V has plans to address this, but
      the lawyers are working on other issues right now. Until that is
      properly resolved, we're reverting to the way things were before #641
      and removing the license line.
      d749752b
  8. Jun 28, 2022
  9. Jun 17, 2022
  10. Jun 10, 2022
  11. May 26, 2022
  12. May 21, 2022
    • Tim Newsome's avatar
      List trigger actions described by the trace spec (#734) · 182b9c4a
      Tim Newsome authored
      Those values are fixed, and there's no need to send somebody looking for
      a different document just to see the very short description.
      182b9c4a
    • Tim Newsome's avatar
      Add trigger action values, for debug_defines.h. (#732) · c40847ad
      Tim Newsome authored
      Leave the descriptions empty, and change registers.py to not emit
      anything for values whose descriptions are empty.
      
      I'm not a huge fan of the duplication of those values in the XML file,
      but I don't want to invent a new mechanism to avoid it right now. (Ooh,
      we could use M4 to generate the XML and use an existing mechanism...)
      c40847ad
  13. May 20, 2022
    • Tim Newsome's avatar
      Add field values to XML register description. (#727) · efd25df7
      Tim Newsome authored
      * Add field values to XML register description.
      
      Generate constants in the C header for the values. E.g.
      ```
       #define CSR_TDATA1_TYPE_NONE                0
       #define CSR_TDATA1_TYPE_LEGACY              1
       #define CSR_TDATA1_TYPE_MCONTROL            2
       #define CSR_TDATA1_TYPE_ICOUNT              3
       ...
      ```
      Make formatting slightly more consistent in the PDF.
      
      * Use \unspecified instead of "undefined values"
      
      * Rename a bunch of field values based on review.
      
      * Rename field values that specify a number of bits
      
      * stop{time,count} values are called normal/freeze
      
      * Abstract command write value arg->arg0
      
      * Name field values <n>bit
      efd25df7
  14. May 19, 2022
  15. May 17, 2022
  16. May 13, 2022
  17. May 11, 2022
    • Tim Newsome's avatar
      Add arguments to C macros that need them. (#724) · 9137a14d
      Tim Newsome authored
      * Add arguments to C macros that need them.
      
      Previously no macros took arguments, even those that depended on e.g.
      XLEN.
      
      Old:
       #define CSR_TDATA1_TYPE_OFFSET              (XLEN-4)
       #define CSR_TDATA1_TYPE_LENGTH              4
       #define CSR_TDATA1_TYPE                     (0xfULL << CSR_TDATA1_TYPE_OFFSET)
      
      New:
       #define CSR_TDATA1_TYPE_OFFSET(XLEN)        (XLEN + -4)
       #define CSR_TDATA1_TYPE_LENGTH              4
       #define CSR_TDATA1_TYPE(XLEN)               (0xf * (1ULL<<(XLEN + -4)))
      
      The new syntax can be a little awkward, but it's correct and works in
      OpenOCD at least. The most awkward new version is this one:
       #define DTM_DMI_ADDRESS_OFFSET              0x22
       #define DTM_DMI_ADDRESS_LENGTH(abits)       abits
       #define DTM_DMI_ADDRESS(abits)              ((0x400000000ULL * (1ULL<<abits)) + -17179869184)
      
      Some of the awkwardness stems from the fact that sympy doesn't support a
      << operator, so I use ** internally and then print it out strangely.
      It's correct, just not idiomatic.
      
      * Tweak how we represent numbers.
      
      Add appropriate U and ULL prefix on large hex constants that we negate.
      9137a14d
    • Tim Newsome's avatar
      mte/mpte apply only to breakpoint traps (#723) · 4c0859bf
      Tim Newsome authored
      * mte/mpte apply only to breakpoint traps
      
      This makes it possible to use triggers to debug some of the exception
      handling code as well.
      
      See 2022 email subject:"trigger questions"
      
      * Mention backwards incompatibility.
      4c0859bf
    • Tim Newsome's avatar
      Tighten up language around icount matching. (#722) · 02a27937
      Tim Newsome authored
      * Tighten up language around icount matching.
      
      Specifically, now icount triggers on M-Mode only systems are more
      useful, because the count might not decrement while in an interrupt
      handler.
      
      See 2022 email discussion subject:"trigger questions"
      
      * Document that this change is backwards incompatible.
      02a27937
    • Tim Newsome's avatar
      Select and issue a command can be simultaneous (#725) · 127e2235
      Tim Newsome authored
      It is not necessary to first select and then issue the command in
      dmcontrol. The old language could have been interpreted that way.
      127e2235
  18. May 10, 2022
  19. Apr 27, 2022
  20. Apr 23, 2022
  21. Apr 08, 2022
  22. Apr 06, 2022
  23. Apr 02, 2022
  24. Mar 29, 2022
  25. Mar 25, 2022
    • Tim Newsome's avatar
      Fix contradiction in icount description. (#665) · 356feb1d
      Tim Newsome authored
      
      
      * Fix contradiction in icount description.
      
      Specifically, after we added the pending bit, the description of a
      possible 1-bit implementation of this register was not updated. As a
      result the count description said that decrementing resulted in a
      trigger, while in the introductory part we said that decrementing
      resulted in pending getting set.
      
      Rewrote it a bit, so it's hopefully easier to read.
      
      Fixes #662.
      
      * Explain 2 icount use cases.
      
      Are there others? Is this clear?
      
      * eret is now mret
      
      Co-authored-by: default avatarPaul Donahue <48959409+pdonahue-ventana@users.noreply.github.com>
      
      * Language
      
      Co-authored-by: default avatarPaul Donahue <48959409+pdonahue-ventana@users.noreply.github.com>
      
      * Small clarification.
      
      * Move single step example code into Appendix.
      
      * Language cleanups.
      
      * Make things less ambiguous.
      
      Remove explanation about how icount can be done in a single bit.
      
      The single-bit implementation can work, but only if you tie all mode
      bits together and have max count of 1. If all mode bits are enabled
      together, there is no case where the existence of a pending bit can make
      a different. But this is only useful for an external debugger, and we
      already say that for external debuggers dcsr.step is the preferred
      solution.
      
      For native debugging, the least hardware I can think of is 2 bits,
      because there are effectively 3 states: disabled, pending, and enabled.
      This assumes the mode bits are tied together in such a way that there is
      only one sensible option. I'm not sure if that's even worth mentioning
      anywhere. It would be a long explanation with little benefit.
      
      * Clarify the icount always decrements.
      
      Even if the chosen action cannot be taken.
      
      Also use proper field macros for most action=0 instances.
      
      * Refer to precise instructions in icount.count.
      
      Co-authored-by: default avatarPaul Donahue <48959409+pdonahue-ventana@users.noreply.github.com>
      356feb1d
    • Tim Newsome's avatar
      Mention textra in the trigger types that it affects. (#711) · 2676fa11
      Tim Newsome authored
      * Mention textra in the trigger types that it affects.
      
      * Clarify textra is implemented for *this* trigger
      
      * Slight rewording.
      2676fa11
    • Tim Newsome's avatar
      3b16253f
  26. Mar 23, 2022
  27. Mar 22, 2022
    • Tim Newsome's avatar
      Move nmi from etrigger to itrigger. (#709) · e9994d71
      Tim Newsome authored
      * Move nmi from etrigger to itrigger.
      
      Per mailing list discussion subject:"etrigger.nmi".
      
      * Add this PR number to the new feature.
      
      * nmi is subject to mode bits.
      
      Based on subject:"NMI trigger and tdata2/tdata3" discussion.
      e9994d71
  28. Mar 17, 2022
    • Paul Donahue's avatar
      Clarify tmexttrigger with action=0. (#707) · 98203bb0
      Paul Donahue authored
      The privileged spec says that medeleg only delegates synchronous exceptions
      so clarify that in the case of tmexttrigger medeleg is delegating an
      asynchronous exception.
      Also clarify what happens to tmexttrigger events that happen while the trigger
      is prevented from firing.
      98203bb0