# US 11,119,903 B2 · Race condition testing via a scheduling test program

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 11,119,903 B2
- Document ID: US11119903B2
- Status: Granted
- Kind: B2
- Application number: 14/702,057
- Filed: 2015-05-01
- Published: 2016-11-03
- Granted: 2021-09-14
- Earliest claimed: 2015-05-01
- Assignees: Fastly, Inc.
- Applicants: Fastly, Inc.
- Inventors: Devon O'Dell
- Web page: https://patentgrep.com/patent/US11119903B2

## CPC

- G06F 11/3688: {for test execution, e.g. scheduling of test suites}
- G06F 9/48: Program initiating; Program switching, e.g. by interrupt
- G06F 9/4881: {Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues}
- G06F 9/50: Allocation of resources, e.g. of the central processing unit [CPU]
- G06F 9/5005: {to service a request}
- G06F 9/5011: {the resources being hardware resources other than CPUs, Servers and Terminals}
- G06F 9/5027: {the resource being a machine, e.g. CPUs, Servers, Terminals}
- G06F 9/5038: {considering the execution order of a plurality of tasks, e.g. taking priority or time dependency constraints into consideration (scheduling strategies G06F9/4881 and subgroups)}
- G06F 9/52: Program synchronisation; Mutual exclusion, e.g. by means of semaphores
- G06F 9/524: {Deadlock detection or avoidance}
- G06F 11/36: Prevention of errors by analysis, debugging or testing of software
- G06F 11/3604: Analysis of software for verifying properties of programs (testing of software G06F11/3668)
- G06F 11/3612: {by runtime analysis (performance monitoring G06F11/3466)}
- G06F 11/362: Debugging of software
- G06F 11/3636: {by tracing the execution of the program}
- G06F 11/3668: Testing of software
- G06F 11/3672: {Test management}
- G06F 11/3684: {for test design, e.g. generating new test cases}
- G06F 11/3696: {Methods or tools to render software testable}
- G06F 11/3698: Environments for analysis, debugging or testing of software
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Disclosed herein are methods, systems, and software to enhance the testing of race conditions in programs. In one example, a method of testing race conditions in a target program with one or more concurrent processes includes generating a scheduling program based on race conditions identified in the target program, wherein the scheduling program includes order of operation rules for the one or more concurrent processes. The method further provides initiating execution of the scheduling program, and executing the target program based on the order of operation rules for the one or more concurrent processes.

## Claims

### Claim 1

A method of operating a computing system to test one or more race conditions in a target program, wherein the target program comprises a first concurrent process and a second concurrent process, the method comprising:
executing a scheduler program, the scheduler program comprising identifying a state of interest in the target program, wherein the state of interest in the target program comprises a first state of interest in the first concurrent process and a second state of interest in the second concurrent process;
initiating independent execution of the first and second concurrent processes, which execute as independent operations on the computing system;
pausing the first concurrent process when the first concurrent process reaches the state of interest, and until the second concurrent process reaches the second state of interest; and
creating the race condition by continuing both the first and second concurrent processes at the state of interest in the target program.

### Claim 2 (depends on 1)

The method of claim 1 further comprising receiving user input to generate the scheduler program.

### Claim 3 (depends on 1)

The method of claim 1 wherein executing the scheduler program comprises initiating a thread for the scheduler program.

### Claim 4 (depends on 1)

The method of claim 1 wherein executing the scheduler program comprises executing the scheduler program in response to initiating the execution of the target program.

### Claim 5 (depends on 4)

The method of claim 4 wherein executing the scheduler program in response to initiating the execution of the target program comprises:
identifying a call from the target program to execute the scheduler program; and
in response to the call, executing the scheduler program.

### Claim 6 (depends on 5)

The method of claim 5 further comprising:
in response to identifying the call, holding execution of the target program; and
in response to executing the scheduler program, continuing execution of the target program.

### Claim 7

An apparatus to perform testing of one or more race conditions in a target program, wherein the target program comprises a first concurrent process and a second concurrent process, the apparatus comprising:
one or more computer readable media; and
processing instructions stored on the one or more computer readable media that, when executed by a processing system, direct the processing system to:
execute a scheduler program, the scheduler program comprising identifying a state of interest in the target program, wherein the state of interest in the target program comprises a first state of interest in the first concurrent process and a second state of interest in the second concurrent process;
initiate independent execution of the first and second concurrent processes, which execute as independent operations on the computing system;
pause the first concurrent process when the first concurrent process reaches the state of interest, and until the second concurrent process reaches the second state of interest; and
create the race condition by continuing both the first and second concurrent processes at the state of interest in the target program.

### Claim 8 (depends on 7)

The apparatus of claim 7, wherein the processing instructions further direct the computing system to receive user input to generate the scheduler program.

### Claim 9 (depends on 7)

The apparatus of claim 7, wherein the processing instructions to execute the scheduler program direct the processing system to initiate a thread for the scheduler program.

### Claim 10 (depends on 7)

The apparatus of claim 7, wherein the processing instructions to execute the scheduler program direct the processing system to execute the scheduler program in response to initiating the execution of the target program.

### Claim 11 (depends on 10)

The apparatus of claim 10, wherein the processing instructions to execute the scheduler program in response to initiating the execution of the target program direct the processing system to:
identify a call from the target program to execute the scheduler program;
in response to the call, execute the scheduler program.

### Claim 12 (depends on 7)

The apparatus of claim 7, wherein the scheduler program and the target program comprise programs written in different programming languages.

### Claim 13

A computing apparatus comprising:
one or more computer readable storage media;
one or more processors operatively coupled with the one or more computer readable storage media; and
program instructions stored on the one or more computer readable storage media for load balancing requests across origin servers that, when executed by the one or more processors, direct the computing apparatus to at least:
execute a scheduler program, the scheduler program comprising identifying a state of interest in a target program, wherein the state of interest in the target program comprises a first state of interest in a first concurrent process and a second state of interest in a second concurrent process;
initiate independent execution of the first and second concurrent processes, which execute as independent operations on the computing apparatus;
pause the first concurrent process when the first concurrent process reaches the state of interest, and until the second concurrent process reaches the second state of interest; and
create a race condition by continuing both the first and second concurrent processes at the state of interest in the target program.

### Claim 14 (depends on 13)

The computing apparatus of claim 13, wherein the scheduler program comprises state rules corresponding to states for each of the first and second concurrent process.
