Patents
Literature
Patsnap Eureka AI that helps you search prior art, draft patents, and assess FTO risks, powered by patent and scientific literature data.

239 results about "Control flow graph" patented technology

In computer science, a control-flow graph (CFG) is a representation, using graph notation, of all paths that might be traversed through a program during its execution. The control-flow graph is due to Frances E. Allen, who notes that Reese T. Prosser used boolean connectivity matrices for flow analysis before.

Variation test method and device based on intelligent automation script

The invention discloses a variation test method and device based on an intelligent automation script. The method comprises the following steps: extracting a statement execution sequence and a branch dependency relationship in an original source code by using a context-aware syntax tree, and generating a control flow diagram and a data flow diagram; performing code semantic analysis on the multi-dimensional code features by using a large language model, identifying potential defect types and variation rules, predicting the test efficiency of variants in combination with a deep Q learning model, and generating to-be-processed variants; performing grammar check and equivalence analysis on the to-be-processed variants to obtain effective variants, and testing the effective variants; variation test indexes are calculated, code weak points are positioned, and test blind areas are identified according to survival variants, so that a visual analysis report is generated; and iteratively generating a new test case according to the current survival variant and the visual analysis report, and testing the current survival variant by using the new test case. According to the invention, the variation test efficiency can be improved.
Owner:BEIJING YULORE INNOVATION TECH

Cross-chain smart contract vulnerability detection method and system based on multi-feature fusion learning

The invention discloses a cross-chain smart contract vulnerability detection method and system based on multi-feature fusion learning. The method comprises the following steps: collecting a cross-chain smart contract vulnerability data set for cleaning and labeling; feature extraction is carried out from the source code and the byte code, an abstract syntax tree (AST) is extracted from the cleaned source code, a basic control flow graph (CFG) is extracted from the byte code, and a cross-chain control flow graph (xCFG) is constructed; carrying out feature representation on AST and xCFG, generating a graph vector through a graph neural network (GNN), generating a semantic vector through CodeBert, and fusing the semantic vector into a feature fusion vector; performing model training and detection, taking the generated vectors as training data and test data, obtaining a cross-chain smart contract vulnerability detection model by adopting Transform-FC model training data, and finally evaluating model performance through accuracy, recall rate, precision rate and F1 value. According to the method, the structural features and semantic features of the codes can be effectively fused, potential vulnerability information in the codes can be fully mined, the recognition capability of the model for cross-chain vulnerabilities can be enhanced, and the accuracy and reliability of the cross-chain vulnerability detection model can be improved, so that the security of a block chain system can be more efficiently guaranteed.
Owner:HOHAI UNIV

Source code bug repairing method, electronic equipment and storage medium

The invention relates to the technical field of vulnerability repair, in particular to a source code vulnerability repair method, electronic equipment and a storage medium, and the method comprises the following steps: obtaining an abstract syntax tree and a control flow graph according to a source code containing a vulnerability, and generating a vulnerability context feature vector by using a graph neural network model in combination with vulnerability position information, determining a historical vulnerability repair case corresponding to the vulnerability context feature vector from a vulnerability-repair knowledge base, inputting the vulnerability context feature vector and the corresponding historical vulnerability repair case into a code generation model, outputting a candidate repair code set corresponding to the source code, evaluating each candidate repair code, and determining the vulnerability-repair knowledge base according to the candidate repair code set. Screening out an optimal repair code to automatically repair the source code vulnerability; according to the method, deep semantic analysis is performed on the vulnerability context, and intelligent reasoning is performed, so that the repair code with correct grammar and adaptive context can be generated, and the automation level and accuracy of vulnerability repair are remarkably improved.
Owner:QINGDAO WANDAO (BEIJING) INFORMATION TECH CO LTD

Multi-language code generation method based on self-supervised pre-training

