3 ms·
Wouldn’t that make it slower than if in C++?
by pipeline_peak 2y ago
Wouldn’t that make it slower than if in C++?
- lukeh 2y agoSwift can be just as fast as C or C++. The danger, in my experience, is that it's not always clear what the performance implications of the language's many convenient abstractions are. (A random example, I recently improved one code path by over an order of magnitude by replacing some serialisation that used Codable with hand-rolled code. Still 100% Swift, just paid a lot of attention to avoiding RTTI and allocations.)
- deleted 2y ago[deleted]
- rixed 2y agoSwift had automatic memory management, so yes () (: Although anything can be made as slow as python yada yada)
- timbit42 2y agoA bit slower is good if it is safer from exploits than C and C++.