uraimo / buildSwiftOnARM

All you need to build Swift on a RaspberryPi or other ARM boards, updated to Swift 5.1.5
489 stars 37 forks source link

[arm32][4.2] Pointer is not sufficiently aligned #30

Closed Kaiede closed 6 years ago

Kaiede commented 6 years ago

After reversing the commit causing the hasVal assert, this is the next failure being hit in x86/arm32.

This doesn’t appear in the 4.1 branch, but does VERY shortly after the last 4.1 merge from master, suggesting it should be pretty fast to track down compared to the last one.

swift: /home/.../buildSwiftOnARM/llvm/include/llvm/ADT/PointerIntPair.h:160: static intptr_t llvm::PointerIntPairInf
o<swift::Type, 1, llvm::PointerLikeTypeTraits<swift::Type> >::updatePointer(intptr_t, PointerT) [PointerT = swift::Type
, IntBits = 1, PtrTraits = llvm::PointerLikeTypeTraits<swift::Type>]: Assertion `(PtrWord & ~PointerBitMask) == 0 && "P
ointer is not sufficiently aligned"' failed.
/home/.../buildSwiftOnARM/build/buildbot_linux/swift-linux-i686/bin/swift[0xc4023f0]                                
Stack dump:                                                                                                            

...

1.      While resolving type ClosedRange.Index at [/home/.../buildSwiftOnARM/swift/stdlib/public/core/ClosedRange.sw
ift:138:11 - line:138:23] RangeText="ClosedRange.I"                                                                    
2.      While resolving type Strideable at [/home/.../buildSwiftOnARM/swift/stdlib/public/core/ClosedRange.swift:131
:37 - line:131:37] RangeText="S"        
Kaiede commented 6 years ago

So, this bug was introduced by a change in Dec, but fixed at the end of January.

The catch is the hasVal bug was introduced between Jan 21 and 25, lurking underneath making it harder to understand what happened here. Closing this out since the fix is already in the 4.2 branch.