IP Library › Granted Patent US 11,734,003
Granted Patent B2
US 11,734,003 · App. 17/552,358 · Granted Aug 22, 2023

Non-transitory computer-readable recording medium, compilation method, and compiler device

Inventor: Yuta Mukai (Kawasaki, JP)
Assignee: FUJITSU LIMITED
G06F9/30065G06F8/443G06F9/30036G06F9/30069
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 11,734,003
App. No.
17/552,358
Granted
Aug 22, 2023
Kind
B2
Abstract

The present disclosure relates to a compiler for causing a computer to execute a process. The process includes generating a first program, wherein the first program includes a first code that determines whether a first area of a memory that a process inside a loop included in a second program refers to in a first execution time of the loop is in duplicate with a second area of the memory that the process refers to in a second execution time of the loop, a second code that executes the process in an order of the first and second execution times when it is determined that the first and the second areas are duplicate, and a third code that executes the process for the first execution time and the process for the second execution time in parallel when it is determined that the first and the second areas are not duplicate.

Claims (45)

1. A non-transitory computer-readable recording medium having stored therein a program for causing a computer to execute a process, the process comprising:

acquiring a source program;

generating a first program that performs processing equivalent to processing of the source program by performing lexical analysis, syntactic analysis, and semantic analysis on the source program; and

generating a second program, the second program includes:

a first code that determines whether a first area of a memory that a process inside a loop included in the first program refers to in a first execution time of the loop is in duplicate with a second area of the memory that the process refers to in a second execution time of the loop;

a second code that executes the process in an order of the first and second execution times when it is determined that the first area and the second area are duplicate; and

a third code that executes the process for the first execution time and the process for the second execution time in parallel when it is determined that the first area and the second area are not duplicate,

the loop has a first array indexed by an execution time of the loop and a second array indexed by each element of the first array,

the process is to store a first element of the second array in the memory in the first execution time and to store a second element of the second array in the memory in the second execution time,

the first area is an area in which the first element is stored in the first execution time, and

the second area is an area in which the second element is stored in the second execution time.

2. The non-transitory computer-readable recording medium as claimed in claim 1 , wherein

the second program calls the loop multiple times, and

the first program includes:

a fourth code that stores a result of the determination at the time of a first call among a plurality of calls;

a fifth code that detects whether a content of any of elements in the first array is changed after the result is stored; and

a sixth code that skips the determination about whether the first area and the second area are duplicate at the time of a second call later than the first call among the plurality of calls when the content of the element is not changed.

3. The non-transitory computer-readable recording medium as claimed in claim 1 , wherein the first code is a code that determines the first area and the second area are duplicate when a third element of the first array indexed by the first execution time is the same as a fourth element of the first array indexed by the second execution time, and determines the first area and the second area are not duplicate when the third element is not the same as the fourth element.

4. The non-transitory computer-readable recording medium as claimed in claim 1 , wherein the third code is a code that executes a vector operation on a vector having the first element and the second element as elements.

5. A compilation method for causing a computer to execute a process, the process comprising:

acquiring a source program;

generating a first program that performs processing equivalent to processing of the source program by performing lexical analysis, syntactic analysis, and semantic analysis on the source program; and

generating a second program;

the second program includes:

a first code that determines whether a first area of a memory that a process inside a loop included in the first program refers to in a first execution time of the loop is in duplicate with a second area of the memory that the process refers to in a second execution time of the loop;

a second code that executes the process in an order of the first and second execution times when it is determined that the first area and the second area are duplicate; and

a third code that executes the process for the first execution time and the process for the second execution time in parallel when it is determined that the first area and the second area are not duplicate,

the loop has a first array indexed by an execution time of the loop and a second array indexed by each element of the first array,

the process is to store a first element of the second array in the memory in the first execution time and to store a second element of the second array in the memory in the second execution time,

the first area is an area in which the first element is stored in the first execution time, and

the second area is an area in which the second element is stored in the second execution time.

6. A compiler device comprising:

a memory; and

a processor coupled to the memory, the processor being configured to

acquire a source program;

generate a first program that performs processing equivalent to processing of the source program by performing lexical analysis, syntactic analysis, and semantic analysis on the source program; and

generate a second program;

the second program includes:

a first code that determines whether a first area of a memory that a process inside a loop included in the first program refers to in a first execution time of the loop is in duplicate with a second area of the memory that the process refers to in a second execution time of the loop;

a second code that executes the process in an order of the first and second execution times when it is determined that the first area and the second area are duplicate; and

a third code that executes the process for the first execution time and the process for the second execution time in parallel when it is determined that the first area and the second area are not duplicate,

the loop has a first array indexed by an execution time of the loop and a second array indexed by each element of the first array,

the process is to store a first element of the second array in the memory in the first execution time and to store a second element of the second array in the memory in the second execution time,

the first area is an area in which the first element is stored in the first execution time, and

the second area is an area in which the second element is stored in the second execution time.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 16, 2021
From: MUKAI, YUTA
To: FUJITSU LIMITED
Reel/Frame 058403/0552 →
Priority Claims (1)
JP 2021-089727 · May 28, 2021 · national
Continuity (1)
Related Publication 20220382548A1 · Dec 1, 2022