|
View:
New views
9 Messages
—
Rating Filter:
Alert me
|
|
|
[rvm-research] How are the unboxed classes implemented?Hi all,
Space.java, the class that defines and manages spaces, is constructed like the following: if (vmRequest.type == VMRequest.REQUEST_DISCONTIGUOUS) { this.contiguous = false; this.descriptor = SpaceDescriptor.createDescriptor(); this.start = Address.zero(); this.extent = Extent.zero(); this.lastDiscontiguousRegion = Address.zero(); VM.memory.setHeapRange(index, HEAP_START, HEAP_END); return; } As I know, Address and Extent classes have not been implemented, their methods return nothing but null. In this case, how can a space be created correctly? which really confuse me a lot. It will be highly appreciated if you can solve my puzzle. Thanks. -- Regards, Liangliang Tong ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] How are the unboxed classes implemented?Hi Liangliang,
if you look in the boot image writer you can see variants of the VM magic that don't return null (these are the actual versions compiled into Jikes RVM), the purpose of the other magics is to capture the API for javac compile time. When the compiler sees the unboxed classes it doesn't treat them as objects with method calls but instead places the unboxed value in a register and directly applies arithmetic, etc. to it. The code for this is in files with magic in their name within the compilers. Regards, Ian -- Looking for Jikes RVM on 64bit Linux? Switch to MRP - http://mrp.codehaus.org/ 2009/6/15 Liangliang Tong <lltong@...>: > Hi all, > > Space.java, the class that defines and manages spaces, is constructed > like the following: > > if (vmRequest.type == VMRequest.REQUEST_DISCONTIGUOUS) { > this.contiguous = false; > this.descriptor = SpaceDescriptor.createDescriptor(); > this.start = Address.zero(); > this.extent = Extent.zero(); > this.lastDiscontiguousRegion = Address.zero(); > VM.memory.setHeapRange(index, HEAP_START, HEAP_END); > return; > } > > As I know, Address and Extent classes have not been implemented, their > methods return nothing but null. > In this case, how can a space be created correctly? which really confuse > me a lot. > It will be highly appreciated if you can solve my puzzle. > Thanks. > > -- > Regards, > Liangliang Tong > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers > ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] How are the unboxed classes implemented?Hi Ian,
You should admit that this reply actually saves my life :) Regards, Liangliang Ian Rogers wrote: > Hi Liangliang, > > if you look in the boot image writer you can see variants of the VM > magic that don't return null (these are the actual versions compiled > into Jikes RVM), the purpose of the other magics is to capture the API > for javac compile time. When the compiler sees the unboxed classes it > doesn't treat them as objects with method calls but instead places the > unboxed value in a register and directly applies arithmetic, etc. to > it. The code for this is in files with magic in their name within the > compilers. > > Regards, > Ian > -- > Looking for Jikes RVM on 64bit Linux? Switch to MRP - http://mrp.codehaus.org/ > > 2009/6/15 Liangliang Tong <lltong@...>: > >> Hi all, >> >> Space.java, the class that defines and manages spaces, is constructed >> like the following: >> >> if (vmRequest.type == VMRequest.REQUEST_DISCONTIGUOUS) { >> this.contiguous = false; >> this.descriptor = SpaceDescriptor.createDescriptor(); >> this.start = Address.zero(); >> this.extent = Extent.zero(); >> this.lastDiscontiguousRegion = Address.zero(); >> VM.memory.setHeapRange(index, HEAP_START, HEAP_END); >> return; >> } >> >> As I know, Address and Extent classes have not been implemented, their >> methods return nothing but null. >> In this case, how can a space be created correctly? which really confuse >> me a lot. >> It will be highly appreciated if you can solve my puzzle. >> Thanks. >> >> -- >> Regards, >> Liangliang Tong >> >> >> ------------------------------------------------------------------------------ >> Crystal Reports - New Free Runtime and 30 Day Trial >> Check out the new simplified licensing option that enables unlimited >> royalty-free distribution of the report engine for externally facing >> server and web deployment. >> http://p.sf.net/sfu/businessobjects >> _______________________________________________ >> Jikesrvm-researchers mailing list >> Jikesrvm-researchers@... >> https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers >> >> > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers > > -- Regards, Liangliang Tong ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] How are the unboxed classes implemented?There is a section in the userguide on Magic: http://docs.codehaus.org/display/RVM/Magic |
|
|
Re: [rvm-research] How are the unboxed classes implemented?Hi Liangliang,
I'll just add a couple more comments. The big picture is that in Jikes RVM we wanted new types that behaved just like Java's primitive types (int, byte, etc). Of course we can't (and don't want to) change the Java language so we use unboxing and compiler intrinsics to achieve new types that are very similar to primitive types in terms of performance. If you're interested in the underlying ideas and design, the following paper may be helpful to you. Some of it is historical, some of it is speculative (things we hope to do, such as more general forms of unboxing): http://cs.anu.edu.au/~Steve.Blackburn/pubs/abstracts.html#vmmagic-vee-2009 Cheers, --Steve On 15/06/2009, at 7:03 PM, Liangliang Tong wrote: > Hi all, > > Space.java, the class that defines and manages spaces, is constructed > like the following: > > if (vmRequest.type == VMRequest.REQUEST_DISCONTIGUOUS) { > this.contiguous = false; > this.descriptor = SpaceDescriptor.createDescriptor(); > this.start = Address.zero(); > this.extent = Extent.zero(); > this.lastDiscontiguousRegion = Address.zero(); > VM.memory.setHeapRange(index, HEAP_START, HEAP_END); > return; > } > > As I know, Address and Extent classes have not been implemented, their > methods return nothing but null. > In this case, how can a space be created correctly? which really > confuse > me a lot. > It will be highly appreciated if you can solve my puzzle. > Thanks. > > -- > Regards, > Liangliang Tong > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] How are the unboxed classes implemented?Hi Steve,
Thanks for your useful comments. Steve Blackburn wrote: > Hi Liangliang, > > I'll just add a couple more comments. > > The big picture is that in Jikes RVM we wanted new types that behaved > just like Java's primitive types (int, byte, etc). Of course we > can't (and don't want to) change the Java language so we use unboxing > and compiler intrinsics to achieve new types that are very similar to > primitive types in terms of performance. > > If you're interested in the underlying ideas and design, the following > paper may be helpful to you. Some of it is historical, some of it is > speculative (things we hope to do, such as more general forms of > unboxing): > > http://cs.anu.edu.au/~Steve.Blackburn/pubs/abstracts.html#vmmagic-vee-2009 > > Cheers, > > --Steve > > > On 15/06/2009, at 7:03 PM, Liangliang Tong wrote: > > >> Hi all, >> >> Space.java, the class that defines and manages spaces, is constructed >> like the following: >> >> if (vmRequest.type == VMRequest.REQUEST_DISCONTIGUOUS) { >> this.contiguous = false; >> this.descriptor = SpaceDescriptor.createDescriptor(); >> this.start = Address.zero(); >> this.extent = Extent.zero(); >> this.lastDiscontiguousRegion = Address.zero(); >> VM.memory.setHeapRange(index, HEAP_START, HEAP_END); >> return; >> } >> >> As I know, Address and Extent classes have not been implemented, their >> methods return nothing but null. >> In this case, how can a space be created correctly? which really >> confuse >> me a lot. >> It will be highly appreciated if you can solve my puzzle. >> Thanks. >> >> -- >> Regards, >> Liangliang Tong >> >> >> ------------------------------------------------------------------------------ >> Crystal Reports - New Free Runtime and 30 Day Trial >> Check out the new simplified licensing option that enables unlimited >> royalty-free distribution of the report engine for externally facing >> server and web deployment. >> http://p.sf.net/sfu/businessobjects >> _______________________________________________ >> Jikesrvm-researchers mailing list >> Jikesrvm-researchers@... >> https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers >> > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers > > -- Regards, Liangliang Tong ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
[rvm-research] To create a space using VMRequestHi All,
Like the following code in org.mmtk.plan.MS.java: /public static final MarkSweepSpace msSpace = new MarkSweepSpace("ms", DEFAULT_POLL_FREQUENCY, VMRequest.create());/ it takes VMRequest.create() as a parameter, yet in VMRequest.java, this method is implemented like this: / public static VMRequest create() { return new VMRequest(REQUEST_DISCONTIGUOUS, Address.zero(), Extent.zero(), 0f, false); }/ Doesn't this method return a space starting with address zero and ending with zero? Thanks in advance. -- Regards, Liangliang Tong ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] To create a space using VMRequestLiangliang,
In that example, the request is for a discontiguous space. These spaces have no pre-defined start or length. They grow their virtual memory footprint on demand. By contrast other methods of VMRequest can request specific regions of the virtual address space for the space. The choice of which to use depends on whether you need specific address ranges to be pinned down. --Steve On 15/06/2009, at 10:16 PM, Liangliang Tong wrote: > Hi All, > > Like the following code in org.mmtk.plan.MS.java: > > /public static final MarkSweepSpace msSpace = new MarkSweepSpace("ms", > DEFAULT_POLL_FREQUENCY, VMRequest.create());/ > > it takes VMRequest.create() as a parameter, yet in VMRequest.java, > this > method is implemented like this: > > / public static VMRequest create() { > return new VMRequest(REQUEST_DISCONTIGUOUS, Address.zero(), > Extent.zero(), 0f, false); > }/ > > Doesn't this method return a space starting with address zero and > ending > with zero? > Thanks in advance. > > -- > Regards, > Liangliang Tong > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
|
|
Re: [rvm-research] To create a space using VMRequestSteve,
Thanks a lot. Steve Blackburn wrote: > Liangliang, > > In that example, the request is for a discontiguous space. These > spaces have no pre-defined start or length. They grow their virtual > memory footprint on demand. By contrast other methods of VMRequest > can request specific regions of the virtual address space for the space. > > The choice of which to use depends on whether you need specific > address ranges to be pinned down. > > --Steve > > On 15/06/2009, at 10:16 PM, Liangliang Tong wrote: > > >> Hi All, >> >> Like the following code in org.mmtk.plan.MS.java: >> >> /public static final MarkSweepSpace msSpace = new MarkSweepSpace("ms", >> DEFAULT_POLL_FREQUENCY, VMRequest.create());/ >> >> it takes VMRequest.create() as a parameter, yet in VMRequest.java, >> this >> method is implemented like this: >> >> / public static VMRequest create() { >> return new VMRequest(REQUEST_DISCONTIGUOUS, Address.zero(), >> Extent.zero(), 0f, false); >> }/ >> >> Doesn't this method return a space starting with address zero and >> ending >> with zero? >> Thanks in advance. >> >> -- >> Regards, >> Liangliang Tong >> >> >> ------------------------------------------------------------------------------ >> Crystal Reports - New Free Runtime and 30 Day Trial >> Check out the new simplified licensing option that enables unlimited >> royalty-free distribution of the report engine for externally facing >> server and web deployment. >> http://p.sf.net/sfu/businessobjects >> _______________________________________________ >> Jikesrvm-researchers mailing list >> Jikesrvm-researchers@... >> https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers >> > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Jikesrvm-researchers mailing list > Jikesrvm-researchers@... > https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers > > -- Regards, Liangliang Tong ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Jikesrvm-researchers mailing list Jikesrvm-researchers@... https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers |
| Free embeddable forum powered by Nabble | Forum Help |