Alternatives to OOP in D

monkyyy crazymonkyyy at gmail.com
Fri Nov 14 06:35:23 UTC 2025


On Friday, 14 November 2025 at 03:39:11 UTC, Peter C wrote:
>
> If you're process a large collection of simple shape objects in 
> a tight loop, then the performance of static polymorphism will 
> likey win - primarly because you reduce the likelihoood of 
> branch prediction failures

"static polymorphism", you either mean classes in which case 
every one is still likely a cache miss or you mean structs and it 
eliminates the possible cache miss and has no branch prediction 
to resolve


More information about the Digitalmars-d-learn mailing list