The invention discloses a multi-language code generation method based on self-supervised pre-training, which comprises the following steps: acquiring and cleaning multi-language code data to form a training corpus; the method comprises the following steps: representing code data as an abstract syntax tree, extracting a control flow diagram and a data flow diagram of the code data, and obtaining unified semantic representation through combination of a diagram encoder and a sequence encoder; designing a self-supervised pre-training task, and pre-training the semantic representation based on the training corpus; constructing a multi-language pre-training model based on the structure-improved recurrent neural tensor network and the multi-language embedding matrix; when a user inputs a natural language, generating a target language code by using the multi-language pre-training model; and target language code correction is carried out through conventional function testing and grammar checking. According to the method, multi-channel recursive combination and a hierarchical recursive expansion mechanism are combined with self-supervised pre-training, so that accurate generation and performability improvement of cross-language codes are realized.
Owner:CLOUD HI-TECH (BEIJING) TECHNOLOGY CO LTD

Cross-modal adaptation fine tuning method and system based on double-branch network architecture

The invention discloses a cross-modal adaptive fine tuning method and system based on a double-branch network architecture, and realizes cross-modal knowledge fusion and migration by combining the modeling capability of a graph neural network on code graph structures such as an abstract syntax tree, a control flow graph and the like and the powerful semantic understanding and generation capability of a large language model. A double-branch architecture is adopted, a graph structure and text input are coded respectively, and feature interaction is achieved through heterogeneous adaptation, structural decoupling and a mask attention mechanism. In a fine tuning stage, three-stage strategies are provided: basic fine tuning of structure perception, efficient parameter migration by combining Adapter, Prefix Tuning and LoRA, and language generation quality and robustness are optimized based on an unsupervised text reconstruction task. The training stage relates to structure sensing tasks such as node prediction, edge reconstruction and subgraph comparison, and the stability and generalization ability are improved in combination with course learning. The method is widely applicable to tasks such as code completion, question and answer and vulnerability detection, and has the advantages of strong structure perception, efficient cross-modal fusion, low training cost and the like.
Owner:PEKING UNIV +1

Flow chart image analysis and structured reconstruction method and device, and storage medium

The invention discloses a flow chart image analysis and structured reconstruction method and device and a storage medium, and relates to the technical field of image processing, and the method comprises the steps: carrying out the element background separation of an input image through a pre-trained convolutional neural network, and obtaining a flow chart image, the elements including text elements and graphic elements; extracting rectangular frame information, arrow information, text information and position coordinates thereof in the preprocessed flow chart image; determining the node type of each node in the flow chart image based on the rectangular frame information and the text information, and determining the connection relationship of each node based on the arrow information in combination with the position coordinates; analyzing the node type and the connection relationship of each node, modeling the logic relationship of each node, and generating a control flow diagram of the flow diagram image; and converting the control flow diagram into structured data, and rendering to generate an interactively editable flow diagram visual interface. According to the method and the device, the technical effect of reconstructing the structured flow chart by identifying the control logic structure of the flow chart is realized.
Owner:JIANTU CHUANGZHI (SHENZHEN) TECH CO LTD

Intelligent contract vulnerability detection method and system based on multi-modal large language model

The invention relates to the technical field of block chains, in particular to a smart contract vulnerability detection method and system based on a multi-modal large language model.The detection method comprises the steps that S1, the system receives source code input of a smart contract; s2, executing semantic branches and graph structure branches in parallel; executing semantic branch processing, calling an annotation agent, and generating an annotation from the source code of the smart contract; calling a vectorization agent, coding the annotation and the source code, and converting the annotation and the source code into a high-dimensional vector; executing graph structure branch processing, compiling a source code into a byte code by the system, and generating a control flow graph; the vectorization agent generates high-dimensional embedded representation of the nodes based on the control flow graph; and S3, integrating features extracted from the semantic branches and the graph structure branches through a multi-modal feature fusion strategy, and inputting the integrated features into a classifier to detect vulnerabilities. The method is based on a multi-modal large language model agent, and potential vulnerabilities in the smart contract are comprehensively analyzed by integrating high-level semantic information and low-level structured data.
Owner:BEIHANG UNIV

