IP Library Granted Patent US 12,657,012
Granted Patent B2
US 12,657,012 · App. 18/542,563 · Granted Jun 16, 2026

Method and system for managing intermediate representation from program

Inventors: Jaejin Lee (Seoul, KR); Jungho Park (Seoul, KR); Gangwon Jo (Seoul, KR); Heehoon Kim (Daejeon, KR); Jinpyo Kim (Seoul, KR)
Assignees: MOREH CORP.; Seoul National University R&DB Foundation
G06F8/41
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 12,657,012
App. No.
18/542,563
Granted
Jun 16, 2026
Kind
B2
Abstract

A method for managing an intermediate representation from a program is executed by one or more processors, and includes extracting, from the program, information on data for input and output and information on operation, generating an intermediate representation from the program using the extracted information on data and the extracted information on operation, storing, in a database, a corresponding relationship between the program and the intermediate representation, storing execution information on operation of the intermediate representation, and deleting at least a part of the intermediate representation based on the execution information.

Claims (118)

1 . A method executed by one or more processors, the method comprising:

determining, information associated with a deep learning program executable by one or more computing devices, wherein the information associated with the deep learning program comprises:

information associated with one or more data elements of the deep learning program, wherein at least one data element of the one or more data elements provides tensor information, and

wherein at least one second data element of the one or more data elements indicates data of the deep learning program; and

information associated with one or more operations of the deep learning program;

generating, based on the information associated with the deep learning program, an intermediate representation of at least a portion of the deep learning program by:

generating a plurality of data nodes corresponding to the data elements of the deep learning program, wherein the plurality of data nodes comprises at least one input data node and at least one output data node;

generating an operation node corresponding to the one or more operations of the deep learning program;

generating a first edge that links an input data node corresponding to input data associated with at least one of the one or more operations to the operation node; and

generating a second edge that links the operation node to an output data node corresponding to output data associated with the at least one of the one or more operations;

storing, in a database, a corresponding relationship between the at least a portion of the deep learning program and the intermediate representation by storing, in the database, a relationship between the data elements and the plurality of data nodes;

executing an optimized form of the deep learning program by executing, based on the intermediate representation, the deep learning program;

storing information indicating an execution status of one or more operations of the deep learning program by:

storing information indicating whether an execution has been performed for at least one of the one or more operations of the intermediate representation;

selecting a first operation to be executed by selecting, from among operations of the intermediate representation, at least a part of unexecuted operation;

executing the first operation; and

updating information indicating that the first operation has been executed; and

deleting, from memory and based on the execution status, at least a part of the intermediate representation.

2 . The method according to claim 1 , further comprising:

adding, based on determining that a new tensor was generated by the deep learning program, a new data node to the intermediate representation.

3 . The method according to claim 1 , further comprising:

updating, based on determining that an existing tensor was generated by the deep learning program, an existing data node of the plurality of data nodes.

4 . The method according to claim 1 , further comprising:

extracting input tensor information from the deep learning program; and

adding, based on the input tensor information, a new operation node to the intermediate representation.

5 . The method according to claim 1 , wherein the deleting the at least the part of the intermediate representation comprises:

selecting a first data node, from among the plurality of data nodes and the operation node, as a node not to be used in a future execution, wherein the selecting the first data node is based on:

the information indicating the execution status

a determination that data corresponding to the first data node is not stored in the database,

one or both of:

a determination that no operation node associated with the first data node exists, or

a condition that operations of all operation nodes associated with the first data node have been executed; and

a determination that the operation node is an executed node;

deleting, from the memory, the first data node; and

deleting, from the memory, an edge associated with the first data node.

6 . The method according to claim 1 , wherein the operation node corresponds to an operation performed on at least two tensors.

7 . An information processing system comprising:

Memory; and

One or more processors coupled to the memory and configured to execute one or more computer-readable programs stored in memory,

determine, information associated with a deep learning program executable by one or more computing devices, wherein the information associated with the deep learning program comprises:

information associated with one or more data elements of the deep learning program, wherein at least one data element of the one or more data elements provides tensor information, and

wherein at least one second data element of the one or more data elements indicates data of the deep learning program; and

information associated with one or more operations of the deep learning program;

generate, based on the information associated with the deep learning program, an intermediate representation of at least a portion of the deep learning program by:

generating a plurality of data nodes corresponding to the data elements of the deep learning program, wherein the plurality of data nodes comprises at least one input data node and at least one output data node;

generating an operation node corresponding to the one or more operations of the deep learning program;

