WO2006126467A1 - マルチプロセッサシステム及びその情報処理方法 - Google Patents

マルチプロセッサシステム及びその情報処理方法 Download PDF

Info

Publication number
WO2006126467A1
WO2006126467A1 PCT/JP2006/310110 JP2006310110W WO2006126467A1 WO 2006126467 A1 WO2006126467 A1 WO 2006126467A1 JP 2006310110 W JP2006310110 W JP 2006310110W WO 2006126467 A1 WO2006126467 A1 WO 2006126467A1
Authority
WO
WIPO (PCT)
Prior art keywords
record
item value
item
array
value
Prior art date
Application number
PCT/JP2006/310110
Other languages
English (en)
French (fr)
Inventor
Shinji Furusho
Original Assignee
Turbo Data Laboratories Inc.
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Turbo Data Laboratories Inc. filed Critical Turbo Data Laboratories Inc.
Priority to EP06756416A priority Critical patent/EP1901183A4/en
Priority to US11/883,264 priority patent/US7801903B2/en
Priority to JP2007517805A priority patent/JP4339381B2/ja
Priority to CN2006800034124A priority patent/CN101133414B/zh
Priority to CA002595858A priority patent/CA2595858A1/en
Priority to KR1020077017364A priority patent/KR101196566B1/ko
Publication of WO2006126467A1 publication Critical patent/WO2006126467A1/ja
Priority to US12/856,429 priority patent/US8065337B2/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/40Data acquisition and logging
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24553Query execution of query operations
    • G06F16/24554Unary operations; Data partitioning operations

