dengkeli
❔ Need guidance on generics, List, IEnumerable
Well honestly the normal design for perf favors the storage by like type. Honestly I just like the pattern, not so much about perf. But it's kinda limited to about 5 k items before it cant be used in frame time
28 replies
❔ Need guidance on generics, List, IEnumerable
My question is: Which is more performant? I'm not competent enough to understand everything happening here, but I do know adding the constraint and doing an explicit cast (T) in the first example seemed orders of magnitude faster. I'm just not fully aware of the consequences of Cast<T> and ToList, and I don't really have a goof enough understanding to profile them myself. Thanks much.
28 replies