generating a first edge that links an input data node corresponding to input data associated with at least one of the one or more operations to the operation node; and

generating a second edge that links the operation node to an output data node corresponding to output data associated with the at least one of the one or more operations;

store, in a database, a corresponding relationship between the at least a portion of the deep learning program and the intermediate representation by storing, in the database, a relationship between the data elements and the plurality of data nodes;

execute an optimized form of the deep learning program by executing, based on the intermediate representation, the deep learning program;

storing information indicating an execution status of one or more operations of the deep learning program by:

storing information indicating whether an execution has been performed for at least one of the one or more operations of the intermediate representation;

selecting a first operation to be executed by selecting, from among operations of the intermediate representation, at least a part of unexecuted operation;

executing the first operation; and

updating information indicating that the first operation has been executed; and

delete, from memory and based on the execution status, at least a part of the intermediate representation.

8 . The information processing system according to claim 7 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

add, based on determining that a new tensor was generated by the deep learning program, a new data node to the intermediate representation.

9 . The information processing system according to claim 7 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

update, based on determining that an existing tensor was generated by the deep learning program, an existing data node of the plurality of data nodes.

10 . The information processing system according to claim 7 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

extract input tensor information from the deep learning program; and

add, based on the input tensor information, a new operation node to the intermediate representation.

11 . The information processing system according to claim 7 , wherein the instructions, when executed by the one or more processors, cause the information processing system to delete the at least the part of the intermediate representation by causing the information processing system to:

select a first data node, from among the plurality of data nodes and the operation node, as a node not to be used in a future execution, wherein the selecting the first data node is based on:

the information indicating the execution status

a determination that data corresponding to the first data node is not stored in the database,

one or both of:

a determination that no operation node associated with the first data node exists, or

a condition that operations of all operation nodes associated with the first data node have been executed; and

a determination that the operation node is an executed node;

delete, from the memory, the first data node; and

delete, from the memory, an edge associated with the first data node.

12 . The information processing system according to claim 7 , wherein the operation node corresponds to an operation performed on at least two tensors.

13 . One or more non-transitory computer-readable media storing instruction that when execute by one or more processors of an information processing system cause the information processing system to:

determine, information associated with a deep learning program executable by one or more computing devices, wherein the information associated with the deep learning program comprises:

information associated with one or more data elements of the deep learning program, wherein at least one data element of the one or more data elements provides tensor information, and

wherein at least one second data element of the one or more data elements indicates data of the deep learning program; and

information associated with one or more operations of the deep learning program;

generating, based on the information associated with the deep learning program, an intermediate representation of at least a portion of the deep learning program by:

generating a plurality of data nodes corresponding to the data elements of the deep learning program, wherein the plurality of data nodes comprises at least one input data node and at least one output data node;

generating an operation node corresponding to the one or more operations of the deep learning program;

generating a first edge that links an input data node corresponding to input data associated with at least one of the one or more operations to the operation node; and

generating a second edge that links the operation node to an output data node corresponding to output data associated with the at least one of the one or more operations;

storing, in a database, a corresponding relationship between the at least a portion of the deep learning program and the intermediate representation by storing, in the database, a relationship between the data elements and the plurality of data nodes;

execute an optimized form of the deep learning program by executing, based on the intermediate representation, the deep learning program;

store information indicating an execution status of one or more operations of the deep learning program by:

storing information indicating whether an execution has been performed for at least one of the one or more operations of the intermediate representation;

selecting a first operation to be executed by selecting, from among operations of the intermediate representation, at least a part of unexecuted operation;

executing the first operation; and

updating information indicating that the first operation has been executed; and

delete, from memory and based on the execution status, at least a part of the intermediate representation by:

selecting a first data node from among the plurality of data nodes and the operation node, as a node not to be used in a future execution, wherein the selecting the first data node is based on:

the information indicating the execution status,

a determination that data corresponding to the data node is not stored in the database,

one or both of:

a determination that no operation node associated with first data node exists, or

a condition that operations of all operation nodes associated with the first data node have been executed; and

a determination that the operation node is an executed node;

deleting from the memory, the first data node; and

deleting form the memory, an edge associated with the first data node.

14 . The one or more non-transitory computer-readable media according to claim 13 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

add, based on determining that a new tensor was generated by the deep learning program, a new data node to the intermediate representation.

15 . The one or more non-transitory computer-readable media according to claim 13 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

update, based on determining that an existing tensor was generated by the deep learning program, an existing data node of the plurality of data nodes.

