Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Program scheduling method for data race detection

A technology of data competition and scheduling method, applied in the direction of software testing/debugging, can solve the problems of missing data competition, inefficiency, unable to efficiently detect data competition, etc., to achieve the effect of improving efficiency

Active Publication Date: 2015-10-14
INST OF SOFTWARE - CHINESE ACAD OF SCI
View PDF3 Cites 12 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Therefore, simply using HBR to detect data races will miss a lot of data races
In addition, HBR cannot effectively detect data races that were previously hidden by it, even if a program is repeatedly run many times.
Therefore, HBR-based data race tools are ineffective in detecting data races that are hidden by

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Program scheduling method for data race detection
  • Program scheduling method for data race detection
  • Program scheduling method for data race detection

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0026] against figure 1 In the data competition hidden by HBR in a, the present invention will schedule the operation of the program to generate the operation shown in b in 1, thereby exposing the data competition on x, and then detected by the data competition detection tool based on HBR.

[0027] like figure 2 As shown, the steps of the present invention include: dividing a given program p into several program blocks {b 1 ,b 2 ,... b n}; By running the program p once, dynamically determine each program block b i The collection of types of locks {L(b 1 ), L(b 2 ),…L(b n )}; Select a data race detection tool based on Happens-before, run the program p again and schedule the operation of each thread according to the relationship between each thread and the lock and the type set of locks in the program block, and use the selected The data competition detection tool detects data competition; recalculates the lock type set corresponding to each program block during the sche...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The present invention relates to a program scheduling method for data race detection and belongs to the field of software testing and the field of software reliability. The program scheduling method comprises the steps of: partitioning a given program into a plurality of program blocks; dynamically determining a set of types of locks in each program block bi by operating a program for once; selecting a data race detection tool, operating the program p again, scheduling operation of each thread according to relations between each thread and the locks and the set of the types of the locks in the program blocks, and detecting data race by using the selected data race detection tool; recomputing a lock type set corresponding to each program block in the program scheduling process; repeating the steps for a couple of times; According to the present invention, operation of the program is scheduled on the basis of the acquiring relation of the lock type set in each program block and the threads for the locks, so that hidden data race can be exposed, and thus, the hidden data race is detected by the data race detection tool based on Happens-before and detection efficiency of data race based on Happens-before is improved.

Description

technical field [0001] The invention belongs to the technical field of software testing and the field of software reliability, in particular to a data competition detection and degree scheduling method in a multi-thread program. Background technique [0002] With the widespread use of multi-core CPUs, more and more software uses multi-threading technology to process certain tasks concurrently. However, a multi-threaded program requires each thread to be well synchronized to complete a certain task during the running process. When there is an error in the synchronization between these threads, it will lead to the occurrence of concurrency defects, and data race (Data Race) is the most basic concurrency defect. [0003] The definition of data competition is: two or more threads simultaneously operate (read or write) on the same variable, and at least one write operation is included. The accurate detection of mainstream data competition is based on the Happens-before relation...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36
Inventor 蔡彦
Owner INST OF SOFTWARE - CHINESE ACAD OF SCI
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products