Code embedding method based on semantic embedding vector generation model and related device

The invention discloses a code embedding method based on a semantic embedding vector generation model, which belongs to the technical field of computers, and comprises the following steps of: obtaining a binary code block, and performing disassembling processing and code structure analysis based on different granularities to obtain a basic block corresponding to the binary code block and a control flow diagram structure feature; performing assembly instruction linear conversion and cross-instruction-set semantic embedding conversion on the basis of the basic blocks corresponding to the binary code blocks and the structural features of the control flow graph to generate a unified binary code semantic embedding vector space corresponding to a cross-instruction-set architecture; obtaining a known vulnerability sample, and performing semantic vulnerability characterization analysis and candidate vulnerability retrieval positioning to generate a candidate vulnerability code block set; and carrying out dynamic analysis verification on the candidate vulnerability code block set and identifying a corresponding vulnerability repair state so as to output a corresponding binary vulnerability code block detection report. According to the method, high-precision semantic embedding of binary codes can be realized.
Owner:HUANENG POWER INT INC +1

Memory allocation method and device, electronic equipment, storage medium and chip

The invention provides a memory allocation method and device, electronic equipment, a storage medium and a chip. The method comprises the following steps: extracting tensor data of each tensor in a kernel program; constructing a control flow diagram according to the kernel program; allocating first address information in a static random access memory for each piece of tensor data; determining an active path of each tensor according to the control flow graph, the active path comprising a first node involving the tensor; an interferogram of the tensors is constructed according to the active path, each second node in the interferogram represents a different tensor, and edges between the second nodes represent an interference relation between the tensors; the first address information of each piece of tensor data is adjusted according to the interferogram, the second address information of each piece of tensor data is obtained, and in different steps of the kernel program, if no interference relation exists between the two tensors, the storage areas of the two pieces of tensor data are reused. According to the invention, the memory reuse rate can be improved.
Owner:SHANGHAI ORIENTAL COMPUTER TECHNOLOGY CO LTD

Micropatch repair path adaptive optimization method, system and device based on variational inference and medium

The invention relates to the technical field of software security, and discloses a variational inference-based micropatch repair path adaptive optimization method, system, device and medium, and the method comprises the steps: constructing a joint control flow diagram and a data flow diagram of a to-be-analyzed program, and forming a program structure diagram; based on the program structure diagram, modeling and sampling potential variables of the repair paths through variational inference, and generating a plurality of candidate repair paths; for each candidate repair path, generating a micropatch statement according to context semantics of each node in the path, and inserting the micropatch statement into a corresponding instrumentation position in the source code; and performing multi-dimensional scoring and sorting on the candidate repair paths, and selecting an optimal repair path for deployment according to a scoring result. According to the method, the structural breakthrough of the whole process is realized in the aspects of path identification, patch generation, strategy optimization, engineering deployment and the like, and a technical support is provided for constructing a software vulnerability repair system with autonomous generation, semantic understanding and controllable deployment capabilities.
Owner:GUIZHOU POWER GRID CO LTD

Intelligent contract vulnerability detection method and system based on semantic comprehension and program path analysis

The invention discloses an intelligent contract vulnerability detection method and system based on semantic comprehension and program path analysis, and belongs to the technical field of network security. The method comprises the following steps: firstly, analyzing an intelligent contract code by using a large language model, and reasoning to generate a structured security rule for defining a taint source, a taint sink and a purifier; secondly, guiding a taint analysis engine by using a security rule, and tracking on a data flow and a control flow diagram of a program so as to efficiently screen out a high-risk taint path; then, carrying out reachability verification on the high-risk path by adopting a symbolic execution technology; and finally, performing final context review on the verified vulnerability path by using the large language model again to generate a vulnerability report. According to the method, the semantic comprehension ability of the large language model and the preciseness of traditional program analysis are subjected to multi-stage cooperation, so that the detection precision and efficiency of the intelligent contract logic vulnerability can be remarkably improved, the interpretability of a report result is greatly enhanced, and the method has important application value.
Owner:ZHEJIANG UNIV +2

