Commits

Slava Pestov committed 800821f9808
IRGen: Layout of root classes containing resiliently-sized fields Now that all the machinery is in place, the ClassMetadataBuilder can (more accurately) query the ClassLayout instead of trying to re-derive whether the field offset vector is dependent, etc. Apart from performing dynamic layout for resiliently-sized fields in concrete classes, this also lets us *skip* dynamic layout if we have a generic class without any dependent fields. I haven't tested subclassing with resilient field layout yet, but getting that working is the next step and should not be too much work. Also, swift_initClassMetadata_UniversalStrategy() only stores the computed field offsets in the field offset globals when the Objective-C runtime is available, because it gets the offset pointers from the Objective-C class rodata. On Linux, we will need to emit code to copy from the field offset vector into field offset globals in IRGen. This is pretty easy, but I'll do it in a follow-up patch so for now the new execution test is XFAIL'd on Linux.