CN115687708B - Transaction quotation data processing method and device and data processing board card - Google Patents

Transaction quotation data processing method and device and data processing board card Download PDF

Info

Publication number
CN115687708B
CN115687708B CN202211137676.6A CN202211137676A CN115687708B CN 115687708 B CN115687708 B CN 115687708B CN 202211137676 A CN202211137676 A CN 202211137676A CN 115687708 B CN115687708 B CN 115687708B
Authority
CN
China
Prior art keywords
data
transaction
calculation
storing
quotation
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN202211137676.6A
Other languages
Chinese (zh)
Other versions
CN115687708A (en
Inventor
张兴
陈岩
张宇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yusur Technology Co ltd
Original Assignee
Yusur Technology Co ltd
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 Yusur Technology Co ltd filed Critical Yusur Technology Co ltd
Priority to CN202211137676.6A priority Critical patent/CN115687708B/en
Publication of CN115687708A publication Critical patent/CN115687708A/en
Application granted granted Critical
Publication of CN115687708B publication Critical patent/CN115687708B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application provides a transaction quotation data processing method and device and a data processing board card, wherein the method comprises the following steps: based on KPU architecture, storing transaction quotation data to a local DDR storage unit divided into a plurality of areas in a partitioned manner; receiving custom classification data aiming at transaction quotation data by using a PCIe interface, and complementarily storing the custom classification data into a DDR (double data rate) storage unit; and according to the pre-acquired custom calculation rule, the corresponding transaction quotation data are called from the DDR storage unit and are processed and calculated, so that the corresponding calculation result is obtained and output. The application can improve the storage and retrieval efficiency of the transaction quotation data in the data processing board card, can carry out self-defined classification and calculation, can meet the personalized processing requirement and processing efficiency of a user on the transaction quotation data, improves the user experience of the data processing board card, and further can improve the application flexibility, processing effectiveness, application universality and sales of the data processing board card.

Description

Transaction quotation data processing method and device and data processing board card
Technical Field
The application relates to the technical field of hardware boards, in particular to a transaction quotation data processing method and device and a data processing board.
Background
For increasingly large user securities analysis needs, trade data processing has become one of the focus of quantitative trade strategy research. The transaction quotation data is the most basic and important part in the transaction process. Accuracy and fineness of market data is particularly important for high frequency traders and low delay traders. At present, transaction quotation data processing is widely applied in software, but for the real-time change condition of the transaction data, the software calculation mode has the problem of lower efficiency, and the timeliness requirement of the transaction quotation data processing can not be completely met. Therefore, a way of processing transaction data by using hardware is proposed.
At present, a manner of processing transaction market data by applying hardware generally adopts an FPGA (field programmable gate array) board card to perform data calculation, and the FPGA board card is integrated with a network card and a network communication function. And (3) linking the FPGA board card to a quotation forwarding server through a network port to receive quotation source data, carrying out protocol analysis on the received original quotation data, and carrying out entrusting book reconstruction on the analyzed data.
However, the conventional manner of processing transaction data by using hardware is to fix business logic in a data processing board to perform overall storage and call, such as a commission Bao Chong structure. However, the flexibility of the mode is poor, the efficiency of storing or retrieving the data is still limited to a certain extent, and the personalized processing requirement and processing efficiency of the transaction quotation data by the user cannot be met, so that the application flexibility, the effectiveness, the sales number and the like of the data processing board card are affected.
Disclosure of Invention
In view of this, embodiments of the present application provide a method and apparatus for processing transaction data, and a data processing board card, so as to eliminate or improve one or more drawbacks in the prior art.
One aspect of the present application provides a transaction quotation data processing method, comprising:
based on KPU architecture, storing transaction quotation data to a local DDR storage unit divided into a plurality of areas in a partitioned manner;
receiving custom classification data aiming at transaction quotation data by using a PCIe interface, and complementarily storing the custom classification data into the DDR storage unit;
and according to the pre-acquired custom calculation rule, the corresponding transaction quotation data are called from the DDR storage unit and are processed and calculated, so that the corresponding calculation result is obtained and output.
In some embodiments of the present application, before the storing the transaction data in the local DDR storage unit divided into the plurality of areas based on the KPU architecture, the method further includes:
dividing a DDR (double data rate) storage unit into a plurality of total areas, and performing memory allocation on each total area based on the storage capacity of the DDR storage unit;
wherein the total zone comprises: a data storage area for storing transaction quotation data, a redundant data storage area for storing redundant data, and a data operation area for reserving for data calculation.
In some embodiments of the present application, before the storing the transaction data in the local DDR storage unit divided into the plurality of areas based on the KPU architecture, the method further includes:
dividing the data storage area into a plurality of sub-storage areas, wherein each sub-storage area is used for storing transaction quotation data corresponding to each index in a linked list node mode;
the linked list node comprises a data field for storing data elements and a pointer field for storing addresses of the next linked list node.
In some embodiments of the present application, the storing the transaction data in the local DDR storage unit divided into a plurality of areas based on the KPU architecture includes:
receiving original transaction quotation data from a quotation forwarding server based on an Ethernet interface;
analyzing the original transaction quotation data according to a FAST protocol or a Binary protocol to obtain formatted transaction quotation data;
and storing the transaction quotation data into the corresponding sub storage areas in a partitioning mode based on the KPU architecture according to the index corresponding to the transaction quotation data.
In some embodiments of the present application, the applying PCIe interface receives custom classification data for transaction quotation data and stores the custom classification data in the DDR memory unit in a complementary manner, including:
Receiving custom classification data for transaction quotation data from a user application program by using a PCIe interface;
analyzing a supplementary field value and a corresponding index corresponding to the custom classification data based on a preset communication protocol;
and storing the supplementary field value to the corresponding sub-storage area in a supplementary mode according to the index of the custom classification data.
In some embodiments of the present application, there are a plurality of the custom computation rules, and each of the custom computation rules includes: rule number, calculation data, trigger type, preset calculation frequency and threshold value;
the rule numbers are used for obtaining corresponding calculation results and then enabling the calculation results to be in one-to-one correspondence with the corresponding calculation rules;
the calculation data includes: at least one of a latest price, a volume of the transaction, a highest price, and a lowest price;
the trigger types include: time triggers and/or conditional triggers.
Another aspect of the present application provides a transaction data processing apparatus, comprising:
the partition storage module is used for storing the transaction quotation data to the local DDR storage units divided into a plurality of areas in a partition mode based on the KPU architecture;
the supplementary storage module is used for receiving the custom classification data aiming at the transaction quotation data by applying a PCIe interface and storing the custom classification data into the DDR storage unit in a supplementary mode;
And the custom calculation module is used for calling corresponding transaction quotation data from the DDR storage unit according to the pre-acquired custom calculation rule, carrying out processing calculation, obtaining a corresponding calculation result and outputting the calculation result.
Another aspect of the present application provides a data processing board including: the DDR memory cell, KPU framework and computer program stored in the data processing board card and used for running in the KPU framework, the KPU framework realizes the transaction quotation data processing method when executing the computer program;
and the KPU framework is respectively in communication connection with the Ethernet interface and the PCIe interface.
In some embodiments of the application, the KPU architecture includes: the system comprises a logic processing unit, a memory management unit, a data scheduler, a task scheduler, a core processor group and a data cache unit group which are connected in sequence, wherein the data cache unit group is also connected with the memory management unit;
the memory management unit and the data scheduler are respectively connected with the DDR storage unit;
the KPU architecture further includes: the network controller is in communication connection with the Ethernet interface, and the PCIe controller is in communication connection with the PCIe interface;
The set of core processors includes a plurality of core processors; the data cache unit group comprises a plurality of data cache units, and each data cache unit is respectively connected with the memory management unit and one core processor.
In some embodiments of the present application, the data processing board is installed on a server through the PCIe interface, and the data processing board is connected to a market forwarding server through a communication connection between the ethernet interface and the market forwarding server so as to obtain transaction market data from the market forwarding server.
Another aspect of the present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the transaction data processing method.
According to the transaction quotation data processing method provided by the application, the transaction quotation data is stored in the local DDR storage unit divided into a plurality of areas based on the KPU architecture, and the analyzed quotation data is stored in the board in a partition mode; the effect of quickly storing or retrieving data is achieved; the PCIe interface is applied to receive the custom classification data aiming at the transaction quotation data, and the custom classification data is additionally stored in the DDR storage unit, so that the analyzed quotation data can be subjected to data classification at a user layer, and the custom classification effect of the user on the quotation data is achieved; according to the pre-acquired custom calculation rule, corresponding transaction quotation data are called from the DDR storage unit and are processed and calculated, a corresponding calculation result is obtained and output, and under the condition of the custom rule, the analyzed quotation data are calculated; the effect of custom calculation of the user on the market data is achieved; the method can improve the storage and retrieval efficiency of the transaction quotation data in the data processing board card, can carry out self-defined classification and calculation, can meet the personalized processing requirement and processing efficiency of a user on the transaction quotation data, improves the user experience of the data processing board card, and further can improve the application flexibility, processing effectiveness, application universality, product sales and the like of the data processing board card.
Additional advantages, objects, and features of the application will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the application. The objectives and other advantages of the application may be realized and attained by the structure particularly pointed out in the written description and drawings.
It will be appreciated by those skilled in the art that the objects and advantages that can be achieved with the present application are not limited to the above-described specific embodiments, and that the above-described and other objects that can be achieved with the present application will be more clearly understood from the following detailed description.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate and together with the description serve to explain the application. The components in the figures are not necessarily to scale, emphasis instead being placed upon illustrating the principles of the application. Corresponding parts in the drawings may be exaggerated, i.e. made larger relative to other parts in an exemplary device actually manufactured according to the present application, for convenience in showing and describing some parts of the present application. In the drawings:
fig. 1 is a general flow chart of a transaction data processing method according to an embodiment of the application.
Fig. 2 is a schematic flow chart of a transaction data processing method according to an embodiment of the application.
Fig. 3 is a schematic structural diagram of a transaction data processing device according to another embodiment of the application.
Fig. 4 is a schematic structural diagram of a data processing board card according to another embodiment of the application.
Fig. 5 is a schematic diagram of physical connection between a data processing board and other servers according to another embodiment of the application.
Fig. 6 is a schematic flow chart of data receiving and analyzing provided by the application example of the present application.
Fig. 7 is a schematic diagram of dividing three total areas provided by an application example of the present application.
FIG. 8 is a schematic diagram illustrating the division of the sub-storage areas in the data storage area provided by the application example of the present application.
Fig. 9 is a flowchart of supplementary data provided by an application example of the present application.
FIG. 10 is a schematic diagram of a custom calculation rule calculation flow provided by an embodiment of the present application.
Detailed Description
The present application will be described in further detail with reference to the following embodiments and the accompanying drawings, in order to make the objects, technical solutions and advantages of the present application more apparent. The exemplary embodiments of the present application and the descriptions thereof are used herein to explain the present application, but are not intended to limit the application.
It should be noted here that, in order to avoid obscuring the present application due to unnecessary details, only structures and/or processing steps closely related to the solution according to the present application are shown in the drawings, while other details not greatly related to the present application are omitted.
It should be emphasized that the term "comprises/comprising" when used herein is taken to specify the presence of stated features, elements, steps or components, but does not preclude the presence or addition of one or more other features, elements, steps or components.
It is also noted herein that the term "coupled" may refer to not only a direct connection, but also an indirect connection in which an intermediate is present, unless otherwise specified.
Hereinafter, embodiments of the present application will be described with reference to the accompanying drawings. In the drawings, the same reference numerals represent the same or similar components, or the same or similar steps.
The existing better technology is to use an FPGA (field programmable gate array) board card to perform data calculation, and the FPGA board card integrates a network card and a network communication function. And (3) linking the FPGA board card to a quotation forwarding server through a network port to receive quotation source data, carrying out protocol analysis on the received original quotation data, and carrying out entrusting book reconstruction on the analyzed data.
The inventor of the present application has found that in the prior art, market data is generally calculated in a solidified manner in a board card when research on a quantized transaction strategy is performed. However, for the transaction policy, a more flexible way is needed to calculate the market data in the board card, such as calculating the average value of the price of the stock in time sharing. The calculation method can be implemented in software, but for the situation of real-time change of transaction data, the calculation mode of the software is slower, the calculation mode of using a hardware board card is more efficient, and the desired result can be calculated more quickly according to the market data by using a custom rule.
Based on the method, the application provides a transaction quotation data processing mode and hardware realization, and the parsed quotation data is stored in the board in a partitioning way; the effect of quickly storing or retrieving data is achieved; the analyzed quotation data can be subjected to data classification in a user layer, so that the effect of custom classification of the quotation data by a user is achieved; under the condition of self-defining rules, calculating the analyzed quotation data; the effect of custom calculation of the user on the market data is achieved.
In one or more embodiments of the application, FPGA refers to: field Programmable Gate Array is an integrated circuit that appears as a semi-custom circuit in the field of Application Specific Integrated Circuits (ASICs), which is the integration of circuits built from various discrete components (e.g., resistors, diodes, transistors) onto a single chip. FPGA accelerator cards are specialized board cards for specific fields and applications, typically deployed in the form of PCIe expansion cards. The board is designed with rich high-speed I/O interfaces and memory resources, but often not equipped with too many debugging functions and resources commonly found on the development board.
In one or more embodiments of the application, PCI refers to: the inter-peripheral interconnect standard (Peripheral Component Interconnect) is a standard proposed by Intel for defining local buses. This standard allows for the installation of expansion cards within a computer that conform to the PCI standard. PCI bus systems require a PCI control card that must be installed in a PCI slot.
In one or more embodiments of the application, PCIe refers to: PCI Express, which is a serial communication system standard that follows existing PCI programming concepts and signal standards and builds on higher speeds. An integrated circuit board using a PCI standard interface may be referred to simply as a PCIe board.
In one or more embodiments of the present application, the data processing board may be a data processing unit DPU (Data Processing Unit) issued by the english-weida (NVIDIA), and particularly may be a model of DPU-K1 or DPU-K2, which outputs mature products and hardware acceleration solutions for various securities enterprises.
The following examples are provided to illustrate the application in more detail.
In order to improve the storage and retrieval efficiency of transaction quotation data in a data processing board card, perform custom classification and calculation and meet the personalized processing requirement and processing efficiency of a user on the transaction quotation data, the embodiment of the application provides a transaction quotation data processing method, which can be realized based on a transaction quotation data processing device and is applied to the data processing board card, referring to fig. 1, and specifically comprises the following contents:
Step 100: the transaction quotation data is stored in the local DDR storage unit divided into a plurality of areas based on the KPU framework.
In one or more embodiments of the present application, the core processor KPU (Kernel Processing Unit) architecture is a special-purpose technology chip architecture developed based on the technical path of "software defined accelerators", which is a coprocessor architecture designed specifically for accelerating domain-specific core function computations, and has a functional core as a basic unit, and has super heterogeneous core integration and scheduling capabilities.
A plurality of core processors are provided in the KPU architecture, and the operation modes of the core processors can be fixed according to rules. The KPU architecture may include PCIe controllers, network controllers, logic processing units, memory management units, data caching units, data schedulers, task schedulers, core processors, and the like. The coprocessor architecture is specially designed for accelerating core function computation in a specific field, takes a functional core as a basic unit, and has super heterogeneous core integration and scheduling capability. The KPU can integrate tens to hundreds of functional cores according to the requirements, can directly abstract the intensive application of computation in the application and synthesize the high-level, realize the architecture customization taking data as the center, has extremely high flexibility, ensures abundant computing power and supports more computing load types with the lowest power consumption.
Step 200: and receiving custom classification data aiming at transaction quotation data by using a PCIe interface, and complementarily storing the custom classification data into the DDR storage unit.
In one or more embodiments of the present application, the DDR (Double Data Rate) memory cell may also be written directly as a DDR, which refers to a double rate synchronous dynamic random access memory, which is one of memories. DDR uses the synchronous circuit, make the designated address, main step of data delivery and output not merely carry out independently, keep and CPU totally synchronous; DDR uses a delay locked loop to provide a data filtered signal DLL (Delay Locked Loop) technique that can be used by the memory controller to pinpoint data, once every 16 outputs, and resynchronize data from different memory modules when the data is valid. DDR essentially doubles the speed of SDRAM without increasing the clock frequency, which allows data to be read on the rising and falling edges of the clock pulses, thus doubling the speed of standard SDRAM.
Step 300: and according to the pre-acquired custom calculation rule, the corresponding transaction quotation data are called from the DDR storage unit and are processed and calculated, so that the corresponding calculation result is obtained and output.
In one or more embodiments of the application, transaction quotation data, which may also be referred to as quotation data, is the most basic, important part of the transaction process. A complete transaction is typically divided into three steps: receiving quotation, analyzing quotation (policy part), issuing buying and selling instructions and trading (algorithm trading part). Accuracy and fineness of market data is particularly important for high frequency traders and low delay traders. The accuracy refers to the accuracy of data and how much the accuracy can reflect the real situation of the market, and the fineness refers to the pushing frequency of the market. The market data is divided into two parts: trade quotation and order delegation quotation. The trade quotation is trade data, and comprises field information such as latest trading price, trading volume, highest price, lowest price and the like; the order consignment quotation is the buying and selling quotation and consignment quantity, and can be classified into first-grade, fifth-grade, tenth-grade and other quotations according to different consignment prices; transaction quotations and order delegation quotations are typically combined to form TAQ (Trades and Quotes) quotations.
As can be seen from the above description, in the transaction quotation data processing method provided by the embodiment of the application, the parsed quotation data is stored in the board in a partition manner; the effect of quickly storing or retrieving data is achieved; the analyzed quotation data can be subjected to data classification at a user layer; the effect of custom classification of the user on the market data is achieved; under the condition of self-defining rules, calculating the analyzed quotation data; the effect of custom calculation of the user on the market data is achieved; the method can improve the storage and retrieval efficiency of the transaction quotation data in the data processing board card, can carry out self-defined classification and calculation, can meet the personalized processing requirement and processing efficiency of a user on the transaction quotation data, improves the user experience of the data processing board card, and further can improve the application flexibility, processing effectiveness, application universality and sales of the data processing board card.
In order to further improve the efficiency of storing and retrieving data in the data processing board, in the transaction quotation data processing method provided by the embodiment of the application, referring to fig. 2, before step 100 in the transaction quotation data processing method, the following contents are specifically included:
step 010: dividing a DDR (double data rate) storage unit into a plurality of total areas, and performing memory allocation on each total area based on the storage capacity of the DDR storage unit; wherein the total zone comprises: a data storage area for storing transaction quotation data, a redundant data storage area for storing redundant data, and a data operation area for reserving for data calculation.
Specifically, the storage of 64GB of memory can be divided into three parts: a data storage area of 30GB, a redundant data storage area of 2GB and a data operation area of 32 GB.
Wherein the data storage area: according to the stock code as an index, 10 3GB data storage areas are equally divided in 30GB data storage areas. Firstly, judging whether the data is Shanghai securities market data or Shenzhen securities market data by using a start code, wherein the market of the A stock is 6, and the market of the B stock is: 0. and determining the partition storage positions of the stock codes according to the judging result. The partition storage mode judges which data memory area the market data should be stored in at intervals of 500. Examples: stock codes 600000-600500 will be stored in the first 3G data storage area, and so on.
Redundant data storage area: the remaining data for stock codes exceeding 605000 (top) or 005000 (bottom) are stored in the redundant data storage area.
The data operation area is a storage area reserved for later data calculation.
In order to further improve the efficiency of storing and retrieving data in a data processing board, in the transaction quotation data processing method provided by the embodiment of the application, referring to fig. 2, after step 010 and before step 100 in the transaction quotation data processing method, the following contents are specifically included:
step 020: dividing the data storage area into a plurality of sub-storage areas, wherein each sub-storage area is used for storing transaction quotation data corresponding to each index in a linked list node mode; the linked list node comprises a data field for storing data elements and a pointer field for storing addresses of the next linked list node.
Specifically, the 30GB data storage area is equally divided into 10 parts, and the received data is stored in the corresponding sub-storage area according to the index. Actual data indexed by stock codes is stored in the data field of linked list nodes.
In one or more embodiments of the application, the linked list is a non-contiguous, non-sequential storage structure on physical storage elements, the logical order of the data elements being achieved by the order of pointer links in the linked list. The linked list is made up of a series of nodes (each element in the linked list is called a node) that can be dynamically generated at runtime. Each node comprises two parts: one is a data field storing a data element and the other is a pointer field storing the address of the next node.
In order to further improve the efficiency, effectiveness and reliability of data partition storage, in the transaction quotation data processing method provided by the embodiment of the application, referring to fig. 2, step 100 in the transaction quotation data processing method specifically includes the following contents:
step 110: the original transaction quotation data is received from the quotation forwarding server based on the Ethernet interface.
Step 120: and analyzing the original transaction quotation data according to the FAST protocol or the Binary protocol to obtain formatted transaction quotation data.
Step 130: and storing the transaction quotation data into the corresponding sub storage areas in a partitioning mode based on the KPU architecture according to the index corresponding to the transaction quotation data.
Specifically, the data processing board card is installed on a server through PCIe (high speed serial computer expansion bus standard), and links with a quotation forwarding server of a dealer through an Ethernet interface to acquire original quotation data. And analyzing the received quotation data into formatted data through a FAST or a Binary protocol.
Formatting the data includes: the latest price, the volume, the amount, the highest price, the lowest price, etc. The board card integrates 64GB DDR3 memory particles, and formatted data is stored into the board card DDR.
In order to further improve the reliability and effectiveness of user-defined classification, in the method for processing transaction quotation data provided by the embodiment of the application, referring to fig. 2, step 200 in the method for processing transaction quotation data specifically includes the following contents:
step 210: receiving custom classification data for transaction quotation data from a user application program by using a PCIe interface;
step 220: analyzing a supplementary field value and a corresponding index corresponding to the custom classification data based on a preset communication protocol;
step 230: and storing the supplementary field value to the corresponding sub-storage area in a supplementary mode according to the index of the custom classification data.
Specifically, steps 210 to 230 may supplement custom classification of stock data according to protocols, such as: and (5) a financial index. The communication protocol includes: stock code, new category, category value. The user application program sends the data to be supplemented to the board card through PCIe, the board card analyzes the field value to be supplemented according to the communication protocol, the market data stored in the data storage area are searched according to the stock codes, and the data to be supplemented are added to the corresponding sub-storage area.
In order to further improve reliability and effectiveness of custom calculation, in the transaction quotation data processing method provided by the embodiment of the application, a plurality of custom calculation rules are provided, and each custom calculation rule comprises: rule number, calculation data, trigger type, preset calculation frequency and threshold value;
the rule numbers are used for obtaining corresponding calculation results and then enabling the calculation results to be in one-to-one correspondence with the corresponding calculation rules; the calculation data includes: at least one of a latest price, a volume of the transaction, a highest price, and a lowest price;
the trigger types include: time triggers and/or conditional triggers.
Specifically, the calculation rule of the board is set according to the rule, and the rule may set a plurality of pieces according to the rule number. The rule protocol includes: rule numbers, calculation data, trigger types, frequencies, thresholds, etc. Because the board card calculates a plurality of rules at the same time, the calculation rules are required to be corresponding to the calculation results, and after the calculation is completed, the calculation results are returned by the calculation rule numbers. The calculation data may be set to the latest price, the amount of the deal, the highest price, and the lowest price, and a plurality of data may be calculated at the same time. The trigger types include time triggers and conditional triggers. Time triggers are on the order of hours, minutes and seconds. The condition triggering is that when the rule is calculated, the calculation result is larger than, smaller than or equal to the threshold value, the condition of the application layer is fed back in an interrupt mode to be triggered. The calculation result returns to the application layer data format: rule number, trigger type and calculation result.
In terms of software, the present application further provides a transaction data processing device for executing all or part of the transaction data processing method, referring to fig. 3, where the transaction data processing device specifically includes the following contents:
the partition storage module 10 is used for storing the transaction quotation data to the local DDR storage units divided into a plurality of areas in a partition mode based on the KPU architecture;
the supplementary storage module 20 is configured to receive custom classification data for transaction quotation data by using a PCIe interface, and store the custom classification data in the DDR storage unit in a supplementary manner;
the custom calculation module 30 is configured to retrieve corresponding transaction quotation data from the DDR memory unit according to the pre-acquired custom calculation rule, perform processing calculation, obtain a corresponding calculation result, and output the calculation result.
The embodiment of the transaction data processing device provided by the application can be particularly used for executing the processing flow of the embodiment of the transaction data processing method in the embodiment, and the functions of the embodiment of the transaction data processing device are not repeated herein, and can be referred to in the detailed description of the embodiment of the transaction data processing method.
The part of the transaction data processing device for processing the transaction data can be executed in a server, and in another practical application situation, all operations can be completed in the client device. Specifically, the selection may be made according to the processing capability of the client device, and restrictions of the use scenario of the user. The application is not limited in this regard. If all operations are performed in the client device, the client device may further include a processor for specific processing of transaction ticker data processing.
The client device may have a communication module (i.e. a communication unit) and may be connected to a remote server in a communication manner, so as to implement data transmission with the server. The server may include a server on the side of the task scheduling center, and in other implementations may include a server of an intermediate platform, such as a server of a third party server platform having a communication link with the task scheduling center server. The server may include a single computer device, a server cluster formed by a plurality of servers, or a server structure of a distributed device.
Any suitable network protocol may be used between the server and the client device, including those not yet developed on the filing date of the present application. The network protocols may include, for example, TCP/IP protocol, UDP/IP protocol, HTTP protocol, HTTPS protocol, etc. Of course, the network protocol may also include, for example, RPC protocol (Remote Procedure Call Protocol ), REST protocol (Representational State Transfer, representational state transfer protocol), etc. used above the above-described protocol.
As can be seen from the above description, the transaction quotation data processing device provided by the embodiment of the application stores the parsed quotation data in the board in a partition manner; the effect of quickly storing or retrieving data is achieved; the analyzed quotation data can be subjected to data classification at a user layer; the effect of custom classification of the user on the market data is achieved; under the condition of self-defining rules, calculating the analyzed quotation data; the effect of custom calculation of the user on the market data is achieved; the method can improve the storage and retrieval efficiency of the transaction quotation data in the data processing board card, can carry out self-defined classification and calculation, can meet the personalized processing requirement and processing efficiency of a user on the transaction quotation data, improves the user experience of the data processing board card, and further can improve the application flexibility, processing effectiveness, application universality and sales of the data processing board card.
The embodiment of the application also provides a data processing board, referring to fig. 4, the data processing board comprises: the DDR memory cell, KPU framework and computer program stored in the data processing board card and used for running in the KPU framework, the KPU framework realizes the transaction quotation data processing method when executing the computer program;
and the KPU framework is respectively in communication connection with the Ethernet interface and the PCIe interface.
Wherein, KPU framework includes: the system comprises a logic processing unit, a memory management unit, a data scheduler, a task scheduler, a core processor group and a data cache unit group which are connected in sequence, wherein the data cache unit group is also connected with the memory management unit;
the memory management unit and the data scheduler are both connected with the DDR storage unit;
the KPU architecture further includes: the network controller is in communication connection with the Ethernet interface, and the PCIe controller is in communication connection with the PCIe interface;
the set of core processors includes a plurality of core processors; the data cache unit group comprises a plurality of data cache units, and each data cache unit is respectively connected with the memory management unit and one core processor.
In addition, referring to fig. 5, the data processing board card is installed on the server through the PCIe interface, and the data processing board card is connected with the market forwarding server through the ethernet interface in a communication manner so as to obtain transaction market data from the market forwarding server.
The embodiment of the application also provides a computer readable storage medium, on which a computer program is stored, which when being executed by a processor, is used for realizing the steps of the transaction quotation data processing method. The computer readable storage medium may be a tangible storage medium such as Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, floppy disks, hard disk, a removable memory disk, a CD-ROM, or any other form of storage medium known in the art.
In order to further explain the scheme, the application also provides a specific application example of the transaction quotation data processing method, in particular to a quotation data processing method based on a custom rule of a KPU architecture, which is used for solving the problems that hardware cannot customize quotation data processing rules and the like in the prior art, and storing parsed quotation data in a board in a partition mode; the effect of quickly storing or retrieving data is achieved; the analyzed quotation data can be subjected to data classification in a user layer, so that the effect of custom classification of the quotation data by a user is achieved; under the condition of self-defining rules, calculating the analyzed quotation data; the effect of custom calculation of the user on the market data is achieved.
The technical scheme adopted by the application example of the application comprises the following steps:
(1) Referring to fig. 4 and 5, the data processing board is mounted on a server through PCIe (high speed serial computer expansion bus standard), and referring to fig. 6, the original quotation data is obtained by linking a quotation forwarding server of a dealer through an ethernet interface. And analyzing the received quotation data into formatted data through a FAST or a Binary protocol.
A plurality of core processors are provided in the KPU (Kernel Processing Unit) architecture, and the operation modes of the core processors can be fixed according to rules. The KPU architecture comprises a PCIe controller, a network controller, a logic processing unit, a memory management unit, a data caching unit, a data scheduler, a task scheduler, a core processor and the like.
(2) The formatted data includes the latest price, volume, amount, maximum and minimum, etc. The board card integrates 64GB DDR3 memory particles, and formatted data is stored into the board card DDR.
(3) Referring to fig. 7, the storage of the 64GB memory is divided into three parts, a 30GB data storage area, a 2GB redundant data storage area, and a 32GB data operation area. Referring to fig. 8, the 30GB data storage area is equally divided into 10 parts (sub-storage areas 1 to 10), and received data is stored in the corresponding sub-storage areas according to indexes. Actual data indexed by stock codes is stored in the data field of linked list nodes.
A linked list is a non-contiguous, non-sequential storage structure on physical storage elements, and the logical order of data elements is achieved by the order of pointer links in the linked list. The linked list is made up of a series of nodes (each element in the linked list is called a node) that can be dynamically generated at runtime. Each node comprises two parts: one is a data field storing a data element and the other is a pointer field storing the address of the next node.
Data storage area: according to the stock code as an index, 10 3GB data storage areas are equally divided in 30GB data storage areas. Firstly, judging whether the Shanghai securities market data or Shenzhen securities market data by using a start code, wherein the upper evidence A stock market is 6, and the deep evidence A stock market is: "0". And determining the partition storage positions of the stock codes according to the judging result. The partition storage mode judges which sub-storage area the market data should be stored in at intervals of 500. Examples: stock codes 600000-600500 would be stored in the first 3G sub-store 1, and so on.
Redundant data storage area: the remaining data for stock codes exceeding 605000 (top) or 005000 (bottom) are stored in the redundant data storage area.
The data operation area is a storage area reserved for later data calculation.
(4) Referring to fig. 9, the custom classification of stock data is supplemented according to a protocol, such as: and (5) a financial index. The communication protocol includes: stock code, new category, category value. The user application program sends the data to be supplemented to the board card through PCIe, the board card analyzes the field value to be supplemented according to the communication protocol, the market data stored in the data storage area are searched according to the stock codes, and the data to be supplemented are added to the sub-storage area.
(5) Referring to fig. 10, the calculation rule of the board is set according to the rule, and the rule may set a plurality of pieces according to the rule number. The rule protocol includes: rule number, calculation data, trigger type, frequency and threshold. Because the board card calculates a plurality of rules at the same time, the calculation rules are required to be corresponding to the calculation results, and after the calculation is completed, the calculation results are returned by the calculation rule numbers. The calculation data may be set to the latest price, the amount of the deal, the highest price, and the lowest price, and a plurality of data may be calculated at the same time. The trigger types include time triggers and conditional triggers. Time triggers are on the order of hours, minutes and seconds. The condition triggering is that when the rule is calculated, the calculation result is larger than, smaller than or equal to the threshold value, the condition of the application layer is fed back in an interrupt mode to be triggered. The calculation result returns to the application layer data format: rule number, trigger type and calculation result.
Compared with the prior art, the application example of the application has the beneficial effects that:
1. for serialized computation of software, the data computation is faster and more efficient to implement in hardware than in software.
2. Existing market data processing is based on market data sent by exchanges, which is not effectively classified for users. The application example provides that users can carry out custom classification on market data based on stock codes.
3. For the existing hardware market data processing board card, the calculation of the market data is fixed, the user-defined operation of the market data cannot be realized, the application example provides that a user can issue a user-defined rule to the board card, the board card calculates the market data according to the user-defined rule, and the calculation result is fed back to the user.
Those of ordinary skill in the art will appreciate that the various illustrative components, systems, and methods described in connection with the embodiments disclosed herein can be implemented as hardware, software, or a combination of both. The particular implementation is hardware or software dependent on the specific application of the solution and the design constraints. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application. When implemented in hardware, it may be, for example, an electronic circuit, an Application Specific Integrated Circuit (ASIC), suitable firmware, a plug-in, a function card, or the like. When implemented in software, the elements of the application are the programs or code segments used to perform the required tasks. The program or code segments may be stored in a machine readable medium or transmitted over transmission media or communication links by a data signal carried in a carrier wave.
It should be understood that the application is not limited to the particular arrangements and instrumentality described above and shown in the drawings. For the sake of brevity, a detailed description of known methods is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method processes of the present application are not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between steps, after appreciating the spirit of the present application.
In this disclosure, features that are described and/or illustrated with respect to one embodiment may be used in the same way or in a similar way in one or more other embodiments and/or in combination with or instead of the features of the other embodiments.
The above description is only of the preferred embodiments of the present application and is not intended to limit the present application, and various modifications and variations can be made to the embodiments of the present application by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (6)

1. A method for processing transaction quotation data, comprising:
dividing a DDR (double data rate) storage unit into a plurality of total areas, and performing memory allocation on each total area based on the storage capacity of the DDR storage unit; wherein the total zone comprises: a data storage area for storing transaction quotation data, a redundant data storage area for storing redundant data, and a data operation area for reserving for data calculation;
based on KPU architecture, storing transaction quotation data to a local DDR storage unit divided into a plurality of areas in a partitioned manner;
receiving custom classification data aiming at transaction quotation data by using a PCIe interface, and complementarily storing the custom classification data into the DDR storage unit;
according to the pre-acquired custom calculation rule, corresponding transaction quotation data are called from the DDR storage unit and are processed and calculated, so that corresponding calculation results are obtained and output;
before the KPU-based architecture stores the transaction quotation data in the local DDR memory unit divided into a plurality of areas, the method further comprises:
dividing the data storage area into a plurality of sub-storage areas, wherein each sub-storage area is used for storing transaction quotation data corresponding to each index in a linked list node mode;
The linked list node comprises a data field for storing data elements and a pointer field for storing addresses of the next linked list node;
the KPU-based architecture stores transaction market data in a partitioned manner to a local DDR storage unit having a plurality of partitioned areas, including:
receiving original transaction quotation data from a quotation forwarding server based on an Ethernet interface;
analyzing the original transaction quotation data according to a FAST protocol or a Binary protocol to obtain formatted transaction quotation data;
according to the index corresponding to the transaction quotation data, storing the transaction quotation data into the corresponding sub-storage area based on the KPU architecture in a partitioning mode;
the application PCIe interface receives custom classification data for transaction quotation data, and stores the custom classification data in the DDR storage unit in a complementary manner, including:
receiving custom classification data for transaction quotation data from a user application program by using a PCIe interface;
analyzing a supplementary field value and a corresponding index corresponding to the custom classification data based on a preset communication protocol;
and storing the supplementary field value to the corresponding sub-storage area in a supplementary mode according to the index of the custom classification data.
2. The method for processing transaction data according to claim 1, wherein a plurality of custom calculation rules are provided, and each custom calculation rule includes: rule number, calculation data, trigger type, preset calculation frequency and threshold value;
the rule numbers are used for obtaining corresponding calculation results and then enabling the calculation results to be in one-to-one correspondence with the corresponding calculation rules;
the calculation data includes: at least one of a latest price, a volume of the transaction, a highest price, and a lowest price;
the trigger types include: time triggers and/or conditional triggers.
3. A transaction data processing device, wherein the transaction data processing device is used for executing the following contents:
dividing a DDR (double data rate) storage unit into a plurality of total areas, and performing memory allocation on each total area based on the storage capacity of the DDR storage unit; wherein the total zone comprises: a data storage area for storing transaction quotation data, a redundant data storage area for storing redundant data, and a data operation area for reserving for data calculation;
the transaction quotation data processing device further comprises:
The partition storage module is used for storing the transaction quotation data to the local DDR storage units divided into a plurality of areas in a partition mode based on the KPU architecture;
the supplementary storage module is used for receiving the custom classification data aiming at the transaction quotation data by applying a PCIe interface and storing the custom classification data into the DDR storage unit in a supplementary mode;
the self-defining calculation module is used for calling corresponding transaction quotation data from the DDR storage unit according to the pre-acquired self-defining calculation rule and carrying out processing calculation to obtain a corresponding calculation result and outputting the calculation result;
before the KPU-based architecture stores the transaction market data in the local DDR memory unit divided into a plurality of areas, the transaction market data processing device is further configured to perform the following steps:
dividing the data storage area into a plurality of sub-storage areas, wherein each sub-storage area is used for storing transaction quotation data corresponding to each index in a linked list node mode;
the linked list node comprises a data field for storing data elements and a pointer field for storing addresses of the next linked list node;
the KPU-based architecture stores transaction market data in a partitioned manner to a local DDR storage unit having a plurality of partitioned areas, including:
Receiving original transaction quotation data from a quotation forwarding server based on an Ethernet interface;
analyzing the original transaction quotation data according to a FAST protocol or a Binary protocol to obtain formatted transaction quotation data;
according to the index corresponding to the transaction quotation data, storing the transaction quotation data into the corresponding sub-storage area based on the KPU architecture in a partitioning mode;
the application PCIe interface receives custom classification data for transaction quotation data, and stores the custom classification data in the DDR storage unit in a complementary manner, including:
receiving custom classification data for transaction quotation data from a user application program by using a PCIe interface;
analyzing a supplementary field value and a corresponding index corresponding to the custom classification data based on a preset communication protocol;
and storing the supplementary field value to the corresponding sub-storage area in a supplementary mode according to the index of the custom classification data.
4. A data processing board card, comprising: DDR memory cell, KPU framework and computer program stored in said data processing board card and used for running in KPU framework, said KPU framework realizes the transaction quotation data processing method according to claim 1 or 2 when executing said computer program;
And the KPU framework is respectively in communication connection with the Ethernet interface and the PCIe interface.
5. The data processing board of claim 4, wherein the KPU framework comprises: the system comprises a logic processing unit, a memory management unit, a data scheduler, a task scheduler, a core processor group and a data cache unit group which are connected in sequence, wherein the data cache unit group is also connected with the memory management unit;
the memory management unit and the data scheduler are respectively connected with the DDR storage unit;
the KPU architecture further includes: the network controller is in communication connection with the Ethernet interface, and the PCIe controller is in communication connection with the PCIe interface;
the set of core processors includes a plurality of core processors; the data cache unit group comprises a plurality of data cache units, and each data cache unit is respectively connected with the memory management unit and one core processor.
6. The data processing board of claim 5, wherein the data processing board is mounted on a server via the PCIe interface, and wherein the data processing board is communicatively coupled to a market forwarding server via the ethernet interface to obtain transaction market data from the market forwarding server.
CN202211137676.6A 2022-09-19 2022-09-19 Transaction quotation data processing method and device and data processing board card Active CN115687708B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211137676.6A CN115687708B (en) 2022-09-19 2022-09-19 Transaction quotation data processing method and device and data processing board card

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211137676.6A CN115687708B (en) 2022-09-19 2022-09-19 Transaction quotation data processing method and device and data processing board card

Publications (2)

Publication Number Publication Date
CN115687708A CN115687708A (en) 2023-02-03
CN115687708B true CN115687708B (en) 2023-08-22

Family

ID=85062018

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211137676.6A Active CN115687708B (en) 2022-09-19 2022-09-19 Transaction quotation data processing method and device and data processing board card

Country Status (1)

Country Link
CN (1) CN115687708B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110611624A (en) * 2018-06-15 2019-12-24 上海仪电(集团)有限公司中央研究院 Massive market quotation data acceleration system and acceleration method based on FPGA
CN111080446A (en) * 2019-12-02 2020-04-28 泰康保险集团股份有限公司 Data processing method and device
CN112003814A (en) * 2019-05-27 2020-11-27 招商证券股份有限公司 Market data processing method and device, terminal equipment and storage medium
CN112347020A (en) * 2020-10-26 2021-02-09 东方证券股份有限公司 FAST market analysis system and method based on CGRA
CN112348522A (en) * 2020-10-26 2021-02-09 东方证券股份有限公司 Wind control detection system based on FPGA regular expression
CN112486888A (en) * 2020-12-11 2021-03-12 盛立金融软件开发(杭州)有限公司 Market data transmission method, device, equipment and medium
CN113434516A (en) * 2021-08-03 2021-09-24 深圳华锐金融技术股份有限公司 Market data storage method and device, computer equipment and readable storage medium
CN114328348A (en) * 2021-12-17 2022-04-12 广东浪潮智慧计算技术有限公司 FPGA acceleration board card and market data processing method thereof

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110611624A (en) * 2018-06-15 2019-12-24 上海仪电(集团)有限公司中央研究院 Massive market quotation data acceleration system and acceleration method based on FPGA
CN112003814A (en) * 2019-05-27 2020-11-27 招商证券股份有限公司 Market data processing method and device, terminal equipment and storage medium
CN111080446A (en) * 2019-12-02 2020-04-28 泰康保险集团股份有限公司 Data processing method and device
CN112347020A (en) * 2020-10-26 2021-02-09 东方证券股份有限公司 FAST market analysis system and method based on CGRA
CN112348522A (en) * 2020-10-26 2021-02-09 东方证券股份有限公司 Wind control detection system based on FPGA regular expression
CN112486888A (en) * 2020-12-11 2021-03-12 盛立金融软件开发(杭州)有限公司 Market data transmission method, device, equipment and medium
CN113434516A (en) * 2021-08-03 2021-09-24 深圳华锐金融技术股份有限公司 Market data storage method and device, computer equipment and readable storage medium
CN114328348A (en) * 2021-12-17 2022-04-12 广东浪潮智慧计算技术有限公司 FPGA acceleration board card and market data processing method thereof

Also Published As

Publication number Publication date
CN115687708A (en) 2023-02-03

Similar Documents

Publication Publication Date Title
US20170364697A1 (en) Data interworking method and data interworking device
JP5871619B2 (en) Method and apparatus for high-speed processing of financial market depth data
CN109075988B (en) Task scheduling and resource issuing system and method
CN107123047B (en) Data acquisition system based on bond transaction and data acquisition method thereof
WO2020207445A1 (en) Blockchain-based event subscription method and apparatus
CN110134516A (en) Finance data processing method, device, equipment and computer readable storage medium
CN103336672B (en) Method for reading data, device and computing device
US20190294476A1 (en) Methods and modules relating to allocation of host machines
CN108959399A (en) Distributed data deletes flow control method, device, electronic equipment and storage medium
WO2018166145A1 (en) Method and device for batch offering of repayment data
CN111143286A (en) Cloud platform log management method and system
US7606906B2 (en) Bundling and sending work units to a server based on a weighted cost
CN111399909A (en) Service system data distribution processing method, device and storage medium
CN107391402A (en) A kind of data operating method, device and a kind of data operation card
CN110489418B (en) Data aggregation method and system
CN111949681A (en) Data aggregation processing device and method and storage medium
CN113886419A (en) SQL statement processing method and device, computer equipment and storage medium
CN115687708B (en) Transaction quotation data processing method and device and data processing board card
CN107194712B (en) Method and device for recording change information of shared account and method and system for supplementing account of internal account
US11521207B2 (en) Tokenization request handling at a throttled rate in a payment network
CN104657087B (en) A kind of method, apparatus and system of virtual disk mapping
CN114860460B (en) Database acceleration method and device and computer equipment
CN115391053A (en) Online service method and device based on CPU and GPU hybrid calculation
CN115168012A (en) Thread pool concurrent thread number determining method and related product
CN107193657A (en) Low latency server based on SOLAFLARE network interface cards

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant