Skip to content

Commit 916bee9

Browse files
[AVR] Remove unnecessary casts (NFC) (#155791)
getSubtargetImpl() already returns const AVRSubtarget *.
1 parent 60bea3d commit 916bee9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/lib/Target/AVR/AVRAsmPrinter.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ void AVRAsmPrinter::emitXXStructor(const DataLayout &DL, const Constant *CV) {
245245
bool AVRAsmPrinter::doFinalization(Module &M) {
246246
const TargetLoweringObjectFile &TLOF = getObjFileLowering();
247247
const AVRTargetMachine &TM = (const AVRTargetMachine &)MMI->getTarget();
248-
const AVRSubtarget *SubTM = (const AVRSubtarget *)TM.getSubtargetImpl();
248+
const AVRSubtarget *SubTM = TM.getSubtargetImpl();
249249

250250
bool NeedsCopyData = false;
251251
bool NeedsClearBSS = false;
@@ -294,7 +294,7 @@ bool AVRAsmPrinter::doFinalization(Module &M) {
294294

295295
void AVRAsmPrinter::emitStartOfAsmFile(Module &M) {
296296
const AVRTargetMachine &TM = (const AVRTargetMachine &)MMI->getTarget();
297-
const AVRSubtarget *SubTM = (const AVRSubtarget *)TM.getSubtargetImpl();
297+
const AVRSubtarget *SubTM = TM.getSubtargetImpl();
298298
if (!SubTM)
299299
return;
300300

0 commit comments

Comments
 (0)