CN103544068A - Process to process communication method and device for browsers and browser - Google Patents

Process to process communication method and device for browsers and browser Download PDF

Info

Publication number
CN103544068A
CN103544068A CN201310493264.0A CN201310493264A CN103544068A CN 103544068 A CN103544068 A CN 103544068A CN 201310493264 A CN201310493264 A CN 201310493264A CN 103544068 A CN103544068 A CN 103544068A
Authority
CN
China
Prior art keywords
thread
browser kernel
kernel process
browser
operational order
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.)
Granted
Application number
CN201310493264.0A
Other languages
Chinese (zh)
Other versions
CN103544068B (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.)
Beijing Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing 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 Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201310493264.0A priority Critical patent/CN103544068B/en
Publication of CN103544068A publication Critical patent/CN103544068A/en
Application granted granted Critical
Publication of CN103544068B publication Critical patent/CN103544068B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a process to process communication method and device for browsers and a browser. The method includes: using a first browser inner core process to judge that the current webpage is suitable for being loaded by a second browser inner core process; using the first browser inner core process to receiving and trigger an operation instruction for loading the current webpage; by a first I/O (input/output) process, transmitting the operation instruction to a second I/O process; using the second I/O process to transmit the operation instruction to a label page sub-process corresponding to the current webpage; using the label page sub-process to render the current webpage according to the operation instruction; by the second I/O process, transmitted the rendered webpage to the first I/O process; using the first browser inner core process to display the rendered webpage. By the method, webpage loading speed and efficiency are increased.

Description