Definitions

  • the present invention relates to an information processing method in a shared memory multiprocessor system in which a plurality of processors share a memory and perform parallel processing, and in particular, a large-scale tabular data on a shared memory is transferred to a plurality of processors. It relates to the information processing method which sorts in parallel.
  • the present invention also relates to a shared memory multiprocessor system that implements such an information processing method.
  • the present invention further relates to a program for realizing such an information processing method.
  • the present invention further relates to a storage medium storing such a program.
  • Sorting is a process that occurs frequently when processing large-scale data, especially large-scale tabular data.
  • Radix (RADIX) sort and counting (COUNTING) sort also called count sort, distribution counting sort
  • Counting sort is sometimes used for sorting each digit of radix sort and is an efficient algorithm, but for its application,
  • Sort target is an integer
  • the present inventor has proposed a data management mechanism suitable for high-speed retrieval, tabulation, and sorting of large-scale tabular data (see Patent Document 1).
  • This data tube has an information block for representing each item value of the tabular data item.
  • item values belonging to tabular data items are represented by item value numbers assigned to the item values and an array of actual item values arranged in the order of the item value numbers.
  • An array is prepared in which the item value numbers corresponding to the item values of each record are arranged in the order of the record number, and the item values of each record are identified by finding the array value of the item values corresponding to the item value numbers of that record. Is done.
  • records to be processed in tabular data are specified by an array in which record numbers are arranged in order.
  • the information block stores the item values corresponding to the item value numbers in the order of the item value numbers in which the item values belonging to the items are ordered (integerized) for each item of the tabular data. It is a table that was made.
  • the field value itself can be any type of data, such as a number (integer, fixed point, floating point, etc.), string, etc. Therefore, this data management mechanism is characterized in that all types of data values can be handled as integers called item value numbers. That is, according to this data management mechanism, for example, when character string data is sorted, items corresponding to the value of character string data are not sorted as they are for sorting. The value number can be sorted as a sort target.
  • the result of sorting is represented by an array in which record numbers are arranged in order.
  • the data management mechanism based on the information block proposed by the present inventor is excellent in that it satisfies the prerequisites 1) to 3) for applying the counting sort.
  • parallel processing architectures are broadly divided into “distributed memory type” and “shared memory type”.
  • distributed memory type each processor has its own local memory, and these are combined to construct a system.
  • the distributed memory type has technical problems such as the complexity of data division management and the low efficiency of interprocessor communication.
  • shared memory type is a method in which multiple processors share one huge memory space. In this method, traffic between the processor group and shared memory becomes a bottleneck, so in reality, more than 100 processors are used. V. It is thought that building a system is not easy.
  • a personal computer configured as a shared memory multiprocessor system using a plurality of CPUs has recently been available.
  • a standard CPU used in this type of personal computer operates with an internal clock that is about 5-6 times the memory bus, and is equipped with automatic parallel execution and pipeline processing functions. Approximately 1 data can be processed in 1 clock (memory bus).
  • Patent Document 1 International Publication WOOOZ10103 Publication
  • Counting sort which is known as an efficient sorting algorithm, is restricted by the preconditions 1) to 3) above, and therefore data based on the above information block proposed by the present inventor. Unless a management mechanism is adopted, it is difficult to apply to large-scale tabular data processing. Furthermore, the technology for sorting large-scale tabular data in parallel using a shared memory multiprocessor system is still known.
  • an object of the present invention is to provide an information processing method for sorting large-scale tabular data on a shared memory in parallel by a plurality of processors using the data management mechanism based on the information block. It is to propose.
  • an object of the present invention is to provide a shared memory type multi-processor system that implements such an information processing method.
  • an object of the present invention is to provide a program for realizing such an information processing method.
  • an object of the present invention is to provide a storage medium in which such a program is recorded.
  • the above item values are arranged in the order of item value numbers (whether ascending or descending) in which item values belonging to the item are ordered (integerized). It relies on a data management mechanism based on an information block, which is a table in which item values corresponding to numbers are stored.
  • the item value itself can be any type of data, such as a number (integer, fixed point, floating point, etc.) or a string.
  • all types of data values can be handled as integers called item value numbers.
  • the item value corresponding to the value of that data is not sorted as it is as the sort target.
  • the data management mechanism based on this information block satisfies the prerequisites for applying the counting sort.
  • the sorting result is represented by an array in which the record numbers are arranged in order.
  • the present invention applies such a data management mechanism to a shared memory multiprocessor system to sort large-scale tabular data on the shared memory in parallel by a plurality of processors.
  • An information processing method and a shared memory multiprocessor system that implements the information processing method are realized. Therefore, according to the present invention, first, a record to be processed is divided and assigned to a plurality of processors. Next, each processor counts the number of local occurrences of the field value number associated with the record being processed. Next, the local number of occurrences of the item value number counted by each processor is converted into a global cumulative number of item value numbers, that is, a cumulative number commonly used among a plurality of processors.
  • each processor uses the global total number as a pointer to change the order of the allocated records. Therefore, according to the present invention, in a shared memory multiprocessor system, records are sorted in parallel with respect to item values (for example, integer values, fixed-point values, floating-point values, character strings, etc.) of items with records. Is possible.
  • item values for example, integer values, fixed-point values, floating-point values, character strings, etc.
  • the allocation of records to be processed to a plurality of processors, the power of the number of local appearances, and the change of the order of the allocated records can be processed in parallel by a plurality of processors.
  • parallel processing of multiple processors may be used, but the cache can be accessed because the memory can be accessed sequentially. Since the hit rate is high, only one or some of the processors can take charge and maintain high speed.
  • a first aspect of the present invention is an information processing method for rearranging the record order according to the item value of a predetermined item of a record in a shared memory multiprocessor system.
  • a shared memory multiprocessor system has a record number array in which the record numbers of tabular data records are stored according to a predetermined record order, and the item value number corresponding to the item value of a predetermined item of the tabular data record is a record.
  • Item value stored in accordance with the number A shared memory for storing the number array and the item value array in which the item values of the tabular data are stored in accordance with the order of the item value numbers corresponding to the item values, and the shared memory A plurality of processors capable of being connected.
  • the information processing method includes the step of dividing the record number array and assigning the record number array to the first plurality of processors, and in each of the first plurality of processors, the assigned record number array Entering the number of occurrences of the item value number corresponding to the record contained in the part,
  • each of the second plurality of processors in the order of the item value numbers, the assigned item values according to the order of the part of the record number array within the range where the item value numbers match. Converting the number of occurrences of each number into a cumulative number;
  • the total number of the item value numbers corresponding to the records included in the portion of the allocated record number array is used as a pointer, and the allocated Storing the record numbers contained in the portion of the record number array in a further record number array;
  • This information processing method includes parallelization of count processing of the number of appearances of an item value number, the number of appearances Parallelization of conversion processing from the cumulative number to the total number and parallelization of the creation processing of the record number array are achieved. Therefore, according to the present invention, it is possible to sort large-scale tabular data in parallel in a shared memory multiprocessor system by extending the counting sort technique so as to be compatible with the shared memory multiprocessor environment.
  • any 1st multiple processors are responsible for each part of the record number array, and any 2nd multiple processors are item value numbers. Responsible for each part of the range. It should be noted that the number of the first multiple units and the number of the second multiple units may be the total number of processors or a part of them.
  • the information processing method of the present invention can sort large-scale tabular data in multiple stages in a shared memory multiprocessor system by introducing the concept of radix sorting for item value numbers. is there. For example, when the size of the item value number array is large, the processing can be made more efficient if the item value number array can be compressed and used. Therefore, the information processing method according to the present invention is:
  • the step of setting the radix of the item value number according to the range of the item value number, and the current digit in order from the lowest digit to the highest digit of the item value number expressed in the radix Repeating the sorting process with the record number array as the current record number array and the second and subsequent times with the further record number array as the current record number array;
  • the record number array is within the range in which the value of the current digit of the item value number matches the order of the value of the current digit of the item value number. Converting each occurrence count of the value of the current digit of the assigned item value number into a cumulative number according to the order of the parts of
  • the cumulative number of the current digit values of the item value numbers corresponding to the records included in the allocated record number array portion is used as a pointer. Storing a record number included in the allocated portion of the record number array in a further record number array.
  • the sorting process for the current digit is repeated in order from the least significant digit of the item value number to the most significant digit, the sorting for the item value number is realized in accordance with the concept of radix sorting. Is done. Therefore, large-scale tabular data can be sorted in parallel in a shared memory multiprocessor system.
  • the step of converting the number of occurrences of the current digit value of the item value number into a cumulative number is executed in parallel by the second plurality of processors.
  • this step may be performed at high speed without being executed in parallel by multiple processors. This is because the processing of this step is performed sequentially, so the cache hit rate is high. Therefore, the information processing method according to the present invention includes the step of setting the radix of the item value number according to the range of the item value number, and the order from the least significant digit to the most significant digit of the item value number represented by the radix.
  • the record number array is set as the current record number array for the first time
  • the further record number array is set as the current record number array for the second and subsequent times.
  • the sorting process is
  • Dividing the current record number array and assigning it to the plurality of processors In each processor, the step of counting the number of occurrences of the value of the current digit of the item value number corresponding to the record included in the portion of the assigned record number array, and the item value number in at least one processor The current digit value of the assigned item value number according to the order of the part of the record number array within the range in which the current digit value of the item value number matches the current digit value order of Converting the number of occurrences of each into a cumulative number,
  • the allocated number is assigned by using a cumulative number of current digit values of the item value numbers corresponding to records included in the allocated record number array portion as a pointer. Storing a record number included in the portion of the record number array in a further record number array;
  • the range of the current digit of the item value number is not divided into a plurality of processors, and preferably at least one processor, preferably one processor has the current value of the item value number.
  • the number of occurrences of the digit value is converted to the cumulative number in order.
  • the sort processing related to the current digit is repeated in order from the lowest digit power of the item value number to the highest digit, so that the sort related to the item value number is realized according to the concept of the radix sort. Therefore, large-scale tabular data can be sorted in parallel on a shared memory multiprocessor system.
  • the present invention supports a record number array in which the record numbers of tabular data records are stored in a predetermined record order, and corresponds to item values of predetermined items of tabular data records.
  • a shared memory that stores an item value number array in which item value numbers to be stored are stored according to record numbers, and an item value array in which item values of tabular data are stored in accordance with the order of item value numbers corresponding to the item values ,
  • An information processing method is provided that rearranges the order of records according to the item value of a predetermined item of a record.
  • the present invention provides a record number array in which the record numbers of the tabular data records are stored according to a predetermined record order, and the item value of the predetermined item of the tabular data record.
  • An item value number array in which the item value numbers corresponding to the item values are stored according to the record number, and an item value array in which the item values of the tabular data are stored according to the order of the item value numbers corresponding to the item values are shared Memory,
  • An information processing method is provided that rearranges the order of records according to the item value of a predetermined item of a record.
  • a second aspect of the present invention is a shared memory multiprocessor system that includes a shared memory and a plurality of processors that can access the shared memory, and implements the information processing method of the present invention. It is.
  • the shared memory includes a record number array in which the record numbers of the tabular data records are stored according to a predetermined record order, and a predetermined item of the tabular data record.
  • An item value number array in which item value numbers corresponding to item values are stored according to record numbers, and item values of tabular data are ranked according to the order of item value numbers corresponding to the item values. Store the stored item value array.
  • the shared memory multiprocessor system of the present invention can use a data management mechanism based on block information.
  • Means for determining a portion of the record number array that the processor is responsible for means for counting the number of occurrences of item value numbers corresponding to records included in the portion of the record number array,
  • each processor can operate in parallel, parallelization of the count of appearance counts, parallelization of conversion to the cumulative number of occurrences, and parallelization of creation of record number arrays are realized. .
  • the cumulative number obtained by the means for converting the number of appearances of the processor responsible for the preceding range in the range of the item value number into the cumulative number is the cumulative number of occurrences of the processor responsible for the immediately following range. Referenced by means of converting to.
  • the shared memory multiprocessor system of the present invention sorts large-scale tabular data in multiple stages by introducing the concept of radix sort with respect to item value numbers.
  • the record number array is the current record number array, 2 From the first time onwards, a means to set the further record number array as the current record number array and repeat the sorting process,
  • the parallel sort processing for each digit up to the lowest digit power of the item value number up to the highest digit is executed in order.
  • the means for repeating the sorting process includes:
  • the value of the item value number in the range to be handled is in accordance with the order of the part of the record number array.
  • the record number included in the record number array portion is further used as a pointer by using the cumulative number of the current digit value of the item value number corresponding to the record included in the record number array portion as a pointer.
  • the parallel sort process for every digit of the item value number is realized.
  • the processing power count of a plurality of units, the conversion of the number of appearances to the cumulative number, and the creation of a further record number array are performed in parallel. Execute.
  • the present invention takes charge of the preceding range of the range of the current digit of the item value number.
  • the cumulative number obtained by the means for converting the number of appearances of the profiler into the cumulative number is referred to by means for converting the number of appearances of the processor responsible for the immediately following range into the cumulative number.
  • the shared memory multiprocessor system according to the present invention that sorts large-scale tabular data in multiple stages in parallel is configured to accumulate at least one, preferably at least one occurrence of each occurrence of the current digit value. It is also possible to run on a single processor. for that reason, In the shared memory multiprocessor system according to the present invention, each processor has means for setting a radix of the item value number according to the range of the item value number, and the least significant digit of the item value number expressed in the radix Set the current digit in order from the most significant digit
  • the means for repeating the sorting process of each processor includes means for determining a portion of the record number array that the processor is responsible for and a current item value number corresponding to the record included in the portion of the record number array. Means for counting the number of occurrences of a digit value;
  • the means for repeating the sorting process of at least one processor is within the range in which the value of the current digit of the item value number matches the order of the value of the current digit of the item value number.
  • the means for repeating the sorting process uses the cumulative number of values of the current digit of the item value number corresponding to the records included in the record number array portion as a pointer, Means for storing record numbers contained in the number array portion in a further record number array.
  • each processor does not need to determine the range handled by its own processor within the range of the current digit value of the item value number, and the number of appearances is counted as a cumulative number by a plurality of processors. Since it is not necessary to share the conversion process, the configuration of the shared memory multiprocessor system is simplified.
  • a storage medium recording such a program is provided.
  • FIG. 1 is a schematic diagram of an embodiment of a computer system that implements an information processing method for rearranging the record order according to the item values of predetermined items of a record according to the present invention.
  • this computer system 10 has p processors (CPUs) 12-1, 12-2,... 12- p that control the entire system and individual components by executing programs.
  • processors CPUs
  • shared memory for storing work data, for example, RAM (Random Access Memory) 14, ROM (Read Only Memory) for storing programs, etc.
  • a program according to the present embodiment for rearranging the record order according to the item value of a predetermined item of the record may be accommodated in the CD-ROM 19 and read by the CD-ROM driver 20, or the ROM 16 May be stored in advance. Alternatively, once the CD-ROM 19 is read, it may be stored in a predetermined area of the external storage medium 18. Alternatively, the program may be supplied from the outside via a network (not shown), an external terminal, and the IZF 22.
  • the shared memory multiprocessor system causes the computer system 10 to execute a program that rearranges the record order according to the item value of a predetermined item of the record. Realized.
  • FIG. 2 is a diagram showing an example of tabular data for explaining the data management mechanism.
  • This tabular data is the data management machine proposed in the above-mentioned International Publication No. WO00Z10103. By using the structure, it is stored in the computer as a data structure as shown in Fig. 3.
  • an array 301 (hereinafter, this array is abbreviated as "OrdSet") that associates the order number of each record of the tabular data with the order number of the internal data. ) Contains the sequence number of the internal data as a value for each tabular record. In this example, since all tabular data is represented as internal data, the record number of the tabular data and the order number of the internal data match.
  • the actual gender value related to the record with the order number “0”, that is, “male” or “female” is a value list 303 (hereinafter referred to as a value list) in which the actual values are sorted according to a predetermined order. It can be obtained by referring to the pointer array 302 (hereinafter abbreviated as “VNo”).
  • the pointer array 302 stores pointers that point to elements in the actual value list 303 in accordance with the order of the order numbers stored in the array OrdSet 301.
  • the item value of the gender corresponding to the record “0” in the tabular data is (1) the array OrdSet301 output takes out the sequence number “0” corresponding to the record “0”, and (2) The element “1” corresponding to the sequence number “0” is extracted from the pointer array 302. (3) From the value list 303, the element “1” indicated by the element “1” extracted from the pointer array 302 to the value list is extracted. It can be obtained by removing the “ woman”.
  • the item values can be obtained for other records as well as for age and height.
  • the tabular data is expressed by a combination of the value list VL and the pointer array VNo to the value list, and this combination is particularly referred to as an “information block”.
  • information blocks relating to gender, age and height are shown as information blocks 308, 309 and 310, respectively.
  • a plurality of processors access record data stored in the shared memory, and high-speed sorting is realized by parallel processing of the plurality of processors.
  • Figures 4A and B show the data structure to be sorted.
  • the tabular data 401 shown in Fig. 4A is an easy-to-divide representation of the data structure to be sorted in a matrix format, and includes 20 records from record 0 to record 19, each record being It consists of two items: age and region.
  • the data structure 402 shown in FIG. 4B represents the data structure stored in the shared memory 14 of the computer system 10.
  • the age information block 404 includes an item value number array (hereinafter, also referred to as VNo: value number) 406 in which item value numbers corresponding to age item values are stored in the order of record numbers, and an age item.
  • the region information block 405 includes an item value number array 408 in which item value numbers corresponding to region item values are stored in the order of record numbers, and an item number corresponding to the item value.
  • the item value array 409 is stored in accordance with the above order.
  • the p processors 12 — 1,..., 12 — p of the computer system 10 can access these data on the shared memory 14.
  • FIG. 5 is a flowchart of a parallel sorting method according to the embodiment of the present invention.
  • the number of CPUs is four and all CPUs operate in parallel.
  • the total number of CPUs in the system and the number of CPUs operating in parallel are not limited to this example.
  • the parallel sorting method consists of five steps from step 501 to step 505.
  • Step 501 Divide the record number array into four parts and assign each part to four CPUs (see Fig. 6).
  • Step 502 Each CPU counts the number of occurrences of the item value number corresponding to the record included in the allocated record number array part in parallel (FIGS. 7A, B to 9A, B). reference).
  • Step 503 Assign five values from the item value number range 0, ie, item value number 0 to item value number 4, to the four CPUs. For example, item values 0 and 1 are assigned to CPU-0, and item values 2 to 4 are assigned to CPU-1 through CPU-3 one by one (see Figure 10A).
  • Step 504 Each of the four CPUs, in the order of the item value numbers, appears within the range in which the item value numbers match, according to the order of the part of the record number array. Convert the number of times to a cumulative number (see Figures 10A and B).
  • Step 505 The four CPUs use the cumulative number of item value numbers corresponding to the records included in the allocated record number array as pointers.
  • the record number contained in the part is stored in a further record number array (see FIGS. 11A, B to 13A, B).
  • FIG. 6 is an explanatory diagram of the initialization step 501 of the parallel sorting method.
  • Four records are assigned to the four CPUs from CPU—0 to CPU—3 in order from the top of the record number array.
  • CPU-0 is responsible for the first OrdSet [0] to the fifth OrdSet [4] in the record number array (x in OrdSet [x] represents the subscript of the array OrdSet).
  • the shared memory 14 is provided with a count array Count 0, Count—1, Count—2, and Count—3 for counting the number of occurrences of the item value number, and is associated with each CPU.
  • the number of Count arrays is the same as the number of CPUs
  • the array size of Count arrays is the same as the size of VL arrays.
  • the elements of the Count array are initialized with 0.
  • FIGS. 7A and B to FIGS. 9A and 9B are explanatory diagrams of the count-up step 502 of the parallel sorting method.
  • CPU-0 reads the value 0 of OrdSet [0], reads the value 1 of VNo [0], using the read value 0 as a subscript, and reads this value 1 As a subscript, the value 0 of Count—0 [1] is incremented to 1.
  • CPU—1 reads the value 5 of OrdSet [5], reads the value 5 of the read value as a subscript, reads the value 2 of VNo [5], uses this value 2 as a subscript, and count— 1 [2 ] Value 0 is incremented to 1.
  • CPU-0 reads the value 1 of Ord Set [l], reads the value 1 of VNo [1] with the read value 1 as a subscript, and this value.
  • Count—0 [3] value 0 is incremented to 1 with 3 as a subscript.
  • CPU-1, CPU-2 and CPU-3 As shown in Fig. 8A and B and Fig. 9A, each processor reads each element of the array OrdSet that its processor is in charge of, reads the element of the array VNo using that element as a subscript, and then reads that element. The corresponding Count array element is incremented with the element as a subscript.
  • FIG. 9B a count-up result as shown in FIG. 9B is obtained.
  • B array 0111 ⁇ —0 element 0111t 0 [i] is the age corresponding to each record in the range OrdSet OrdSet [0] force OrdSet [4] Represents the number of occurrences of item value number i. For example
  • Count—0 [0] indicates that the number of occurrences of the item value number 0 in the CPU — 0 range is one, and Count — 3 [1] is the item in the CPU — 3 range Number of occurrences of value number 1 Represents power ⁇ times.
  • FIGS. 10A and 10B are explanatory diagrams of the cumulative number steps 503 and 504 of the parallel sorting method.
  • the number is accumulated in ascending order of the item value numbers corresponding to ascending sort.
  • CPU—0 is responsible for the cumulative number ⁇ of the first and second rows (ie, item value numbers 0 and 1) of the array Count
  • CP 11 1 to J? 11 3 is in charge of the cumulative number of the third to fifth rows (ie, item value numbers 3 to 5) of the array Count.
  • accumulation is done in the horizontal direction of the array count (ie, the line with the same subscript), and then the previous line is added to the subsequent line.
  • the total number of totals is determined by adding to. Side Note that the cumulative number of directions can be executed in parallel by each CPU.
  • FIG. 10B shows the order of the cumulative number ⁇ in a line in the vertical direction.
  • the row (l) Count-0: 0 represents that the count value 1 of the first element Count-0 [0] of the array Count-0 is converted to the cumulative number 0. That is,
  • FIGS. 11A and 11B to FIGS. 13A and 13B are explanatory diagrams of a transfer step 505 for storing record numbers in a further record number array.
  • each CPU reads the record number within its range from the record number array OrdSet, and then reads the item value number from the pointer array VNo using the record number as a subscript.
  • CPU—0 reads the value 0 of OrdSet [0] (ie, record number 0), then reads the value 1 of VNo [0], and then associates Is Read Count—0 [1] value 5 of Count array, set record number 0 to OrdSet [5], and increment Count—0 [1] value to 6.
  • This record number transfer process proceeds in the same manner as sub-step 2 in FIG. 11B, sub-steps 3 and 4 in FIGS. 12A and B, and sub-step 5 in FIG. 13A.
  • a further record number array OrdSet ' is obtained.
  • FIGS. 14A to 14C and FIGS. 15A and 15B are diagrams showing the results of applying the parallel sorting method according to the embodiment of the present invention to the data structure shown in FIG. 4B.
  • ascending sort was performed on the age, so the record number array OrdSet 'in the result contains records with age item values of 16, 18, 20, 21, and 23 in order of age. You can see that they are lined up. Also, the order of records with the same age is stored in the order in the original record number array OrdSet!
  • FIGS. 16A and 16B are explanatory diagrams of the cumulative number step of the parallel (descending order) sort method according to the embodiment of the present invention.
  • the cumulative number ⁇ is given priority in the horizontal direction of the array Count (that is, the row with the same subscript), and then the cumulative number of the rear row is set to the cumulative number of the preceding row. By adding to the number, the total cumulative number is determined. Note that the cumulative number in the horizontal direction can be executed in parallel by each CPU.
  • a single processor is selected for which the CPU performs the calculation of the cumulative number, and that processor is accumulated independently. Counting may be performed.
  • Fig. 16B shows the order of the cumulative number ⁇ in a vertical row. In FIG. 16B, for example, the row of (1) Count—0: 4 represents that the count value 1 of the first element Count—0 [4] of the array Count—0 is converted to the cumulative number 0.
  • FIGS. 17A and 17B to FIGS. 19A and 19B are explanatory diagrams of the transfer step 505 of the parallel sort method in descending order.
  • each CPU reads the record number within the range that it is responsible for from the record number array OrdSet, then reads the item value number from the pointer array VNo using that record number as a subscript, and then this item.
  • Using the value number as a subscript read the accumulated number from the counted count array associated with the own processor, point to the read accumulated number, and add the record number to the record number array OrdSet '. And increment the cumulative value of the Count array by one.
  • FIGS. 20A and 20B and FIGS. 21A to 21C are diagrams showing the results of applying the descending order parallel sorting method, which is useful for the embodiment of the present invention, to the data structure shown in FIG. 4B.
  • the record number array OrdSet 'in the result has records with age item values of 23, 21, 20, 18, and 16 in order of age. You can see that In addition, the order of records with the same age is stored in the original record number array OrdSet!
  • each CPU is assigned a range of target item value numbers. Item value numbers 0 and 1 are assigned to CPU-0, item value number 2 is assigned to CPU-1, item value number 3 is assigned to CPU-2, and item value number 4 is assigned to CPU-3. Therefore, if the elements of the Count array are represented in the form of Count [i] [j] as described above (i is the number of the CPU responsible for the power count, j is the item value number), the cumulative number of each CPU ⁇ 's responsibility
  • each CPU—i calculates a subtotal Sum [i] of the counts in the range
  • each CPU-i converts the Count value into a cumulative number in the assigned range, and adds the calculated total number of subtotals Aggr_sum [i] to the cumulative number of the Count value, thereby finally Accumulate the total number of counts.
  • This calculation of Count ' is also parallel processing. In this way: • CPU — 0 responsibility range (item value numbers 0 and 1)
  • Parallel sorting based on the above counting sort can be combined with the idea of radix sort.
  • the item value numbers are expressed in radix and the above parallel sorting is performed for each digit to perform efficient sorting. It is possible to realize.
  • the following describes such a multi-stage parallel sorting method.
  • the multi-stage parallel sort according to the present embodiment completes the final sort by performing the sort process for the current digit in order, starting with the least significant digit power, and finally performing the sort process for the most significant digit. To do.
  • An example of the multi-stage parallel sorting method according to the embodiment of the present invention also uses the data structure of Fig. 4B used in the above example of the parallel sorting method.
  • the number of CPUs is four, and an example in which all CPUs operate in parallel is considered. It should be noted that the total number of CPUs in the system and the number of CPUs operating in parallel are not limited to this example.
  • the item value number VNo regarding age can take a value from 0 to 4.
  • the item value number is 2 in the lower and upper digits. It is broken down into digits. Specifically, the modulo (4) value of the item value number is the lower digit value, and the quotient obtained by dividing the item value number by 4 is the upper digit value.
  • FIG. 22 is a flowchart of the multi-stage parallel sorting method that works according to the embodiment of the present invention. is there.
  • the multi-stage parallel sorting method is composed of five steps from step 2201 to step 2205.
  • the lowest digit of (in this example, the modulo (4) value of the item value number) is set to the current digit.
  • Step 2202 The current record number array is divided and assigned to four processors.
  • Step 2203 In each of the four processors, the number of occurrences of the current digit value of the item value number corresponding to the record included in the allocated record number array portion is counted.
  • Step 2204 The range of the current digit value of the item value number is divided and assigned to four processors.
  • Step 2205 In each of the four processors, in the order of the current digit value of the item value number, within the range where the current digit value of the item value number matches, the record number array According to the order of the parts, the number of occurrences of the current digit value of the assigned item value number is converted into a cumulative number.
  • Step 2206 In each of the four processors, a pointer to the total number of occurrences of the current digit value of the item value number corresponding to the record included in the allocated record number array part As a result, the record number included in the allocated record number array is stored in the further record number array.
  • Step 2207 Determine whether or not the sorting process has been performed up to the most significant digit of the item value number expressed in radix. If the sorting is performed up to the most significant digit, the multi-stage parallel sorting process is terminated. .
  • Step 2208 If an unprocessed digit remains, set that digit to the current digit, set the further record number array as the current record number array, and return to Step 2202.
  • the sort processing from step 22002 to step 2206 is the same processing as the parallel sort method of the present invention described above, and the item value Only that the value of the current digit of the field value number is used instead of the number Are different.
  • the data shown in Fig. 4B is sorted in ascending order of age using four CPUs.
  • a sorting process is set for the value of module 4 (MOD 4) of the age item value number (lower digit value).
  • MOD 4 module 4
  • DIV 4 quotient
  • initial step 2201 an array similar to the Count array shown in FIG. 6 is prepared.
  • the array in this example is an array that counts the number of occurrences of the value of the current digit of the item value number.
  • FIGS. 23A and B to FIGS. 25A and 25B are explanatory diagrams of the counting step 2203 of the first stage of the multi-stage parallel sorting method.
  • CPU-0 reads the value 0 of OrdSet [0]
  • the value 1 of modulo 4 (MOD4) is subscripted
  • the value 0 of Count—0 [1] is incremented to 1.
  • CPU—1 reads the value 5 of OrdSet [5], reads this value 5 as a subscript, reads the value 2 of VNo [5], subtracts the value 2 of MOD4 of this value 2, and count — 1 Increment the value 0 of [2] to 1. Thereafter, by executing sub-step 2 in FIG. 23B, sub-step 3 in FIG. 24A, sub-step 4 in FIG. 24B and sub-step 5 in FIG. 25A, a count-up result as shown in FIG. 25B is obtained.
  • Fig. 23A, B to Fig. 25A, B Array Count—0 element Count—0 [i] is the same?
  • 11 0 represents the number of occurrences of the value i in the lower digit of the item value number of the age corresponding to each record in the range of 0 (13 et [0] force OrdSet [4] in the array 0 361; in charge of 0
  • Count—0 [0] indicates that the value 0 of the lower digit of the item value number in the range assigned to CPU—0 is 0, and Count 3 [1] indicates CPU—3. This means that the number of occurrences of the value 1 of the lower digit of the item value number in the assigned range of is 2 times.
  • FIGS. 26A and 26B are explanatory diagrams of the cumulative number step in the first stage of the multi-stage parallel sorting method.
  • the cumulative number is calculated in ascending order of the value of the lower digit of the item value number in correspondence with the ascending sort.
  • CPU — 0 is the first row of the array Count (ie, the value 0 in the lower digit of the item value number) )
  • CPU-1 to CPU-3 are responsible for accumulating the 2nd to 4th rows of the array Count (that is, values 1 to 3 in the lower digits of the item value number), respectively. To do. As shown in Fig.
  • the cumulative number ⁇ is given priority in the horizontal direction of the array Count (that is, the row with the same subscript), and then the cumulative number of the preceding row is added to the subsequent row. By adding to the number, the total cumulative number is determined. As described above, the cumulative number in the horizontal direction may be handled by a single CPU that can execute each CPU in parallel.
  • FIGS. 27A and B to FIGS. 29A and 29B are explanatory diagrams of a transfer step of storing record numbers in a further record number array in the first stage of the multistage parallel sort method.
  • each CPU reads the record number within the range for which it is responsible from the record number array OrdSet, and then uses the record number as a subscript to insert the value of the lower digit of the item value number from the pointer array VNo.
  • FIG. 29B shows the record number array OrdSet 'obtained in the first stage as a result of such a transfer step.
  • FIG. 30 shows the assignment of the current record number array OrdSet to four CPUs in step 2202 of the second stage of the multi-stage parallel sorting method according to the embodiment of the present invention. It is a figure which shows the state which prepared the Count arrangement
  • FIGS. 31A and B to FIGS. 33A and B are explanatory diagrams of the counting step of the second stage of the multi-stage parallel sorting method.
  • CPU-0 reads the value 2 of OrdSet '[0]
  • the value 1 of the quotient (DIV4) divided by 4 is subscripted and the value 0 of Count—0 [1] is incremented to 1.
  • CPU-1 reads the value 12 of OrdSet '[5], reads this value 12 as a subscript, reads the value 4 of VNo [12], and subtracts the value 1 of DIV4 of this value 4 as a subscript.
  • Count— 1 [1] value 0 is incremented to 1.
  • the sub-step 2 in Fig. 31B and the sub-step in Fig. By executing step 3, sub-step 4 of FIG. 32B and sub-step 5 of FIG. 33A, a second-stage count-up result as shown in FIG. 33B is obtained.
  • the element Count—0 [i] of the array Count—0 is the number of each OrdSet '[0] to OrdSet [4] in the array OrdSet that the CPU—0 is responsible for. This indicates the number of occurrences of the value i in the upper digit of the age item value number corresponding to the record.
  • Count—0 [0] indicates that the number of occurrences of the value 0 in the upper digit of the item value number in the CPU_0's assigned range is 4 and Count—3 [1] is CPU-3 This means that the number of occurrences of the value 1 of the upper digit of the item value number in the assigned range is 0.
  • FIG. 34 is an explanatory diagram of the second-stage cumulative number step in the multi-stage parallel sorting method.
  • the cumulative number is calculated in ascending order of the value of the upper digit of the item value number. Since the number of values in the upper digits of the item value number has been reduced to 2 due to the multi-level key, in this example, for example, CPU-0 is responsible for the cumulative number of all values.
  • CPU—0 is Count [0] [0], Count [l] [0], Count [2] [0], Count [3] [0], Count [0] Cumulative counting is performed in the order of [l], Count [l] [l], Count [2] [l], and Count [3] [l].
  • CPU-0 and CPU-1 are assigned to the two CPUs, 0 and 1 in the upper digits of the item value number, and the two CPUs perform the cumulative number calculation. Also good.
  • FIGS. 35A and B to FIGS. 37A and B are explanatory diagrams of a transfer step of storing record numbers in a further record number array in the second stage of the multistage parallel sort method.
  • each CPU reads the record number within the range for which it is responsible from the record number array OrdSet, and then uses the record number as a subscript to set the value of the upper digit of the item value number from the pointer array VNo.
  • the accumulated number associated with the processor is read from the Count array column, and the read accumulated number is pointed to Then, the record number is stored in the record number array OrdSet "and the cumulative value of the Count array is incremented by 1.
  • Figure 37B shows the record number array OrdSet obtained in the second stage as a result of such a transfer step. "Represents.
  • the multi-stage parallel sorting method of this embodiment is composed of two stages of the lower digit and the upper digit of the item value number, no further sorting is performed. Therefore, the second stage The record number array OrdSet "obtained at the floor is the result of sorting the first record number array OrdSet in ascending order with respect to age.
  • FIGS. 38A to 38C and FIGS. 39A and B are diagrams showing the results of applying the ascending multi-stage parallel sorting method, which is useful for the embodiment of the present invention, to the data structure shown in FIG. 4B.
  • ascending order was sorted for age, so the records with the age item values of 16, 18, 20, 21, and 23 are listed in order of age in the resulting record number array OrdSet.
  • the order of the records with the same age is stored in the original record number array OrdSet, and the results are shown in Figs. This is consistent with the result of applying the ascending parallel sort method, which is useful for the embodiment of the present invention, to the data structure of FIG. 4B.
  • the multi-stage parallel sort of the present invention operates similarly in descending sort.
  • the cumulative number ⁇ operation in each stage of the multi-stage parallel sort may be processed in parallel by a plurality of processors, or at least one, preferably one.
  • the processor may process alone.
  • the above multi-stage parallel sort completes the final sort by sorting the current digit in order, starting with the least significant digit, and finally sorting the most significant digit. .
  • a data structure as shown in Fig. 40 is used.
  • the number of CPUs is one.
  • the total number of records is 20 from record number 0 to record number 19, and the field value number is 9 from 0 to 8. That is, there are nine actual age values: 15, 16, 18, 19, 20, 21, 23, 25, and 28.
  • the item value number VNo relating to age can take a value from 0 to 8.
  • the value of Euro (4) is the value of the lower digit.
  • the upper digit of the item value number can take three values, 0, 1, and 2.
  • the lower digit can take four values, 0, 1, 2, and 3.
  • Count-1 for counting the number of occurrences of the upper digits 0, 1, and 2 is prepared, and the element is initialized with 0.
  • Count-l [0] is an area for counting the number of records in which the value of the upper digit of the item value number is 0.
  • this first-stage count-up process allows the number of records with the value power ⁇ of the upper digit of the item value number to be 12 and the value of the upper digit is 1.
  • the number of records is 7, and the number of records with the value S 2 in the upper digit is 1. Further, as shown in FIG. 41D, this count value is accumulated.
  • the record number array OrdSet is converted into a further record number array OrdSet ′ using the array Aggr-1 in which the cumulative number of occurrences of the value of the upper digit of the item value number is entered.
  • FIGS. 42A and 42B are explanatory diagrams of record number transfer processing in such a multi-stage sort.
  • FIG. 42A and 42B are explanatory diagrams of record number transfer processing in such a multi-stage sort.
  • FIG. 42A shows transfer of OrdSet [0]
  • FIG. 42B shows transfer of OrdSet [19].
  • Figure 43 shows the record number array OrdSet 'as a result of the first-stage record number transfer, and the range in which the upper digit values are distributed. For example, records whose upper digit value is 0 are distributed in the range from OrdSet '[0] to OrdSet' [11] (interval 0) in the record number array OrdSet ', and the upper digit value is 1. The records are distributed in the range (Section 1) from OrdSet '[12] to Ord Set' [18] in the record number array OrdSet '.
  • Records with the upper digit value 2 are records in the record number array OrdSet' OrdSet ' [19] (Section 2).
  • the record numbers are sorted by the value of the lower digit of the item value number within each section. For example, section 1 of OrdSet 'is transferred to section 1 corresponding to OrdSet ". Since the section is already defined by the upper digit in the second stage sort, the record number is transferred outside the section. There is nothing.
  • FIG. 44 is a diagram showing an initial state of the second stage of the multistage sorting.
  • section 1 of OrdSet is explained.
  • Count—2 is an array for counting the number of occurrences of the lower digit value (0, 1, 2, 3) of the item value number in section 1.
  • FIGS. 45A to 45C are explanatory diagrams of the second stage count-up and the cumulative number ⁇ in the multi-stage sort. Counting up sequentially starting from Figure 45A yields a countup sequence as shown in Figure 45B. This count up sequence is counted as shown in FIG. 45C.
  • the computer system 10 is caused to execute a program that rearranges the record order according to the item value of a predetermined item of the record. More specifically, in the present embodiment, as described below, the program causes each CPU to execute the processing steps described above or to realize the functions described above.
  • the computer system 10 is loaded with an OS (for example, Linux (registered trademark)). Initially, a certain CPU (eg, CPU12-1) force program is loaded into memory (eg, shared memory 14) under OS control. When loaded into S-memory, if each of CPU12-1, 12-2,..., 12-p should execute the process, each CPU is controlled under OS control. Implement the specified function.
  • OS for example, Linux (registered trademark)
  • each CPU reads a predetermined processing step in the program stored in the shared memory 14 and executes the processing step.
  • a specific CPU should perform processing, other specific functions are realized on the specific CPU under the control of the OS. That is, only a specific CPU reads another predetermined processing step in the program stored in the shared memory 14, and executes the other predetermined processing step.
  • the storage location of the program executed by each CPU is not limited to the shared memory 14, but may be a local memory (not shown) associated with each CPU.
  • the program realizes a predetermined function in each CPU and, if necessary, provides a specific CPU with another predetermined function. Can be realized.
  • FIG. 1 is a schematic diagram of a computer system according to an embodiment of the present invention.
  • FIG. 2 is a diagram showing an example of tabular data for explaining the data management mechanism.
  • FIG. 3 is an explanatory diagram of a data management mechanism that works according to the embodiment of the present invention.
  • FIGS. 4A and 4B are explanatory diagrams of a data structure to be sorted, which is useful in the embodiment of the present invention.
  • FIG. 5 is a flowchart of a parallel sorting method according to an embodiment of the present invention.
  • FIG. 6 is an explanatory diagram of the initial step of the parallel sorting method that is effective in the embodiment of the present invention.
  • FIGS. 7A and 7B show count-up states of a parallel sorting method that is effective in the embodiment of the present invention. It is explanatory drawing (the 1) of a group.
  • FIGS. 8A and 8B are explanatory diagrams (part 2) of the count-up step of the parallel sorting method that is effective in the embodiment of the present invention.
  • FIGS. 9A and 9B are explanatory diagrams (part 3) of the count-up step of the parallel sorting method that is effective in the embodiment of the present invention.
  • FIG. 10A and FIG. 10B are explanatory diagrams of the total number of steps in the ascending parallel sort method useful for the embodiment of the present invention.
  • FIGS. 11A and 11B are explanatory diagrams (part 1) of the transfer step of the ascending parallel sort method that is useful for the embodiment of the present invention.
  • FIGS. 12A and 12B are explanatory diagrams (part 2) of the transfer step of the ascending parallel sort method useful for the embodiment of the present invention.
  • FIGS. 13A and 13B are explanatory diagrams (part 3) of the transfer step of the ascending parallel sort method useful for the embodiment of the present invention.
  • FIGS. 14A to 14C are diagrams (part 1) showing the results of applying the ascending parallel sort method according to the embodiment of the present invention to the data structure shown in FIG. 4B.
  • FIGS. 15A and 15B are diagrams (part 2) showing the result of applying the ascending parallel sort method according to the embodiment of the present invention to the data structure shown in FIG. 4B.
  • FIGS. 16A and 16B are explanatory diagrams of the total number of steps in the descending order parallel sorting method useful for the embodiment of the present invention.
  • FIGS. 17A and 17B are explanatory diagrams (part 1) of the transfer step of the descending order parallel sort method that is useful in the embodiment of the present invention.
  • FIGS. 18A and 18B are explanatory diagrams (part 2) of the transfer step of the descending order parallel sort method that is useful in the embodiment of the present invention.
  • FIGS. 19A and 19B are explanatory diagrams (part 3) of the transfer step of the descending order parallel sort method that is useful in the embodiment of the present invention.
  • FIGS. 20A and 20B are diagrams (part 1) showing the results of applying the descending order parallel sorting method according to the embodiment of the present invention to the data structure shown in FIG. 4B.
  • FIGS. 21A to 21C show the data structure shown in FIG. 4B according to the embodiment of the present invention. It is the figure (the 2) which shows the result which applies the parallel descending sort method which is powerful.
  • FIG. 22 is a flowchart of a multi-stage parallel sorting method according to the embodiment of the present invention.
  • FIGS. 23A and 23B are explanatory diagrams (part 1) of the count-up step of the first stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 24A and 24B are explanatory diagrams (part 2) of the count-up step in the first stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 25A and 25B are explanatory diagrams (part 3) of the count-up step in the first stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIG. 26A and FIG. 26B are explanatory diagrams of the first-stage accumulating step of the ascending order multi-stage parallel sorting method that is useful for the embodiment of the present invention.
  • FIGS. 27A and 27B are explanatory diagrams (part 1) of the transfer step in the first stage of the ascending order multi-stage parallel sort method useful for the embodiment of the present invention.
  • FIGS. 28A and 28B are explanatory diagrams (part 2) of the transfer step in the first stage of the ascending multi-stage parallel sort method that is useful for the embodiment of the present invention.
  • FIGS. 29A and 29B are explanatory diagrams (part 3) of the transfer step of the first stage of the ascending order multi-stage parallel sort method useful for the embodiment of the present invention.
  • FIG. 30 is an explanatory diagram of the initial step of the second stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 31A and 31B are explanatory diagrams (part 1) of the count-up step in the second stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 32A and 32B are explanatory diagrams (part 2) of the count-up step in the second stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 33A and 33B are explanatory diagrams (part 3) of the count-up step in the second stage of the multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIG. 34 is an explanatory diagram of the second-stage accumulating step in the ascending multi-stage parallel sorting method that is useful in the embodiment of the present invention.
  • FIGS. 35A and 35B show the ascending order of the multi-stage parallel sorting method that is useful in the embodiment of the present invention. It is explanatory drawing (the 1) of a two-step transfer step.
  • FIGS. 36A and 36B show the ascending order of the multi-stage parallel sorting method that is useful for the embodiment of the present invention.
  • FIGS. 37A and 37B are explanatory diagrams (part 3) of the second-stage transfer step of the ascending multi-stage parallel sort method useful for the embodiment of the present invention.
  • FIGS. 38A to C are views (No. 1) showing the results of applying the ascending multi-stage parallel sort method according to the embodiment of the present invention to the data structure shown in FIG. 4B. .
  • FIGS. 39A and 39B are diagrams (part 2) showing the results of applying the ascending multi-stage parallel sorting method according to the embodiment of the present invention to the data structure shown in FIG. 4B. is there.
  • FIG. 40 is a data structure diagram for explaining multi-step sorting.
  • FIGS. 41A to 41D are explanatory diagrams of the first stage count-up and the cumulative number ⁇ in the multi-stage sort.
  • FIGS. 42A and B are explanatory diagrams of the transfer of record numbers in the first stage of multi-stage sorting.
  • Figure 43 is an explanatory diagram of the result of record number transfer in the first stage of multi-stage sorting.
  • Figure 44 shows the initial state of the second stage of multi-stage sorting.
  • FIGS. 45A to 45C are explanatory diagrams of the second stage count-up and the cumulative number of keys in the multi-stage sort.
  • FIGS. 46A and 46B are explanatory diagrams of the second-stage record number transfer in the multi-stage sort. Explanation of symbols

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Computational Linguistics (AREA)
  • Computer Hardware Design (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Devices For Executing Special Programs (AREA)

Abstract

 共有メモリ上の大規模な表形式データを複数台のプロセッサで並列にソートする。本発明によれば、最初に、処理対象のレコードが分割されて複数台のプロセッサへ割り当てられる。次に、各プロセッサが処理対象のレコードに関連付けられた項目値番号のローカルな出現回数をカウントする。次に、各プロセッサでカウントされた項目値番号のローカルな出現回数を、項目値番号のグローバルな累計数、すなわち、複数台のプロセッサ間で共通に用いられる累計数に変換する。最後に、各プロセッサは、このグローバルな累計数をポインタとして利用することにより、割り当てられたレコードの順序を入れ替える。

Description

明 細 書
マルチプロセッサシステム及びその情報処理方法
技術分野
[0001] 本発明は、複数台のプロセッサがメモリを共有して並列処理を行う共有メモリ型マル チプロセッサシステムにおける情報処理方法、特に、共有メモリ上の大規模な表形式 データを複数台のプロセッサで並列にソートする情報処理方法に関する。
[0002] 本発明は、また、このような情報処理方法を実施する共有メモリ型マルチプロセッサ システムに関する。
[0003] 本発明は、さらに、このような情報処理方法を実現させるためのプログラムに関する
[0004] 本発明は、さらに、このようなプログラムを記録した記憶媒体に関する。
背景技術
[0005] 社会全体のさまざまな場所にコンピュータが導入され、インターネットをはじめとする ネットワークが浸透した今日では、そこここで、大規模データが蓄積'処理されるように なった。
[0006] 一方で、大規模データを処理するために、効率の良 、アルゴリズムが開発されて!ヽ る。大規模データ、特に、大規模な表形式データを処理する際に頻出する処理はソ ートである。効率的なソートアルゴリズムとして、基数 (RADIX)ソートとカウンティング( COUNTING)ソート(計数ソート、分布数え上げソートとも称される)が知られて 、る。 カウンティングソートは基数ソートの各桁のソートに利用されることがあり、効率の良い ァノレゴリズムであるが、その適用のためには、
1)ソート対象が整数であること
2)ソート対象となる整数の上限と下限が分力つて 、ること
3)ソート対象となる整数の上限と下限の差が、大きすぎな!/、こと
という前提条件がある。
[0007] これに対して、本発明者は、大規模な表形式データを高速に検索、集計、ソートす るために適したデータ管理機構を提案している(特許文献 1を参照)。このデータ管 理機構は、表形式データの項目の各項目値を表すための情報ブロックを有する。こ の情報ブロックでは、表形式データの項目に属する項目値は、各項目値に付与され た項目値番号と、項目値番号の順番に並べられた実際の項目値の配列とによって表 される。各レコードの項目値に対応した項目値番号をレコード番号順に並べた配列 が準備され、各レコードの項目値は、当該レコードの項目値番号に対応した値を項 目値の配列力 見つけることによって特定される。また、表形式データ中の処理対象 のレコードは、レコード番号を順番に並べた配列によって特定される。
[0008] 情報ブロックは、表形式データの各項目に対し、その項目に属する項目値が順序 付け (整数化)された項目値番号の順番に、上記項目値番号に対応した項目値が格 納されたテーブルである。項目値自体は、数値 (整数、固定小数点、浮動小数点など )、文字列などのどのようなタイプのデータでもよい。したがって、このデータ管理機構 は、あらゆるタイプのデータの値が項目値番号という整数で取り扱えることに特長があ る。すなわち、このデータ管理機構によれば、たとえば、文字列型のデータのソートを 行う際に、文字列型のデータをそのままソート対象としてソートするのではなぐ文字 列型のデータの値に対応した項目値番号をソート対象としてソートすることができる。 このとき、ソートの結果はレコード番号を順番に並べた配列によって表される。このよう に、本発明者が提案した情報ブロックに基づくデータ管理機構は、カウンティングソ ートを適用するための上記 1)から 3)の前提条件を満たしている点で優れている。
[0009] 他方で、大規模データを処理するために必要である膨大な計算を高速に実行する ため、並列処理を導入することが試みられている。ソートに関しても各種の並列ソート アルゴリズムが提案されている。一般に、並列処理アーキテクチャは「分散メモリ型」と 「共有メモリ型」に大別される。分散メモリ型は、各プロセッサがそれぞれローカルなメ モリを持ち、これらを結合してシステムを構築する。この方式では、理論的に数百〜 数万台ものプロセッサを組み込んだハードウェアシステムの設計が可能である。しか しながら、分散メモリ型は、データの分掌管理の複雑さや、プロセッサ間通信の効率 の低さなどの技術的課題がある。これに対して、共有メモリ型は複数のプロセッサが 1 つの巨大なメモリ空間を共有する方式である。この方式では、プロセッサ群と共有メモ リ間のトラフィックがボトルネックとなるので、現実的には百台を越えるプロセッサを用 V、てシステムを構築することは容易ではな 、、と考えられて 、る。
[0010] しかし、このような状況下で、近年、複数台の CPUを用いた共有メモリ型マルチプロ セッサシステムとして構成されたパーソナルコンピュータが入手可能である。この種の パーソナルコンピュータに使用される標準的な CPUは、メモリバスの 5〜6倍程度の 内部クロックで動作し、その内部に自動的な並列実行機能やパイプライン処理機能 が装備されており、およそ 1データを 1クロック (メモリバス)で処理できる。
特許文献 1:国際公開 WOOOZ10103号公報
発明の開示
発明が解決しょうとする課題
[0011] したがって、大規模な表形式データを処理するために、効率的なソートアルゴリズム と、共有メモリ型マルチプロセッサシステムとを組み合わせることが望まれる。
[0012] 効率的なソートアルゴリズムとして知られているカウンティングソートは、上記の 1)か ら 3)の前提条件によって制約されているので、本発明者が提案した上記の情報プロ ックに基づくデータ管理機構を採用しない限り、大規模な表形式データの処理に適 用することが困難である。さらに、大規模な表形式データを共有メモリ型マルチプロセ ッサシステムで並列ソートする技術は未だ知られて 、な 、。
[0013] したがって、本発明の目的は、上記情報ブロックに基づくデータ管理機構を利用し て、共有メモリ上の大規模な表形式データを複数台のプロセッサで並列にソートする ための情報処理方法を提案することである。
[0014] また、本発明の目的は、このような情報処理方法を実施する共有メモリ型マルチプ 口セッサシステムを提供することである。
[0015] さらに、本発明の目的は、このような情報処理方法を実現させるためのプログラムを 提供することである。
[0016] さらに、本発明の目的は、このようなプログラムを記録した記憶媒体を提供すること である。
課題を解決するための手段
[0017] 本発明は、表形式データの各項目に対し、その項目に属する項目値が順序付け( 整数化)された項目値番号の順番 (昇順又は降順のどちらでもよ、)に、上記項目値 番号に対応した項目値が格納されたテーブルである情報ブロックに基づくデータ管 理機構に依拠している。項目値自体は、数値 (整数、固定小数点、浮動小数点など) 、文字列などのどのようなタイプのデータでもよい。このデータ管理機構を採用するこ とにより、あらゆるタイプのデータの値が項目値番号という整数で取り扱える。すなわ ち、このデータ管理機構によれば、任意のタイプのデータのソートを行う際に、その任 意のタイプのデータをそのままソート対象としてソートするのではなぐそのデータの 値に対応した項目値番号をソート対象としてソートすることができる。したがって、この 情報ブロックに基づくデータ管理機構は、カウンティングソートを適用するための前提 条件を満たしている。また、表形式データ中の処理対象のレコードがレコード番号を 順番に並べた配列によって特定されるので、ソートの結果はレコード番号を順番に並 ベた配列によって表される。
[0018] 本発明は、このようなデータ管理機構を共有メモリ型マルチプロセッサシステムに適 用することにより、共有メモリ上の大規模な表形式データを複数台のプロセッサで並 列にソートするための情報処理方法、及び、その情報処理方法を実施する共有メモ リ型マルチプロセッサシステムを実現する。そのため、本発明によれば、最初に、処 理対象のレコードが分割されて複数台のプロセッサへ割り当てられる。次に、各プロ セッサが処理対象のレコードに関連付けられた項目値番号のローカルな出現回数を カウントする。次に、各プロセッサでカウントされた項目値番号のローカルな出現回数 を、項目値番号のグローバルな累計数、すなわち、複数台のプロセッサ間で共通に 用いられる累計数に変換する。最後に、各プロセッサは、このグローバルな累計数を ポインタとして利用することにより、割り当てられたレコードの順序を入れ替える。した がって、本発明によれば、共有メモリ型マルチプロセッサシステムにおいて、レコード のある項目の項目値 (たとえば、整数値、固定小数点数値、浮動小数点数値、文字 列など)に関してレコードを並列にソートすることが可能である。
[0019] 処理対象のレコードの複数台のプロセッサへの割り当て、ローカルな出現回数の力 ゥント、及び、割り当てられたレコードの順序の入れ替えは、複数台のプロセッサが並 列に処理可能である。また、グローバルな累計数の算出は、複数台のプロセッサの 並列処理を利用してもよいが、メモリにシーケンシャルにアクセスできるためキャッシュ へのヒット率が高いので、 1台又は一部のプロセッサだけが担当して高速性を維持で きる。
[0020] 上記の本発明の原理は以下の種々の態様によって実施される。
[0021] 本発明の第 1の態様は、共有メモリ型マルチプロセッサシステムにおいてレコードの 所定の項目の項目値に応じてレコード順を並べ換える情報処理方法である。共有メ モリ型マルチプロセッサシステムは、表形式データのレコードのレコード番号が所定 のレコード順に従って格納されたレコード番号配列、表形式データのレコードの所定 の項目の項目値に対応する項目値番号がレコード番号に従って格納された項目値 番号配列、及び、表形式データの項目値が当該項目値に対応する項目値番号の順 序に従って格納された項目値配列を記憶する共有メモリと、前記共有メモリにァクセ ス可能である複数台のプロセッサと、を具備する。本発明による情報処理方法は、 前記レコード番号配列を分割して第 1の複数台のプロセッサに割り当てるステップと 前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した項目値番号の出現回数を力 ゥントするステップと、
前記項目値番号の範囲を分割して第 2の複数台のプロセッサに割り当てるステップ と、
前記第 2の複数台のプロセッサのうちの各プロセッサにおいて、前記項目値番号の 順番に、前記項目値番号が一致する範囲内では前記レコード番号配列の部分の順 番に従って、前記割り当てられた項目値番号のそれぞれの出現回数を累計数に変 換するステップと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の累計数を ポインタとして利用して、前記割り当てられた前記レコード番号配列の部分に含まれ るレコード番号をさらなるレコード番号配列に格納するステップと、 を含む。
[0022] この情報処理方法は、項目値番号の出現回数のカウント処理の並列化、出現回数 から累計数への変換処理の並列化、及び、さらなるレコード番号配列の作成処理の 並列化を達成する。したがって、本発明は、カウンティングソートの技術を共有メモリ 型マルチプロセッサ環境に適合するように拡張することにより、大規模な表形式デー タを共有メモリ型マルチプロセッサシステムにおいて並列ソートすることが可能である
。尚、マルチプロセッサシステムを構成する複数台のプロセッサのうち、任意の第 1の 複数台のプロセッサがレコード番号配列のそれぞれの部分を担当し、任意の第 2の 複数台のプロセッサが項目値番号の範囲のそれぞれの部分を担当する。第 1の複数 台の個数と第 2の複数台の個数はマルチプロセッサシステムを構成するプロセッサの 全数でもよぐその一部でもよいことに注意する必要がある。
また、本発明の情報処理方法は、項目値番号に関して基数ソートの考え方を導入 することにより、大規模な表形式データを共有メモリ型マルチプロセッサシステムにお いて多段階で並列ソートすることが可能である。たとえば、項目値番号配列のサイズ が大き 、場合には、項目値番号配列を圧縮して利用できれば処理を効率化すること が可能である。そのため、本発明による情報処理方法は、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁に関して、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として、ソート処理を 繰り返すステップと、
を含む。これにより、最下位桁カゝら最上位桁まで順番に項目値番号の桁ごとに並列ソ ート処理が行われる。前記ソート処理は、
前記現在のレコード番号配列を分割して第 1の複数台のプロセッサに割り当てるス テツプと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の桁の値 の出現回数をカウントするステップと、
前記項目値番号の現在の桁の値の範囲を分割して第 2の複数台のプロセッサに割 り当てるステップと、 前記第 2の複数台のプロセッサのうちの各プロセッサにおいて、前記項目値番号の 現在の桁の値の順番に、前記項目値番号の現在の桁の値が一致する範囲内では前 記レコード番号配列の部分の順番に従って、前記割り当てられた項目値番号の現在 の桁の値のそれぞれの出現回数を累計数に変換するステップと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の現在の桁 の値の累計数をポインタとして利用して、前記割り当てられた前記レコード番号配列 の部分に含まれるレコード番号をさらなるレコード番号配列に格納するステップと、 を含む。
[0024] 本発明によれば、項目値番号の最下位桁カゝら最上位桁へ順番に現在の桁に関す るソート処理が繰り返されるので、基数ソートの考え方に従って項目値番号に関する ソートが実現される。したがって、大規模な表形式データを共有メモリ型マルチプロセ ッサシステムにおいて並列ソートすることが可能である。
[0025] 上記の多段階並列ソートでは、項目値番号の現在の桁の値のそれぞれの出現回 数を累計数に変換するステップは第 2の複数台のプロセッサによって並列に実行さ れる。しかし、このステップは複数台のプロセッサによって並列に実行しなくても高速 に行える場合がある。なぜならば、このステップの処理は、シーケンシャルに行われる ので、キャッシュヒット率が高いからである。そのため、本発明による情報処理方法は 前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁に関して、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として、ソート処理を 繰り返すステップと、
を含み、
前記ソート処理が、
前記現在のレコード番号配列を分割して前記複数台のプロセッサに割り当てるステ ップと、 各プロセッサにおいて、前記割り当てられたレコード番号配列の部分に含まれるレ コードに対応した項目値番号の現在の桁の値の出現回数をカウントするステップと、 少なくとも 1台のプロセッサにおいて、前記項目値番号の現在の桁の値の順番に、 前記項目値番号の現在の桁の値が一致する範囲内では前記レコード番号配列の部 分の順番に従って、前記割り当てられた項目値番号の現在の桁の値のそれぞれの 出現回数を累計数に変換するステップと、
前記各プロセッサにお 、て、前記割り当てられたレコード番号配列の部分に含まれ るレコードに対応した前記項目値番号の現在の桁の値の累計数をポインタとして利 用して、前記割り当てられた前記レコード番号配列の部分に含まれるレコード番号を さらなるレコード番号配列に格納するステップと、
を含む。
[0026] 本情報処理方法では、項目値番号の現在の桁の範囲は複数台のプロセッサに分 割されることがなぐ少なくとも 1台、好ましくは、 1台のプロセッサが、項目値番号の現 在の桁の値の出現回数を順番に累計数に変換する。この場合も、項目値番号の最 下位桁力 最上位桁へ順番に現在の桁に関するソート処理が繰り返されるので、基 数ソートの考え方に従って項目値番号に関するソートが実現される。したがって、大 規模な表形式データを共有メモリ型マルチプロセッサシステムにおいて並列ソートす ることが可能である。
[0027] また、本発明は上記目的を達成するため、表形式データのレコードのレコード番号 が所定のレコード順に従って格納されたレコード番号配列、表形式データのレコード の所定の項目の項目値に対応する項目値番号がレコード番号に従って格納された 項目値番号配列、及び、表形式データの項目値が当該項目値に対応する項目値番 号の順序に従って格納された項目値配列を記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
前記レコード番号配列を分割して前記複数台のプロセッサに割り当てるステップと、 前記複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられたレコ ード番号配列の部分に含まれるレコードの順番を当該レコードに対応した項目値番 号に応じて入れ替え、当該レコードのレコード番号をさらなるレコード番号配列に格 納するステップと、
を含む、レコードの所定の項目の項目値に応じてレコード順を並べ換える情報処理 方法を提供する。
[0028] さらに、本発明は上記目的を達成するため、表形式データのレコードのレコード番 号が所定のレコード順に従って格納されたレコード番号配列、表形式データのレコー ドの所定の項目の項目値に対応する項目値番号がレコード番号に従って格納された 項目値番号配列、及び、表形式データの項目値が当該項目値に対応する項目値番 号の順序に従って格納された項目値配列を記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の上位の桁に関して前記レコード番号配 列中のレコード番号を並べ換え、前記項目値番号の上位の桁の値の順番に区分さ れた中間的なレコード番号配列を生成するステップと、
前記中間的なレコード番号配列の区分ごとにプロセッサを割り当てるステップと、 前記区分ごとに割り当てられた各プロセッサが、前記中間的なレコード番号配列の 前記区分内のレコード番号を前記項目値番号の下位の桁の値の順番に並べ換える ステップと、
を含む、レコードの所定の項目の項目値に応じてレコード順を並べ換える情報処理 方法を提供する。
[0029] 本発明の第 2の態様は、共有メモリと前記共有メモリにアクセス可能である複数台の プロセッサとを具備し、上記の本発明の情報処理方法を実施する共有メモリ型マル チプロセッサシステムである。本発明の共有メモリ型マルチプロセッサシステムにお ヽ て、前記共有メモリは、表形式データのレコードのレコード番号が所定のレコード順に 従って格納されたレコード番号配列、表形式データのレコードの所定の項目の項目 値に対応する項目値番号がレコード番号に従って格納された項目値番号配列、及 び、表形式データの項目値が当該項目値に対応する項目値番号の順序に従って格 納された項目値配列を記憶する。これにより、本発明の共有メモリ型マルチプロセッ サシステムはブロック情報に基づくデータ管理機構を利用することができる。
[0030] 各プロセッサは、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める手段と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の出現回 数をカウントする手段と、
前記項目値番号の範囲のうち自プロセッサが受け持つ範囲を決める手段と、 前記項目値番号の順番に、前記項目値番号が一致する範囲内では前記レコード 番号配列の部分の順番に従って、前記受け持つ範囲内の項目値番号のそれぞれの 出現回数を累計数に変換する手段と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の累 計数をポインタとして利用して、前記レコード番号配列の部分に含まれるレコード番 号をさらなるレコード番号配列に格納する手段と、
を含む。
[0031] 各プロセッサは並列に動作可能であるため、出現回数のカウントの並列化、出現回 数の累計数への変換の並列化、及び、さらなるレコード番号配列の作成の並列化が 実現される。
[0032] 項目値番号の出現回数を累計数に変換する際に、得られた累計数を項目値番号 の順に伝搬させる必要がある。そのため、前記項目値番号の範囲のうち先行する範 囲を受け持つプロセッサの前記出現回数を累計数に変換する手段によって得られた 前記累計数が、直後の範囲を受け持つプロセッサの前記出現回数を累計数に変換 する手段によって参照される。
[0033] また、本発明の共有メモリ型マルチプロセッサシステムは、項目値番号に関して基 数ソートの考え方を導入することにより、大規模な表形式データを多段階で並列ソー トするため、各プロセッサが、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する手段と、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁を設定し、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として設定し、ソート 処理を繰り返す手段と、
を含む。これにより、項目値番号の最下位桁力 最上位桁までの桁ごとの並列ソート 処理が順番に実行される。さらに、前記ソート処理を繰り返す手段は、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める手段と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の 桁の値の出現回数をカウントする手段と、
前記項目値番号の現在の桁の値の範囲のうち自プロセッサが受け持つ範囲を決め る手段と、
前記項目値番号の現在の桁の値の順番に、前記項目値番号の現在の桁の値が一 致する範囲内では前記レコード番号配列の部分の順番に従って、前記受け持つ範 囲内の項目値番号の現在の桁の値のそれぞれの出現回数を累計数に変換する手 段と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の現 在の桁の値の累計数をポインタとして利用して、前記レコード番号配列の部分に含ま れるレコード番号をさらなるレコード番号配列に格納する手段と、
を含む。これにより、項目値番号の桁ごとの並列ソート処理が実現される。本発明に よれば、項目値番号の桁ごとのソート処理において、複数台のプロセッサ力 出現回 数のカウントと、出現回数の累計数への変換と、さらなるレコード番号配列の作成と、 を並列に実行する。
[0034] また、出現回数の累計数への変換を複数台のプロセッサで分担して行うため、本発 明にお 、て、前記項目値番号の現在の桁の範囲のうち先行する範囲を受け持つプ 口セッサの前記出現回数を累計数に変換する手段によって得られた前記累計数が、 直後の範囲を受け持つプロセッサの前記出現回数を累計数に変換する手段によつ て参照される。
[0035] さらに、大規模な表形式データを多段階で並列ソートする本発明による共有メモリ 型マルチプロセッサシステムは、現在の桁の値のそれぞれの出現回数の累計数化を 少なくとも 1台、好ましくは、 1台のプロセッサで実行することも可能である。そのため、 本発明による共有メモリ型マルチプロセッサシステムにおいて、各プロセッサは、前記 項目値番号の範囲に応じて前記項目値番号の基数を設定する手段と、前記基数で 表現された前記項目値番号の最下位桁から最上位桁まで順番に現在の桁を設定し
、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2回目以降はさら なるレコード番号配列を現在のレコード番号配列として設定し、ソート処理を繰り返す 手段と、を含む。
[0036] 各プロセッサの前記ソート処理を繰り返す手段は、前記レコード番号配列のうち自 プロセッサが受け持つ部分を決める手段と、前記レコード番号配列の部分に含まれ るレコードに対応した項目値番号の現在の桁の値の出現回数をカウントする手段と、 を含む。
[0037] さらに、少なくとも 1台のプロセッサの前記ソート処理を繰り返す手段は、前記項目 値番号の現在の桁の値の順番に、前記項目値番号の現在の桁の値が一致する範 囲内では前記レコード番号配列の部分の順番に従って、前記項目値番号の現在の 桁の値のそれぞれの出現回数を累計数に変換する手段を含む。
[0038] さらに、前記ソート処理を繰り返す手段は、前記レコード番号配列の部分に含まれ るレコードに対応した前記項目値番号の現在の桁の値の累計数をポインタとして利 用して、前記レコード番号配列の部分に含まれるレコード番号をさらなるレコード番号 配列に格納する手段を含む。
[0039] 本発明によれば、各プロセッサは、項目値番号の現在の桁の値の範囲のうち自プ 口セッサが受け持つ範囲を決める必要がなくなり、複数台のプロセッサで出現回数を 累計数に変換する処理を分担しなくても済むので、共有メモリ型マルチプロセッサシ ステムの構成が簡単ィ匕される。
[0040] さらに、本発明の第 3の態様によれば、このような情報処理方法を実現させるための プログラムが提供される。
[0041] さらに、本発明の第 4の態様によれば、このようなプログラムを記録した記憶媒体が 提供される。
発明の効果
[0042] 本発明によれば、共有メモリ型の並列処理環境にお!、て、大規模な表形式データ の高速並列ソートを実現可能な情報処理装置を提供することが可能となる。
発明を実施するための最良の形態
[0043] 以下、添付図面を参照して本発明の種々の実施例を説明する。
[0044] [コンピュータシステム構成]
図 1は本発明によるレコードの所定の項目の項目値に応じてレコード順を並べ換え る情報処理方法を実施するコンピュータシステムの一実施例の概略図である。図 1に 示すように、このコンピュータシステム 10は、プログラムを実行することによりシステム 全体および個々の構成部分を制御する p台のプロセッサ(CPU) 12— 1、 12- 2, . . . 12— p、ワークデータなどを記憶する共有メモリ、たとえば、 RAM(Random Access Memory) 14,プログラム等を記憶する ROM(Read Only Memory) 16,ハードディスク 等の固定記憶媒体 18、 CD— ROM19をアクセスするための CD— ROMドライバ 20 、 CD— ROMドライバ 20や外部ネットワーク(図示せず)と接続された外部端子との 間に設けられたインタフェース(IZF) 22、キーボードやマウスからなる入力装置 24、 CRT表示装置 26を備えている。 CPU12、 RAM 14, ROM16、外部記憶媒体 18、 I ZF22、入力装置 24および表示装置 26は、バス 28を介して相互に接続されている 。図示されていないが、各 CPUは固有のローカルメモリを備えていてもよい。
[0045] 本実施の形態にかかる、レコードの所定の項目の項目値に応じてレコード順を並べ 換えるプログラムは、 CD—ROM19に収容され、 CD— ROMドライバ 20に読取られ ても良いし、 ROM16に予め記憶されていても良い。また、いったん CD— ROM19 力も読み出したものを、外部記憶媒体 18の所定の領域に記憶しておいても良い。或 いは、上記プログラムは、ネットワーク(図示せず)、外部端子および IZF22を経て外 部から供給されるものであっても良い。
[0046] また、本発明の実施の形態に力かる共有メモリ型マルチプロセッサシステムは、コン ピュータシステム 10にレコードの所定の項目の項目値に応じてレコード順を並べ換 えるプログラムを実行させることにより実現される。
[0047] [情報ブロックに基づくデータ管理機構]
図 2はデータ管理機構を説明するための表形式データの一例を表す図である。こ の表形式データは、上述の国際公開第 WO00Z10103号に提案したデータ管理機 構を用いることにより、コンピュータ内では図 3に示されるようなデータ構造として記憶 される。
[0048] 図 3に示すように、表形式データの各レコードの並び順の番号と、内部データの並 び順の番号を対応付ける配列 301 (以下、この配列を「OrdSet」のように略記する。 ) には、表形式のレコード毎に内部データの並び順番号が値として配置される。この例 では、すべての表形式データが内部データとして表されるため、表形式データのレコ ード番号と内部データの並び順番号とは一致する。
[0049] 例えば、性別に関しては、表形式データのレコード 0に対応する内部データの並び 順番号は、配列 OrdSet301から「0」であることがわかる。並び順番号が「0」であるレ コードに関する実際の性別の値、即ち、「男」又は「女」は、実際の値が所定の順序に 従ってソートされた値リスト 303 (以下、値リストを「VL」のように略記する。)へのポイン タ配列 302 (以下、ポインタ配列を「VNo」のように略記する。)を参照することによって 取得できる。ポインタ配列 302は、配列 OrdSet301に格納されている並び順番号の 順に従って、実際の値リスト 303中の要素を指し示すポインタを格納している。これに より、表形式データのレコード「0」に対応する性別の項目値は、(1)配列 OrdSet301 力もレコード「0」に対応する並び順番号「0」を取り出し、(2)値リストへのポインタ配列 302から並び順番号「0」に対応する要素「1」を取り出し、(3)値リスト 303から、値リス トへのポインタ配列 302から取り出された要素「1」によって指し示される要素「女」を 取り出すことにより取得できる。
[0050] 他のレコードに対しても、また、年齢及び身長に関しても同様に項目値を取得する ことができる。
[0051] このように表形式データは、値リスト VLと、値リストへのポインタ配列 VNoの組合せに より表現され、この組合せを、特に、「情報ブロック」と称する。図 3には、性別、年齢及 び身長に関する情報ブロックがそれぞれ情報ブロック 308、 309及び 310として示さ れている。
[0052] 単一のコンピュータ力 単一のメモリ(物理的には複数であっても良いが、単一のァ ドレス空間に配置されアクセスされるという意味で単一のメモリ)であれば、当該メモリ に、順序集合の配列 OrdSet、各情報ブロックを構成する値リスト VLおよびポインタ配 列 VNoとを記憶しておけばよい。しかしながら、大量のレコードを保持するためには、 その大きさに伴ってメモリ容量も大きくなるため、これらの大量のレコードを並列処理 できるのが望ましい。
[0053] そこで、本実施の形態においては、複数台のプロセッサが共有メモリに記憶された レコードのデータにアクセスし、複数台のプロセッサの並列処理により、高速なソート を実現している。
[0054] [並列ソート]
次に、本発明の実施の形態にかかる、共有メモリ型マルチプロセッサシステムにお V、てレコードの所定の項目の項目値に応じてレコード順を並べ換える情報処理方法 、すなわち、並列ソート方法を説明する。図 4A、 Bはソート対象のデータ構造を表す 図である。図 4Aに示された表形式データ 401は、ソート対象のデータ構造を行列形 式で分力りやすく表現したものであり、レコード 0からレコード 19までの 20個のレコー ドを含み、各レコードは、年齢と地域の二つの項目により構成される。図 4Bに示され たデータ構造 402は、コンピュータシステム 10の共有メモリ 14に記憶されたデータ構 造を表している。図 4Bのレコード番号配列 (OrdSet :順序集合を表す) 403はレコード 番号 0から 19を所定の順に従って格納する配列である。本例では、レコード番号は 0 力も 19の順に格納されている。年齢と地域のデータは、それぞれ、情報ブロック 404 と情報ブロック 405の形で記憶される。年齢の情報ブロック 404は、年齢の項目値に 対応する項目値番号がレコード番号の順番に従って格納された項目値番号配列(以 下では、 VNo :値番号とも称される) 406と、年齢の項目値が当該項目値に対応する 項目値番号の順序に従って格納された項目値配列(以下では、 VL:値リストとも称さ れる) 407とにより構成される。同様に、地域の情報ブロック 405は、地域の項目値に 対応する項目値番号がレコード番号の順番に従って格納された項目値番号配列 40 8と、地域の項目値が当該項目値に対応する項目番号の順序に従って格納された項 目値配列 409とにより構成される。コンピュータシステム 10の p台のプロセッサ 12— 1 、 · · ·、 12— pは、共有メモリ 14上のこれらのデータにアクセスすることが可能である。
[0055] 図 5は、本発明の実施の形態に力かる並列ソート方法のフローチャートである。本 実施の形態では、 CPUの台数は 4台とし、すべての CPUが並列に動作する例を考 える。システム内の CPUの総数、及び、並列に動作する CPUの台数はこの例に限 定されないことに注意すべきである。また、以下では、説明の便宜上、年齢の項目に 関して、年齢の昇順にソートする場合を考える。また、年齢の項目値配列の要素は年 齢の昇順に並べられている。並列ソート方法は、ステップ 501からステップ 505の 5ス テツプにより構成される。
[0056] ステップ 501:レコード番号配列を 4分割して各部分を 4台の CPUに割り当てる(図 6を参照)。
[0057] ステップ 502 :各 CPUは、割り当てられたレコード番号配列の部分に含まれるレコ ードに対応した項目値番号の出現回数を並列的にカウントする(図 7A、 B乃至図 9A 、Bを参照)。
[0058] ステップ 503:項目値番号の範囲、すなわち、項目値番号 0から項目値番号 4まで の 5個の値を 4台の CPUに割り当てる。たとえば、 CPU— 0は項目値番号 0及び 1が 割り当てられ、 CPU— 1から CPU— 3は項目値番号 2から項目値番号 4までが一つ ずつ割り当てられる(図 10Aを参照)。
[0059] ステップ 504 :4台の CPUは、それぞれ、項目値番号の順番に、項目値番号が一致 する範囲内ではレコード番号配列の部分の順番に従って、割り当てられた項目値番 号のそれぞれの出現回数を累計数に変換する(図 10A及び Bを参照)。
[0060] ステップ 505 :4台の CPUは、割り当てられたレコード番号配列の部分に含まれるレ コードに対応した項目値番号の累計数をポインタとして利用して、割り当てられたレコ ード番号配列の部分に含まれるレコード番号をさらなるレコード番号配列に格納する (図 11A、 B乃至図 13A、 Bを参照)。
[0061] 次に各ステップを詳述する。
[0062] 図 6は並列ソート方法の初期化ステップ 501の説明図である。 CPU— 0から CPU— 3の 4台の CPUには、レコード番号配列の先頭から順番に 4レコードずつが割り当て られる。たとえば、 CPU— 0は、レコード番号配列の先頭の OrdSet[0]から 5番目の OrdSet[4]までを担当する(OrdSet[x]の xは配列 OrdSetの添字を表す)。また、 共有メモリ 14には、項目値番号の出現回数をカウントするためのカウント配列 Count 0、 Count— 1、 Count— 2及び Count— 3が設けられ、各 CPUに関連付けられる 。 Count配列の個数は CPUの数と同数であり、 Count配列の配列サイズは VL配列 のサイズと同じである。 Count配列の要素は 0で初期化される。
[0063] 図 7A、 B乃至図 9A、 Bは並列ソート方法のカウントアップステップ 502の説明図で ある。図 7Aのサブステップ 1では、たとえば、 CPU— 0は、 OrdSet[0]の値 0を読み 出し、読み出された値 0を添字として、 VNo [0]の値 1を読み出し、この値 1を添字とし て、 Count— 0[1]の値 0を 1にインクリメントする。同様に、 CPU— 1は、 OrdSet[5] の値 5を読み出し、読み出された値 5を添字として、 VNo [5]の値 2を読み出し、この 値 2を添字として、 Count— 1 [2]の値 0を 1にインクリメントする。 CPU— 2及び CPU —3についても同様である。図 7Bのサブステップ 2では、たとえば、 CPU— 0は、 Ord Set[l]の値 1を読み出し、読み出された値 1を添字として、 VNo [1]の値 3を読み出 し、この値 3を添字として、 Count— 0[3]の値 0を 1にインクリメントする。 CPU— 1、 C PU— 2及び CPU— 3についても同様である。各プロセッサは、図 8A及び B、図 9A に示されるように、自プロセッサが担当する配列 OrdSetの各要素を読み出し、その 要素を添字として、配列 VNoの要素を読み出し、さらに、その読み出された要素を添 字として対応する Count配列の要素をインクリメントする。その結果として、図 9Bに示 されるようなカウントアップ結果が得られる。図 9A、 Bの配列じ0111^—0の要素じ01111 t 0 [i]は、 CPU— 0が担当した配列 OrdSetの OrdSet [0]力 OrdSet [4]の範囲 内の各レコードに対応する年齢の項目値番号 iの出現回数を表わしている。たとえば
、 Count— 0[0]は、 CPU— 0の担当範囲内の項目値番号 0の出現回数が 1回であ ることを表し、 Count— 3 [1]は CPU— 3の担当範囲内の項目値番号 1の出現回数 力^回であることを表す。
[0064] 図 10A、 Bは並列ソート方法の累計数化ステップ 503及び 504の説明図である。本 例では、昇順ソートに対応して、項目値番号の昇順に累計数化を行う。 CPU— 0は、 配列 Countの 1行目と 2行目(すなわち、項目値番号 0と 1)の累計数ィ匕を担当し、 CP 11 1乃至じ?11 3は、それぞれ、配列 Countの 3乃至 5行目(すなわち、項目値番 号 3乃至 5)の累計数ィ匕を担当する。図 10Aに示されるように、累計数化は配列 Cou ntの横方向(すなわち、添字が一致する行)を優先して行われ、次に、先行する行の 累計数を後続する行の累計数に加算することにより、全体の累計数が決まる。尚、横 方向の累計数ィ匕は、各 CPUが並列に実行できることに注意すべきである。
[0065] 一般に、 i番目(0≤i≤p— l)の CPUである CPU—iがカウントアップした項目値番 号 j (0≤j≤q— 1)のカウント値を Count[i][j]、累計数を Count'[i][j]のように表すと、累 計数ィ匕は次のように記述できる。
Count'[0][0]=0
Count'[i][0]=Count'[i-l][q-l]+Count[i-l][q] 但し、 i〉l
Count ' [i] Q]=Count' [i] [j-l]+Count[i] [j-1] 但し、 j〉l
このように、累計数演算では、先行の行力 次の行へオフセット Count'[i-l][q-l]を 伝搬させることが必要である。したがって、本実施の形態では、累計数化の演算を C PUが分担して行っている力 1台のプロセッサを選択し、そのプロセッサが単独で累 計数化を行ってもよい。
[0066] 図 10Bは累計数ィ匕の順番を縦方向で一列に表したものである。たとえば、図 10B において、(l) Count—0 : 0の行は、配列 Count— 0の先頭の要素 Count— 0[0]の カウント値 1が累計数 0に変換されることを表している。すなわち、
1, 2, 2, 0, 2, 0, 2, 2, 0, 2, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1
というカウント値の系列を累計数ィ匕すると、
0, 1, 3, 5, 5, 7, 7, 9, 11, 11, 13, 13, 14, 15, 16, 16, 17, 18, 18, 19 になる。
[0067] 図 11A、 B乃至図 13A、 Bはレコード番号をさらなるレコード番号配列に格納する転 送ステップ 505の説明図である。転送ステップでは、各 CPUは、レコード番号配列 O rdSetから自分が担当する範囲内のレコード番号を読み出し、次に、そのレコード番 号を添字として、ポインタ配列 VNoから項目値番号を読み出し、さらに、この項目値 番号を添字として、自プロセッサに関連付けられた累計数ィ匕された Count配列から 累計数値を読み出し、この読み出された累計数値をポイントしてさらなるレコード番号 配列 OrdSet'にレコード番号を格納すると共に、 Count配列の累計数値を 1ずつィ ンクリメントする。
[0068] たとえば、図 11Aのサブステップ 1では、 CPU— 0は、 OrdSet [0]の値 0 (すなわち 、レコード番号 0)を読み出し、次に VNo [0]の値 1を読み出し、さらに、関連付けられ た Count配列の Count— 0[1]の値 5を読み出し、 OrdSet[5]にレコード番号 0を設 定すると共に、 Count— 0[1]の値を 6にインクリメントする。このレコード番号の転送 処理は、以下同様に、図 11Bのサブステップ 2、図 12A及び Bのサブステップ 3及び 4、図 13Aのサブステップ 5のように進められ、最終的に、図 13Bに示されるようなさら なるレコード番号配列 OrdSet'が得られる。
[0069] 図 14A〜C及び図 15A、 Bは、図 4Bに示されたデータ構造に対して本発明の実施 の形態に力かる並列ソート方法を適用した結果を示す図である。本例では、年齢に 関する昇順ソートを行ったので、結果のレコード番号配列 OrdSet'には、年齢の項 目値として 16歳、 18歳、 20歳、 21歳及び 23歳を有するレコードが年齢順に並んで いることがわかる。また、年齢が一致するレコードの順番は、元のレコード番号配列 O rdSet中の順番が保存されて!、る。
[0070] 上記の並列ソート方法は年齢に関する昇順ソートの例について説明している力 こ の並列ソート方法は年齢に関する降順ソートにも同様に適用できる。降順ソートは昇 順ソートと同様に行われるが、累計数ィ匕の順番が昇順ソートとは異なる。図 16A、 B は本発明の実施の形態にカゝかる並列(降順)ソート方法の累計数化ステップの説明 図である。図 16Aに示されるように、累計数ィ匕は配列 Countの横方向(すなわち、添 字が一致する行)を優先して行われ、次に、後方の行の累計数を先行する行の累計 数に加算することにより、全体の累計数が決まる。尚、横方向の累計数ィ匕は、各 CPU が並列に実行できることに注意すべきである。
[0071] 一般に、 i番目(0≤i≤p— l)の CPUである CPU—iがカウントアップした項目値番 号 j (0≤j≤q— 1)のカウント値を Count[i][j]、累計数を Count'[i][j]のように表すと、累 計数ィ匕は次のように記述できる。
Count'[p-l][0]=0
Count'[i][0]=Count'[i+l][q-l]+Count[i+l][q] 但し、 i〉l
Count ' [i] Q]=Count' [i] [j-l]+Count[i] [j-1] 但し、 j〉l
このように、累計数演算では、後方の行力 前の行へオフセット Count'[i+l][q-l]を 伝搬させることが必要である。したがって、本実施の形態では、累計数化の演算を C PUが分担して行っている力 1台のプロセッサを選択し、そのプロセッサが単独で累 計数ィ匕を行ってもよい。図 16Bは累計数ィ匕の順番を縦方向で一列に表したものであ る。図 16Bにおいて、たとえば、(1) Count— 0 :4の行は、配列 Count— 0の先頭の 要素 Count— 0[4]のカウント値 1が累計数 0に変換されることを表している。
[0072] 図 17A、 B乃至図 19A、 Bは降順の並列ソート方法の転送ステップ 505の説明図で ある。転送ステップでは、各 CPUは、レコード番号配列 OrdSetから自分が担当する 範囲内のレコード番号を読み出し、次に、そのレコード番号を添字として、ポインタ配 列 VNoから項目値番号を読み出し、さらに、この項目値番号を添字として、自プロセ ッサに関連付けられた累計数ィ匕された Count配列から累計数値を読み出し、この読 み出された累計数値をポイントしてさらなるレコード番号配列 OrdSet'にレコード番 号を格納すると共に、 Count配列の累計数値を 1ずつインクリメントする。
[0073] 図 20A、 B及び図 21A〜Cは、図 4Bに示されたデータ構造に対して本発明の実施 の形態に力かる降順の並列ソート方法を適用した結果を示す図である。本例では、 年齢に関する降順ソートを行ったので、結果のレコード番号配列 OrdSet'には、年 齢の項目値として 23歳、 21歳、 20歳、 18歳及び 16歳を有するレコードが年齢順に 並んでいることがわかる。また、年齢が一致するレコードの順番は、元のレコード番号 配列 OrdSet中の順番が保存されて!、る。
[0074] [並列累計数化演算]
次に、上記の実施例で説明した累計数化ステップ 504をさらに具体的に説明する。 図 9Bに示すようなカウント結果が得られたとき、図 10A及び Bに示されるような累計 数化が行われる。累計数ィ匕を並列に行うため、各 CPUには、対象とする項目値番号 の値の範囲が割り当てられる。 CPU— 0には項目値番号 0と 1が、 CPU— 1には項目 値番号 2が、 CPU— 2には項目値番号 3が、 CPU— 3には項目値番号 4が割り当て られる。したがって、 Count配列の要素を、上述のように Count[i][j]の形で表す (iは力 ゥントを担当した CPUの番号、 jは項目値番号を表す)と、各 CPUの累計数ィ匕の担当 範囲:
•CPU— 0の担当範囲(項目値番号 0及び 1)
Count[0][0]=l
Count[l][0]=2 Count[2][0]=2
Count[3][0]=0
Count[0][l]=2
Count[l][l]=0
Count[2][l]=2
Count[3][l]=2
•CPU— 1の担当範囲(項目値番号 2)
Count[0][2]=0
Count[l][2]=2
Count[2][2]=0
Count[3][2]=l
•CPU— 2の担当範囲(項目値番号 3)
Count[0][3]=l
Count[l][3]=l
Count[2][3]=0
Count[3][3]=l
•CPU— 3の担当範囲(項目値番号 4)
Count[0][4]=l
Count[l][4]=0
Count[2][4]=l
Count[3][4]=l
が得られる。
このような担当範囲が決まると、最初に、各 CPU— iが担当範囲内のカウントの小計 Sum[i]を計算すると、
Sum[0]=ll
Sum[l]=3
Sum[2]=3
Sum[3]=3 が得られる。この小計の計算は並列処理である。
[0076] 次に、この小計を CPU— 0から CPU— 3へ順番に伝搬させて、小計の累計数 Aggr_ sum[i]を計算すると、
Aggr_sum[0]=0
Aggr_sum[lJ=Aggr_sum[OJ+Sum[OJ=ll
Aggr_sum[2]=Aggr_sum[lJ+Sum[l]=14
Aggr_sum[3]=Aggr_sum[2]+Sum[2]=17
が得られる。小計の累計数は先頭が 0になるように定義される。
[0077] 最後に、各 CPU— iは、担当範囲で Count値を累計数に変換し、算出された小計の 累計数 Aggr_sum[i]をその Count値の累計数に加算することにより、最終的なカウント の累計数 Count'を得る。この Count'の計算も並列処理である。これにより、 •CPU— 0の担当範囲(項目値番号 0及び 1)
Count'[0][0]=0+Aggr_sum[0]=0+0=0
Count'[l][0]=Count'[0][0]+Count[0][0]=0+l=l
Count'[2][0]=Count'[l][0]+Count[l][0]=l+2=3
Count'[3][0]=Count'[2][0]+Count[2][0]=3+2=5
Count'[0][l]=Count'[3][0]+Count[3][0]=5+0=5
Count'[l][l]=Count'[0][l]+Count[0][l]=5+2=7
Count'[2][l]=Count'[l][l]+Count[l][l]=7+0=7
Count'[3][l]=Count'[2][l]+Count[2][l]=7+2=9
•CPU- 1の担当範囲(項目値番号 2)
Count'[0][2]=0+Aggr_sum[l]=9+2=11
Count'[l][2]=Count'[0][2]+Count[0][2]=l 1+0=11
Count'[2][2]=Count'[l][2]+Count[l][2]=ll+2=13
Count'[3][2]=Count'[2][2]+Count[2][2]=13+0=13
•CPU— 2の担当範囲(項目値番号 3)
Count ' [0][3]=0+Aggr—sum[2]=0+ 14= 1
Count'[l][3]=Count'[0][3]+Count[0][3]=14+l=15 Count'[2][3]=Count'[l][3]+Count[l][3]=15+l=16
Count ' [3][3]=Count, [2] [3]+Count[2] [3]=16+0=16
•CPU— 3の担当範囲(項目値番号 4)
Count'[0][4]=0+Aggr_sum[3]=0+17=17
Count'[l][4]=Count'[0][4]+Count[0][4]=17+l=18
Count'[2][4]=Count'[l][4]+Count[l][4]=18+0=18
Count'[3][4]=Count'[2][4]+Count[2][4]=18+l=19
が得られる。
[0078] この結果は図 10Bに示された累計数ィ匕の結果と一致している。
[0079] [多段階並列ソート]
上記のカウンティングソートに基づく並列ソートは基数ソートの考え方と組み合わせ ることが可能である。項目値配列 VLのサイズが大きいとき、すなわち、項目値番号の 個数が多数であるときには、項目値番号を基数で表現し、桁ごとに上記の並列ソート を実施することにより、効率的なソートを実現することが可能である。以下では、このよ うな多段階並列ソート方法について説明する。特に、本実施の形態にかかる多段階 並列ソートは、最下位の桁力 始めて順番に現在の桁に関するソート処理を行い、最 後に最上位の桁に関するソート処理を行うことによって最終的なソートを完了する。
[0080] 本発明の実施にかかる多段階並列ソート方法の一例でも、上記の並列ソート方法 の例で使用した図 4Bのデータ構造を利用する。本実施の形態では、 CPUの台数は 4台とし、すべての CPUが並列に動作する例を考える。システム内の CPUの総数、 及び、並列に動作する CPUの台数はこの例に限定されな 、ことに注意すべきである 。また、以下では、説明の便宜上、年齢の項目に関して、年齢の昇順にソートする場 合を考える。また、年齢の項目値配列の要素は年齢の昇順に並べられている。図 4B のデータ構造では、年齢に関する項目値番号 VNoは 0から 4までの値を取り得るの で、基数 =4として項目値番号を分解すると、項目値番号は下の桁と上の桁の 2桁に 分解される。具体的には、項目値番号のモジュロ (4)の値が下の桁の値であり、項目 値番号を 4で割った商が上の桁の値である。
[0081] 図 22は、本発明の実施の形態に力かる多段階並列ソート方法のフローチャートで ある。多段階並列ソート方法は、ステップ 2201からステップ 2205の 5ステップにより 構成される。
[0082] ステップ 2201:項目値番号の範囲に応じて項目値番号の基数 (本例では基数 =4 )を選択し、初期のレコード番号配列 OrdSetを現在のレコード番号配列に設定し、 項目値番号の最下位の桁 (本例では項目値番号のモジュロ(4)の値)を現在の桁に 設定する。
[0083] ステップ 2202:現在のレコード番号配列を分割して 4台のプロセッサに割り当てる。
[0084] ステップ 2203 :4台のプロセッサのうちの各プロセッサにおいて、割り当てられたレ コード番号配列の部分に含まれるレコードに対応した項目値番号の現在の桁の値の 出現回数をカウントする。
[0085] ステップ 2204:項目値番号の現在の桁の値の範囲を分割して 4台のプロセッサに 割り当てる。
[0086] ステップ 2205 :4台のプロセッサのうちの各プロセッサにおいて、項目値番号の現 在の桁の値の順番に、項目値番号の現在の桁の値が一致する範囲内ではレコード 番号配列の部分の順番に従って、割り当てられた項目値番号の現在の桁の値のそ れぞれの出現回数を累計数に変換する。
[0087] ステップ 2206 :4台のプロセッサのうちの各プロセッサにおいて、割り当てられたレ コード番号配列の部分に含まれるレコードに対応した項目値番号の現在の桁の値の 出現回数の累計数をポインタとして利用して、割り当てられたレコード番号配列の部 分に含まれるレコード番号をさらなるレコード番号配列に格納する。
[0088] ステップ 2207:基数で表現された項目値番号の最上位桁までソート処理が行われ た力どうかを判定し、最上位桁までソートされているならば、多段階並列ソート処理を 終了する。
[0089] ステップ 2208 :未処理の桁が残っているならば、その桁を現在の桁に設定し、さら なるレコード番号配列を現在のレコード番号配列として、ステップ 2202へ戻る。
[0090] 上記の本発明の実施の形態に力かる多段階並列ソート方法において、ステップ 22 02からステップ 2206までのソート処理は、上記の本発明の並列ソート方法と同様の 処理であり、項目値番号の代わりに項目値番号の現在の桁の値が使用される点だけ が異なっている。
[0091] 次に、本発明の実施の形態に力かる多段階並列ソート方法を具体的に説明する。
本例では、図 4Bに示されたデータを、 4台の CPUを使用し、年齢の昇順でソートす る。初期ィ匕ステップ 2201は、 1段階目のソート処理として、年齢の項目値番号のモジ ュロー 4 (MOD 4)の値(下位の桁の値)に関するソート処理を設定し、 2段階目のソ ート処理として、年齢の項目値番号の 4で割った商(DIV 4)の値に関するソート処 理を設定する。
[0092] 初期ィ匕ステップ 2201では、図 6に示された Count配列と同様の配列が準備される 。但し、本例の配列は、項目値番号の現在の桁の値の出現回数をカウントする配列 である。
[0093] 図 23A、 B乃至図 25A、 Bは、多段階並列ソート方法の第 1段階のカウントステップ 2203の説明図である。図 23Aのサブステップ 1では、たとえば、 CPU— 0は、 OrdS et[0]の値 0を読み出し、読み出された値 0を添字として、 VNo[0]の値 1を読み出し 、この値 1のモジュロ一 4 (MOD4)の値 1を添字として、 Count— 0[1]の値 0を 1にィ ンクリメントする。同様に、 CPU— 1は、 OrdSet[5]の値 5を読み出し、この値 5を添 字として、 VNo [5]の値 2を読み出し、この値 2の MOD4の値 2を添字として、 Count —1 [2]の値 0を 1にインクリメントする。以下、図 23Bのサブステップ 2、図 24Aのサブ ステップ 3、図 24Bのサブステップ 4及び図 25Aのサブステップ 5を実行することにより 、図 25Bに示されるようなカウントアップ結果が得られる。図 23A、 B〜図 25A、 Bの 配列 Count— 0の要素 Count— 0[i]は、じ?11 0が担当した配列0 361;の0 (13 et [0]力 OrdSet [4]の範囲内の各レコードに対応する年齢の項目値番号の下位 の桁の値 iの出現回数を表わしている。たとえば、 Count— 0[0]は、 CPU— 0の担当 範囲内の項目値番号の下位の桁の値 0の出現回数が 1回であることを表し、 Count 3 [1]は CPU— 3の担当範囲内の項目値番号の下位の桁の値 1の出現回数が 2 回であることを表す。
[0094] 図 26A、Bは多段階並列ソート方法の第 1段階の累計数化ステップの説明図である 。本例では、昇順ソートに対応して、項目値番号の下位の桁の値の昇順に累計数ィ匕 を行う。 CPU— 0は、配列 Countの 1行目(すなわち、項目値番号の下位の桁の値 0 )の累計数化を担当し、 CPU— 1乃至 CPU— 3は、それぞれ、配列 Countの 2乃至 4 行目(すなわち、項目値番号の下位の桁の値 1乃至 3)の累計数化を担当する。図 2 6Aに示されるように、累計数ィ匕は配列 Countの横方向(すなわち、添字が一致する 行)を優先して行われ、次に、先行する行の累計数を後続する行の累計数に加算す ることにより、全体の累計数が決まる。尚、横方向の累計数ィ匕は、既に説明したように 各 CPUが並列に実行可能である力 単一の CPUが担当してもよい。
[0095] 図 27A、 B乃至図 29A、 Bは多段階並列ソート方法の第 1段階においてレコード番 号をさらなるレコード番号配列に格納する転送ステップの説明図である。転送ステツ プでは、各 CPUは、レコード番号配列 OrdSetから自分が担当する範囲内のレコー ド番号を読み出し、次に、そのレコード番号を添字として、ポインタ配列 VNoから項目 値番号の下位の桁の値を読み出し、さらに、この項目値番号の下位の桁の値を添字 として、自プロセッサに関連付けられた累計数ィ匕された Count配列カゝら累計数値を 読み出し、この読み出された累計数値をポイントしてさらなるレコード番号配列 OrdS et'にレコード番号を格納すると共に、 Count配列の累計数値を 1ずつインクリメント する。図 29Bはこのような転送ステップの結果として第 1段階で得られたレコード番号 配列 OrdSet'を表す。
[0096] 第 2段階では、第 1段階で得られたレコード番号配列 OrdSet'を初期条件として、 年齢の項目値番号の上位の桁の値 (DIV 4の値)に関する昇順ソートを実行する。
[0097] 図 30は、本発明の実施の形態に力かる多段階並列ソート方法の第 2段階のステツ プ 2202において、現在のレコード番号配列 OrdSet,を 4台の CPUに割り当て、それ ぞれの Count配列を準備した状態を示す図である。
[0098] 図 31A、 B乃至図 33A、 Bは、多段階並列ソート方法の第 2段階のカウントステップ の説明図である。図 31Aのサブステップ 1では、たとえば、 CPU— 0は、 OrdSet' [0 ]の値 2を読み出し、読み出された値 2を添字として、 VNo [2]の値 4を読み出し、この 値 1の 4で割った商(DIV4)の値 1を添字として、 Count— 0[1]の値 0を 1にインクリメ ントする。同様に、 CPU— 1は、 OrdSet' [5]の値 12を読み出し、この値 12を添字と して、 VNo [12]の値 4を読み出し、この値 4の DIV4の値 1を添字として、 Count— 1 [1]の値 0を 1にインクリメントする。以下、図 31Bのサブステップ 2、図 32Aのサブス テツプ 3、図 32Bのサブステップ 4及び図 33Aのサブステップ 5を実行することにより、 図 33Bに示されるような第 2段階のカウントアップ結果が得られる。図 31A、 B〜33A 、 Bにおいて、配列 Count— 0の要素 Count— 0[i]は、 CPU— 0が担当した配列 Or dSet,の OrdSet' [0]から OrdSet[4]の範囲内の各レコードに対応する年齢の項 目値番号の上位の桁の値 iの出現回数を表わしている。たとえば、 Count—0[0]は 、 CPU— 0の担当範囲内の項目値番号の上位の桁の値 0の出現回数が 4回であるこ とを表し、 Count— 3 [1]は CPU— 3の担当範囲内の項目値番号の上位の桁の値 1 の出現回数が 0回であることを表す。
[0099] 図 34は多段階並列ソート方法の第 2段階の累計数化ステップの説明図である。本 例では、昇順ソートに対応して、項目値番号の上位の桁の値の昇順に累計数ィ匕を行 う。多段階ィ匕によって項目値番号の上位の桁の値の個数は 2個に削減されているの で、本例では、たとえば、 CPU— 0がすべての値の累計数ィ匕を担当する。図 34Aに 示されるように、 CPU— 0は、 Count[0][0]、 Count[l][0]、 Count[2][0]、 Count[3][0]、 C ount[0][l]、 Count[l][l]、 Count[2][l]、及び、 Count[3][l]の順に累計数化を行う。勿 論、本例の場合に、 CPU— 0と CPU— 1の 2台の CPUに項目値番号の上位の桁の 値 0と 1を割り当て、 2台の CPUが累計数ィ匕演算を行ってもよい。
[0100] 図 35A、 B乃至図 37A、 Bは多段階並列ソート方法の第 2段階においてレコード番 号をさらなるレコード番号配列に格納する転送ステップの説明図である。転送ステツ プでは、各 CPUは、レコード番号配列 OrdSetから自分が担当する範囲内のレコー ド番号を読み出し、次に、そのレコード番号を添字として、ポインタ配列 VNoから項目 値番号の上位の桁の値を読み出し、さらに、この項目値番号の上位の桁の値を添字 として、自プロセッサに関連付けられた累計数ィ匕された Count配列カゝら累計数値を 読み出し、この読み出された累計数値をポイントしてさらなるレコード番号配列 OrdS et"にレコード番号を格納すると共に、 Count配列の累計数値を 1ずつインクリメント する。図 37Bはこのような転送ステップの結果として第 2段階で得られたレコード番号 配列 OrdSet"を表す。
[0101] 本実施例の多段階並列ソート方法は項目値番号の下位の桁と上位の桁の 2段階 により構成されているので、これ以上のソート処理は行われない。したがって、第 2段 階で得られたレコード番号配列 OrdSet"が最初のレコード番号配列 OrdSetを年齢 に関して昇順にソートを行った結果である。
[0102] 図 38A〜C及び図 39A、 Bは、図 4Bに示されたデータ構造に対して本発明の実施 の形態に力かる昇順の多段階並列ソート方法を適用した結果を示す図である。本例 では、年齢に関する昇順ソートを行ったので、結果のレコード番号配列 OrdSet"に は、年齢の項目値として 16歳、 18歳、 20歳、 21歳及び 23歳を有するレコードが年 齢順に並んでいることがわかる。また、年齢が一致するレコードの順番は、元のレコー ド番号配列 OrdSet中の順番が保存されている。この結果は、図 14A〜C及び図 15 A、Bに示された本発明の実施の形態に力かる昇順の並列ソート方法を図 4Bのデー タ構造に適用した結果と一致している。
[0103] また、上記の多段階並列ソート方法は昇順ソートであるが、本発明の多段階並列ソ ートは降順ソートでも同様に動作する。さらに、既に説明したように、多段階並列ソー トの各段階における累計数ィ匕演算は、複数台のプロセッサで並列処理してもよぐ或 いは、少なくとも 1台、好ましくは、 1台のプロセッサが単独で処理してもよい。
[0104] [多段階ソート]
上記の多段階並列ソートは、最下位の桁力も始めて順番に現在の桁に関するソー ト処理を行い、最後に最上位の桁に関するソート処理を行うことによって最終的なソ ートを完了している。これに対して、最上位の桁力も始めて順番に現在の桁に関する ソート処理を行い、最後に最下位の桁に関するソート処理を行うことによって最終的 なソートを完了することも可能である。以下では、このような最上位力も最下位の順に ソート処理を多段化する方法を簡単に説明する。
[0105] 本例では、図 40に示されるようなデータ構造を利用する。また、本例では、 CPUの 台数は 1台とする。また、以下では、年齢の項目に関して、年齢の昇順にソートする 場合を考える。レコードの総数はレコード番号 0からレコード番号 19までの 20個であ り、項目値番号は 0から 8までの 9個である。すなわち、実際の年齢の値は、 15、 16、 18、 19、 20、 21、 23、 25及び 28の 9通りである。図 40のデータ構造では、年齢に 関する項目値番号 VNoは 0から 8までの値を取り得るので、基数 =4として項目値番 号を分解すると、項目値番号を 4で割った商が上の桁の値であり、項目値番号のモジ ュロ(4)の値が下の桁の値である。項目値番号の上の桁は 0、 1及び 2の 3通りの値を 取り、下の桁は 0、 1、 2及び 3の 4通りの値を取り得る。
[0106] 最初に、第 1段階において、上の桁の値 0、 1及び 2の出現回数をカウントするため の配列 Count— 1を準備し、要素を 0で初期化する。たとえば、 Count-l[0]は、項目 値番号の上位の桁の値が 0であるレコードの個数をカウントするための領域である。
[0107] 次に、レコード番号配列 OrdSetの先頭の要素(すなわち、レコード)力 順番に、 その要素に対応する項目値番号を配列 VNoから読み出し、その項目値番号を 4で 割った商の値をポインタとして用いて、配列 Count— 1の要素の値をインクリメントす る。図 41A〜Dは、 OrdSet[0] =0、 OrdSet [7] = 7,及び、 OrdSet[19] = 19の 3 個のレコード番号について、項目値番号の上位の桁の値を算出し、該当するカウン タをカウントアップし、次に累計数ィ匕する例の説明図である。図 41C力もわ力るように 、この第 1段階のカウントアップ処理により、項目値番号の上位の桁の値力^であるレ コードの個数は 12個、上位の桁の値が 1であるレコードの個数は 7個、上位の桁の値 力 S 2であるレコードの個数は 1個である。さらに、図 41Dに示されるように、このカウント 値を累計数化する。
[0108] 次に、項目値番号の上位の桁の値の出現回数が累計数ィ匕された配列 Aggr— 1を 用いて、レコード番号配列 OrdSetをさらなるレコード番号配列 OrdSet'に変換する 。具体的には、 OrdSet [i] =jであるならば、 VNo [j]を読み出し、この VNo [j]を 4で 割った商 (VNo [j] DIV 4)を kとすると、 Aggr— l [k]の値を読み出し、 OrdSet[A ggr— 1 [k] ]にレコード番号 jを設定し、 Aggr- 1 [k]をインクリメントする。図 42A、 B は、このような多段階ソートにおけるレコード番号転送処理の説明図であり、図 42A は OrdSet [0]の転送を、図 42Bは OrdSet [19]の転送を表している。図 43は、第 1 段階のレコード番号転送の結果のレコード番号配列 OrdSet'と、上位の桁の値が分 布する範囲とを表している。たとえば、上位の桁の値が 0であるレコードはレコード番 号配列 OrdSet'の OrdSet' [0]から OrdSet' [11]の範囲(区間 0)に分布し、上位 の桁の値が 1であるレコードはレコード番号配列 OrdSet'の OrdSet' [12]から Ord Set' [18]の範囲(区間 1)に分布し、上位の桁の値が 2であるレコードはレコード番 号配列 OrdSet'の OrdSet' [19] (区間 2)に存在する。 [0109] 次に、多段階ソートの第 2段階では、各区間内で、項目値番号の下位の桁の値によ つてレコード番号をソートする。たとえば、 OrdSet'の区間 1は、 OrdSet"の対応した 区間 1へ転送される。第 2段階のソートでは、既に上位の桁で区間が定められている ので、レコード番号が区間外に転送されることはない。
[0110] 図 44は、多段階ソートの第 2段階の初期状態を表す図である。以下の説明では、 O rdSet'の区間 1について説明する。たとえば、複数台のプロセッサが存在する場合 には、区間ごとにプロセッサを割り当てることにより、以下の処理を並列化することも可 能である。 Count— 2は区間 1内で項目値番号の下位の桁の値(0, 1, 2, 3)の出現 回数をカウントするための配列である。
[0111] 図 45A〜Cは、多段階ソートの第 2段階のカウントアップ及び累計数ィ匕の説明図で ある。図 45Aから始めて順番にカウントアップすることにより、図 45Bに示されるような カウントアップ配列が得られる。このカウントアップ配列は、図 45Cに示されるように累 計数化される。
[0112] 最後に、第 2の累計数配列 Aggr— 2をポインタとして利用して、レコード番号配列 O rdSet,の区間 1をレコード番号配列 OrdSet"の区間 1へ転送することにより、多段階 ソートが完了する。図 46A、 Bは、多段階ソートの第 2段階のレコード番号転送の説明 図である。具体的には、 OrdSet' [i] =jであるならば、 VNo [j]を読み出し、この VN o [j]を 4で割った余り(VNo [j] MOD 4)を kとすると、 Aggr— 2 [k]の値を読み出 し、 OrdSet" [Aggr— 2 [k] ]にレコード番号 jを設定し、 Aggr— 2 [k]をインクリメント する。図 46Aは OrdSet' [14]の転送を、図 46Bは OrdSet' [18]の転送を表してい る。図 46Bの OrdSet"の区間 1は、区間 1の最終的なソート結果を表している。
[0113] 区間 1と同様に、その他の区間 0、区間 2についても第 2段階のカウントアップ、累計 数化、及び、レコード番号転送を適用することにより、レコード番号配列 OrdSetの全 体がレコード番号配列 OrdSet"へ転送され、ソートが完了する。
[0114] 前述したように、本発明の実施の形態においては、コンピュータシステム 10にレコ ードの所定の項目の項目値に応じてレコード順を並べ替えるプログラムを実行させる 。より具体的には、本実施の形態においては、以下のように、プログラムは、各 CPU に、上述した処理ステップを実行させ、或いは、上述した機能を実現させる。 [0115] 本実施の形態において、コンピュータシステム 10には、 OS (たとえば、リナックス(L inux:登録商標))が搭載される。初期的には、 OSの制御にしたがって、ある CPU ( たとえば、 CPU12- 1)力 プログラムをメモリ(たとえば共有メモリ 14)にロードする。 プログラム力 Sメモリにロードされると、 CPU12— 1、 12- 2, . . .、 12— pの各々が処 理を実行すべき場合には、 OSの制御の下、各 CPUに、それぞれ、所定の機能を実 現させる。つまり、各 CPUが、共有メモリ 14に記憶されたプログラム中の所定の処理 ステップを読み出し、当該処理ステップを実行する。その一方、特定の CPUが処理 をすべき場合には、 OSの制御の下、当該特定の CPUに、他の所定の機能を実現さ せる。つまり、特定の CPUのみ力 共有メモリ 14に記憶されたプログラム中の他の所 定の処理ステップを読み出し、当該他の所定の処理ステップを実行する。なお、各 C PUが実行するプログラムの格納場所は、上記共有メモリ 14に限定されず、各 CPU に付随するそれぞれのローカルメモリ(図示せず)でもよ 、。
[0116] このように、本実施の形態においては、 OSの制御の下、プログラムは、各 CPUに 所定の機能を実現させるとともに、必要に応じて、特定の CPUに、他の所定の機能 を実現させることができる。
[0117] 本発明は、以上の実施の形態に限定されることなぐ特許請求の範囲に記載された 発明の範囲内で、種々の変更が可能であり、それらも本発明の範囲内に包含される ものであることは言うまでもない。
図面の簡単な説明
[0118] [図 1]図 1は本発明の実施の形態に力かるコンピュータシステムの概要図である。
[図 2]図 2はデータ管理機構を説明するための表形式データの一例を表す図である。
[図 3]図 3は本発明の実施の形態に力かるデータ管理機構の説明図である。
[図 4]図 4A、Bは本発明の実施の形態に力かるソート対象のデータ構造の説明図で ある。
[図 5]図 5は本発明の実施の形態に力かる並列ソート方法のフローチャートである。
[図 6]図 6は本発明の実施の形態に力かる並列ソート方法の初期ィ匕ステップの説明図 である。
[図 7]図 7A、Bは本発明の実施の形態に力かる並列ソート方法のカウントアップステツ プの説明図(その 1)である。
[図 8]図 8A、Bは本発明の実施の形態に力かる並列ソート方法のカウントアップステツ プの説明図(その 2)である。
[図 9]図 9A、Bは本発明の実施の形態に力かる並列ソート方法のカウントアップステツ プの説明図(その 3)である。
[図 10]図 10A、Bは本発明の実施の形態に力かる昇順の並列ソート方法の累計数ィ匕 ステップの説明図である。
[図 11]図 11A、Bは本発明の実施の形態に力かる昇順の並列ソート方法の転送ステ ップの説明図(その 1)である。
[図 12]図 12A、Bは本発明の実施の形態に力かる昇順の並列ソート方法の転送ステ ップの説明図(その 2)である。
[図 13]図 13A、Bは本発明の実施の形態に力かる昇順の並列ソート方法の転送ステ ップの説明図(その 3)である。
[図 14]図 14A〜Cは、図 4Bに示されたデータ構造に対して本発明の実施の形態に 力かる昇順の並列ソート方法を適用した結果を示す図(その 1)である。
[図 15]図 15A、 Bは、図 4Bに示されたデータ構造に対して本発明の実施の形態にか 力る昇順の並列ソート方法を適用した結果を示す図(その 2)である。
圆 16]図 16A、Bは本発明の実施の形態に力かる降順の並列ソート方法の累計数ィ匕 ステップの説明図である。
圆 17]図 17A、Bは本発明の実施の形態に力かる降順の並列ソート方法の転送ステ ップの説明図(その 1)である。
[図 18]図 18A、Bは本発明の実施の形態に力かる降順の並列ソート方法の転送ステ ップの説明図(その 2)である。
[図 19]図 19A、Bは本発明の実施の形態に力かる降順の並列ソート方法の転送ステ ップの説明図(その 3)である。
[図 20]図 20A、 Bは、図 4Bに示されたデータ構造に対して本発明の実施の形態にか かる降順の並列ソート方法を適用した結果を示す図(その 1)である。
[図 21]図 21A〜Cは、図 4Bに示されたデータ構造に対して本発明の実施の形態に 力かる降順の並列ソート方法を適用した結果を示す図(その 2)である。
圆 22]図 22は本発明の実施の形態に力かる多段階並列ソート方法のフローチャート である。
圆 23]図 23A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 1段階 のカウントアップステップの説明図(その 1)である。
圆 24]図 24A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 1段階 のカウントアップステップの説明図(その 2)である。
圆 25]図 25A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 1段階 のカウントアップステップの説明図(その 3)である。
圆 26]図 26A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 1段階の累計数化ステップの説明図である。
圆 27]図 27A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 1段階の転送ステップの説明図(その 1)である。
圆 28]図 28A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 1段階の転送ステップの説明図(その 2)である。
圆 29]図 29A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 1段階の転送ステップの説明図(その 3)である。
圆 30]図 30は本発明の実施の形態に力かる多段階並列ソート方法の第 2段階の初 期ィ匕ステップの説明図である。
圆 31]図 31A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 2段階 のカウントアップステップの説明図(その 1)である。
圆 32]図 32A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 2段階 のカウントアップステップの説明図(その 2)である。
圆 33]図 33A、Bは本発明の実施の形態に力かる多段階並列ソート方法の第 2段階 のカウントアップステップの説明図(その 3)である。
圆 34]図 34は本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 2段 階の累計数化ステップの説明図である。
圆 35]図 35A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 2段階の転送ステップの説明図(その 1)である。
圆 36]図 36A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第
2段階の転送ステップの説明図(その 2)である。
圆 37]図 37A、Bは本発明の実施の形態に力かる昇順の多段階並列ソート方法の第 2段階の転送ステップの説明図(その 3)である。
[図 38]図 38A〜Cは、図 4Bに示されたデータ構造に対して本発明の実施の形態に 力かる昇順の多段階並列ソート方法を適用した結果を示す図(その 1)である。
[図 39]図 39A、 Bは、図 4Bに示されたデータ構造に対して本発明の実施の形態にか 力る昇順の多段階並列ソート方法を適用した結果を示す図 (その 2)である。
圆 40]図 40は多段階ソートを説明するためのデータ構造図である。
圆 41]図 41A〜Dは多段階ソートの第 1段階のカウントアップ及び累計数ィ匕の説明 図である。
圆 42]図 42A、Bは多段階ソートの第 1段階のレコード番号転送の説明図である。 圆 43]図 43は多段階ソートの第 1段階のレコード番号転送の結果の説明図である。 圆 44]図 44は多段階ソートの第 2段階の初期状態を表す図である。
圆 45]図 45A〜Cは多段階ソートの第 2段階のカウントアップ及び累計数ィ匕の説明図 である。
圆 46]図 46A、Bは多段階ソートの第 2段階のレコード番号転送の説明図である。 符号の説明
コンピュータシステム
12- 1, 12- 2, · · · , 12-p
14 共有メモリ
16 ROM
18 固定記憶装置
20 CD— ROMドライバ
22 I/F
24 入力装置
26 表示装置