Cross-language software vulnerability detection method and device

The invention relates to a cross-language software vulnerability detection method and device, and the method comprises the steps: carrying out the analysis of a Joern static analysis pair, carrying out the integration and semantic enhancement of an abstract syntax tree, a control flow graph and a data dependence graph, and obtaining a cross-warehouse heterogeneous code graph; obtaining cross-language intermediate representation based on a compiler framework; after the cross-language intermediate representation and the cross-warehouse heterogeneous code graph are modeled, weighted fusion is carried out through a gated cross attention mechanism, and a multi-modal data set is obtained; carrying out migration training on the multi-modal cross-language vulnerability detection model, and carrying out vulnerability detection on cross-language software to obtain a detection result; through multi-modal data fusion and modeling, in combination with cross-language intermediate representation and a cross-warehouse heterogeneous code graph, the defects of a traditional method in the aspects of cross-language generalization ability and context reasoning ability are effectively overcome; the method has the advantages that the generalization ability of cross-language vulnerability detection is improved, the false alarm rate and the missing report rate are reduced, and the comprehensive utilization effect of global structure information is enhanced.
Owner:WSGRI SMART CITY(WUHAN) ENGINEERING TECHNOLOGY CO LTD

Intelligent detection method for network security vulnerabilities

The invention discloses an intelligent detection method for network security vulnerabilities, and relates to the technical field of network security vulnerability detection, and the method comprises the following steps: analyzing source codes to construct an abstract syntax tree, a control flow graph and a call graph, identifying sensitive operation points based on a rule base, and screening hotspot functions in combination with code indexes and the call graph; extracting a candidate path from a program entry to a sensitive operation point, encoding to generate a path context snapshot, and scoring through a pre-training model; selecting a high-risk path to execute sparse symbolic execution, simplifying constraints by using variable interval information, and dynamically feeding back and adjusting scores; poC input verification is generated for the path triggering the vulnerability constraint, a report containing the path constraint, the triggering condition and the PoC is output, program analysis and machine learning are combined, the vulnerability detection efficiency and precision are improved, and the method is suitable for code security analysis of scenes such as an embedded system.
Owner:GUANGDONG CABLE RADIO & TELEVISION NETWORK CO LTD

Static binary code taint analysis method based on propagation action range

The invention discloses a static binary code taint analysis method based on a propagation action scope, and relates to the field of static binary code taint analysis, and the static binary code taint analysis method comprises the following steps: extracting a program instruction set and a control flow structure based on a disassembling result of a target binary code; calculating a value set with a source of the binary code based on the control flow graph; on the basis of the control flow diagram and the value set with the source, executing cross-function stain propagation analysis, and identifying memory positions or registers influenced by pollution in each function and propagation action ranges of the memory positions or the registers; and extracting all instruction sets using the taint data based on the taint and the propagation action range thereof. According to the method, the false alarm rate of static binary taint analysis can be reduced and the instruction set involved in the taint analysis can be reduced without increasing the analysis overhead, so that the method has important significance in improving the instrumentation efficiency and the operation efficiency of dynamic taint analysis and improving the accuracy of protocol reversion, fuzzy testing and vulnerability mining based on the taint analysis.
Owner:EAST CHINA NORMAL UNIV

Compilation method for compiling C language source code into RISC-V assembly code