The method of interprocess communication, device and browser in a kind of browser
Technical field
The present invention relates to the technical field of browser, particularly relate to device and a kind of browser of interprocess communication in the method for interprocess communication in a kind of browser, a kind of browser.
Background technology
Browser can be divided into two parts, i.e. kernel and shell from framework.Browser kernel refers to the core of browser, can be divided into two parts: render engine (layout engineer or Rendering Engine) and JS(JavaScript) engine.Content (comprising HTML, XML, image etc.), organize your messages that render engine is mainly responsible for obtaining webpage (as add CSS(Cascading Style Sheets, CSS (cascading style sheet) list) etc.), and the display mode of calculating webpage, then can export display or printer to.The difference of browser kernel has difference for the grammar explanation of webpage, so the effect of playing up is not identical yet.All web browsers, email client and other need the application program of editor, display network content all to need kernel.JS engine is to resolve Javascript language, carries out the dynamic effect that webpage realized in Javascript language.
The kind of browser kernel has a lot, more common browser kernel has the Trident kernel that the IE browser of Microsoft uses at present, the Gecko kernel that Firefox browser uses, the Webkit kernel that the Safari browser of apple and the Chrome browser of Google use, and, the Presto kernel that Opera browser adopts.
When user initiates the request of a browsing page by browser, browser is the content from targeted website downloading web pages by kernel, and then analyzing web page content, carries out script, calculates typesetting, finally outputs to display and is shown to user.Each browser has a kernel, no matter user opens how many webpages by a browser process, browser all uses same kernel to explain and carries out.
But this single kernel browser has significant limitation, because the network standard that webpage is supported according to certain kernel often making, the network standard of supporting for certain particular core, other kernels possibly cannot be supported (even cannot support) well.For example, user uses Firefox browser browsing page, and the kernel of Firefox browser can be supported W3C standard well, therefore uses this browser can browse the webpage of making according to W3C standard.If use the Internet bank but user wants to browse China Merchants Bank's webpage, Firefox browser just cannot meet this user's request.Because Internet bank's function of China Merchants Bank website needs ActiveX pin function, and this function may only have the kernel of IE to support, user just cannot use Internet bank's function of China Merchants Bank in the situation that using Firefox browser like this.
Summary of the invention
In view of the above problems, the present invention has been proposed to a kind of a kind of method and corresponding a kind of device that carries out webpage loading that carries out webpage loading that overcomes the problems referred to above or address the above problem is at least in part provided, and a kind of browser.
According to one aspect of the present invention, the method of interprocess communication in a kind of browser is provided, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described method comprises:
Adopt described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Adopt described the first browser kernel process to receive and trigger the operational order that current web page loads;
By a described I/O thread, described operational order is sent in described the 2nd I/O thread;
Adopt described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Adopt described Shipping Options Page face thread according to described operational order, current web page to be played up;
By described the 2nd I/O thread, the webpage after playing up is sent in a described I/O thread;
Adopt described the first browser kernel process to show the webpage after playing up.
Alternatively, the step that described the first browser kernel process reception of described employing triggers the operational order of current web page loading comprises:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
Alternatively, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
The step that described the 2nd I/O thread of described employing is sent to described operational order in the Shipping Options Page face thread that current web page is corresponding comprises:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
Alternatively, described the first browser kernel process of described employing judges that current web page is suitable for the step that adopts the second browser kernel process to load:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel process of coupling is the second browser kernel process.
Alternatively, the step that the described URL that adopts current web page in described the first browser kernel process searches the browser kernel of current web page coupling comprises:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
According to a further aspect in the invention, the device of interprocess communication in a kind of browser is provided, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described device comprises:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
Alternatively, described operational order receiver module is also suitable for:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
Alternatively, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
Described the second operational order sending module is also suitable for:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
Alternatively, described adaptive kernel determination module is also suitable for:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel of coupling is the second browser kernel process.
Alternatively, described adaptive kernel determination module is also suitable for:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
According to a further aspect in the invention, a kind of browser is provided, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described browser comprises:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
The present invention can be when judging that current web page is suitable for adopting the second browser kernel process to load, two browser kernel processes of browser are switched, can use the operational order of the first browser kernel process can pass on accurately and efficiently in the Shipping Options Page face thread of webpage of appointment carries out, realize normally playing up and loading of webpage, return in the first browser kernel process and show, improved loading velocity and the efficiency of webpage.
Above-mentioned explanation is only the general introduction of technical solution of the present invention, in order to better understand technological means of the present invention, and can be implemented according to the content of instructions, and for above and other objects of the present invention, feature and advantage can be become apparent, below especially exemplified by the specific embodiment of the present invention.
Accompanying drawing explanation
By reading below detailed description of the preferred embodiment, various other advantage and benefits will become cheer and bright for those of ordinary skills.Accompanying drawing is only for the object of preferred implementation is shown, and do not think limitation of the present invention.And in whole accompanying drawing, by identical reference symbol, represent identical parts.In the accompanying drawings:
Fig. 1 shows the flow chart of steps of the embodiment of the method for interprocess communication in a kind of according to an embodiment of the invention browser; And,
Fig. 2 shows the structured flowchart of the device embodiment of interprocess communication in a kind of according to an embodiment of the invention browser.
Embodiment
Exemplary embodiment of the present disclosure is described below with reference to accompanying drawings in more detail.Although shown exemplary embodiment of the present disclosure in accompanying drawing, yet should be appreciated that and can realize the disclosure and the embodiment that should do not set forth limits here with various forms.On the contrary, it is in order more thoroughly to understand the disclosure that these embodiment are provided, and can by the scope of the present disclosure complete convey to those skilled in the art.
With reference to Fig. 1, show the flow chart of steps of the embodiment of the method for interprocess communication in a kind of according to an embodiment of the invention browser, wherein, described browser can comprise the first browser kernel process and the second browser kernel process, described the first browser kernel process can comprise an I/O(input/output, I/O) thread, described the second browser kernel process comprises can the 2nd I/O thread, I/O distribution of information thread and window thread, described window thread can comprise one or more Shipping Options Page face threads, specifically can comprise the following steps:
Step 101, adopts described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
It should be noted that, browser can comprise two or more browser kernels, the first browser kernel can be the browser kernel of the current acquiescence use of browser, the browser kernel of this acquiescence can be system setting, also can make user arrange, can be specifically the browser kernel of the contour performance of Webkit kernel.Certainly, can also be Gecko kernel, Presto kernel etc., the embodiment of the present invention is not limited this.
The second browser kernel can be built-in other browser kernels except the first browser kernel of browser, can be in the loading of the adaptive current web page of some situation, can be Trident kernel (being IE kernel), comprise IE-com kernel (compatible IE kernel) and/or IE-stand kernel.Certainly, can also be Gecko kernel, Presto kernel etc., the embodiment of the present invention is not limited this.
Process (Process) is the basis of operating system configuration, can be a program of carrying out; It can be the program example moving in computing machine; It can be an entity can distributing to processor and be carried out by processor; Can be that execution by single order shows, current state and one group of described active unit of relevant system resource.
Thread (thread), is called as Lightweight Process (Lightweight Process, LWP) sometimes, is the minimum unit that program is carried out stream.Thread is an entity in process, the base unit of independently being dispatched and assigning by system, thread oneself does not have system resource, only has any requisite resource that is in operation, but it can share whole resources that process has with other thread that belongs to a process together.
A thread can create and cancel another thread, between a plurality of threads in same process, can concurrently carry out.Each program has a thread at least, if program only has a thread, that is exactly program itself.Thread is a single sequential control flow process in program.In single program, move a plurality of threads simultaneously and complete different work, be called multithreading.
IPC(Inter-Process Communication, interprocess communication), be a kind of mechanism of Inter-Process Communication, the process of operating system and thread can pass through its swap data and message.
In browser, an I/O thread and the 2nd I/O thread can be for the transmission of data; Window thread can carry out corresponding Web Page Processing for the label webpage (Tab page) of browser, and particularly, Shipping Options Page face thread can carry out web page resources loading processing for corresponding webpage.
In a preferred embodiment of the present invention, described step 101 specifically can comprise following sub-step:
Sub-step S11 adopts the URL of current web page to search the browser kernel process that current web page mates in described the first browser kernel process;
In specific implementation, know that webpage that user asks and the method for the fitting relation between browser kernel process (being that current web page is suitable for adopting which browser kernel process to load) can have multiple.
Wherein, can be according to the content and the presetting rule that obtain from solicited message, know webpage that user asks and the fitting relation between described browser kernel process.
Particularly, presetting rule can comprise specific adaptation rule, General adaptive rule and/or adaptation rule not, in the process of request of loading webpage, can be according to specific adaptation rule, General adaptive rule and/or adaptation rule not, know webpage that user asks and the fitting relation between browser kernel process.Wherein, specific adaptation rule can comprise the fitting relation between webpage and browser kernel process, General adaptive rule can be included as user and select the fastest browser kernel process of average loading velocity or for user's selection, network standard is supported to best browser kernel process, and adaptation rule can not comprise the not fitting relation between webpage and browser kernel process.
Because browser also can send the load request information about Web page loading to corresponding server according to the load request receiving, server can return to response message for load request information, in response message, can carry the information such as content of pages of some webpages, therefore under this kind of situation, can also, according to content and the presetting rule of the acquisition of the response message for load request information of returning from server, again know the browser kernel process of the webpage adaptation of asking with user; If the adaptive browser kernel process of again knowing is different from the adaptive browser kernel process of knowing based on solicited message before this, select the adaptive browser kernel process of again knowing to load the webpage that user asks.
In another method, because browser also can send the load request information about Web page loading to corresponding server according to the load request receiving, server can return to response message for load request information, in response message, can carry the information such as content of pages of some webpages, therefore in the method, can be directly according to content and the presetting rule of the response information acquisition of returning for load request information of returning from server, know webpage that user asks and the fitting relation between browser kernel process.
Certainly, also can be according to content and the presetting rule of the content obtaining from load request, the response information acquisition of returning for load request information returned from server, jointly know webpage that user asks and the fitting relation between browser kernel process.
In addition, while stating in the use the method Web page loading that each embodiment provides, can also detect loading the situation of the webpage of user's request; If there is the phenomenon that meets preset browser kernel process switching condition, according to presetting rule, again know the browser kernel process with this webpage adaptation; Select the adaptive browser kernel process of again knowing to load the webpage that user asks.Wherein, the phenomenon that meets preset browser kernel process switching condition can comprise: in loading procedure, detect institute's loading velocity slower, or the abnormal demonstration of webpage after loaded, detected, etc.
In a preferred embodiment of the present invention, described sub-step S11 further can comprise following sub-step:
Sub-step S111 searches the browser kernel process with the URL adaptation of current web page in preset white list;
And/or,
Sub-step S112 searches the browser kernel process not adaptive with the URL of current web page in preset blacklist.
In specific implementation, in white list, can record specific adaptation rule and/or General adaptive rule, in blacklist, can record not adaptation rule.
Sub-step S12, when finding, judges that the browser kernel process of coupling is the second browser kernel process.
When finding the browser kernel process of current browser in white list, can judge that this browser kernel process is as the second browser kernel process;
When finding the browser kernel process of current browser in blacklist, can judge that the browser kernel process except this browser kernel process is the second browser kernel process.
Step 102, adopts described the first browser kernel process to receive and triggers the operational order that current web page loads;
The concrete indication of the web page operation that operational order can carry out for user, for example, advance, retreat etc., specifically can comprise operation name and/or operating parameter.
In a preferred embodiment of the present invention, described step 102 specifically can comprise following sub-step:
Sub-step S21, adopts a described I/O thread to receive and triggers the operational order that current web page loads.
In specific implementation, the first browser kernel process can adopt an I/O thread to receive operational order.
Step 103, is sent to described operational order in described the 2nd I/O thread by a described I/O thread;
Current web page is suitable for adopting the second browser kernel to load, and the efficiency loading for improving webpage, can adopt the second browser kernel process to load, and needs to obtain corresponding operation and refers to.
Step 104, adopts described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
When the 2nd I/O thread gets operational order account, just can be sent to the Shipping Options Page face thread that current web page is corresponding, in order to carry out the loading of web page resources.
In a preferred embodiment of the present invention, in described operational order, can comprise the second browser kernel process identification (PID) (Process ID) and Shipping Options Page face thread identification (Tab page ID); Described step 104 can comprise following sub-step:
Sub-step S31, extracts the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Sub-step S32, adopts described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
The second browser kernel process identification (PID) can be for identifying the second browser kernel process, Shipping Options Page face thread identification can be for the sub-thread of the identification (RFID) tag page, and the second browser kernel process identification (PID) and Shipping Options Page face thread identification can be indicated the Shipping Options Page face thread that unique current page is corresponding.
System message recursion instruction (PostMessage) is Windows API(Application Programming Interface, application programming interface) in a common mathematical function, for a piece of news is put into message queue.This function is put into (sending) by a message and is associated in message queue to the thread creating with specified window, does not wait for that thread processing messages just returns, and is asynchronous message pattern.Message in message queue is by calling GetMessage function and PeekMessage function is obtained.
Message processing function in the embodiment of the present invention is arranged in the 2nd I/O thread, each specific operational order need to be forwarded again, because the operational order that it finally receives or carry out in the 2nd I/O thread, under concrete example can be shown in:
Figure BDA0000398424180000111
Wherein, Msg is operational order.
Because above message processing function is being in the 2nd I/O thread, so process function OnExecuteCodeEx, cannot directly process operational order, also need again to forward once to the Shipping Options Page face thread of current window thread, then in the message processing function WndProc of current Shipping Options Page face thread, process.
Step 105, adopts described Shipping Options Page face thread according to described operational order, current web page to be played up;
The mode that different browser kernels is played up can be different, take Trident kernel as example, and loading and play up html page can be as follows:
1, the order of Trident kernel downloading web pages resource is from top to bottom, and the order of playing up web page resources is also from top to bottom, downloads and plays up simultaneously and carry out;
2, when being rendered into certain part of the page, all parts above it have all been downloaded (being not that all elements that are associated have all been downloaded);
If 3 labels that run into semantic interpretation embed file (JS script, CSS pattern), so now the downloading process of Trident kernel can be enabled independent connection and downloaded;
4 and resolve after download, in resolving, stop the download of all down elements of the page;
5, style sheet is after download completes, by with before resolve together with all style sheet of download, after being parsed, will all elements (containing what played up in the past) before this being re-started and be played up;
6, in JS, CSS if any redefining, rear defined function will cover front defined function.
It should be noted that, loading the required web page resources of current web page can be obtained to server request by the first browser kernel process, and by an I/O thread, web page resources is sent in the 2nd I/O thread.
Step 106, is sent to the webpage after playing up in a described I/O thread by described the 2nd I/O thread;
After the second browser kernel completes and plays up operation, just the webpage after playing up can be sent to the first browser kernel and show.
Step 107, adopts described the first browser kernel process to show the webpage after playing up.
In specific implementation, the first browser kernel process can comprise UI(User Interface, user interface) thread, can adopt the webpage after UI thread is played up to show.
The present invention can be when judging that current web page is suitable for adopting the second browser kernel process to load, two browser kernel processes of browser are switched, can use the operational order of the first browser kernel process can pass on accurately and efficiently in the Shipping Options Page face thread of webpage of appointment carries out, realize normally playing up and loading of webpage, return in the first browser kernel process and show, improved loading velocity and the efficiency of webpage.
With reference to Fig. 2, show the structured flowchart of the device embodiment of interprocess communication in a kind of according to an embodiment of the invention browser, described browser can comprise the first browser kernel process and the second browser kernel process, described the first browser kernel process can comprise an I/O thread, described the second browser kernel process can comprise the 2nd I/O thread, I/O distribution of information thread and window thread, described window thread can comprise one or more Shipping Options Page face threads, and described device specifically can comprise as lower module:
Adaptive kernel determination module 201, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module 202, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module 203, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module 204, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module 205, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module 206, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module 207, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
In a preferred embodiment of the present invention, described operational order receiver module can also be suitable for:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
In a preferred embodiment of the present invention, in described operational order, can comprise the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
Described the second operational order sending module can also be suitable for:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
In a preferred embodiment of the present invention, described adaptive kernel determination module can also be suitable for:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel of coupling is the second browser kernel process.
In a preferred embodiment of the present invention, described adaptive kernel determination module can also be suitable for:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
For device embodiment, because it is substantially similar to embodiment of the method, so description is fairly simple, relevant part is referring to the part explanation of embodiment of the method.
The present invention also provides a kind of browser, described browser can comprise the first browser kernel process and the second browser kernel process, described the first browser kernel process can comprise an I/O thread, described the second browser kernel process can comprise the 2nd I/O thread, I/O distribution of information thread and window thread, described window thread can comprise one or more Shipping Options Page face threads, and described browser specifically can comprise as lower module:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
In a preferred embodiment of the present invention, described operational order receiver module can also be suitable for:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
In a preferred embodiment of the present invention, in described operational order, can comprise the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
Described the second operational order sending module can also be suitable for:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
In a preferred embodiment of the present invention, described adaptive kernel determination module can also be suitable for:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel of coupling is the second browser kernel process.
In a preferred embodiment of the present invention, described adaptive kernel determination module can also be suitable for:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
The algorithm providing at this is intrinsic not relevant to any certain computer, virtual system or miscellaneous equipment with demonstration.Various general-purpose systems also can with based on using together with this teaching.According to description above, it is apparent constructing the desired structure of this type systematic.In addition, the present invention is not also for any certain programmed language.It should be understood that and can utilize various programming languages to realize content of the present invention described here, and the description of above language-specific being done is in order to disclose preferred forms of the present invention.
In the instructions that provided herein, a large amount of details have been described.Yet, can understand, embodiments of the invention can not put into practice in the situation that there is no these details.In some instances, be not shown specifically known method, structure and technology, so that not fuzzy understanding of this description.
Similarly, be to be understood that, in order to simplify the disclosure and to help to understand one or more in each inventive aspect, in the above in the description of exemplary embodiment of the present invention, each feature of the present invention is grouped together into single embodiment, figure or sometimes in its description.Yet, the method for the disclosure should be construed to the following intention of reflection: the present invention for required protection requires than the more feature of feature of clearly recording in each claim.Or rather, as reflected in claims below, inventive aspect is to be less than all features of disclosed single embodiment above.Therefore, claims of following embodiment are incorporated to this embodiment thus clearly, and wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and can the module in the equipment in embodiment are adaptively changed and they are arranged in one or more equipment different from this embodiment.Module in embodiment or unit or assembly can be combined into a module or unit or assembly, and can put them into a plurality of submodules or subelement or sub-component in addition.At least some in such feature and/or process or unit are mutually repelling, and can adopt any combination to combine all processes or the unit of disclosed all features in this instructions (comprising claim, summary and the accompanying drawing followed) and disclosed any method like this or equipment.Unless clearly statement in addition, in this instructions (comprising claim, summary and the accompanying drawing followed) disclosed each feature can be by providing identical, be equal to or the alternative features of similar object replaces.
In addition, those skilled in the art can understand, although embodiment more described herein comprise some feature rather than further feature included in other embodiment, the combination of the feature of different embodiment means within scope of the present invention and forms different embodiment.For example, in the following claims, the one of any of embodiment required for protection can be used with array mode arbitrarily.
All parts embodiment of the present invention can realize with hardware, or realizes with the software module moved on one or more processor, or realizes with their combination.It will be understood by those of skill in the art that and can use in practice microprocessor or digital signal processor (DSP) to realize the some or all functions according to the some or all parts in the equipment of interprocess communication in the browser of the embodiment of the present invention.The present invention for example can also be embodied as, for carrying out part or all equipment or device program (, computer program and computer program) of method as described herein.Realizing program of the present invention and can be stored on computer-readable medium like this, or can there is the form of one or more signal.Such signal can be downloaded and obtain from internet website, or provides on carrier signal, or provides with any other form.
It should be noted above-described embodiment the present invention will be described rather than limit the invention, and those skilled in the art can design alternative embodiment in the situation that do not depart from the scope of claims.In the claims, any reference symbol between bracket should be configured to limitations on claims.Word " comprises " not to be got rid of existence and is not listed as element or step in the claims.Being positioned at word " " before element or " one " does not get rid of and has a plurality of such elements.The present invention can be by means of including the hardware of some different elements and realizing by means of the computing machine of suitably programming.In having enumerated the unit claim of some devices, several in these devices can be to carry out imbody by same hardware branch.The use of word first, second and C grade does not represent any order.Can be title by these word explanations.
The invention discloses the method for interprocess communication in A1, a kind of browser, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described method comprises:
Adopt described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Adopt described the first browser kernel process to receive and trigger the operational order that current web page loads;
By a described I/O thread, described operational order is sent in described the 2nd I/O thread;
Adopt described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Adopt described Shipping Options Page face thread according to described operational order, current web page to be played up;
By described the 2nd I/O thread, the webpage after playing up is sent in a described I/O thread;
Adopt described the first browser kernel process to show the webpage after playing up.
A2, the method as described in A1, the step that described the first browser kernel process of described employing receives the operational order that triggers current web page loading comprises:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
A3, the method as described in A1, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
The step that described the 2nd I/O thread of described employing is sent to described operational order in the Shipping Options Page face thread that current web page is corresponding comprises:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
A4, the method as described in A1, described the first browser kernel process of described employing judges that current web page is suitable for the step that adopts the second browser kernel process to load:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel process of coupling is the second browser kernel process.
A5, the method as described in A4, the step that the described URL that adopts current web page in described the first browser kernel process searches the browser kernel of current web page coupling comprises:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
The invention also discloses the device of interprocess communication in B6, a kind of browser, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described device comprises:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
B7, the device as described in B6, described operational order receiver module is also suitable for:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
B8, the device as described in B6, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
Described the second operational order sending module is also suitable for:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
B9, the device as described in B6, described adaptive kernel determination module is also suitable for:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel of coupling is the second browser kernel process.
B10, the device as described in B9, described adaptive kernel determination module is also suitable for:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
The invention also discloses C11, a kind of browser, comprise in B6 to B10 the device of interprocess communication in the browser described in any one.

