by pcwalton · 7y ago · 0 comments
Mike Ash has a nice series that goes through the disassembly of objc_msgSend: https://www.mikeash.com/pyblog/friday-qa-2017-06-30-dissecti...
I expect you can't use jump tables in objc because you can't really "patch in" jump tables at runtime as it's AOT-compiled rather than JIT-ed.
Plus, in a JIT you can go even further and just do direct calls, no need for the indirection of tables.
Nit: method calls to objects that are not nil, since the latter causes objc_msgSend to bail out before the hash table is consulted.