Claims

請求の範囲
[1] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、レコードの所定の項目 の項目値に応じてレコード順を並べ換える情報処理方法であって、
前記レコード番号配列を分割して第 1の複数台のプロセッサに割り当てるステップと 前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した項目値番号の出現回数を力 ゥントするステップと、
前記項目値番号の範囲を分割して第 2の複数台のプロセッサに割り当てるステップ と、
前記第 2の複数台のプロセッサのうちの各プロセッサにおいて、前記項目値番号の 順番に、前記項目値番号が一致する範囲内では前記レコード番号配列の部分の順 番に従って、前記割り当てられた項目値番号のそれぞれの出現回数を累計数に変 換するステップと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の累計数を ポインタとして利用して、前記割り当てられた前記レコード番号配列の部分に含まれ るレコード番号をさらなるレコード番号配列に格納するステップと、
を含む情報処理方法。
[2] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、レコードの所定の項目 の項目値に応じてレコード順を並べ換える情報処理方法であって、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁に関して、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として、ソート処理を 繰り返すステップと、
を含み、
前記ソート処理が、
前記現在のレコード番号配列を分割して第 1の複数台のプロセッサに割り当てるス テツプと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の桁の値 の出現回数をカウントするステップと、
前記項目値番号の現在の桁の値の範囲を分割して第 2の複数台のプロセッサに割 り当てるステップと、
前記第 2の複数台のプロセッサのうちの各プロセッサにおいて、前記項目値番号の 現在の桁の値の順番に、前記項目値番号の現在の桁の値が一致する範囲内では前 記レコード番号配列の部分の順番に従って、前記割り当てられた項目値番号の現在 の桁の値のそれぞれの出現回数を累計数に変換するステップと、
前記第 1の複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられた レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の現在の桁 の値の累計数をポインタとして利用して、前記割り当てられた前記レコード番号配列 の部分に含まれるレコード番号をさらなるレコード番号配列に格納するステップと、 を含む、 情報処理方法。
表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、レコードの所定の項目 の項目値に応じてレコード順を並べ換える情報処理方法であって、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁に関して、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として、ソート処理を 繰り返すステップと、
を含み、
前記ソート処理が、
前記現在のレコード番号配列を分割して前記複数台のプロセッサに割り当てるステ ップと、
各プロセッサにおいて、前記割り当てられたレコード番号配列の部分に含まれるレ コードに対応した項目値番号の現在の桁の値の出現回数をカウントするステップと、 少なくとも 1台のプロセッサにおいて、前記項目値番号の現在の桁の値の順番に、 前記項目値番号の現在の桁の値が一致する範囲内では前記レコード番号配列の部 分の順番に従って、前記割り当てられた項目値番号の現在の桁の値のそれぞれの 出現回数を累計数に変換するステップと、
前記各プロセッサにお 、て、前記割り当てられたレコード番号配列の部分に含まれ るレコードに対応した前記項目値番号の現在の桁の値の累計数をポインタとして利 用して、前記割り当てられた前記レコード番号配列の部分に含まれるレコード番号を さらなるレコード番号配列に格納するステップと、 を含む、
情報処理方法。
[4] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、レコードの所定の項目 の項目値に応じてレコード順を並べ換える情報処理方法であって、
前記レコード番号配列を分割して前記複数台のプロセッサに割り当てるステップと、 前記複数台のプロセッサのうちの各プロセッサにおいて、前記割り当てられたレコ ード番号配列の部分に含まれるレコードの順番を当該レコードに対応した項目値番 号に応じて入れ替え、当該レコードのレコード番号をさらなるレコード番号配列に格 納するステップと、
を含む、
情報処理方法。
[5] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、レコードの所定の項目 の項目値に応じてレコード順を並べ換える情報処理方法であって、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定するステップと、 前記基数で表現された前記項目値番号の上位の桁に関して前記レコード番号配 列中のレコード番号を並べ換え、前記項目値番号の上位の桁の値の順番に区分さ れた中間的なレコード番号配列を生成するステップと、
前記中間的なレコード番号配列の区分ごとにプロセッサを割り当てるステップと、 前記区分ごとに割り当てられた各プロセッサが、前記中間的なレコード番号配列の 前記区分内のレコード番号を前記項目値番号の下位の桁の値の順番に並べ換える ステップと、
を含む、
情報処理方法。
[6] 共有メモリと前記共有メモリにアクセス可能である複数台のプロセッサとを具備した 共有メモリ型マルチプロセッサシステムであって、
前記共有メモリが、表形式データのレコードのレコード番号が所定のレコード順に 従って格納されたレコード番号配列、表形式データのレコードの所定の項目の項目 値に対応する項目値番号がレコード番号に従って格納された項目値番号配列、及 び、表形式データの項目値が当該項目値に対応する項目値番号の順序に従って格 納された項目値配列を記憶し、
各プロセッサが、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める手段と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の出現回 数をカウントする手段と、
前記項目値番号の範囲のうち自プロセッサが受け持つ範囲を決める手段と、 前記項目値番号の順番に、前記項目値番号が一致する範囲内では前記レコード 番号配列の部分の順番に従って、前記受け持つ範囲内の項目値番号のそれぞれの 出現回数を累計数に変換する手段と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の累 計数をポインタとして利用して、前記レコード番号配列の部分に含まれるレコード番 号をさらなるレコード番号配列に格納する手段と、
を含む、
共有メモリ型マルチプロセッサシステム。
[7] 前記項目値番号の範囲のうち先行する範囲を受け持つプロセッサの前記出現回数 を累計数に変換する手段によって得られた前記累計数が、直後の範囲を受け持つ プロセッサの前記出現回数を累計数に変換する手段によって参照される、請求項 6 に記載の共有メモリ型マルチプロセッサシステム。
共有メモリと前記共有メモリにアクセス可能である複数台のプロセッサとを具備した 共有メモリ型マルチプロセッサシステムであって、
前記共有メモリが、表形式データのレコードのレコード番号が所定のレコード順に 従って格納されたレコード番号配列、表形式データのレコードの所定の項目の項目 値に対応する項目値番号がレコード番号に従って格納された項目値番号配列、及 び、表形式データの項目値が当該項目値に対応する項目値番号の順序に従って格 納された項目値配列を記憶し、
各プロセッサが、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する手段と、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁を設定し、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として設定し、ソート 処理を繰り返す手段と、
を含み、
前記ソート処理を繰り返す手段が、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める手段と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の 桁の値の出現回数をカウントする手段と、
前記項目値番号の現在の桁の値の範囲のうち自プロセッサが受け持つ範囲を決め る手段と、
前記項目値番号の現在の桁の値の順番に、前記項目値番号の現在の桁の値が一 致する範囲内では前記レコード番号配列の部分の順番に従って、前記受け持つ範 囲内の項目値番号の現在の桁の値のそれぞれの出現回数を累計数に変換する手 段と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の現 在の桁の値の累計数をポインタとして利用して、前記レコード番号配列の部分に含ま れるレコード番号をさらなるレコード番号配列に格納する手段と、
を含む、
共有メモリ型マルチプロセッサシステム。
[9] 前記項目値番号の現在の桁の範囲のうち先行する範囲を受け持つプロセッサの前 記出現回数を累計数に変換する手段によって得られた前記累計数が、直後の範囲 を受け持つプロセッサの前記出現回数を累計数に変換する手段によって参照される 、請求項 8に記載の共有メモリ型マルチプロセッサシステム。
[10] 共有メモリと前記共有メモリにアクセス可能である複数台のプロセッサとを具備した 共有メモリ型マルチプロセッサシステムであって、
前記共有メモリが、表形式データのレコードのレコード番号が所定のレコード順に 従って格納されたレコード番号配列、表形式データのレコードの所定の項目の項目 値に対応する項目値番号がレコード番号に従って格納された項目値番号配列、及 び、表形式データの項目値が当該項目値に対応する項目値番号の順序に従って格 納された項目値配列を記憶し、
各プロセッサが、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する手段と、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁を設定し、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として設定し、ソート 処理を繰り返す手段と、
を含み、
前記ソート処理を繰り返す手段が、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める手段と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の 桁の値の出現回数をカウントする手段と、
を含み、
少なくとも 1台のプロセッサの前記ソート処理を繰り返す手段力 前記項目値番号の 現在の桁の値の順番に、前記項目値番号の現在の桁の値が一致する範囲内では前 記レコード番号配列の部分の順番に従って、前記項目値番号の現在の桁の値のそ れぞれの出現回数を累計数に変換する手段を含み、
前記ソート処理を繰り返す手段が、前記レコード番号配列の部分に含まれるレコー ドに対応した前記項目値番号の現在の桁の値の累計数をポインタとして利用して、 前記レコード番号配列の部分に含まれるレコード番号をさらなるレコード番号配列に 格納する手段をさらに含む、
共有メモリ型マルチプロセッサシステム。
[11] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
各プロセッサに、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める機能と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の出現回 数をカウントする機能と、
前記項目値番号の範囲のうち自プロセッサが受け持つ範囲を決める機能と、 前記項目値番号の順番に、前記項目値番号が一致する範囲内では前記レコード 番号配列の部分の順番に従って、前記受け持つ範囲内の項目値番号のそれぞれの 出現回数を累計数に変換する機能と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の累 計数をポインタとして利用して、前記レコード番号配列の部分に含まれるレコード番 号をさらなるレコード番号配列に格納する機能と、
を実現させるためのプログラム。
[12] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
各プロセッサに、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する機能と、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁を設定し、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として設定し、前記 現在の桁のソート処理を制御する機能と、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める機能と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の 桁の値の出現回数をカウントする機能と、
前記項目値番号の現在の桁の値の範囲のうち自プロセッサが受け持つ範囲を決め る機能と、
前記項目値番号の現在の桁の値の順番に、前記項目値番号の現在の桁の値が一 致する範囲内では前記レコード番号配列の部分の順番に従って、前記受け持つ範 囲内の項目値番号の現在の桁の値のそれぞれの出現回数を累計数に変換する機 能と、
前記レコード番号配列の部分に含まれるレコードに対応した前記項目値番号の現 在の桁の値の累計数をポインタとして利用して、前記レコード番号配列の部分に含ま れるレコード番号をさらなるレコード番号配列に格納する機能と、
を実現させるためのプログラム。
表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
各プロセッサに、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する機能と、 前記基数で表現された前記項目値番号の最下位桁から最上位桁まで順番に現在 の桁を設定し、 1回目は前記レコード番号配列を現在のレコード番号配列として、 2 回目以降はさらなるレコード番号配列を現在のレコード番号配列として設定し、前記 現在の桁のソート処理を制御する機能と、
前記レコード番号配列のうち自プロセッサが受け持つ部分を決める機能と、 前記レコード番号配列の部分に含まれるレコードに対応した項目値番号の現在の 桁の値の出現回数をカウントする機能と、
を実現させ、
少なくとも 1台のプロセッサに、前記項目値番号の現在の桁の値の順番に、前記項 目値番号の現在の桁の値が一致する範囲内では前記レコード番号配列の部分の順 番に従って、前記項目値番号の現在の桁の値のそれぞれの出現回数を累計数に変 換する機能を実現させ、
前記各プロセッサに、前記レコード番号配列の部分に含まれるレコードに対応した 前記項目値番号の現在の桁の値の累計数をポインタとして利用して、前記レコード 番号配列の部分に含まれるレコード番号をさらなるレコード番号配列に格納する機 能をさらに実現させるためのプログラム。
表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、 を具備した共有メモリ型マルチプロセッサシステムにおいて、
前記レコード番号配列の部分が割り当てられた前記複数台のプロセッサのうちの各 プロセッサに、前記割り当てられたレコード番号配列の部分に含まれるレコードの順 番を当該レコードに対応した項目値番号に応じて入れ替え、当該レコードのレコード 番号をさらなるレコード番号配列に格納する機能を実現させるためのプログラム。
[15] 表形式データのレコードのレコード番号が所定のレコード順に従って格納されたレ コード番号配列、表形式データのレコードの所定の項目の項目値に対応する項目値 番号がレコード番号に従って格納された項目値番号配列、及び、表形式データの項 目値が当該項目値に対応する項目値番号の順序に従って格納された項目値配列を 記憶する共有メモリと、
前記共有メモリにアクセス可能である複数台のプロセッサと、
を具備した共有メモリ型マルチプロセッサシステムにおいて、
少なくとも 1台のプロセッサに、
前記項目値番号の範囲に応じて前記項目値番号の基数を設定する機能と、 前記基数で表現された前記項目値番号の上位の桁に関して前記レコード番号配 列中のレコード番号を並べ換え、前記項目値番号の上位の桁の値の順番に区分さ れた中間的なレコード番号配列を生成する機能と、
を実現させ、
前記中間的なレコード番号配列の区分ごとに割り当てられた各プロセッサに、前記 中間的なレコード番号配列の前記区分内のレコード番号を前記項目値番号の下位 の桁の値の順番に並べ換える機能を実現させるためのプログラム。
[16] 請求項 11乃至 15のうちいずれか 1項に記載のプログラムを記録したコンピュータ読 み取り可能な記憶媒体。
PCT/JP2006/310110 2005-05-24 2006-05-22 マルチプロセッサシステム及びその情報処理方法 WO2006126467A1 (ja)

