Re: Tail recursion in Java, was Proper Tail Recursive C++

markt@harlequin.co.uk (Mark Tillotson)
14 May 1997 23:57:53 -0400

          From comp.compilers

Related articles
Re: Proper Tail Recursive C++ erik.schnetter@student.uni-tuebingen.de (1997-03-21)
Re: Tail recursion in Java, was Proper Tail Recursive C++ danwang@atomic.CS.Princeton.EDU (1997-03-22)
Re: Tail recursion in Java, was Proper Tail Recursive C++ Dave@occl-cam.demon.co.uk (Dave Lloyd) (1997-03-27)
Re: Tail recursion in Java, was Proper Tail Recursive C++ ramsdell@linus.mitre.org (John D. Ramsdell) (1997-04-02)
Re: Tail recursion in Java, was Proper Tail Recursive C++ hbaker@netcom.com (1997-04-03)
Re: Tail recursion in Java, was Proper Tail Recursive C++ markt@harlequin.co.uk (1997-05-14)
| List of all articles for this month |
From: markt@harlequin.co.uk (Mark Tillotson)
Newsgroups: comp.compilers
Date: 14 May 1997 23:57:53 -0400
Organization: Harlequin Ltd, Longstanton House, Cambridge UK
References: 97-03-129 97-03-136 97-03-155 97-04-019
Keywords: Java, optimize

> > Surely the compiler has to apply the same policy statically as would
> > be applied dynamically.
>
> How does a Java VM know that the code it is running is produced by a
> compiler?


Even more to the point, the same class (as compiled) could be secure
in one runtime, and insecure in another - it is a dynamic property of
class loading, not something that can be determined statically.


The solution is that at load time we can make a determination of which
method calls are potentially between trusted and untrusted classes,
and label them as not tail-eliminatable. You also have to do an
analysis for calls from synchronized methods, which are again not, in
general, tail-eliminatable.




__Mark
[ markt@harlequin.co.uk | http://www.harlequin.co.uk/ | +44(0)1954 785433 ]
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.