hey, i am very disappointed with unity perfomance, but maybe it is my fault so i wanted to ask about my code. i am traversing a single linked list, and on every node i am checking for null. On low end pc it can take even 10ms with very large lists. here is my code: Code (CSharp): while(n) { // do something n =n.next; } i know that unity has custom == operator or something, but does it mean that I can't do anything to speed it up? Maybe I should use List< > instead? But I am remvoing and adding often...
What's the "do something" part? That's most likely the cause of any performance issues. For confirmation, comment that part out and profile again. Also, how big is your LinkedList<>?