The invention discloses a compiling method for compiling a C language source code into an RISC-V assembly code. The method comprises the following steps: acquiring a C language source code; performing lexical analysis on the C language source code to generate a mark flow; performing syntactic analysis on the mark flow, and constructing an abstract syntax tree; performing semantic analysis on the abstract syntax tree to generate a target abstract syntax tree; constructing a runtime environment of the RISC-V assembly code; generating an intermediate code and a control flow diagram corresponding to the intermediate code according to a rule in the runtime environment and the target abstract syntax tree; generating a target code by using the intermediate code and the control flow diagram corresponding to the intermediate code; according to the technical scheme, the intermediate representation more adaptive to RISC-V custom instruction mapping can be generated, so that the execution efficiency of assembly codes is improved; and meanwhile, by designing a lightweight runtime environment, the performance overhead is further reduced.
Owner:CHINA SOUTHERN POWER GRID COMPANY

Binary vulnerability retrieval and positioning method and system based on high-dimensional vulnerability characterization

The invention relates to the field of code vulnerability detection, in particular to a binary vulnerability retrieval and positioning method and system based on high-dimensional vulnerability characterization, and the method comprises the steps: firstly inputting a binary file, analyzing the structural information of the binary file, and analyzing a machine instruction; extracting binary file function information, generating a cross-platform basic block IR instruction sequence, constructing a control flow graph, and constructing a data dependency graph; splicing the program dependency graph feature vector and the basic block IR instruction sequence feature vector, and performing multi-modal feature fusion to generate a comprehensive high-dimensional vulnerability representation vector; and finally, inputting the high-dimensional vulnerability representation vector into an index for searching to obtain a plurality of nearest neighbor indexes and distances, converting the distances into similarity, filtering according to a similarity threshold to obtain a most similar vulnerability vector, and obtaining vulnerability information and vulnerability positions corresponding to the vulnerability vector. The problems that traditional binary vulnerability detection cross-platform and compiler optimization detection fails and the result reliability is low are solved.
Owner:HUANENG POWER INT INC +1

Code conversion method and related device

The invention discloses a code conversion method and a related device, and the method comprises the steps: obtaining an input code, carrying out the grammatical analysis of the input code, and generating an abstract syntax tree which comprises a plurality of nodes; coding a code text in the input code to generate a first semantic vector; encoding the structure in the abstract syntax tree to generate a second semantic vector; processing the first semantic vector, and converting the first semantic vector into a second semantic vector; generating a control flow diagram according to the abstract syntax tree, and constructing a data flow diagram; determining a plurality of semantic units according to the control flow diagram and the data flow diagram; obtaining a preset domain knowledge graph, wherein the preset domain knowledge graph comprises a plurality of concept nodes; according to the concept nodes and the semantic units, analyzing the second semantic vector to obtain a target semantic vector, decoding the target semantic vector into a target language, and generating a target code. By adopting the method and the device, code conversion expansibility and accuracy can be improved.
Owner:WEBANK (CHINA)

Cross-platform binary code block layered semantic similarity detection method and related device

The invention discloses a cross-platform binary code block hierarchical semantic similarity detection method and a related device, and belongs to the field of code vulnerability detection.The cross-platform binary code block hierarchical semantic similarity detection method comprises the following steps that structural information of a binary file is analyzed, a machine instruction is analyzed through a hybrid disassembling engine, a basic block is extracted from the structural information of the binary file, and the basic block is extracted from the binary file; constructing a control flow graph, a data dependency graph and a function call graph; extracting instruction level semantics, basic block level semantics and function level semantics from the instruction sequence, the basic block, the control flow graph, the data dependency graph and the function call graph; according to the instruction-level semantics, the basic-block-level semantics and the function-level semantics, constructing instruction-level features, basic-block-level features and function-level features; and carrying out hierarchical similarity detection on the instruction-level features, the basic block-level features and the function-level features. The method and the related device can solve the problems of low detection efficiency and poor accuracy when a traditional vulnerability detection method is used for detecting vulnerabilities.
Owner:HUANENG POWER INT INC +1

Malicious code control flow feature extraction method and system based on graph neural network

