home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 1
Development
General Development (no feature request here!)
Some simple coding techniques to push C# as fast as possible
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Anonymous" data-source="post: 6289"><p>Well, you could change nSize inside the for loop, so I'm not sure how the compiler would get out of evaluating it every time, or at least checking that nSize hasn't changed. Now, the compiler may be smart enough to see that nSize isn't being changed inside the loop and store that calculation. On that matter I couldn't answer. Regardless of it all, to maximize performance you should take that calculation out of the 'for' line. (assuming you don't change nSize in the loop of course!)</p></blockquote><p></p>
[QUOTE="Anonymous, post: 6289"] Well, you could change nSize inside the for loop, so I'm not sure how the compiler would get out of evaluating it every time, or at least checking that nSize hasn't changed. Now, the compiler may be smart enough to see that nSize isn't being changed inside the loop and store that calculation. On that matter I couldn't answer. Regardless of it all, to maximize performance you should take that calculation out of the 'for' line. (assuming you don't change nSize in the loop of course!) [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
Development
General Development (no feature request here!)
Some simple coding techniques to push C# as fast as possible
Contact us
RSS
Top
Bottom