Claims (10)

1. the method for interprocess communication in a browser, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described method comprises:
Adopt described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Adopt described the first browser kernel process to receive and trigger the operational order that current web page loads;
By a described I/O thread, described operational order is sent in described the 2nd I/O thread;
Adopt described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Adopt described Shipping Options Page face thread according to described operational order, current web page to be played up;
By described the 2nd I/O thread, the webpage after playing up is sent in a described I/O thread;
Adopt described the first browser kernel process to show the webpage after playing up.
2. the method for claim 1, is characterized in that, the step that described the first browser kernel process of described employing receives the operational order that triggers current web page loading comprises:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
3. the method for claim 1, is characterized in that, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
The step that described the 2nd I/O thread of described employing is sent to described operational order in the Shipping Options Page face thread that current web page is corresponding comprises:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
4. the method for claim 1, is characterized in that, described the first browser kernel process of described employing judges that current web page is suitable for the step that adopts the second browser kernel process to load:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel process of coupling is the second browser kernel process.
5. method as claimed in claim 4, is characterized in that, the step that the described URL that adopts current web page in described the first browser kernel process searches the browser kernel of current web page coupling comprises:
In preset white list, search the browser kernel process with the URL adaptation of current web page;
And/or,
In preset blacklist, search the browser kernel process not adaptive with the URL of current web page.
6. the device of interprocess communication in a browser, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described device comprises:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
7. device as claimed in claim 6, is characterized in that, described operational order receiver module is also suitable for:
Adopt a described I/O thread to receive and trigger the operational order that current web page loads.
8. device as claimed in claim 6, is characterized in that, described operational order comprises the second browser kernel process identification (PID) and Shipping Options Page face thread identification;
Described the second operational order sending module is also suitable for:
Extract the second browser kernel process identification (PID) and Shipping Options Page face thread identification in described operational order;
Adopt described the 2nd I/O thread to adopt system message recursion instruction that described operational order is sent in described the second browser kernel process identification (PID) and Shipping Options Page face thread corresponding to Shipping Options Page face thread identification.
9. device as claimed in claim 6, is characterized in that, described adaptive kernel determination module is also suitable for:
In described the first browser kernel process, adopt the URL of current web page to search the browser kernel process that current web page mates;
When finding, judge that the browser kernel of coupling is the second browser kernel process.
10. a browser, described browser comprises the first browser kernel process and the second browser kernel process, described the first browser kernel process comprises an I/O thread, described the second browser kernel process comprises the 2nd I/O thread and window thread, described window thread comprises one or more Shipping Options Page face threads, and described browser comprises:
Adaptive kernel determination module, is suitable for adopting described the first browser kernel process to judge that current web page is suitable for adopting the second browser kernel process to load;
Operational order receiver module, is suitable for adopting described the first browser kernel process to receive and triggers the operational order that current web page loads;
The first operational order sending module, is suitable for by a described I/O thread, described operational order being sent in described the 2nd I/O thread;
The second operational order sending module, is suitable for adopting described the 2nd I/O thread that described operational order is sent in the Shipping Options Page face thread that current web page is corresponding;
Rendering module, is suitable for adopting described Shipping Options Page face thread according to described operational order, current web page to be played up;
Webpage sending module, is suitable for by described the 2nd I/O thread, the webpage after playing up being sent in a described I/O thread;
Web displaying module, is suitable for adopting described the first browser kernel process to show the webpage after playing up.
CN201310493264.0A 2013-10-18 2013-10-18 Process to process communication method and device for browsers and browser Active CN103544068B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310493264.0A CN103544068B (en) 2013-10-18 2013-10-18 Process to process communication method and device for browsers and browser

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310493264.0A CN103544068B (en) 2013-10-18 2013-10-18 Process to process communication method and device for browsers and browser

