On Wednesday 25 February 2004 11:45, virupaksha wrote:
> Dear All,
>
> I have a requirement, where i need to stop garbage collection, is
> there any way to implement? Because, I need to  judge our code is
> good and optimized,
>
> I need some ray of hope,,,,

The thing you're asking for is possibly a Profiler which gathers
statistics about which parts of your code might be performance
bottlenecks and should be optimized first. There are numerous
solutions for this task available today, so better ask Google.
Then, - just to note - one of the premier influences on perfor-
mance is the overall application design. If you have databases
or other kinds of backends included, which I presume, one
of the typical performance bottlenecks is a suboptimal way
to access them. A single query that doesn't perform right
can well keep your entire application hanging for an indeter-
minable amount of time. Generally: if you experience per-
formance problems of some kind, the strategy should be
to find out *what exactly is slow* first. If you get hold of
the possible weak points, optimize these first. In a
larger-scaled application, there are always parts that
are coded suboptimal, but without a noticeable impact
on overall performance. Then, there are some critical
'hotspots' which get executed numerous times (a
suboptimally coded loop, for example) or functions
that are heavily used. Such are the spots you have
to look for. Telling from experience, most applications
are quite forgiving when it comes to 'slow' code
that could be done better, but there are always
'critical' parts where optimization really pays off.
So in the end, it's usually kind of a mix. If you can't
tell the hotspots 'manually' by knowing them from
your application design, you can fall back to 'Tools'.
Tools, though, are just tools and don't spare you
from the arduous task of analyzing your app's
performance. It's always you who has to do the
real work. That said, there are different possible
strategies to address performance problems.
One of the most important is to 'dumbly' log
execution times at certain stages in your code.
If your Java code might be a culprit in the
end, use a profiler to determine what's
causing delays there. Focus on the
'hotspots' then. But remember: there was a
time when there were no such 'tools', so
people had to live without them. And did.
      
If you use Oracle JDeveloper 9i/10g, there's a built-in profiler
in this IDE plus a feature named 'Code Coach' which helps
avoiding the most common mistakes. Note that both require
the Oracle VM and therefore run only under Windows. 

> Thanks in advance,
>
> Viru

HTH,

-- Chris.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to