3 ms·
To be pedantic, ObjFW is an alternative framework, not an alternative runtime. They do include a runtime for architectures that do not have a native ObjC runtim
by lgg 14y ago
To be pedantic, ObjFW is an alternative framework, not an alternative runtime. They do include a runtime for architectures that do not have a native ObjC runtime, but that runtime is API compatible with Apple's. Since they use the same compilers (clang and gcc) they have the same inlining limitations and the compiler will generate calls into the runtime in the exact same places.
- Midar 14y agoBut the runtime has a faster dispatch than Apple's ;). Actually, I don't get all this "Messaging is slow". In the ObjFW runtime, it's just 12 instructions for x86_64. That's barely noticable. I even used ObjC in an HPC application and compared it to the C version, just for fun. There was no measurable difference in performance. What's more important in the average application is that the foundation classes are fast. For example, C#'s and Cocoa's dictionaries are really slow (but I don't know why). While C# and Cocoa both need 1.2 sec to insert 1 Mio objects into a dictionary and retrieve them, ObjFW only needs 0.3.