Re: The 5% solution
On Thu, May 10, 2001 at 10:19:10AM +0100, Dave Mitchell wrote: to be such that the writing of the Perl 5 to 6 translator utility is still feasable. If you're at TPC this year, you'll hear me how explain how translators *far* weirder than simply Perl 5 to Perl 6 are possible. :) Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft CLR, so that if you can somehow get bytecode onto it - from whatever language - you can run it. So we've got some bytecode that perl can run. Now think about what B::Deparse does. -- Overall there is a smell of fried onions. (fnord)
RE: The 5% solution
-Original Message- From: Simon Cozens [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 10, 2001 8:01 AM To: Dave Mitchell Cc: [EMAIL PROTECTED] Subject: Re: The 5% solution On Thu, May 10, 2001 at 10:19:10AM +0100, Dave Mitchell wrote: to be such that the writing of the Perl 5 to 6 translator utility is still feasable. If you're at TPC this year, you'll hear me how explain how translators *far* weirder than simply Perl 5 to Perl 6 are possible. :) Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft CLR, so that if you can somehow get bytecode onto it - from whatever language - you can run it. ... at half the speed with twice the bugs and no security and no meaningful error messages but lots of good marketing verbage... I'd say we aim a bit higher than a Microsoft example, but point taken nonetheless. p
Re: The 5% solution
Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft CLR, so that if you can somehow get bytecode onto it - from whatever language - you can run it. So we've got some bytecode that perl can run. Now think about what B::Deparse does. I knew the intention was to go the B::Deparse route, but I'd worry about perl5 byte-code not being semantically similar to Perl 6 bytecode. There's a lot of implicit assumptions about what an aassign op does, say. But the words suck, teach, eggs and grandma are probably appropriate at this point if suitably re-arranged ;-)
Re: The 5% solution
Dave Mitchell writes: : Content-MD5: FiIz8m/ma8enU5CTBqhsQw== : X-Mailer: dtmail 1.3.0 @(#)CDE Version 1.4.2 SunOS 5.8 sun4u sparc : X-Spam-Rating: onion.valueclick.com 1.6.2 0/1000/N : : : Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft : CLR, so that if you can somehow get bytecode onto it - from whatever : language - you can run it. So we've got some bytecode that perl can run. : Now think about what B::Deparse does. : : I knew the intention was to go the B::Deparse route, It was, but the current intention is to pursue Perl 5 translation (and maybe even a limp-along compatibility mode) via an alternate parser sitting beside the standard Perl 6 parser. Then people can convert piecemeal when they see the benefits of Perl 6 outweighing the risks. Still, we won't aim for 100% bug compatibility. If 99.99% of scripts translate, that's good enough for me. :-) Actually, if 95% of Perl 5 scripts translate, I'll be overjoyed. Larry
Re: The 5% solution
At 08:40 AM 5/10/2001 -0700, Larry Wall wrote: Dave Mitchell writes: : Content-MD5: FiIz8m/ma8enU5CTBqhsQw== : X-Mailer: dtmail 1.3.0 @(#)CDE Version 1.4.2 SunOS 5.8 sun4u sparc : X-Spam-Rating: onion.valueclick.com 1.6.2 0/1000/N : : : Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft : CLR, so that if you can somehow get bytecode onto it - from whatever : language - you can run it. So we've got some bytecode that perl can run. : Now think about what B::Deparse does. : : I knew the intention was to go the B::Deparse route, It was, but the current intention is to pursue Perl 5 translation (and maybe even a limp-along compatibility mode) via an alternate parser sitting beside the standard Perl 6 parser. Then people can convert piecemeal when they see the benefits of Perl 6 outweighing the risks. There might still be a B::Deparse solution, or a standalone p5 bytecode-p6 bytecode converter, at least at the start. Both for example reasons (potentially to use as, say, a Java bytecode-p6 bytecode converter) and as a way to get bytecode streams to feed into the developing p6 interpreter. Dan --it's like this--- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk
Re: The 5% solution
Dan Sugalski writes: : At 08:40 AM 5/10/2001 -0700, Larry Wall wrote: : Dave Mitchell writes: : : Content-MD5: FiIz8m/ma8enU5CTBqhsQw== : : X-Mailer: dtmail 1.3.0 @(#)CDE Version 1.4.2 SunOS 5.8 sun4u sparc : : X-Spam-Rating: onion.valueclick.com 1.6.2 0/1000/N : : : : : : Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft : : CLR, so that if you can somehow get bytecode onto it - from whatever : : language - you can run it. So we've got some bytecode that perl can run. : : Now think about what B::Deparse does. : : : : I knew the intention was to go the B::Deparse route, : : It was, but the current intention is to pursue Perl 5 translation (and : maybe even a limp-along compatibility mode) via an alternate parser : sitting beside the standard Perl 6 parser. Then people can convert : piecemeal when they see the benefits of Perl 6 outweighing the risks. : : There might still be a B::Deparse solution, or a standalone p5 bytecode-p6 : bytecode converter, at least at the start. Sure, don't want to discourage the B::Deparse folks. In fact, a healthy competition between them and the p6 parser folks might make both better. :-) : Both for example reasons : (potentially to use as, say, a Java bytecode-p6 bytecode converter) and as : a way to get bytecode streams to feed into the developing p6 interpreter. That would be one way to build p6. Another approach is to use the p5 interpreter as scaffolding, with some kind of (not necessarily lightweight) semantic compatibility translation going back and forth. Then you can write new bits of the p6 interpreter and slip them in piecemeal while relying on the p5 interpreter to emulate the bits you haven't written yet. Eventually you've thrown away essentially all the scaffolding, and then you're done (hah!). This is essentially how I managed the p4 to p5 transition. We might need that semantic cushion layer anyway if we want to intermix p5 and p6 modules during the transition. Intermixing modules isn't in our long-term best interest, of course, but as a migration aid I think people would find it extremely helpful. And any way we can help people with their migration is going to be beneficial in the long run. It's likely that translated p6 will run faster than emulated p5 in any event, so I don't think we'll have a long term problem with people using mixed systems. But it's a critical mass problem, and until we get the critical mass of p6 modules out there, people won't switch at all, unless they have a way to mix and match, I suspect. Larry
Re: The 5% solution
On Thu, May 10, 2001 at 08:40:52AM -0700, Larry Wall wrote: Dave Mitchell writes: : Briefly: We want the Perl 6 runtime to be an equivalent of the Microsoft : CLR, so that if you can somehow get bytecode onto it - from whatever : language - you can run it. So we've got some bytecode that perl can run. : Now think about what B::Deparse does. : : I knew the intention was to go the B::Deparse route, It was, but the current intention is to pursue Perl 5 translation (and maybe even a limp-along compatibility mode) via an alternate parser sitting beside the standard Perl 6 parser. I should have been more clear. I was referring to what B::Deparse does at the moment - turns opcode trees into Perl 5 code. If you can somehow get bytecode onto Perl 6 - which you'll need to do with an alternate parser - you can then use the Perl 6 equivalent of B::Deparse to spit out Perl 6. I was suggesting retrofit perl 5 parser - perl6 - Perl 6 B::Deparse rather than perl 5 parser - perl 5 - Perl 5 B::Deparse::ToPerl6 (Try not to think about perl 5 parser - perl 5 - Perl 5 B::Deparse::ToPython or retrofit python parser - perl5 - Perl 5 B::Deparse . It'll only hurt.) -- You're not Dave. Who are you?
Re: The 5% solution
Simon Cozens writes: : If you can somehow get bytecode onto Perl 6 - which you'll : need to do with an alternate parser - you can then use the Perl 6 equivalent : of B::Deparse to spit out Perl 6. At some point it would have to be annotated with formatting and comment info, though. Somebody will have to cogitate about that eventually. And about what to do when it's not clear where to put the comments in the new code... Larry