[all-commits] [llvm/llvm-project] 236898: [RISCV] Accept zicntr and zihpm command line options

Craig Topper via All-commits all-commits at lists.llvm.org
Wed Apr 26 10:13:27 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 236898f6191af51fd5bd52e62987a1edb58b279b
      https://github.com/llvm/llvm-project/commit/236898f6191af51fd5bd52e62987a1edb58b279b
  Author: Craig Topper <craig.topper at sifive.com>
  Date:   2023-04-26 (Wed, 26 Apr 2023)

  Changed paths:
    M llvm/docs/RISCVUsage.rst
    M llvm/lib/Support/RISCVISAInfo.cpp
    M llvm/lib/Target/RISCV/RISCVFeatures.td
    M llvm/test/CodeGen/RISCV/attributes.ll

  Log Message:
  -----------
  [RISCV] Accept zicntr and zihpm command line options

This change adds the definition of the two extensions, but does not either a) make any register definitions conditional on them or b) enabled the extensions by default.

This is somewhat analogous to https://reviews.llvm.org/D143953, but with some key differences.  The best discussion I can find on status is here: https://github.com/riscv/riscv-profiles/issues/43.  These were removed between document version 2.1 and 2.2, but were not defined as new extensions in 2.2.  That addition came later - in March 2022.

According to https://drive.google.com/file/d/1qa57pePesOiDOrNzxuuGFhCL4Rbi9AYB/view these were ratified in March 2023.

Reviewed By: asb, reames

Differential Revision: https://reviews.llvm.org/D144215


  Commit: 3ce3ee6169828060d3671be1de6a67c21efcc668
      https://github.com/llvm/llvm-project/commit/3ce3ee6169828060d3671be1de6a67c21efcc668
  Author: Craig Topper <craig.topper at sifive.com>
  Date:   2023-04-26 (Wed, 26 Apr 2023)

  Changed paths:
    M llvm/lib/Support/RISCVISAInfo.cpp
    M llvm/lib/Target/RISCV/RISCVFeatures.td
    M llvm/test/CodeGen/RISCV/attributes.ll

  Log Message:
  -----------
  [RISCV] Make Zicntr and Zihpm imply Zicsr.

Zicntr and Zihpm are names for groups of CSRs so they should imply
that CSRs exist.

Reviewed By: asb, kito-cheng

Differential Revision: https://reviews.llvm.org/D148962


Compare: https://github.com/llvm/llvm-project/compare/1bce1beac4b7...3ce3ee616982


More information about the All-commits mailing list