Publications (2)

Publication Number Publication Date
CN103544068A true CN103544068A (en) 2014-01-29
CN103544068B CN103544068B (en) 2017-05-24

Family

ID=49967543

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310493264.0A Active CN103544068B (en) 2013-10-18 2013-10-18 Process to process communication method and device for browsers and browser

Country Status (1)

Country Link
CN (1) CN103544068B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104020993A (en) * 2014-05-30 2014-09-03 北京金山网络科技有限公司 Webpage rendering method and device
CN110442400A (en) * 2019-08-15 2019-11-12 网易(杭州)网络有限公司 Browser control method and device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2009139845A1 (en) * 2008-05-13 2009-11-19 Google Inc. Multi-process browser architecture
CN101655863A (en) * 2009-04-24 2010-02-24 北京搜狗科技发展有限公司 Method for loading web pages in browser and browser
CN102624891A (en) * 2012-03-08 2012-08-01 腾讯科技(深圳)有限公司 Method for switching kernel of browser and corresponding browser
CN102917074A (en) * 2012-11-09 2013-02-06 北京奇虎科技有限公司 Server-side browser realization method and server
CN102915256A (en) * 2012-03-08 2013-02-06 北京金山安全软件有限公司 Message transmission method and device under multi-core browser
CN102981903A (en) * 2012-12-10 2013-03-20 北京奇虎科技有限公司 Method for process multiplexing in multi-core browser and multi-core browser of process multiplexing

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2009139845A1 (en) * 2008-05-13 2009-11-19 Google Inc. Multi-process browser architecture
CN101655863A (en) * 2009-04-24 2010-02-24 北京搜狗科技发展有限公司 Method for loading web pages in browser and browser
CN102624891A (en) * 2012-03-08 2012-08-01 腾讯科技(深圳)有限公司 Method for switching kernel of browser and corresponding browser
CN102915256A (en) * 2012-03-08 2013-02-06 北京金山安全软件有限公司 Message transmission method and device under multi-core browser
CN102917074A (en) * 2012-11-09 2013-02-06 北京奇虎科技有限公司 Server-side browser realization method and server
CN102981903A (en) * 2012-12-10 2013-03-20 北京奇虎科技有限公司 Method for process multiplexing in multi-core browser and multi-core browser of process multiplexing

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104020993A (en) * 2014-05-30 2014-09-03 北京金山网络科技有限公司 Webpage rendering method and device
CN110442400A (en) * 2019-08-15 2019-11-12 网易(杭州)网络有限公司 Browser control method and device

