US2017315830A1PendingUtilityA1

On-demand loading of dynamic scripting language code for reduced memory usage

Assignee: FUTUREWEI TECHNOLOGIES INCPriority: Feb 23, 2015Filed: Jul 18, 2017Published: Nov 2, 2017
Est. expiryFeb 23, 2035(~8.6 yrs left)· nominal 20-yr term from priority
G06F 8/4434G06F 9/44505G06F 9/44521G06F 9/45529G06F 9/45512G06F 9/44594G06F 8/427G06F 8/51G06F 8/41
57
PatentIndex Score
0
Cited by
0
References
0
Claims

Abstract

A computer-implemented method and system for reducing the amount of memory space required to store applications written in dynamic scripting languages loads a program module into memory and removes a category of program code, such as debug information or function definitions, from the program module. The method and system also receives a request for debug information, or a function call or query, and determines whether or not the corresponding program code is in memory. If not, then the location in storage is identified where the program module is stored, and another copy containing the corresponding program code is loaded into memory. The corresponding program code is located and copied into the program module in memory, and a response is provided to the request.

Claims

exact text as granted — not AI-modified
What is claimed is: 
     
         1 . A method implemented by one or more processors, wherein the one or more processors execute instructions stored on a memory to perform the method steps comprising:
 receiving a request for a redacted code section of compiled code;   determining that the requested redacted code section is not in a memory and based thereon:
 identifying a location in a storage where the requested redacted code section is stored from a respective placeholder of the requested redacted code section; 
 obtaining the requested redacted code section from the identified storage location; and 
 modifying the compiled code to include the obtained redacted code section. 
   
     
     
         2 . The method of  claim 1  wherein the obtained redacted code section is a function definition or debugging information. 
     
     
         3 . The method of  claim 2  wherein the obtained redacted code section is a function definition and wherein modifying the compiled code to include the obtained redacted code section comprises forming a complete function in the compiled code using the obtained redacted code section. 
     
     
         4 . The method of  claim 1 , wherein modifying the compiled code to include the obtained redacted code section comprises:
 compiling the obtained redacted code section; and   inserting the compiled redacted code section into the compiled code in place of the placeholder.   
     
     
         5 . The method of  claim 1  wherein identifying the location in the storage wherein the requested redacted code section is stored from the respective placeholder of the requested redacted code section comprises:
 obtaining a location of a file and an offset within the file where the requested redacted code section in stored. 
 
     
     
         6 . The method of  claim 1  wherein the request is a function call or a query of a function definition. 
     
     
         7 . The method of  claim 1 , further comprising executing the modified compiled code. 
     
     
         8 . The method of  claim 7  wherein the execution is within a virtual machine. 
     
     
         9 . The method of  claim 1 , further comprising, prior to receiving the request:
 redacting the code section from dynamic scripting language program source code.   
     
     
         10 . The method of  claim 1 , further comprising, prior to receiving the request:
 inserting the respective placeholder in program source code for the redacted code section to generate redacted program code.   
     
     
         11 . The method of  claim 1 , further comprising, prior to receiving the request:
 compiling redacted program code to generate the compiled code.   
     
     
         12 . A system comprising:
 a memory storage comprising instructions; and   one or more processors in communication with the memory, wherein the one or more processors execute the instructions to:
 receiving a request for a redacted code section of compiled code; 
 determine that the requested redacted code section is not in a memory and based thereon:
 identify a location in a storage where the requested redacted code section is stored from a respective placeholder of the requested redacted code section; 
 obtain the requested redacted code section from the identified storage location; and 
 modify the compiled code to include the obtained redacted code section. 
 
   
     
     
         13 . The system of  claim 12  wherein the obtained redacted code section is a function definition or debugging information. 
     
     
         14 . The system of  claim 12  wherein the obtained redacted code section is a function definition and wherein the one or more processors execute the instructions to perform:
 form a complete function in the compiled code using the obtained redacted code section. 
 
     
     
         15 . The system of  claim 12 , wherein the one or more processors execute the instructions to perform:
 compile the obtained redacted code section; and   insert the compiled redacted code section into the compiled code in place of the placeholder.   
     
     
         16 . The system of  claim 12 , wherein the one or more processors execute the instructions to perform:
 obtain a location of a file and an offset within the file where the requested redacted code section in stored.   
     
     
         17 . The system of  claim 12 , wherein the request is a function call or a query of a function definition. 
     
     
         18 . The system of  claim 12 , wherein the one or more processors execute the instructions to perform execute the modified compiled code. 
     
     
         19 . The system of  claim 18  wherein the execution is within a virtual machine. 
     
     
         20 . A non-transitory computer-readable medium storing instructions that, when executed by one or more processors, cause the one or more processors execute the instructions to:
 receive a request for a redacted code section of compiled code;   determine that the requested redacted code section is not in a memory and based thereon:
 identify a location in a storage where the requested redacted code section is stored from a respective placeholder of the requested redacted code section; 
 obtain the requested redacted code section from the identified storage location; and 
 modify the compiled code to include the obtained redacted code section.

Join the waitlist — get patent alerts

Track US2017315830A1 — get alerts on status changes and closely related new filings.

We store only your email — no account needed. See our privacy policy.