The invention discloses a malicious code control flow feature extraction method based on a graph neural network. The method comprises the following steps: constructing a control flow graph, a data flow graph and a function call graph; designing a drawing neural network architecture; training a graph-level classifier; performing graph interpretation by using a GNNExplainer algorithm, attention mechanism analysis and a gradient analysis method; converting the extracted control flow mode into a structured detection signature, and mapping the structured detection signature to an original binary code; and integrating with a static analysis tool through a standardized interface. The invention further discloses a malicious code control flow feature extraction system based on the graph neural network. Multi-level graph structure representation is constructed, important information such as a control flow structure and a data dependency relationship is fully reserved, the deep structure similarity of malicious codes can be recognized, the deformation resistance is higher, and therefore the malicious code detection precision is improved; according to the method, key sub-graphs can be recognized, graph structure features are converted into detection rules, then the detection rules are integrated with existing static analysis tools, and practicability is improved.
Owner:HARBIN ANTIY TECH

Data prefetching method and device

The invention discloses a data prefetching method and device, and relates to the technical field of computers. The data prefetching method comprises the steps that a control flow diagram and events, recorded by a PMU, of basic blocks in the control flow diagram are obtained, target paths of multiple paths in the control flow diagram are determined according to the occurrence frequency of the events of the basic blocks in the control flow diagram, and then target data corresponding to a first basic block are written into a buffer before the first basic block is executed. Wherein the sum of the occurrence frequency of all events of the basic block in the target path is greater than or equal to a first threshold value, and the target data is data with the access frequency or the access frequency greater than or equal to a second threshold value in the data needing to be accessed when the target path is executed. The sum of the occurrence times corresponding to the target path is greater than or equal to the first threshold value, so that the probability that the target path is frequently executed is relatively high, the target data determined according to the target path is written into the cache in advance, and the data access efficiency when the processor executes according to the control flow diagram can be improved.
Owner:HUAWEI TECH CO LTD

Digital archive management system based on block chain

ActiveCN120763119AFinanceSemantic analysisWaiting periodDigital Archives
The invention discloses a digital archive management system based on a block chain, and relates to the technical field of archive management, and the system comprises an extraction module which is used for extracting a state set according to behavior statistical information in the digital archive management system; the risk analysis module is used for positioning a text position according to a normal set in the state set, predicting a semantic layer exception risk and an authority risk, constructing a control flow graph to evaluate a structural layer exception risk, and summarizing to generate a risk signal; the association analysis module is used for analyzing the operation threat condition of the Solidiity contract in the digital archive management system on the basis of the risk analysis module, and judging the starting of a Solidiity contract correction mechanism; the influence module is used for starting a Solidinity contract correction mechanism and analyzing the influence of an abnormal condition on Solidinity contract operation; the waiting setting module is used for setting a time lock waiting period.
Owner:NANJING MIS ELECTRONIC INFORMATION TECH CO LTD

Vulnerability detection method and system based on code block characteristics

The invention relates to the field of code vulnerability detection, in particular to a vulnerability detection method and system based on code block features. The method comprises the steps that firstly, a binary file is analyzed, and a machine instruction is analyzed through a hybrid disassembling engine; secondly, performing static linear scanning on the extracted binary file instruction, constructing a control flow graph, dividing basic blocks, extracting an operation code sequence in the basic blocks, and constructing a cross-basic-block data dependency graph and a system calling sequence called by the basic blocks; secondly, using an LSH algorithm to realize rapid filtering, performing similarity comparison on extracted basic block features and vulnerability feature library features, realizing coarse-grained matching, and screening out a matching candidate set; feature fusion is carried out on the candidate set basic block operation code sequence, the basic block data dependency graph and the system calling sequence called by the basic block, GNN fine-grained matching is carried out on the fused features, and vulnerability detection is carried out. The problems that traditional binary vulnerability detection is poor in adaptability and low in result reliability are solved.
Owner:HUANENG POWER INT INC +1

Cross-language interaction malicious behavior detection method based on high-order function

