Skip to content

Commit a47b694

Browse files
committed
tests: fix the dead_alloc_elim.sil for 32-bit architectures
1 parent 797d94d commit a47b694

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

test/SILOptimizer/dead_alloc_elim.sil

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -699,17 +699,8 @@ sil @$ss23_ContiguousArrayStorageCfD : $@convention(method) <Element> (@owned _C
699699
bb0(%0 : $_ContiguousArrayStorage<Element>):
700700
%1 = ref_tail_addr %0 : $_ContiguousArrayStorage<Element>, $Element
701701
%2 = address_to_pointer %1 : $*Element to $Builtin.RawPointer
702-
%3 = upcast %0 : $_ContiguousArrayStorage<Element> to $__ContiguousArrayStorageBase
703-
%4 = ref_element_addr %3 : $__ContiguousArrayStorageBase, #__ContiguousArrayStorageBase.countAndCapacity
704-
%5 = struct_element_addr %4 : $*_ArrayBody, #_ArrayBody._storage
705-
%6 = struct_element_addr %5 : $*_SwiftArrayBodyStorage, #_SwiftArrayBodyStorage.count
706-
%7 = struct_element_addr %6 : $*Int, #Int._value
707-
%8 = load %7 : $*Builtin.Int64
708-
%9 = builtin "assumeNonNegative_Int64"(%8 : $Builtin.Int64) : $Builtin.Int64
709702
%10 = metatype $@thick Element.Type
710-
%11 = builtin "truncOrBitCast_Int64_Word"(%9 : $Builtin.Int64) : $Builtin.Word
711-
%12 = builtin "destroyArray"<Element>(%10 : $@thick Element.Type, %2 : $Builtin.RawPointer, %11 : $Builtin.Word) : $()
712-
fix_lifetime %0 : $_ContiguousArrayStorage<Element>
703+
%12 = builtin "destroyArray"<Element>(%10 : $@thick Element.Type, %2 : $Builtin.RawPointer, undef : $Builtin.Word) : $()
713704
dealloc_ref %0 : $_ContiguousArrayStorage<Element>
714705
%15 = tuple ()
715706
return %15 : $()

0 commit comments

Comments
 (0)