Typechecking JVML
In Java 6 (Mustang) we will be
releasing a new version of the byte code verifier. For those of you living in blessed ignorance, the verifier is in essence a typechecker for machine language of the JVM, which I will refer to as JVML below.
So why are we doing this? To make verification faster, simpler and more adaptable. The existing verifier performs type inference (more precisely,
type reconstruction). In JVML, types are declared for fields, formal parameters of methods and method return types - but not for local variables or the
operand stack.
Hence, the verifier must infer the types of local variables and the operand stack based on how they are used. This is slow, memory intensive and very complicated.
The new scheme is rooted in research done by Eva Rose for her master's thesis a few years back.
The new verifier requires additional type declarations for local variables and the operand stack in JVML. As a consequence of this and other detailed changes,
it doesn't need to infer them, and is about twice as fast,
uses a fraction of the memory and is vastly simpler than the old
verifier.
So increased speed and reduced space are obviously good. Simplicity is also obviously good, but looking at the software industry, it's clear that it worships complexity. An appreciation of simplicity for its own sake is sorely lacking. Most people need very concrete examples before
they are willing to invest any effort for the sake of simplicity.
Here is one example of why this simplification might be useful. Let's imagine that at some point in time, it might be plausible (in terms of compatibility) to reify generics.
Among many other issues, this entails verification of generics.
It will be relatively straightforward to extend the new verifier to typecheck generics. Anyone who would seek to get the old verifier to do this is probably in need of clinical assistance.
In Mustang, javac will generate the necessary type information in the class files it produces. It won't generate code using jsr and ret either (nor will other tools Sun releases). Other vendors may need more time to catch up, which is why we will fall back to the old verifier for a while.
The spec for all this is being worked out as part of JSR202 where you can get a draft spec. You can also get more detail on practicalities in Wei Tao's article on the
typechecking verifier. Obviously, the verifier is critical to the security and integrity ofthe Java platform. Because of this, we'd like to get the community involved in banging on
both the spec and the implementation. If there are any holes, we want to find them
before the release.
To that end, Sun is asking for knowledgable people to have a go at
cracking the new verification scheme. If you find a hole in the spec, you'll get recognized at the JavaOne 2006 conference.
Honorable mention for finding holes in the implementation. Details should be available soon at the Crack the Verifier
Initiative web
page.
Posted at 06:00PM Oct 30, 2005 by gbracha in Java | Comments[47]
Posted by Patrick Wright on October 31, 2005 at 05:06 AM PST #
Posted by Dana on October 31, 2005 at 06:27 AM PST #
Posted by Fred Grott on October 31, 2005 at 06:29 AM PST #
Posted by Udo Schuermann on October 31, 2005 at 06:43 AM PST #
Posted by Tal Rotbart on October 31, 2005 at 06:45 AM PST #
Posted by Eric Lauzon on October 31, 2005 at 11:13 AM PST #
Posted by Eric Lauzon on October 31, 2005 at 11:13 AM PST #
Posted by Eric Lauzon on October 31, 2005 at 12:32 PM PST #
Posted by Joel Jones on November 01, 2005 at 01:48 PM PST #
Posted by Peter Taylor on November 02, 2005 at 08:40 AM PST #
Posted by Gilad Bracha on November 02, 2005 at 10:05 AM PST #
Posted by Radu Grigore on November 10, 2005 at 09:26 AM PST #
Posted by Mohan Radhakrishnan on November 15, 2005 at 05:31 AM PST #
Posted by d r on November 19, 2005 at 01:14 PM PST #
Posted by kambiz shahri on November 21, 2005 at 03:13 PM PST #
Posted by 62.38.141.229 on December 01, 2005 at 03:35 AM PST #
Posted by Mike M on December 17, 2005 at 11:39 AM PST #
Create a compiled JAR cache which contains shared library lightly compiled versions of JARS. When Java sees a new JAR it looks in the cache first to see if it has already been verified, checking timestamps. If found, it can just be memory mapped in, very fast. And, more importantly it can be shared.
"Lightly compiled" means not inlining that could be invalidated by other JARS. Still much faster than byte code.
This would obviate the need for the monolithic Java process.
Once you cache byte coding, then you don't need the javac/byte code at all. Just load source directly into java. Much simpler build environment.
Posted by Anthony Berglas on December 18, 2005 at 04:36 PM PST #
Some time ago, Java bytecode verification was one of my research interests and I am still interested in the issue.
I can still remember some oddities and will check what Mustang intends to do with them. Inlining the subroutines has at least removed the biggest question mark already ;-)
If I got it right, this is currently the only discussion list (the link in the forums section does not seem to be ready). Hence, let me post some first comments.
The specification request has become more "specific" with respect to the semantics of the type checking rules - thanks for that. The only thing I want to suggest, is to place a more detailed view on the type hierarchy somewhere. This should include the first layer of array types (with reference and primitive type elements) - to help the newcomers understand the consequences of the inductive definition and the special role of type <tt>object</tt>.
Finally, can anybody give me a short intention about the algorithm? Is it mainly the CLDC style verification enhanced by a more sophisticated encoding or have you adopted any of Eva Rose's advanced ideas like integration of type information that has been constructed by the verifier and the minimization of the active stack map attributes during the verification process?
Best regards
Posted by KarstenKlohs on December 23, 2005 at 12:45 AM PST #
Posted by Amit Kumar on December 28, 2005 at 04:27 AM PST #
Posted by David Hoyt on January 11, 2006 at 02:48 PM PST #
Posted by Maarten Bodewes on January 12, 2006 at 02:35 PM PST #
Posted by Dalibor Topic on February 21, 2006 at 08:40 PM PST #
Posted by www on November 21, 2006 at 07:03 AM PST #
Posted by olo on January 24, 2007 at 12:12 PM PST #
Posted by www on January 27, 2007 at 08:51 AM PST #
Posted by google排名 on January 30, 2007 at 07:02 PM PST #
Posted by publish articles free on April 13, 2007 at 02:11 AM PDT #
Posted by search engine on April 13, 2007 at 02:27 AM PDT #
Posted by antibiotics online on April 13, 2007 at 02:42 AM PDT #
Posted by hair loss solution on April 13, 2007 at 03:28 AM PDT #
Posted by Cialis best price buy online. on April 23, 2007 at 08:56 AM PDT #
Posted by treadmill on May 17, 2007 at 04:39 AM PDT #
Posted by hongk on May 21, 2007 at 06:51 PM PDT #
Posted by www on June 04, 2007 at 02:11 PM PDT #
Posted by sent on July 02, 2007 at 04:50 PM PDT #
Posted by sss on July 02, 2007 at 04:54 PM PDT #
Posted by sss on July 02, 2007 at 04:55 PM PDT #
Posted by dtrdhy on July 19, 2007 at 12:33 PM PDT #
Posted by 哈罗 on July 19, 2007 at 12:33 PM PDT #
Posted by sertr55yr on July 19, 2007 at 12:33 PM PDT #
Posted by dtrdhy on July 19, 2007 at 12:33 PM PDT #
Posted by 哈罗 on July 19, 2007 at 12:33 PM PDT #
<a HREF="http://www.sextoysex.com/sex/start/products/rabbit.html?a=adult-products">jack rabbit vibrator</a> jack rabbit vibrator
<a HREF="http://www.sextoysex.com/sex/start/products/strapon.html?a=adult-products">strap on cocks</a> strap on cocks
<a HREF="http://www.sextoysex.com/sex/start/products/vibrators.html?a=adult-products">strap on vibrators</a> strap on vibrators
<a HREF="http://www.sextoysex.com/sex/start/products/cockrings.html?a=adult-products">ejaculation rings</a> ejaculation rings
<a HREF="http://www.sextoysex.com/sex/start/products/penis-enlargers.html?a=adult-products">penis enlargers</a> penis enlargers
<a HREF="http://www.sextoysex.com/sex/start/products/masturbators.html?a=adult-products">realistic vaginas</a> realistic vaginas
<a HREF="http://www.sextoysex.com/sex/start/products/anal.html?a=adult-products">anal beads</a> anal beads
<a HREF="http://www.sextoysex.com/sex/start/products/lubes.html?a=adult-products">intimate body massage</a> intimate body massage
<a HREF="http://www.sextoysex.com/sex/start/products/bondage.html?a=adult-products">bondage sex toys</a> bondage sex toys
<a HREF="http://www.sextoysex.com/sex/start/products/dolls.html?a=adult-products">sex doll</a> sex doll
Posted by adult toys on September 30, 2007 at 01:13 AM PDT #
http://www.jazz-d.com 北京展览公司
http://www.jazz-d.com 展览制作
http://www.jazz-d.com 展柜制作
http://www.jazz-d.com 展台搭建
http://www.jazz-d.com 会议布置
http://www.suohenggk.com/ 工控产品
http://www.suohenggk.com/ 东方马达
http://www.suohenggk.com/ rkc温控器
http://www.suohenggk.com/ 神视传感器
http://www.suohenggk.com/ 日东胶带
http://www.7come.com/ 爱普泰克
http://www.7come.com/ 爱普泰克网易拍
http://www.7come.com/ 爱普泰克网e拍
http://www.7come.com/ 网易拍
http://www.7come.com/ 网e拍
http://www.7come.com/ Aiptek
http://www.yaone.com 服务器托管
http://www.yaone.com 北京服务器托管
http://www.yaone.com 北京主机托管
http://www.yaone.com 双线托管
http://www.yaone.com 电信托管
http://www.yaone.com 托管主机
http://www.achristmas.cn 圣诞工艺品
http://www.achristmas.cn 圣诞工艺品厂
http://www.qiledao.com/ 成人用品
http://www.qiledao.com/ 性用品
http://www.qiledao.com/ 性生活用品
http://www.qiledao.com/ 性保健用品
http://www.qiledao.com/ 北京成人用品
http://www.qiledao.com/ 成人用品商城
http://wz.yaone.com 网站建设
http://wz.yaone.com 网站制作
http://wz.yaone.com 网页制作
http://wz.yaone.com 北京网站建设
http://wz.yaone.com 北京网站制作
http://wz.yaone.com 北京网页制作
http://wz.yaone.com 北京网站建设公司
http://wz.yaone.com 网站建设公司
Posted by 98JIGDSF on October 31, 2007 at 02:55 AM PDT #
It's nice to find a site you can trust. I like the privacy of shopping online, but you never know what sites are okay. This site was recommended by a friend so I tried it. The service was great! I'm becoming a frequent shopper! ;) <a href="http://www.moystoys.com">gay sexshop paypal</a>
[URL= http://www.moystoys.com ] Sex Toys Generic Dildos Giant[/URL]
http://www.moystoys.com
toys
Posted by Adult Sex Shop on February 18, 2008 at 12:57 PM PST #
Generic Ativan (Lorazepam) is used to treat anxiety. This drug may also be used for seizures, alcohol withdrawal, prevention of nausea and vomiting due to chemotherapy, tension headache, and for sleeping trouble (insomnia).
http://www.nordmed.com/generic-ativan-medication.php http://www.nordmed.com/ativan-brand-medication.php
Klonopin (Clonazepam) is used to control seizures. It is also used to relieve anxiety. This medicine is a benzodiazepine used to treat seizures and panic disorder. http://www.nordmed.com/generic-klonopin-medication.php http://www.nordmed.com/klonopin-brand-medication.php
Prozac (FLUOXETINE) is a Serotonin Reuptake Inhibitor (SSRI) that helps patients with depression by increasing the availability of serotonin in the brain. Scientists believe serotonin affects many types of activity in the brain, including the regulation of mood.
http://www.nordmed.com/generic-prozac-medication.php
Zoloft (SERTRALINE) is a selective Serotonin Reuptake Inhibitor (SSRI) used to treat depression, panic disorder, obsessive - compulsive disorders (OCD), post-traumatic stress disorder (PTSD, and a severe form of premenstrual syndrome (Premenstrual Dysphoric Disorder - PMDD).
http://www.nordmed.com/generic-zoloft-medication.php
Posted by medications from europe on May 06, 2008 at 01:46 AM PDT #