File tree Expand file tree Collapse file tree 2 files changed +6
-9
lines changed
lib/SILOptimizer/SILCombiner Expand file tree Collapse file tree 2 files changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -937,9 +937,6 @@ SILInstruction *SILCombiner::visitLoadInst(LoadInst *LI) {
937
937
// / ->
938
938
// / %2 = index_addr %ptr, x+y
939
939
SILInstruction *SILCombiner::visitIndexAddrInst (IndexAddrInst *IA) {
940
- if (IA->getFunction ()->hasOwnership ())
941
- return nullptr ;
942
-
943
940
unsigned index = 0 ;
944
941
SILValue base = isConstIndexAddr (IA, index);
945
942
if (!base)
Original file line number Diff line number Diff line change @@ -410,12 +410,12 @@ bb0:
410
410
}
411
411
412
412
// CHECK-LABEL: sil [ossa] @optimize_nested_index_addr
413
- // XHECK : bb0(%0 : $Builtin.RawPointer):
414
- // XHECK -NEXT: %1 = pointer_to_address %0
415
- // XHECK -NEXT: %2 = integer_literal $Builtin.Word, 10
416
- // XHECK -NEXT: %3 = index_addr %1 : $*UInt8, %2
417
- // XHECK -NEXT: %4 = address_to_pointer %3
418
- // XHECK -NEXT: return %4
413
+ // CHECK : bb0(%0 : $Builtin.RawPointer):
414
+ // CHECK -NEXT: %1 = pointer_to_address %0
415
+ // CHECK -NEXT: %2 = integer_literal $Builtin.Word, 10
416
+ // CHECK -NEXT: %3 = index_addr %1 : $*UInt8, %2
417
+ // CHECK -NEXT: %4 = address_to_pointer %3
418
+ // CHECK -NEXT: return %4
419
419
sil [ossa] @optimize_nested_index_addr : $@convention(thin) (Builtin.RawPointer) -> Builtin.RawPointer {
420
420
bb0(%0 : $Builtin.RawPointer):
421
421
%1 = integer_literal $Builtin.Word, 3
You can’t perform that action at this time.
0 commit comments