inlining across .java files?

Jeff Sturm
Mon Oct 14 13:00:00 GMT 2002

On Fri, 11 Oct 2002, Andrew Haley wrote:
> Adam Megacz writes:
>  >
>  > If I compile multiple .java files as one "compilation unit" (one
>  > invocation of gcj), will gcj inline *across* files?  If not, is there
>  > any way I can get it to do this?
> It could be made to, but we don't yet support it.

I tried this.  It doesn't quite work yet.  For one thing,
soft_initclass_node doesn't get inlined on static methods, since it isn't
in the method's tree representation.  Instead, it is expanded directly
into RTL by complete_start_java_method.  Ditto for synchronization.

Although I observed a ~10% speedup by inlining an entire application, it
isn't clear how much of that was actually due to inlining vs. dropping the
class initialization.


More information about the Java mailing list