CN106325966B - Software compilation method and device - Google Patents

Software compilation method and device Download PDF

Info

Publication number
CN106325966B
CN106325966B CN201510367841.0A CN201510367841A CN106325966B CN 106325966 B CN106325966 B CN 106325966B CN 201510367841 A CN201510367841 A CN 201510367841A CN 106325966 B CN106325966 B CN 106325966B
Authority
CN
China
Prior art keywords
compiler task
clients
server
client
upper limit
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
CN201510367841.0A
Other languages
Chinese (zh)
Other versions
CN106325966A (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.)
Nanjing ZTE New Software Co Ltd
Original Assignee
Nanjing ZTE New Software 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 Nanjing ZTE New Software Co Ltd filed Critical Nanjing ZTE New Software Co Ltd
Priority to CN201510367841.0A priority Critical patent/CN106325966B/en
Priority to PCT/CN2016/077582 priority patent/WO2017000601A1/en
Publication of CN106325966A publication Critical patent/CN106325966A/en
Application granted granted Critical
Publication of CN106325966B publication Critical patent/CN106325966B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The present invention provides a kind of software compilation method and devices, wherein this method comprises: server-side distributes compiler task to one or more client and locally;Wherein, which is the foundation that server-side and one or more client are compiled respective source code;After the completion of server-side compiles the source code for being synchronized to server-side, application library is synchronized to one or more client, and receive the process of one or more client transmission;Server-side completes Software package according to application library and process.It solves the problems, such as that compiling large software efficiency is lower in the related technology through the invention, and then improves large software compiling efficiency.

Description

