[llvm] [CFIInserter] Improve `CSRSavedLocation` struct. (PR #168869)

Mikhail Gudim via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 10 08:25:31 PST 2025


================
@@ -266,12 +319,16 @@ void CFIInstrInserter::calculateOutgoingCFAInfo(MBBCFAInfo &MBBInfo) {
       case MCCFIInstruction::OpValOffset:
         break;
       }
-      if (CSRReg || CSROffset) {
+      CSRSavedLocation CSRLoc;
+      if (CSRReg)
----------------
mgudim wrote:

> Isn't 0 a valid dwarf register number?

`CSRReg` is `std::optional<unsigned>`

https://github.com/llvm/llvm-project/pull/168869


More information about the llvm-commits mailing list