[llvm] bd08f1b - [MC] Remove dead code, NFC

Phoebe Wang via llvm-commits llvm-commits at lists.llvm.org
Mon May 1 22:43:37 PDT 2023


Author: Phoebe Wang
Date: 2023-05-02T13:43:27+08:00
New Revision: bd08f1bfb51206f71223e627be47dd88039fc021

URL: https://github.com/llvm/llvm-project/commit/bd08f1bfb51206f71223e627be47dd88039fc021
DIFF: https://github.com/llvm/llvm-project/commit/bd08f1bfb51206f71223e627be47dd88039fc021.diff

LOG: [MC] Remove dead code, NFC

This code was added in 408b5e660300f9, but neither the return value nor
`Res` was used in the following code.

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

Added: 
    

Modified: 
    llvm/lib/MC/MCCodeView.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/MC/MCCodeView.cpp b/llvm/lib/MC/MCCodeView.cpp
index aec8fc89acb23..a27ef64bec0fa 100644
--- a/llvm/lib/MC/MCCodeView.cpp
+++ b/llvm/lib/MC/MCCodeView.cpp
@@ -649,8 +649,6 @@ void CodeViewContext::encodeDefRange(MCAsmLayout &Layout,
       const MCSymbolRefExpr *SRE = MCSymbolRefExpr::create(RangeBegin, Ctx);
       const MCBinaryExpr *BE =
           MCBinaryExpr::createAdd(SRE, MCConstantExpr::create(Bias, Ctx), Ctx);
-      MCValue Res;
-      BE->evaluateAsRelocatable(Res, &Layout, /*Fixup=*/nullptr);
 
       // Each record begins with a 2-byte number indicating how large the record
       // is.


        


More information about the llvm-commits mailing list