You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ObjC] Check entire chain of superclasses to see if class has fixed offsets
As of now, we only check if a class directly inherits from NSObject to determine if said lass has fixed offsets and can therefore "opt-out" from the non-fragile ABI for ivars.
However, if an NSObject subclass has fixed offsets, then so must the subclasses of that subclass, so this allows us to optimize instances of subclasses of subclasses that inherit from NSObject and so on.
To determine this, we need to find that the compiler can see the implementation of each intermediate class, as that means it is statically linked.
Perhaps there is another way to figure this out at link time as well, but that is for another time and another PR.
Fixes: #81369
0 commit comments