• Post Reply Bookmark Topic Watch Topic
  • New Topic

First time tweaker :o  RSS feed

 
David Phluphy
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
(I've rewritten this post now, seeing as it probably was little useless the way I first wrote it)

Hi!

I'm pretty new to programming. Just started the second year of my computer science masters degree. We're doing algorithms now, so I'm wondering how to get started with tweaking, just general hints and tips. An introductory tutorial maybe?

Thanks in advance
 
fred rosenberger
lowercase baba
Bartender
Posts: 12529
48
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Never 'guess' where the bottleneck is. You can almost be sure of one thing - you'll guess wrong. the only way to really know where the bottlenecks are is to use a profiler.

next - why does this need to be optimized? What are the performance requirements, and how does it not meet them?

It's now fairly well known that you will most likely spend more time debugging your code than you can ever save by shaving a millisecond off the run time. Therefore, it is better to focus on writing clean, clear, easy to read, and understandable code than squeezing every clock-cycle of speed by writing obscure hacks.

I say all this without looking at a single line of your code. They are just general tips.
 
David Phluphy
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A profiler will tell me how long each operation takes? Could you perhaps recommend a free profiler that works with eclipse?

I just want to do it for fun and for experience, if I learn which techniques are faster I can write better code from the beginning, in stead of optimizing it later
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!