The invention discloses a cross-language interaction malicious behavior detection method based on a high-order function, and relates to the technical field of computer security. The method comprises the following steps: receiving a source code of a certain program, modeling a cross-language interface in the program, and identifying and marking a cross-language calling boundary; different language source codes are converted into universal intermediate representations (IR), the IR is combined, and cross-language calling points are marked; constructing a global cross-language function call graph and a control flow graph, determining a function analysis sequence by inverse topological sorting to perform dependency analysis on each function, and abstracting dependency information in the processes into a function abstract in a high-order function form; and parameter instantiation is carried out when function calling is processed, so that the dependency relationship between the cross-language APIs is obtained. According to the method, efficient analysis and transmission of the cross-language dependency relationship are realized through the high-order function abstract and the dependency matrix, the high overhead of constructing a complex system dependency graph by a traditional method is avoided, and the analysis efficiency and the detection accuracy are improved.
Owner:NANJING UNIV OF POSTS & TELECOMM

Firmware function vulnerability detection method and system based on multi-granularity feature fusion

The invention relates to a firmware function vulnerability detection method and system based on multi-granularity feature fusion. The method comprises the following steps: preprocessing firmware to be detected to obtain a function instruction set and a function control flow diagram; extracting structural features and semantic features of the function instruction set and the function control flow diagram, and performing feature fusion by adopting a double-gating weighted fusion model to obtain function fusion features of the firmware to be detected; performing similarity comparison on the fusion feature of the firmware function to be detected and a preset vulnerability feature; and determining a vulnerability detection result based on a similarity comparison result, and performing visual display. A firmware function vulnerability detection technology based on multi-granularity feature fusion is provided, and a reset gate and an update gate are introduced to solve the problems of information selection and feature retention during fusion of different features; and then carrying out training and similarity detection on the model under a twinning neural network architecture. The detection accuracy is remarkably improved, and meanwhile, higher-degree automatic detection is realized.
Owner:SICHUAN UNIV

Static analysis method and device for program problems, electronic equipment, readable storage medium and program product

The embodiment of the invention provides a program problem static analysis method and device, electronic equipment, a readable storage medium and a program product, and relates to the technical field of program static analysis. The method comprises the steps that a target program is analyzed based on a rule constraint set of target syntax, and an abstract syntax tree is generated; constructing an annotation control flow graph according to the abstract syntax tree; according to the annotation control flow diagram, identifying a periodic task in the target program; and on the basis of performing loop expansion on the execution process of the periodic task, performing symbolic execution analysis on the annotation control flow diagram, and identifying the cross-period conflict problem of the periodic task. By identifying the periodic task and circularly expanding the periodic task, the analysis limitation on the program problem in the related technology is solved, the cross-period conflict problem in the program is efficiently identified, and the static guarantee capability on the program quality is improved.
Owner:SHANGHAI FORMAL TECH INFORMATION TECH CO LTD

Detecting uninitialized variables during program pre-compilation using control flow graphs

PendingUS20260044322A1Code compilationUninitialized variableTheoretical computer science
In various examples, static single assignment-based control flow graph traversal analysis for uninitialized variable detection system and methods are disclosed. A pre-compiler stage of a compiler system, may reconstruct source code into an SSA form IR and detect and identify uninitialized variables based on applying a variable analysis pass that traverses a CFG corresponding to the SSA form IR. A variable analysis pass may traverse through the CFG to build a defined variable map and a Phi variable map. The maps may be used to map undefined variables to basic blocks of the CFG where the undefined variables occur. The variable analysis pass may pass uninitialized variable data to a compiler error handling process. The compiler error handling process may produce an error report that traces the basic block with undefined variables to lines of the source code to assist in efficiently debugging the source code.
Owner:NVIDIA CORP

Code detection and protection method, system, equipment and medium

