Tool or IDE for function inlining

A

Alex

Dear All!

I need to inline my functions bodys into caller functions. Please
suggest me a good tool or IDE for refactoring. Currently I use Jbuilder
2005, but unsatisfied with its dumb text substitution and hungs.
 
M

Mark Thornton

Alex said:
Dear All!

I need to inline my functions bodys into caller functions. Please
suggest me a good tool or IDE for refactoring.

Why do you need to do this? Most JIT compilers will do this
automatically at run time where appropriate.

Mark Thornton
 
F

FunkyKarma

I need to inline my functions bodys into caller functions. Please
Why do you need to do this? Most JIT compilers will do this
automatically at run time where appropriate.

While JIT compilers and Java source compilers should do this in some
situations, it has been my experience that it doesn't (always) happen. I
suppose sometimes method visibility and lack of being final may explain some
of it, but still the bottom line is that I've experienced performance
benefit by inlining by hand.

I too would like to see an easy to use tool to make this happen. Or better
yet the introduction of macros and/or language keywords to facilitate it.
Although I know that's not at all likely to happen.

I've heard of people using C precompilers to do some of this but that
approach is cumbersome at best.
 
?

=?ISO-8859-1?Q?Daniel_Sj=F6blom?=

Alex said:
Dear All!

I need to inline my functions bodys into caller functions. Please
suggest me a good tool or IDE for refactoring. Currently I use Jbuilder
2005, but unsatisfied with its dumb text substitution and hungs.

Eclipse.
 
A

Alex

I need this because I am programming J2ME with SUN KVM interpreter. The
call is cost enormous cpu cycles (I bencmarked it). Also if function
body is properly inlined, it gives more chances to javac optimize
bytecode and shrinks .class size.
 
F

FunkyKarma

Dear All!

Unless I'm missing something, the Eclipse Refactor->Inline feature is not
the answer. Using that feature is a one time shot sort of thing. After the
inlining is done, one can't undo it. That inhibits maintaining the inlined
code. That is, a change to the inlined code means changing it everywhere in
which it was inlined.
 
E

Eli

A new software engineering technique called Binary Refactoring
addresses this and other similar problems.

"Inline Method" is one of the binary refactorings supported
by BARBER, a reference implementation of
a binary refactoring browser for Java: http://j-orchestra.org/barber/.

Unfortunately, BARBER is a research prototype rather than
a production-quality software tool.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top