@@ -1544,7 +1544,7 @@ void LoadableStorageAllocation::
15441544 storageType);
15451545 if (pass.containsDifferentFunctionSignature (pass.F ->getLoweredFunctionType (),
15461546 storageType)) {
1547- auto *castInstr = argBuilder.createUncheckedBitCast (
1547+ auto *castInstr = argBuilder.createUncheckedReinterpretCast (
15481548 RegularLocation (const_cast <ValueDecl *>(arg->getDecl ())), arg,
15491549 newSILType);
15501550 arg->replaceAllUsesWith (castInstr);
@@ -1912,8 +1912,8 @@ static void castTupleInstr(SingleValueInstruction *instr, IRGenModule &Mod,
19121912 switch (instr->getKind ()) {
19131913 // Add cast to the new sil function type:
19141914 case SILInstructionKind::TupleExtractInst: {
1915- castInstr = castBuilder.createUncheckedBitCast (instr-> getLoc (), instr,
1916- newSILType.getObjectType ());
1915+ castInstr = castBuilder.createUncheckedReinterpretCast (
1916+ instr-> getLoc (), instr, newSILType.getObjectType ());
19171917 break ;
19181918 }
19191919 case SILInstructionKind::TupleElementAddrInst: {
@@ -2471,8 +2471,8 @@ getOperandTypeWithCastIfNecessary(SILInstruction *containingInstr, SILValue op,
24712471 }
24722472 assert (currSILType.isObject () && " Expected an object type" );
24732473 if (newSILType != currSILType) {
2474- auto castInstr = builder.createUncheckedBitCast (containingInstr-> getLoc (),
2475- op, newSILType);
2474+ auto castInstr = builder.createUncheckedReinterpretCast (
2475+ containingInstr-> getLoc (), op, newSILType);
24762476 return castInstr;
24772477 }
24782478 }
@@ -2653,8 +2653,8 @@ bool LoadableByAddress::recreateUncheckedEnumDataInstr(
26532653 auto *takeEnum = enumBuilder.createUncheckedEnumData (
26542654 enumInstr->getLoc (), enumInstr->getOperand (), enumInstr->getElement (),
26552655 caseTy);
2656- newInstr = enumBuilder.createUncheckedBitCast (enumInstr->getLoc (), takeEnum ,
2657- newType);
2656+ newInstr = enumBuilder.createUncheckedReinterpretCast (enumInstr->getLoc (),
2657+ takeEnum, newType);
26582658 } else {
26592659 newInstr = enumBuilder.createUncheckedEnumData (
26602660 enumInstr->getLoc (), enumInstr->getOperand (), enumInstr->getElement (),
@@ -2708,7 +2708,7 @@ bool LoadableByAddress::fixStoreToBlockStorageInstr(
27082708 if (destType.getObjectType () != srcType) {
27092709 // Add cast to destType
27102710 SILBuilderWithScope castBuilder (instr);
2711- auto *castInstr = castBuilder.createUncheckedBitCast (
2711+ auto *castInstr = castBuilder.createUncheckedReinterpretCast (
27122712 instr->getLoc (), src, destType.getObjectType ());
27132713 instr->setOperand (StoreInst::Src, castInstr);
27142714 }
0 commit comments