Also Published As

Publication number Publication date
CN103544068B (en) 2017-05-24

Similar Documents

Publication Publication Date Title
CN103500210A (en) Method, device and browser for carrying out webpage loading
KR101391894B1 (en) content request optimization
US8122104B2 (en) Method and system for providing XML-based asynchronous and interactive feeds for web applications
JP5335083B2 (en) New tab page and bookmark toolbar in browser
US8812658B1 (en) Pre-fetching of network page content
US9292253B2 (en) Methods and apparatus for voiced-enabling a web application
US9400633B2 (en) Methods and apparatus for voiced-enabling a web application
US9781262B2 (en) Methods and apparatus for voice-enabling a web application
CN103559097A (en) Inter-process communication method and device in browser and browser
CN103500194A (en) Method, device and browser for loading webpage
US10157612B2 (en) Methods and apparatus for voice-enabling a web application
CN102982169A (en) Browser and method for isolating webpage plugins
CN102096582A (en) Off-line gadget integration development environment
JP6418004B2 (en) Event notification program, event notification method, and event notification device
US20210209526A1 (en) Landing page processing method, device and medium
CN102999578A (en) Method and device for processing page element
US9292252B2 (en) Methods and apparatus for voiced-enabling a web application
CN102902802A (en) Webpage transcoding method and device
CN103034495A (en) Browser capable of isolating plug-in in webpage and webpage plug-in isolating method
US20240179224A1 (en) Systems and methods for rendering interactive web pages
WO2015080903A1 (en) Systems and methods for executing aspects of a document
CN102981848A (en) Webpage main body element processing browser and method
CN102981844A (en) Browser treating webpage main body element and method treating the webpage main body element
CN110889073B (en) Page request response method, server and computer storage medium
CN102981845A (en) Page elements processing method of browser and page elements processing device of browser

Legal Events

Date Code Title Description
C06 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
TR01 Transfer of patent right

Effective date of registration: 20220714

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.

TR01 Transfer of patent right