IP Library Granted Patent US 6,865,738
Granted Patent B2
US 6,865,738 · App. 10/267,382 · Granted Mar 8, 2005

Method and apparatus for managing independent asynchronous I/O operations within a virtual machine

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 6,865,738
App. No.
10/267,382
Granted
Mar 8, 2005
Kind
B2
Abstract

One embodiment of the present invention provides a system that facilitates performing independent asynchronous I/O operations within a platform-independent virtual machine. Upon encountering an I/O operation, a language thread within the system marshals parameters for the I/O operation into a parameter space located outside of an object heap of the platform-independent virtual machine. Next, the language thread causes an associated operating system thread (OS-thread) to perform the I/O operation, wherein the OS-thread accesses the parameters from the parameter space. In this way, the OS-thread does not access the parameters in the object heap directly while performing the I/O operation.

Claims (58)

1. A method for performing independent asynchronous I/O operations within a platform-independent virtual machine, comprising:

encountering an I/O operation during execution of a language thread within the platform-independent virtual machine;

wherein the I/O operation includes parameters for the I/O operation; and in response to encountering the I/O operation,

marshalling the parameters for the I/O operation into a parameter space located outside of an object heap for the platform-independent virtual machine, wherein the marshalling is performed by the language thread, and

causing an operating system thread (OS-thread) associated with the language thread to perform the I/O operation, wherein the OS-thread accesses the parameters from the parameter space;

whereby the OS-thread does not access the object heap directly while performing the I/O operation

wherein the platform-independent virtual machine operates in accordance with a hybrid thread model in which language threads that are not performing I/O operations execute as co-routines on a single OS-thread; and

wherein language threads performing I/O operations are associated with dedicated OS-threads that perform the I/O operations.

2. The method of claim 1 , wherein after the OS-thread finishes the I/O operation, the method further comprises:

unmarshalling parameters from the parameter space, wherein the unmarshalling is performed by the language thread; and

returning from the I/O operation.

3. The method of claim 2 ,

wherein marshalling the parameters involves marshalling the parameters from the object heap; and

wherein unmarshalling the parameters involves unmarshalling the parameters into the object heap.

4. The method of claim 1 , wherein the parameter space is associated with the OS-thread and is allocated from a global pool of memory located outside of the object heap.

5. The method of claim 1 , wherein the parameter space is associated with the OS-thread and is allocated in an unused end of the object heap.

6. The method of claim 1 , wherein the parameter space is allocated in stack space associated with the OS-thread.

7. A computer-readable storage medium storing instructions that when executed by a computer cause the computer to perform a method for performing independent asynchronous I/O operations within a platform-independent virtual machine, the method comprising:

encountering an I/O operation during execution of a language thread within the platform-independent virtual machine;

wherein the I/O operation includes parameters for the I/O operation; and in response to encountering the I/O operation,

marshalling the parameters for the I/O operation into a parameter space located outside of an object heap for the platform-independent virtual machine, wherein the marshalling is performed by the language thread, and

causing an operating system thread (OS-thread) associated with the language thread to perform the I/O operation, wherein the OS-thread accesses the parameters from the parameter space;

whereby the OS-thread does not access the object heap directly while performing the I/O operation

wherein the platform-independent virtual machine operates in accordance with a hybrid thread model in which language threads that are not performing I/O operations execute as co-routines on a single OS-thread; and

wherein language threads performing I/O operations are associated with dedicated OS-threads that perform the I/O operations.

8. The computer-readable storage medium of claim 7 , wherein after the OS-thread finishes the I/O operation, the method further comprises:

unmarshalling parameters from the parameter space, wherein the unmarshalling is performed by the language thread; and

returning from the I/O operation.

9. The computer-readable storage medium of claim 8 ,

wherein marshalling the parameters involves marshalling the parameters from the object heap; and

wherein unmarshalling the parameters involves unmarshalling the parameters into the object heap.

10. The computer-readable storage medium of claim 7 , wherein the parameter space is associated with the OS-thread and is allocated from a global pool of memory located outside of the object heap.

11. The computer-readable storage medium of claim 7 , wherein the parameter space is associated with the OS-thread and is allocated in an unused end of the object heap.

12. The computer-readable storage medium of claim 7 , wherein the parameter space is allocated in stack space associated with the OS-thread.

13. An apparatus that performs independent asynchronous I/O operations within a platform-independent virtual machine, comprising:

an execution mechanism within the platform-independent virtual machine that is configured to execute a language thread;

wherein upon encountering an I/O operation, the execution mechanism is configured to,

use the language thread to marshal parameters for the I/O operation into a parameter space located outside of an object heap for the platform-independent virtual machine, and to

cause an operating system thread (OS-thread) associated with the language thread to perform the I/O operation, wherein the OS-thread accesses the parameters from the parameter space;

whereby the OS-thread does not access the object heap directly while performing the I/O operation

wherein the platform-independent virtual machine operates in accordance with a hybrid thread model in which language threads that are not performing I/O operations execute as co-routines on a single OS-thread; and

wherein language threads performing I/O operations are associated with dedicated OS-threads that perform the I/O operations.

14. The apparatus of claim 13 , wherein after the OS-thread finishes the I/O operation, the execution mechanism is configured to:

unmarshal parameters from the parameter space, wherein the unmarshalling is performed by the language thread; and to

return from the I/O operation.

15. The apparatus of claim 14 ,

wherein the execution mechanism is configured to marshal the parameters from the object heap; and

wherein the execution mechanism is configured to unmarshal the parameters into the object heap.

16. The apparatus of claim 13 , wherein the parameter space is associated with the OS-thread and is allocated from a global pool of memory located outside of the object heap.

17. The apparatus of claim 13 , wherein the parameter space is associated with the OS-thread and is allocated in an unused end of the object heap.

18. The apparatus of claim 13 , wherein the parameter space is allocated in stack space associated with the OS-thread.

19. A means for performing independent asynchronous I/O operations within a platform-independent virtual machine, comprising:

an execution means for executing a language thread within the platform-independent virtual machine;

a receiving means for receiving an I/O operation during execution of the language thread;

a marshalling means for marshalling parameters for the I/O operation using the language thread into a parameter space located outside of an object heap for the platform-independent virtual machine; and

a calling means that calls an operating system thread (OS-thread) associated with the language thread to perform the I/O operation, wherein the OS-thread accesses the parameters from the parameter space

wherein the platform-independent virtual machine operates in accordance with a hybrid thread model in which language threads that are not performing I/O operations execute as co-routines on a single OS-thread; and

wherein language threads performing I/O operations are associated with dedicated OS-threads that perform the I/O operations.

Assignments (2)
MERGER AND CHANGE OF NAME Recorded Dec 12, 2015
From: ORACLE USA, INC.; SUN MICROSYSTEMS, INC.; ORACLE AMERICA, INC.
To: ORACLE AMERICA, INC.
Reel/Frame 037278/0877 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 9, 2002
From: MATHISKE, BERND J.W.; WOLD, SAUL G.; LAM, LOI K.
To: SUN MICROSYSTEMS, INC.
Reel/Frame 013378/0445 →