Priority Applications (7)

Application Number Priority Date Filing Date Title
EP06756416A EP1901183A4 (en) 2005-05-24 2006-05-22 MULTIPROCESSOR SYSTEM AND INFORMATION PROCESSING METHOD
US11/883,264 US7801903B2 (en) 2005-05-24 2006-05-22 Shared-memory multiprocessor system and method for processing information
JP2007517805A JP4339381B2 (ja) 2005-05-24 2006-05-22 共有メモリ型マルチプロセッサシステム及びその情報処理方法
CN2006800034124A CN101133414B (zh) 2005-05-24 2006-05-22 多处理器系统及其信息处理方法
CA002595858A CA2595858A1 (en) 2005-05-24 2006-05-22 Multiprocessor system, and its information processing method
KR1020077017364A KR101196566B1 (ko) 2005-05-24 2006-05-22 멀티 프로세서 시스템 및 그 정보처리방법
US12/856,429 US8065337B2 (en) 2005-05-24 2010-08-13 Shared-memory multiprocessor system and method for processing information

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2005150604 2005-05-24
JP2005-150604 2005-05-24

Related Child Applications (2)

Application Number Title Priority Date Filing Date
US11/883,264 A-371-Of-International US7801903B2 (en) 2005-05-24 2006-05-22 Shared-memory multiprocessor system and method for processing information
US12/856,429 Division US8065337B2 (en) 2005-05-24 2010-08-13 Shared-memory multiprocessor system and method for processing information

