This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Patch: RFC: PR 27352
Bryce McKinlay writes:
> Andrew Haley wrote:
> > > Andrew's patch was to rewrite forName() and getClassLoader()
> > > invocations to add a class argument. Mostly this is for
> > > performance, since it avoids having to do the stack trace. It fixed
> > > 27352 as a side-effect, but only for newly-compiled native code.
> >
> > No, that's not true. The important case is within Class itself, where
> > a call is made (eg) from Class.getPackage() to Class.getClassLoader().
>
> Oh, good point. Oops - I must have been running an older build that
> didn't have this fix (and I saw the PR was still open so assumed it
> wasn't entirely fixed).
>
> Still, I think that using getClassLoaderInternal() at least makes the
> code a bit clearer - and slightly more efficient.
It does, yeah. Fair enough.
Andrew.