Special calling sequence for caller-sensitive methods

US2016357586A1 · US · A1

Patent metadata
FieldValue
Publication numberUS-2016357586-A1
Application numberUS-201615090347-A
CountryUS
Kind codeA1
Filing dateApr 4, 2016
Priority dateJun 8, 2015
Publication dateDec 8, 2016
Grant date

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

In one approach, a method comprises: a virtual machine receiving an invocation instruction from a caller that invokes a callee, wherein the caller represents a first set of instructions and the callee represents a second set of instructions, wherein the invocation instruction is associated with a first set of arguments; in response to receiving the invocation instruction and determining that the callee requires one or more additional parameters to be supplied by the virtual machine, the virtual machine causing the one or more additional parameters to be appended to the first set of arguments to create a second set of arguments; wherein the virtual machine prevents the caller from providing the one or more additional arguments that are to be supplied by the virtual machine; the virtual machine invoking the callee using the second set of arguments.

First claim

Opening claim text (preview).

What is claimed is: 1 . A method comprising: a virtual machine receiving an invocation instruction from a caller that invokes a callee, wherein the caller represents a first set of instructions and the callee represents a second set of instructions, wherein the invocation instruction is associated with a first set of arguments; in response to receiving the invocation instruction and determining that the callee requires one or more additional arguments that are to be supplied by the virtual machine and are specified by metadata associated with the callee, the virtual machine causing the one or more additional arguments specified by the metadata to be added to the first set of arguments to create a second set of arguments; wherein the virtual machine prevents the caller from providing the one or more additional arguments that are to be supplied by the virtual machine; the virtual machine invoking the callee using the second set of arguments; wherein the method is performed by one or more computing devices. 2 . The method of claim 1 , wherein the virtual machine causes the one or more additional arguments to be appended to the first set of arguments to create the second set of arguments by pushing the one or more additional arguments onto an operand stack for the caller that contains the first one or more arguments. 3 . The method of claim 1 , wherein the callee is a caller-sensitive method and the one or more additional arguments includes at least one parameter containing information related to the caller. 4 . The method of claim 1 , wherein the invocation instruction references an entry of a run-time constant pool and further comprising: the virtual machine determining whether the entry of the run-time constant pool is a resolved entry that contains a concrete memory location of the callee and one or more cached arguments or an unresolved entry that contains a symbolic link to the callee; in response to determining that the entry of the run-time constant pool is an unresolved entry, the virtual machine identifying a memory location of the callee based on the symbolic link and updating the entry with the memory location and contents of the one or more additional arguments, wherein the second set of instructions is located at the memory location, wherein the virtual machine invokes the callee by executing the second set of instructions located at the memory location; in response to determining that the entry of the run-time constant pool is a resolved entry, the virtual machine causing the one or more additional arguments to be added to the first set of arguments to create the second set of arguments by adding the one or more cached arguments to the first set of arguments, and the virtual machine invoking the callee by executing the second set of instructions located at the concrete memory location. 5 . The method of claim 1 , wherein the callee is defined using a public signature and a corresponding non-public signature, the invocation instruction references a descriptor, and further comprising: in response to the virtual machine receiving the invocation instruction, the virtual machine determining a memory location for the second set of instructions by searching for the public signature that matches the descriptor, locating the corresponding non-public signature based on the public signature, and identifying the memory location based on the non-public signature, wherein the virtual machine invokes the callee based on the memory location. 6 . The method of claim 1 , wherein the invocation instruction from the caller references a descriptor identifying the first set of arguments and the callee is defined using a signature that identifies the second set of arguments that includes both the first set of arguments and the one or more additional arguments. 7 . The method of claim 1 , wherein the metadata comprises a private signature of the callee that identifies the second set of arguments and a public signature of the callee that identifies the first set of arguments. 8 . The method of claim 1 , wherein the metadata comprises one or more annotations associated with the callee that identify the one or more additional arguments. 9 . A method comprising: receiving an invocation instruction from a caller that invokes a callee, wherein the caller represents a first set of instructions and the callee represents a second set of instructions, wherein the invocation instruction is associated with a first set of arguments; in response to receiving the invocation instruction and determining that the callee is code whose behavior changes based on information related to the caller, causing the information related to the caller to be added as one or more additional arguments to the first set of arguments to create a second set of arguments by invoking a bootstrap function associated with the callee that links the caller to the callee and injects the one or more additional arguments; invoking the callee using the second set of arguments; wherein the method is performed by one or more computing devices. 10 . The method of claim 9 , further comprising: determining one or more types of caller information to add as the one or more additional arguments based on metadata associated with the callee. 11 . The method of claim 9 , wherein determining that the callee is code whose behavior changes based on the information related to the caller is performed by inspecting metadata associated with the callee which represents a reference to the bootstrap function. 12 . The method of claim 9 , wherein the information related to the caller is one or more of: a name of the caller, a class containing the caller, a namespace of the caller, a class loader of the caller, a module of the caller, or one or more permissions of the caller. 13 . The method of claim 9 , wherein causing the information related to the caller to be appended as one or more additional arguments to the first set of arguments to create the second set of arguments is performed by pushing the one or more additional arguments onto an operand stack for the caller. 14 . The method of claim 9 , wherein the invocation instruction references an entry of a run-time constant pool and further comprising: determining whether the entry of the run-time constant pool is a resolved entry that contains a concrete memory location of the callee and one or more cached parameters or an unresolved entry that contains a symbolic link to the callee; in response to determining that the entry of the run-time constant pool is an unresolved entry, identifying a memory location of the callee based on the symbolic link and updating the entry with the memory location and contents of the one or more additional arguments, wherein the second set of instructions is located at the memory location, wherein invoking the callee is performed by executing the second set of instructions located at the memory location; in response to determining that the entry of the run-time constant pool is a resolved entry, causing the one or more additional arguments to be appended to the first set of arguments to create the second set of arguments by appending the one or more cached parameters to the first set of arguments and invoking the callee by executing the second set of instructions located at the concrete memory location. 15 . The method of claim 9 , wherein the invocation instruction from the caller uses a descriptor identifying the first set of arguments and the callee is defined using a signature that identifies the second set of arguments that includes both the first set of arguments and the one

Assignees

Inventors

Classifications

  • G06F8/41Primary

    Compilation · CPC title

  • Abstract machines for programme code execution, e.g. Java virtual machine [JVM], interpreters, emulators · CPC title

  • Program loading or initiating (bootstrapping G06F9/4401; security arrangements for program loading or initiating G06F21/57) · CPC title

  • Memory management, e.g. access or allocation · CPC title

  • Involving translation to a different instruction set architecture, e.g. just-in-time translation in a JVM · CPC title

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US2016357586A1 cover?
In one approach, a method comprises: a virtual machine receiving an invocation instruction from a caller that invokes a callee, wherein the caller represents a first set of instructions and the callee represents a second set of instructions, wherein the invocation instruction is associated with a first set of arguments; in response to receiving the invocation instruction and determining that th…
Who is the assignee on this patent?
Oracle Int Corp
What technology area does this patent fall under?
Primary CPC classification G06F8/41. Mapped technology areas include Physics.
When was this patent published?
Publication date Thu Dec 08 2016 00:00:00 GMT+0000 (Coordinated Universal Time) (A1). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 8 related publications on this page (citations in our corpus or others sharing the same primary CPC).