Publications (1)

Publication Number Publication Date
WO2006126467A1 true WO2006126467A1 (ja) 2006-11-30

Family

ID=37451891

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2006/310110 WO2006126467A1 (ja) 2005-05-24 2006-05-22 マルチプロセッサシステム及びその情報処理方法

Country Status (7)

Country Link
US (2) US7801903B2 (ja)
EP (1) EP1901183A4 (ja)
JP (1) JP4339381B2 (ja)
KR (1) KR101196566B1 (ja)
CN (1) CN101133414B (ja)
CA (1) CA2595858A1 (ja)
WO (1) WO2006126467A1 (ja)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008155852A1 (ja) * 2007-06-21 2008-12-24 Turbo Data Laboratories Inc. メモリ共有型並列処理システムにおいて表形式データを集計する方法及び装置
WO2009028050A1 (ja) * 2007-08-28 2009-03-05 Turbo Data Laboratories, Inc. 表形式データを操作するマルチコア対応データ処理方法、マルチコア型処理装置、及び、プログラム
WO2009044486A1 (ja) * 2007-10-05 2009-04-09 Turbo Data Laboratories, Inc. 表形式データをソートする方法、マルチコア型装置、及び、プログラム

Families Citing this family (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007020849A1 (ja) * 2005-08-15 2007-02-22 Turbo Data Laboratories Inc. 共有メモリ型マルチプロセッサシステム及びその情報処理方法
US8438472B2 (en) 2009-01-02 2013-05-07 Apple Inc. Efficient data structures for parsing and analyzing a document
US8959094B2 (en) * 2010-05-28 2015-02-17 Oracle International Corporation Early return of partial sort results in a database system
US20120259869A1 (en) * 2011-04-07 2012-10-11 Infosys Technologies, Ltd. System and method for implementing a window sorting mechanism
GB2500863A (en) * 2012-01-20 2013-10-09 Data Re Ltd A method of indexing a database
KR101196145B1 (ko) 2012-02-21 2012-10-30 인하대학교 산학협력단 Cuda를 이용한 최장공통비상위문자열 그래프 모델의 병렬 생성 방법
KR101993258B1 (ko) 2012-11-22 2019-09-27 삼성전자주식회사 레지스터 슬라이싱 회로 및 이를 포함하는 시스템 온 칩
US9177006B2 (en) * 2012-12-29 2015-11-03 International Business Machines Corporation Radix sort with read-only key
KR101770234B1 (ko) * 2013-10-03 2017-09-05 후아웨이 테크놀러지 컴퍼니 리미티드 소프트웨어 프로그램의 연산 블록을 멀티-프로세서 시스템의 코어에 할당하는 방법 및 시스템
CN104657388A (zh) * 2013-11-22 2015-05-27 阿里巴巴集团控股有限公司 一种数据处理方法和装置
US9628107B2 (en) 2014-04-07 2017-04-18 International Business Machines Corporation Compression of floating-point data by identifying a previous loss of precision
US9959299B2 (en) 2014-12-02 2018-05-01 International Business Machines Corporation Compression-aware partial sort of streaming columnar data
US10909078B2 (en) 2015-02-25 2021-02-02 International Business Machines Corporation Query predicate evaluation and computation for hierarchically compressed data
US10296612B2 (en) 2015-09-29 2019-05-21 At&T Mobility Ii Llc Sorting system
US10416959B2 (en) 2015-10-27 2019-09-17 At&T Mobility Ii Llc Analog sorter
US10261832B2 (en) * 2015-12-02 2019-04-16 At&T Mobility Ii Llc Sorting apparatus
US10496370B2 (en) 2015-12-02 2019-12-03 At&T Intellectual Property I, L.P. Adaptive alphanumeric sorting apparatus
US10216478B2 (en) 2016-03-30 2019-02-26 International Business Machines Corporation Increasing radix sorting efficiency utilizing a crossover point
US9934287B1 (en) 2017-07-25 2018-04-03 Capital One Services, Llc Systems and methods for expedited large file processing
CN108052309A (zh) * 2017-12-26 2018-05-18 杭州迪普科技股份有限公司 一种对象排序方法及装置
CN109857573B (zh) * 2018-12-29 2021-03-05 深圳云天励飞技术有限公司 一种数据共享方法、装置、设备及系统
US11281427B2 (en) * 2019-04-24 2022-03-22 Ido Dov Cohen Fast sort engine

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05242049A (ja) * 1991-07-10 1993-09-21 Hitachi Ltd 分散データベースのソート方法およびアクセス方法
WO2004092948A1 (ja) * 2003-04-16 2004-10-28 Turbo Data Lab Inc 情報処理システムおよび情報処理方法

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE69232425T2 (de) 1991-07-10 2002-10-10 Hitachi Ltd Sortierverfahren in einer verteilten Datenbank und Zugangsverfahren dazu
US5765146A (en) * 1993-11-04 1998-06-09 International Business Machines Corporation Method of performing a parallel relational database query in a multiprocessor environment
WO2000010103A1 (fr) 1998-08-11 2000-02-24 Shinji Furusho Procede et dispositif de recuperation, de stockage et de triage de donnees formatees en tableaux
JP2001147800A (ja) * 1999-11-22 2001-05-29 Taabo Data Laboratory Kk 情報処理システム、並びに、この情報処理システムを利用したソート方法、コンパイル方法およびジョイン方法
JP2004522235A (ja) * 2001-07-18 2004-07-22 コーニンクレッカ フィリップス エレクトロニクス エヌ ヴィ 多重プロセッサデバイスにおける不揮発性メモリ装置と方法
JP4620593B2 (ja) * 2003-10-24 2011-01-26 株式会社ターボデータラボラトリー 情報処理システムおよび情報処理方法
WO2007020849A1 (ja) * 2005-08-15 2007-02-22 Turbo Data Laboratories Inc. 共有メモリ型マルチプロセッサシステム及びその情報処理方法

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05242049A (ja) * 1991-07-10 1993-09-21 Hitachi Ltd 分散データベースのソート方法およびアクセス方法
WO2004092948A1 (ja) * 2003-04-16 2004-10-28 Turbo Data Lab Inc 情報処理システムおよび情報処理方法

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008155852A1 (ja) * 2007-06-21 2008-12-24 Turbo Data Laboratories Inc. メモリ共有型並列処理システムにおいて表形式データを集計する方法及び装置
JP4881435B2 (ja) * 2007-06-21 2012-02-22 株式会社ターボデータラボラトリー メモリ共有型並列処理システムにおいて表形式データを集計する方法及び装置
WO2009028050A1 (ja) * 2007-08-28 2009-03-05 Turbo Data Laboratories, Inc. 表形式データを操作するマルチコア対応データ処理方法、マルチコア型処理装置、及び、プログラム
JP5208117B2 (ja) * 2007-08-28 2013-06-12 株式会社ターボデータラボラトリー 表形式データを操作するマルチコア対応データ処理方法、マルチコア型処理装置、及び、プログラム
WO2009044486A1 (ja) * 2007-10-05 2009-04-09 Turbo Data Laboratories, Inc. 表形式データをソートする方法、マルチコア型装置、及び、プログラム

Also Published As

Publication number Publication date
US20080215584A1 (en) 2008-09-04
CA2595858A1 (en) 2006-11-30
EP1901183A4 (en) 2010-01-13
US8065337B2 (en) 2011-11-22
CN101133414B (zh) 2011-05-04
JP4339381B2 (ja) 2009-10-07
US7801903B2 (en) 2010-09-21
US20100312802A1 (en) 2010-12-09
KR101196566B1 (ko) 2012-11-01
CN101133414A (zh) 2008-02-27
KR20080014726A (ko) 2008-02-14
EP1901183A1 (en) 2008-03-19
JPWO2006126467A1 (ja) 2008-12-25

Similar Documents

Publication Publication Date Title
WO2006126467A1 (ja) マルチプロセッサシステム及びその情報処理方法
CN110826719B (zh) 一种量子程序的处理方法、装置、存储介质和电子装置
US9240237B2 (en) Semiconductor device and method of writing/reading entry address into/from semiconductor device
JP4511469B2 (ja) 情報処理方法及び情報処理システム
WO2005106713A1 (ja) 情報処理方法及び情報処理システム
CN110990299B (zh) 非规整组相联cache组地址映射方法
JP4881435B2 (ja) メモリ共有型並列処理システムにおいて表形式データを集計する方法及び装置
CN105608056A (zh) 一种基于Flink的大规模矩阵并行化的计算方法
JP4620593B2 (ja) 情報処理システムおよび情報処理方法
JPWO2009044486A1 (ja) 表形式データをソートする方法、マルチコア型装置、及び、プログラム
WO2010013320A1 (ja) 表形式データを操作する方法、分散メモリ型マルチプロセッサ、及び、プログラム
JP4772506B2 (ja) 情報処理方法、情報処理システムおよびプログラム
Noon et al. Optimization query processing for multi-tiered persistent storage
JP4036257B2 (ja) 共有ライブラリ生成方法およびシステム
WO2004092948A1 (ja) 情報処理システムおよび情報処理方法
CN101120309A (zh) 加法器及其合成装置、合成方法、合成程序、合成程序记录媒体
Shao et al. Speeding up model building for ECGA on CUDA platform
JPWO2006112430A1 (ja) 情報処理システムおよび情報処理方法
JP5008720B2 (ja) メモリ間接参照をメモリ直接参照に変換する方法及び装置
Rhein Performance and Hardware Requirements of Parallel Addition Algorithms for Optical Implementation Using SEEDs
Trahan et al. Scaling multiple addition and prefix sums on the reconfigurable mesh
JPS608973A (ja) 最短路探索装置
JPS63177616A (ja) 計数方法および装置
CN85105498A (zh) 检索关联矩阵的方法

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 200680003412.4

Country of ref document: CN

DPE2 Request for preliminary examination filed before expiration of 19th month from priority date (pct application filed from 20040101)
121 Ep: the epo has been informed by wipo that ep was designated in this application
WWE Wipo information: entry into national phase

Ref document number: 2007517805

Country of ref document: JP

WWE Wipo information: entry into national phase

Ref document number: 2006756416

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 2595858

Country of ref document: CA

WWE Wipo information: entry into national phase

Ref document number: 11883264

Country of ref document: US

WWE Wipo information: entry into national phase

Ref document number: 1020077017364

Country of ref document: KR

NENP Non-entry into the national phase

Ref country code: DE

NENP Non-entry into the national phase

Ref country code: RU