The invention provides a code detection and protection method, system and device and a medium, and belongs to the technical field of malicious code detection.The method specifically comprises the steps that WASM byte codes are obtained; converting the byte code into a WAT text and an intermediate representation, and analyzing meta-information; respectively constructing control flow diagrams and program dependency diagrams of the JS and the WASM based on the AST and the intermediate representation, and fusing the control flow diagrams and the program dependency diagrams into a unified dependency diagram through cross-language interface nodes; matching the dependency graph by using a preset malicious rule base, and marking a suspicious level; if not, WASM is injected into a Unikernel mirror image to be executed in an isolation environment, and behavior fingerprints during operation are collected; and outputting a malicious and non-malicious conclusion by combining the static analysis result with dynamic feature rating such as resource consumption and abnormal events. Through cross-language dependency graph fusion and dynamic and static combination analysis, malicious behaviors in WASM and JS interaction are captured, execution and behavior collection are isolated, the misjudgment risk is reduced, the detection accuracy is improved, and efficient and accurate WebAssembly module protection is achieved.
Owner:TAIAN POWER SUPPLY CO OF STATE GRID SHANDONG ELECTRIC POWER CO

Instruction processing method and device for thread bundle branch execution and storage medium

The embodiment of the invention provides an instruction processing method and device for thread bundle branch execution and a storage medium, and relates to the technical field of artificial intelligence chips, and the method comprises the steps: setting an aggregation mask and a target address of a branch aggregation block in each branch initial block of a branch generated in an original control flow diagram, the aggregation mask indicates a plurality of threads executing the branch start block. Respectively inserting an aggregation instruction into a plurality of branch precursor blocks corresponding to the branch aggregation block so as to indicate that after a thread (namely part of threads in a plurality of threads for executing the branch initial block) executing each branch precursor block arrives, the threads enter the branch aggregation block for execution according to a target address of the branch aggregation block; therefore, the correctness of the branch execution of the topology sequence and the thread bundle is ensured. Secondly, due to the fact that the original control flow diagram does not need to be modified, the corresponding compilation optimization strategy can be correctly executed for the branch structure in the compilation stage, and the correctness of compilation optimization (such as compilation optimization depending on mark elimination) is guaranteed.
Owner:SHANGHAI BIREN TECH CO LTD

Firmware patch state judgment method based on graph embedding and random walk

The invention provides a firmware patch state judgment method based on graph embedding and random walk. The method comprises the steps of obtaining a target function, a vulnerability function and a patch function from target firmware; constructing a corresponding dual-channel control flow diagram based on the target function, the vulnerability function and the patch function; respectively inputting the target dual-channel control flow diagram, the vulnerability dual-channel control flow diagram and the patch dual-channel control flow diagram into a preset graph auto-encoder model for graph embedding processing to obtain a corresponding graph embedding matrix; and performing patch state judgment based on the target graph embedding matrix, the vulnerability graph embedding matrix and the patch graph embedding matrix through random walk processing, and outputting a judgment result. According to the firmware patch state judgment method based on graph embedding and random walk, on the basis of the two-channel control flow graph, dimension reduction compression is performed through the preset graph auto-encoder model, and the graph embedding matrix is constructed, so that the accuracy and efficiency of firmware patch state judgment are improved.
Owner:ELECTRIC POWER RES INST OF GUANGDONG POWER GRID CO LTD

A multi-language code generation method based on self-supervised pre-training

The application discloses a kind of multilingual code generation methods based on self-supervised pre-training, comprising the following steps: obtaining and cleaning multilingual code data, forming training corpus;Code data is represented as abstract syntax tree, the control flow graph and data flow graph of code data are extracted, and unified semantic representation is obtained by combining graph encoder and sequence encoder;Self-supervised pre-training task is designed, and the semantic representation is pre-trained based on the training corpus;Multilingual pre-training model is constructed based on the recursive neural tensor network and multilingual embedding matrix improved in structure;When natural language is input by user, the multilingual pre-training model is used to generate target language code;Target language code is corrected by routine function test and syntax check.The application realizes accurate generation and executable improvement of cross-language code by combining self-supervised pre-training with multichannel recursive combination and hierarchical recursive development mechanism.
Owner:CLOUD HI-TECH (BEIJING) TECHNOLOGY CO LTD