Software compilation method and device
Technical field
The present invention relates to the communications fields, in particular to a kind of software compilation method and device.
Background technique
Mega project software architecture is complicated, and size of code is big, and millions of line codes are even more;Development language multiplicity, such as Compilation, c, c++, the low-level languages such as scripting language and high-level language weave in;Code organization is complicated, and the level of nesting is more, into Journey is made of multicomponent, there is complicated hierarchical dependencies between component.Therefore single machine completely compiles the soft of a mega project Part version, very time-consuming.
The popular distributed compilation tool of industry has IncrediBuild, distcc at present.The two tools are all In precompile file distributing to each client machine, client completes compiling and destination file is returned to server-side progress chain again It connects.
IncrediBuild is the distributed compilation software of a corresponding Visual C++, is not suitable for our linux environment The compiling of lower multi-language environment.
The shortcomings that using when distcc, is that its load-balancing algorithm is too simple, and the agent process of distcc is to each work Make the current load of machine not perceive, the unique foundation for distributing preprocessed file is that host appears in the change of DISTCC_HOST environment Order in amount, host name is more forward, will obtain more compiler tasks, however when certain machine performance mistakes in compiling field Difference, whole compilation performance can be remarkably decreased, this when blocking the compiler task operation of Make operation on these machines Performance change is particularly evident.
The tool of a similar principles was also made in presently relevant technology, basic principle is host downloading source code, is packaged and divides It is dealt into each client, each client decompresses again.Task distribution is using static distribution algorithms, it is believed that every machine performance is consistent, puts down Distribute.Task distribution granularity it is also more extensive, be by veneer be granularity distribute, i.e., a compiler task is exactly to compile one All application software on veneer.
For in the related technology, the lower problem of compiling large software efficiency is not put forward effective solutions also.
Summary of the invention
The present invention provides a kind of software compilation method and devices, at least to solve to compile large software effect in the related technology The lower problem of rate.
According to an aspect of the invention, there is provided a kind of software compilation method, comprising: server-side to one or more Client and local distribution compiler task;Wherein, the compiler task is the server-side and one or more of clients Hold the foundation being compiled to respective source code;It, will after the completion of the server-side compiles the source code for being synchronized to the server-side Application library is synchronized to one or more of clients, and receives the process that one or more of clients are sent;Institute It states server-side and Software package is completed according to the application library and the process.
Optionally, it includes: that acquisition is one that server-side, which distributes compiler task to one or more client and locally, Or the compiler task upper limit of multiple client;Distributed according to the compiler task upper limit to one or more of clients The compiler task.
Optionally, obtain one or more of clients the compiler task upper limit include: obtain it is one or The hardware asset information of multiple client;The compiler task upper limit is obtained according to the hardware asset information.
Optionally, obtaining the compiler task upper limit according to the hardware asset information includes: to be obtained by following formula The compiler task upper limit: compiler task upper limit y=(core*2) the * 0.6+ (mem) * 0.4;Wherein, described in core is represented The hardware-core number of one or more client, mem represent the memory size of one or more of clients, and unit is G。
Optionally, it includes: that acquisition is one that server-side, which distributes compiler task to one or more client and locally, Or the performance parameter of multiple client;One or more of client distributions are determined whether according to the performance parameter The compiler task, and distribute to one or more of clients the quantity of the compiler task.
Optionally, it is communicated between the server-side and one or more of clients using TIPC.
According to another aspect of the present invention, a kind of software translating device is provided, comprising: distribution module is used for one A or multiple client and local distribution compiler task;Wherein, the compiler task be the server-side and it is one or The foundation that person's multiple client is compiled respective source code;Processing module, for the clothes will to be synchronized in the server-side Be engaged in end source code compiling after the completion of, application library is synchronized to one or more of clients, and receive it is one or The process that multiple client is sent;Packetization module, for completing Software package according to the application library and the process.
Optionally, the distribution module includes: first acquisition unit, for obtaining one or more of clients The compiler task upper limit;First Dispatching Unit, for being divided according to the compiler task upper limit to one or more of clients Send out compiler task described.
Optionally, the first acquisition unit includes: the first acquisition subelement, for obtaining one or more of visitors The hardware asset information at family end;Second obtains subelement, for obtaining the compiler task according to the hardware asset information Limit.
Optionally, the second acquisition subelement is also used to: obtaining the compiler task upper limit by following formula: described Compiler task upper limit y=(core*2) * 0.6+ (mem) * 0.4;Wherein, core represents the hard of one or more of clients Nucleus number in part, mem represent the memory size of one or more of clients, and unit is G.
Optionally, the distribution module includes: second acquisition unit, for obtaining one or more of clients Performance parameter;Second Dispatching Unit, for determining whether one or more of clients point according to the performance parameter It sends out compiler task described, and distributes the quantity of the compiler task to one or more of clients.
Optionally, it is communicated between the server-side and one or more of clients using TIPC.
Through the invention, compiler task is distributed to one or more client and locally using server-side;Wherein, the volume Translating task is the foundation that server-side and one or more client are compiled respective source code;It will be synchronized in server-side After the completion of the source code compiling of server-side, application library is synchronized to one or more client, and receives one or more visitor The process that family end is sent;Server-side completes Software package according to application library and process.It is large-scale soft to solve compiling in the related technology The lower problem of part efficiency, and then improve large software compiling efficiency.
Detailed description of the invention
The drawings described herein are used to provide a further understanding of the present invention, constitutes part of this application, this hair Bright illustrative embodiments and their description are used to explain the present invention, and are not constituted improper limitations of the present invention.In the accompanying drawings:
Fig. 1 is the flow chart of software compilation method according to an embodiment of the present invention;
Fig. 2 is software translating apparatus structure block diagram according to an embodiment of the present invention;
Fig. 3 is software translating apparatus structure block diagram (one) according to an embodiment of the present invention;
Fig. 4 is software translating apparatus structure block diagram (two) according to an embodiment of the present invention;
Fig. 5 is software translating apparatus structure block diagram (three) according to an embodiment of the present invention;
Fig. 6 is distributed compilation network diagram according to an embodiment of the present invention;
Fig. 7 is service end system block diagram according to an embodiment of the present invention;
Fig. 8 is FTP client FTP block diagram according to an embodiment of the present invention;
Fig. 9 is serve end program flow chart according to an embodiment of the present invention;
Figure 10 is client-side program flow chart according to an embodiment of the present invention.
Specific embodiment
Hereinafter, the present invention will be described in detail with reference to the accompanying drawings and in combination with Examples.It should be noted that not conflicting In the case of, the features in the embodiments and the embodiments of the present application can be combined with each other.
It should be noted that description and claims of this specification and term " first " in above-mentioned attached drawing, " Two " etc. be to be used to distinguish similar objects, without being used to describe a particular order or precedence order.
A kind of software compilation method is provided in the present embodiment, and Fig. 1 is software translating side according to an embodiment of the present invention The flow chart of method, as shown in Figure 1, the process includes the following steps:
Step S102, server-side distribution compiler task to one or more client and locally;Wherein, the compiler task The foundation that respective source code is compiled for server-side and one or more client;
Application library is synchronized to one after the completion of server-side compiles the source code for being synchronized to the server-side by step S104 Or multiple client, and receive the process of one or more client transmission;
Step S106, server-side complete Software package according to the application library and the process.
Through the above steps, server-side and client are according to itself compiler task to being synchronized to the server-side and the client The source code at end is compiled, and server-side completes Software package according to the application library and the process, compared to using in the related technology IncrediBuild distcc distributed compilation tool carries out software translating, solves and compiles large software in the related technology The lower problem of efficiency, and then improve large software compiling efficiency.
Above-mentioned steps S102 is related to server-side to one or more client and local distribution compiler task, needs to illustrate , compiler task can be distributed in several ways.In one alternate embodiment, one or more client is obtained The compiler task upper limit distributes the compiler task to one or more client according to the compiler task upper limit.Another can Select in embodiment, obtain the performance parameter of one or more client, according to the performance parameter determine whether one or Multiple client distributes the compiler task, and distributes the quantity of the compiler task to one or more client.
During obtaining the compiler task upper limit of one or more client, in one alternate embodiment, obtain The hardware asset information for taking one or more client obtains the compiler task upper limit according to the hardware asset information.
According to hardware asset information obtain the compiler task upper limit mode can there are many, in one alternate embodiment, The compiler task upper limit: compiler task upper limit y=(core*2) * 0.6+ (mem) * 0.4 is obtained by following formula;Wherein, Core represents the hardware-core number of one or more client, and the memory that mem represents one or more client is big Small, unit is G.
In one alternate embodiment, it is communicated between server-side and one or more client using TIPC.
Through the above description of the embodiments, those skilled in the art can be understood that according to above-mentioned implementation The method of example can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but it is very much In the case of the former be more preferably embodiment.Based on this understanding, technical solution of the present invention is substantially in other words to existing The part that technology contributes can be embodied in the form of software products, which is stored in a storage In medium (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal device (can be mobile phone, calculate Machine, server or network equipment etc.) execute the method that each embodiment of the present invention is somebody's turn to do.
A kind of update device of software version in communication equipment is additionally provided in the present embodiment, and the device is for realizing upper Embodiment and preferred embodiment are stated, the descriptions that have already been made will not be repeated.As used below, term " module " can be with Realize the combination of the software and/or hardware of predetermined function.Although device described in following embodiment is preferably come with software real It is existing, but the realization of the combination of hardware or software and hardware is also that may and be contemplated.
Fig. 2 is software translating apparatus structure block diagram according to an embodiment of the present invention, as shown in Fig. 2, the device includes: distribution Module 22 is used for one or more client and local distribution compiler task;Wherein, which is server-side and one The foundation that a or multiple client is compiled respective source code;Processing module 24, for clothes will to be synchronized in server-side It is engaged in after the completion of the source code compiling at end, application library is synchronized to one or more client, and receive one or more visitor The process that family end is sent;Packetization module 26, for completing Software package according to the application library and the process.
Fig. 3 is software translating apparatus structure block diagram (one) according to an embodiment of the present invention, as shown in figure 3, distribution module 22 It include: first acquisition unit 222, for obtaining the compiler task upper limit of one or more client;First Dispatching Unit 224, for distributing the compiler task to one or more client according to the compiler task upper limit.
Fig. 4 is software translating apparatus structure block diagram (two) according to an embodiment of the present invention, as shown in figure 4, first obtains list Member 222 includes: the first acquisition subelement 2222, and for obtaining the hardware asset information of one or more client, second is obtained Subelement 2224 is taken, for obtaining the compiler task upper limit according to the hardware asset information.
Optionally, the second acquisition subelement 2224 is also used to: obtaining the compiler task upper limit: the compiling by following formula Task upper limit y=(core*2) * 0.6+ (mem) * 0.4;Wherein, core represents the hardware-core of one or more client Number, mem represent the memory size of one or more client, and unit is G.
Fig. 5 is software translating apparatus structure block diagram (three) according to an embodiment of the present invention, as shown in figure 5, distribution module 22 It include: second acquisition unit 226, for obtaining the performance parameter of one or more client;Second Dispatching Unit 228 is used In determining whether that one or more client distributes the compiler task according to the performance parameter, and it is to one or more A client distributes the quantity of the compiler task.Optionally, between server-side and one or more client using TIPC into Row communication.
It should be noted that above-mentioned modules can be realized by software or hardware, for the latter, Ke Yitong Following manner realization is crossed, but not limited to this: above-mentioned module is respectively positioned in same processor;Alternatively, above-mentioned module be located at it is more In a processor.
The embodiments of the present invention also provide a kind of storage mediums.Optionally, in the present embodiment, above-mentioned storage medium can To be arranged to store the program code for executing following steps:
S1, server-side distribution compiler task to one or more client and locally;Wherein, which is service The foundation that end and one or more client are compiled respective source code;
Application library is synchronized to one or more after the completion of server-side compiles the source code for being synchronized to the server-side by S2 A client, and receive the process of one or more client transmission;
S3, server-side complete Software package according to the application library and the process.
Optionally, in the present embodiment, above-mentioned storage medium can include but is not limited to: USB flash disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or The various media that can store program code such as CD.
Optionally, in the present embodiment, processor executes above-mentioned S1, S2 according to program code stored in storage medium And S3.
Optionally, the specific example in the present embodiment can be with reference to described in above-described embodiment and optional embodiment Example, details are not described herein for the present embodiment.
One, alternative embodiment of the present invention uses following technical scheme:
1. forming distributed compilation network using more linux servers, as shown in Figure 6.
2. source code is synchronized on each compiler server using svn.
3. distributing compiler task to client and locally from server-side after the completion of source code downloading.Client and local volume It has been translated that, library is synchronized to each node of network, by Process Synchronization to server-side.
4. finally completing Software package in server-side.
5. the foundation of distributed compilation network.
Distributed compilation network is communicated using tipc, first detects finger daemon in each node installation of network.Detection guard into Journey regularly sends broadcast message, and other nodes are received to establish after broadcast message and be contacted with broadcaster, and acquisition network respectively saves in real time Point online information.
6. task distribution algorithms:
The compiler task of server-side is granularity division by library and process, and process depends on public library, first compiles so library obtains, Compilation process again is completed in library compiling.
Compiler task is distributed in server-side progress, and the algorithm that server-side is combined using static and dynamic is come to client With compiler task is locally-assigned.
1.1 static allocation algorithms:
Compiling is the mistake for consuming very much memory and central processing unit (Central Processing Unit, referred to as CPU) Journey is each compiling machine static state setting maximum task upper limit first according to compiling machine hardware configuration.Compiling machine first reports oneself Hardware asset information.
Hardware resource and the corresponding relationship of the compiling upper limit are as follows:
Compiler task upper limit y=(core*2) * 0.6+ (mem) * 0.4core represents hardware-core number, and it is big that mem represents memory Small, unit is G.When this is according to operation, a formula that actual resource consumption is probably estimated.General 8 core, 8G memory 12 A compiler task is the upper limit.
1.2 dynamic allocation algorithms:
Compiling machine timing reports the performance parameter of itself to server-side, and performance parameter is that reflection own resource can utilize situation A numerical value.Empirical equation is as follows:
Performance=CPU_USE_RATE*0.8+FREE_MEM_RATE*0.2
The performance parameter and the compiling machine that server-side is reported according to compiling machine just decide whether to continue to send in compiler task number Compiler task is sent out to the node.Strategy be it is such, do not distributed if the compiler task of the compiling machine reaches the upper limit compiling appoint Business;If Performance is less than 90%, and the compiling machine compiler task does not reach the upper limit, then continues to distribute compiler task, Otherwise stop distributing compiler task.
7. the reliability of distributed compilation network communicates.
A problem of also a problem of distributed network is exactly reliable communication.Distributed compilation requires the feelings not disconnected in network Under condition, it can guarantee that message reliably distributes.TIPC when more message are concurrent also can packet loss, so distributed compilation tool is done A reliable news module.Reliable news module principle is similar to synchronization message, all to be disappeared using what reliable news interface was sent Breath is all distributed by reliable news thread, and reliable news thread is the lower thread of priority ratio, the message all bands sent Upper sequence number, opposite end must just calculate and send successfully to a response, this message after receiving message;Postpone weight if not replying Hair announces that message sends failure after reaching the repeating transmission upper limit.Reliable news thread can send out message and give source sender of the message, inform Message sends failure.
8. reliable file synchronization function.
File synchronization uses tcp message transmission data, and tcp agreement is to send message in order, will not be out-of-order.File synchronization Promoter send filename and file verification information, the files such as recipient carry out crc verification after transmitting, it is ensured that file is same The accuracy of step.
Distributed compilation tool is write using c language, by guarding tool, services ending tool and client utility three It is grouped as;The tool of guarding is to broadcast the message in two layers of domain, and carry out networking according to the broadcast message of other nodes;Server-side work Have and be responsible for task collection and distribution, client-side management, location resource allocation and compiler task execute;Client utility is responsible for local Resource management with report, location resource allocation and compiler task execute.
Two, 1. server-sides and FTP client FTP composition.
Server-side and FTP client FTP block diagram, such as Fig. 7, shown in Fig. 8.
Compiler task search module, major function are parsing configuration files, read and need the veneer that compiles, cpu, library and Process.
Compiler task distribution module, major function are formulation task distribution policies, are distributed to task, to compiler task As a result it is tracked and is counted.
File synchronization module, major function are that certain types of file is wanted in search, the network section provided according to session management Point information, synchronous documents.
Message module, major function are to establish the reliable news channel of two layers of tipc agreement, and by message priority and disappear Thread belonging to ceasing carries out message dispatch.
Performance statistic module, major function are the local cpu of statistics, memory service condition.
Compiler task execution module, major function are to be performed locally compilation process, and handle according to the compiler task distributed Compiling result is reported to server-side.
Session management module, major function are the link setup between network node, chain rupture, keep-alive management.
2. client and server-side program flow diagram
2.1 serve end program flow charts
Session management module and reliable news module are first initialized after powering on, session management uses the data structure of chained list, Reliable news realization principle can refer to above-mentioned introduction.Next creation TCP finger daemon (for file synchronization module), reliably Message threads, file synchronization thread, Complied executing thread, server-side task management thread, compiler task dispatch thread.It is above first After beginningization, judge whether client is ready to, starts to distribute library compiler task if being ready to, application library has all compiled Start library after finishing to synchronize, i.e., the library file for compiling generation on each node will be synchronized on other nodes.After library synchronously completes Start to distribute process compiler task, after process compiler task compiles, each client will compile the process compiling file generated It is synchronized to server-side.After all process files all synchronously complete, each client will be to the compiling log of server synchronization local File.
Fig. 9 is serve end program flow chart according to an embodiment of the present invention, as shown in figure 9, the process includes the following steps:
Step S902, first initializes session management module after powering on;
Step S904 initializes reliable news module;
Step S906 parses compiler task;
Next step S908 creates TCP finger daemon;
Step S910 creates reliable news thread;
Step S912 creates file synchronization thread;
Step S914 creates Complied executing thread;
Step S916, server-side task management thread;
Step S918, compiler task dispatch thread;
Step S920 after the above initialization, judges whether client is ready to, in the situation that judging result is no Under, step S922 is executed, in the case where the judgment result is yes, executes step S944;
Step S922 sleeps one second;
Step S924 starts to distribute library compiler task;
Step S926 judges whether that library encoding tasks distribute completion, if the determination result is NO, executes step S928 executes step S930 in the case where the judgment result is yes;
Step S928 sleeps one second;
Step S930, sync vault to other nodes;
Step S932 judges whether that local and client synchronization are completed, if the determination result is NO, executes step S934 executes step S936 in the case where the judgment result is yes;
Step S934 sleeps one second;
Step S936 starts to distribute process compiler task;
Step S938, the process of judging whether are synchronized to server-side, if the determination result is NO, execute step S940 executes step S942 in the case where the judgment result is yes;
Step S940 sleeps one second;
Step S942 informs that each client exits.
2.2 client-side program flow charts
Seemingly, client does not have task collection, client-side management, task distribution module to basic initialization process and main classes. After client receives compiler task, starting compiling waits compilings to terminate to return to compiling result to server-side.
Figure 10 is client-side program flow chart according to an embodiment of the present invention, and as shown in Figure 10, which includes following step It is rapid:
Step S1002, first initializes session management module after powering on;
Step S1004 initializes reliable news module;
Step S1006 creates TCP finger daemon;
Step S1008 creates assignment file synchronizing thread;
Step S1010 creates reliable news thread;
Step S1012 creates Complied executing thread;
Step S1014 creates client-side management thread;
Step S1016 reports local be ready to server-side;
Step S1018 judges whether there is library compiler task, if the determination result is NO, executes step S1020, In the case where the judgment result is yes, step S1022 is executed;
Step S1020 sleeps one second;
Step S1022 executes compiler task and returns to compiling result;
Step S1024 judges whether that all library compilings are completed, if the determination result is NO, executes step S1026 executes step S1028 in the case where the judgment result is yes;
Step S1026 sleeps one second;
Step S1028, sync vault to other nodes;
Step S1030 judges whether there is process compiler task, if the determination result is NO, executes step S1032 executes step S1034 in the case where the judgment result is yes;
Step S1032 sleeps one second;
Step S1034 executes compiler task and returns to compiling result;
Step S1036 judges whether that all process compilings finish, if the determination result is NO, executes step S1038 executes step S1040 in the case where the judgment result is yes;
Step S1038 sleeps one second;
Step S1040, synchronized process file to server-side;
Step S1042, synchronization log file to server-side;
Step S1044, judges whether to receive and exits command, and if the determination result is NO, executes step S1046, In the case where the judgment result is yes, step S1048 is executed;
Step S1046 sleeps one second;
Step S1048, is exited.
Abnormality processing in 2.3 compilation processes
If there is Network Abnormal in compilation process, main root is distributed again according to the compiler task for being issued to lost contact client.
In conclusion the tool provided through the invention is environmentally run in linux, when solving large software compiling Between a too long distributed compilation tool, it is to distribute compiler task and compiler language using library and process as granularity there are also compile It is unrelated to translate device, using static and dynamic task allocation algorithms, the resource of each compiling machine is effectively utilized.With the relevant technologies In tool compare, have a following difference: 1 carries out that source code is synchronous using svn, improves the speed of source code downloading;2 every machines Install after distributed tool can automatic network-building, each node can initiate compiler task as server-side;The distribution of 3 tasks Granularity is thinner, and allocation algorithm greatly improves compilation speed in such a way that static dynamic combines;4 use reliable message Communication modes improve the reliability of distributed compilation.Solve the problems, such as that large software compilation time is too long, it is super for us The compiling of large software can save general more than 6 hours.Compared with the relevant technologies, the present invention can intelligently set up distributed compilation Network, server-side is according to client machine performance and Current hardware resource utilization reasonable distribution compiler task, using reliable Message communication increases the safety of distributed compilation.
Obviously, those skilled in the art should be understood that each module of the above invention or each step can be with general Computing device realize that they can be concentrated on a single computing device, or be distributed in multiple computing devices and formed Network on, optionally, they can be realized with the program code that computing device can perform, it is thus possible to which they are stored It is performed by computing device in the storage device, and in some cases, it can be to be different from shown in sequence execution herein Out or description the step of, perhaps they are fabricated to each integrated circuit modules or by them multiple modules or Step is fabricated to single integrated circuit module to realize.In this way, the present invention is not limited to any specific hardware and softwares to combine.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, made any to repair Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.

Claims (6)

1. a kind of software compilation method characterized by comprising
Server-side distribution compiler task to one or more client and locally;Wherein, the compiler task is the service The foundation that end and one or more of clients are compiled respective source code;
After the completion of the server-side compiles the source code for being synchronized to the server-side, application library is synchronized to one or more A client, and receive the process that one or more of clients are sent;
The server-side completes Software package according to the application library and the process;
Wherein, the server-side includes: to one or more client and local distribution compiler task
Obtain the compiler task upper limit of one or more of clients;
Distribute the compiler task to one or more of clients according to the compiler task upper limit;
Wherein, the compiler task upper limit for obtaining one or more of clients includes:
Obtain the hardware asset information of one or more of clients;
The compiler task upper limit is obtained according to the hardware asset information;
Wherein, described to include: according to the hardware asset information acquisition compiler task upper limit
The compiler task upper limit is obtained by following formula:
Compiler task upper limit y=(core*2) the * 0.6+ (mem) * 0.4;Wherein, core represents one or more of visitors The hardware-core number at family end, mem represent the memory size of one or more of clients, and unit is G.
2. the method according to claim 1, wherein server-side distribution to one or more client and locally Compiler task includes:
Obtain the performance parameter of one or more of clients;
Determine whether that one or more of clients distribute the compiler task according to the performance parameter, and to institute State the quantity that one or more client distributes the compiler task.
3. method according to claim 1 or 2, which is characterized in that the server-side and one or more of clients It is communicated between end using TIPC.
4. a kind of software translating device characterized by comprising
Distribution module is used for one or more client and local distribution compiler task;Wherein, the compiler task is clothes The foundation that business end and one or more of clients are compiled respective source code;
Processing module, for after the completion of the server-side compiles the source code for being synchronized to the server-side, application library to be synchronized to One or more of clients, and receive the process that one or more of clients are sent;
Packetization module, for completing Software package according to the application library and the process;
The distribution module includes:
First acquisition unit, for obtaining the compiler task upper limit of one or more of clients;
First Dispatching Unit, for distributing the compiling to one or more of clients according to the compiler task upper limit Task;
The first acquisition unit includes:
First obtains subelement, for obtaining the hardware asset information of one or more of clients;
Second obtains subelement, for obtaining the compiler task upper limit according to the hardware asset information;
The second acquisition subelement is also used to:
The compiler task upper limit is obtained by following formula:
Compiler task upper limit y=(core*2) the * 0.6+ (mem) * 0.4;Wherein, core represents one or more of visitors The hardware-core number at family end, mem represent the memory size of one or more of clients, and unit is G.
5. device according to claim 4, which is characterized in that the distribution module includes:
Second acquisition unit, for obtaining the performance parameter of one or more of clients;
Second Dispatching Unit, described in determining whether the distribution of one or more of clients according to the performance parameter Compiler task, and distribute to one or more of clients the quantity of the compiler task.
6. device according to claim 4 or 5, which is characterized in that the server-side and one or more of clients It is communicated between end using TIPC.
CN201510367841.0A 2015-06-29 2015-06-29 Software compilation method and device Active CN106325966B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201510367841.0A CN106325966B (en) 2015-06-29 2015-06-29 Software compilation method and device
PCT/CN2016/077582 WO2017000601A1 (en) 2015-06-29 2016-03-28 Software compiling method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510367841.0A CN106325966B (en) 2015-06-29 2015-06-29 Software compilation method and device

Publications (2)

Publication Number Publication Date
CN106325966A CN106325966A (en) 2017-01-11
CN106325966B true CN106325966B (en) 2019-08-13

Family

ID=57609303

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510367841.0A Active CN106325966B (en) 2015-06-29 2015-06-29 Software compilation method and device

Country Status (2)

Country Link
CN (1) CN106325966B (en)
WO (1) WO2017000601A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107391221B (en) * 2017-07-28 2020-08-07 迈普通信技术股份有限公司 Scheduling server, compiling server and distributed compiling method
CN109542446A (en) * 2017-08-14 2019-03-29 中兴通讯股份有限公司 A kind of compiling system, method and compiler
CN110825370B (en) * 2018-08-08 2023-04-18 阿里巴巴集团控股有限公司 Mobile terminal application development method, device and system
CN111301789B (en) * 2018-12-11 2022-08-12 顺丰科技有限公司 Application software packaging method and device
CN113032035B (en) * 2019-12-24 2022-07-12 Oppo广东移动通信有限公司 Configuration file processing method and device and electronic equipment
CN112083927B (en) * 2020-07-06 2023-06-30 宁波三星医疗电气股份有限公司 Method for acquiring SVN version information of software in power acquisition terminal on site

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101140525A (en) * 2007-10-17 2008-03-12 中兴通讯股份有限公司 Distributed translate and edit method
CN101582041A (en) * 2009-05-25 2009-11-18 中山大学 Distributed compilation method and system based on web
CN103870310A (en) * 2014-02-18 2014-06-18 小米科技有限责任公司 Program compilation method and relevant device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8458661B2 (en) * 2006-03-31 2013-06-04 Ebay Inc. Distributed parallel build system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101140525A (en) * 2007-10-17 2008-03-12 中兴通讯股份有限公司 Distributed translate and edit method
CN101582041A (en) * 2009-05-25 2009-11-18 中山大学 Distributed compilation method and system based on web
CN103870310A (en) * 2014-02-18 2014-06-18 小米科技有限责任公司 Program compilation method and relevant device

Also Published As

Publication number Publication date
CN106325966A (en) 2017-01-11
WO2017000601A1 (en) 2017-01-05

Similar Documents

Publication Publication Date Title
CN106325966B (en) Software compilation method and device
CN110389900B (en) Distributed database cluster testing method and device and storage medium
CN104881494B (en) The methods, devices and systems synchronous with Redis server progress data
CN107172187B (en) A kind of SiteServer LBS and method
CN107590072A (en) A kind of application and development and the method and apparatus of test
US9760410B2 (en) Technologies for fast synchronization barriers for many-core processing
CN104699541A (en) Method, device, data transmission assembly and system for synchronizing data
CN104468638B (en) A kind of distributed data processing method and system
CN103716403A (en) SAAS application deployment method and system for PAAS platform under cloud computing environment
CN104954411A (en) Method for sharing network resource by distributed system, terminal thereof and system thereof
EP3616057B1 (en) Method for intra-subgraph optimization in tuple graph programs
CN107479981B (en) Processing method and device for realizing synchronous call based on asynchronous call
CN102025753B (en) Load balancing method and equipment for data resources of servers
CN104462158A (en) Data grabbing method and data grabbing system
Lou et al. Startup-aware dependent task scheduling with bandwidth constraints in edge computing
CN109376020B (en) Data processing method, device and storage medium under multi-block chain interaction concurrence
EP4287017A2 (en) Automatic configuration of logging infrastructure for software deployments using source code
CN106445784B (en) Information monitoring method and device
CN109446272A (en) A kind of data processing method and device of server
CN113708971A (en) Openstack cloud platform deployment method and related device
CN114398286A (en) Automatic testing method and device, electronic equipment and storage medium
CN109032786A (en) Jenkins continuous integrating cluster, APP packaging method and server
CN112181431A (en) Distributed data packaging method and system, storage medium and computing device
Hwang Design and implementation of cloud offloading framework among devices for web applications
CN111382046B (en) Test system, method and device for distributed software system

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
TA01 Transfer of patent application right

Effective date of registration: 20190717

Address after: 210012 Nanjing, Yuhuatai District, South Street, Bauhinia Road, No. 68

Applicant after: Nanjing Zhongxing Software Co., Ltd.

Address before: 518057 Nanshan District science and technology, Guangdong Province, South Road, No. 55, No.

Applicant before: ZTE Corporation

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant