Invention Grant
- Patent Title: Matching graphs generated from source code
-
Application No.: US17009306Application Date: 2020-09-01
-
Publication No.: US11455152B2Publication Date: 2022-09-27
- Inventor: Qianyu Zhang
- Applicant: X Development LLC
- Applicant Address: US CA Mountain View
- Assignee: X Development LLC
- Current Assignee: X Development LLC
- Current Assignee Address: US CA Mountain View
- Agency: Middleton Reutlinger
- Main IPC: G06F8/41
- IPC: G06F8/41 ; G06N3/02 ; G06N20/00

Abstract:
Techniques are described herein for training a machine learning model and using the trained machine learning model to more accurately determine alignments between matching/corresponding nodes of predecessor and successor graphs representing predecessor and successor source code snippets. A method includes: obtaining a first abstract syntax tree that represents a predecessor source code snippet and a second abstract syntax tree that represents a successor source code snippet; determining a mapping across the first and second abstract syntax trees; obtaining a first control-flow graph that represents the predecessor source code snippet and a second control-flow graph that represents the successor source code snippet; aligning blocks in the first control-flow graph with blocks in the second control-flow graph; and applying the aligned blocks as inputs across a trained machine learning model to generate an alignment of nodes in the first abstract syntax tree with nodes in the second abstract syntax tree.
Public/Granted literature
- US20220066752A1 MATCHING GRAPHS GENERATED FROM SOURCE CODE Public/Granted day:2022-03-03
Information query