16 . The one or more non-transitory computer-readable media according to claim 13 , wherein the instructions, when executed by the one or more processors, further cause the information processing system to:

extract input tensor information from the deep learning program; and

add, based on the input tensor information, a new operation node to the intermediate representation.

17 . The one or more non-transitory computer-readable media according to claim 13 , wherein the instructions, when executed by the one or more processors, cause the information processing system to delete the at least the part of the intermediate representation by causing the information processing system to:

select a first data node, from among the plurality of data nodes and the operation node, as a node not to be used in a future execution, wherein the selecting the first data node is based on:

the information indicating the execution status

a determination that data corresponding to the first data node is not stored in the database,

one or both of:

a determination that no operation node associated with the first data node exists, or

a condition that operations of all operation nodes associated with the first data node have been executed; and

a determination that the operation node is an executed node;

delete, from the memory, the first data node; and

delete, from the memory, an edge associated with the first data node.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 15, 2023
From: LEE, JAEJIN; PARK, JUNGHO; JO, GANGWON; KIM, HEEHOON; KIM, JINPYO
To: MOREH CORP.; SEOUL NATIONAL UNIVERSITY R&DB FOUNDATION
Reel/Frame 065890/0132 →
Priority Claims (2)
KR 10-2021-0077965 · Jun 16, 2021 · national
KR 10-2022-0072639 · Jun 15, 2022 · national
Continuity (2)
Continuation PCTKR2022008507 · Jun 15, 2022
Related Publication 20240118876A1 · Apr 11, 2024
References Cited (26)
US 10540757B1 · Bouhnik · 2020 [cited by examiner]
US 10776626B1 · Lin · 2020 [cited by examiner]
US 10901715B1 · Raiman · 2021 [cited by examiner]
US 11461662B1 · Zheng · 2022 [cited by examiner]
US 11467811B1 · Durakovic · 2022 [cited by examiner]
US 11704562B1 · Khaitan · 2023 [cited by examiner]
US 11704564B2 · Faivishevsky · 2023 [cited by examiner]
US 11790223B2 · Wang · 2023 [cited by examiner]
US 12118460B2 · Zaidy · 2024 [cited by examiner]
US 12468929B2 · Bogdan · 2025 [cited by examiner]
US 20040221277A1 · Owen et al. · 2004 [cited by applicant]
US 20170124452A1 · Tucker et al. · 2017 [cited by applicant]
US 20210295822A1 · Tomkins · 2021 [cited by examiner]
US 20220206765A1 · Geng et al. · 2022 [cited by applicant]
KR 1020060004953A · 2006 [cited by applicant]
WO 2021052391A1 · 2021 [cited by applicant]
Duboscq et al, “An Intermediate Representation for Speculative Optimizations in a Dynamic Compiler”, ACM, pp. 1-10 (Year: 2013). [cited by examiner]
Kunft et al, “An Intermediate Representation for Optimizing Machine Learning Pipelines”, ACM, pp. 1-15 (Year: 2019). [cited by examiner]
Radu et al, “Towards Multimodal Deep Learning for Activity Recognition on Mobile Devices”, ACM, pp. 1-5 (Year: 2016). [cited by examiner]
Wang et al, “Vulnerability Feature Extraction Model for Source Code Based on Deep Learning”, IEEE, pp. 1-5 (Year: 2021). [cited by examiner]
Kamath et al, “Comparative Study between Traditional Machine Learning and Deep Learning Approaches for Text Classification”, ACM, pp. 1-12 (Year: 2018). [cited by examiner]
Li et al. “The Deep Learning Compiler: A Comprehensive Survey” vol. 1, No. 1, Article . Publication date: Aug. 2020., pp. 1-34. [cited by applicant]
Geifman “Compilers for Deep Learning: Definition, Pros& Cons, and Popular Examples” Retrieved from the Internet: <URL: <https://deci.ai/blog/graph-compilers>>, printed Dec. 5, 2023, p. 1-28, Apr. 28, 2021. [cited by applicant]
Reissmann, Nico, et al., RVSDG: An Intermediate Representation for Optimizing Compilers, Norwegian University of Science and Technology, Mar. 17, 2020, 25 pages. [cited by applicant]
Darte, Alain, et al., Liveness Analysis in Explicitly-Parallel Programs, Proceedings of the 6th International Workshop on Polyhedral Compilation Techniques, Jan. 18, 2016, 10 pages. [cited by applicant]
Oct. 30, 2025 (KR) Office Action, App No. 10-2022-0133270, 6 pages. [cited by applicant]