TWI359377B - System and method for providing execute-in-place f - Google Patents

System and method for providing execute-in-place f Download PDF

Info

Publication number
TWI359377B
TWI359377B TW95111326A TW95111326A TWI359377B TW I359377 B TWI359377 B TW I359377B TW 95111326 A TW95111326 A TW 95111326A TW 95111326 A TW95111326 A TW 95111326A TW I359377 B TWI359377 B TW I359377B
Authority
TW
Taiwan
Prior art keywords
file
memory
driver
file system
interface
Prior art date
Application number
TW95111326A
Other languages
Chinese (zh)
Other versions
TW200703102A (en
Inventor
Carsten Otte
Ulrich Weigand
Original Assignee
Ibm
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 Ibm filed Critical Ibm
Publication of TW200703102A publication Critical patent/TW200703102A/en
Application granted granted Critical
Publication of TWI359377B publication Critical patent/TWI359377B/en

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Memory System (AREA)
  • Stored Programmes (AREA)

Description

1359377 九、發明說明· 【發明所屬之技術領域】 本發明廣義上有關操作系統,且尤其是有w 用於實施現場執行功能之系統及方法的操作系味 【先前技術】 先前技術電腦系…统含有不變性大量儲存裝置(如硬碟 機)以保持程式及資料檔案。此等檔案之內交 円各必須被載入 RAM(隨機存取記憶體)類型的系統記憶體, 姐 以便由CPU(中 央處理單元)存取或執行。此操作通常係由 .± 节由一代表應用程式 之操作系統施行。先前技術電腦系統及操作系統支援虛擬 s己憶體及需求分頁。應用並不直接使用李硌4给触, 尔、-元δ己憶體位址以 指定其使用之代碼和資料;而是其使用「 風擬位址」以指 定記憶體位置,其係藉著一由CPU電路實施且由操作系統 控制之分頁機制翻譯成系統記憶體位址。此允許操作系統 免於必須將程式和資料㈣全數載人RAM。而是系統記憶 體被分為一特定大小之塊(稱為「頁」),且操作系統僅在 存取此特定頁時才將檔案内容之對應塊載入各記憶體頁 中。此過程通常係稱為「需求分頁(demandpaging)J。 此方法之缺點在於RAM係需要保持程式和資料檔案 之内合,減少可用於其他目的之RAM。同時,其通常需要 二時間以將内容下載至RAM » —些先前技術電腦系統因 此提供不同類型之不變性儲存裝置,其可由cpu依照如 RAM( 6己憶體定址裝置)之相同方式直接存取。—記憶體定 5 1359377 址裝置之先前技術具體實施例係一快閃記憶卡。記憶體定 址裝置允許CPU執行代碼且存取儲存於其上之資料,無須 先將内容下載至RAM内。此直接執行駐留在一記憶體定址 裝置上之代碼的方法係稱為「現場執行(execute-in-place)」。為 了將現場執行功能提供予在一支援虛擬記憶體之操作系統 上執行之應用,該操作系統必須控制分頁機制,使得—應 用之位址空間的某些虛擬位址被映射至由記憶體定址穿置 支援之位址範圍内的系統記憶體位址。1359377 IX. INSTRUCTIONS OF THE INVENTION · TECHNICAL FIELD OF THE INVENTION The present invention relates broadly to operating systems, and in particular to operating systems and methods for performing field execution functions. [Prior Art] Prior Art Computer Systems Contains invariant mass storage devices (such as hard disk drives) to maintain programs and data files. Each of these files must be loaded into a RAM (random access memory) type of system memory for access or execution by the CPU (central processing unit). This operation is usually performed by an operating system that represents the application. Prior art computer systems and operating systems support virtual suffixes and demand paging. The application does not directly use Li Wei 4 to give the er, - δ δ recall address to specify the code and data to be used; instead, it uses the "Wind Address" to specify the memory location, which is based on The paging mechanism implemented by the CPU circuit and controlled by the operating system translates into a system memory address. This allows the operating system to be free of the need to load the program and data (4) all in RAM. Instead, the system memory is divided into blocks of a certain size (called "pages"), and the operating system loads the corresponding blocks of the file contents into the memory pages only when accessing the particular page. This process is often referred to as "demandpaging". The disadvantage of this method is that the RAM needs to keep the program and data files inside and reduce the RAM that can be used for other purposes. At the same time, it usually takes two hours to download the content. To RAM » Some prior art computer systems thus provide different types of invariant storage devices that can be accessed directly by the CPU in the same manner as RAM (6 Replica Addressing Device). - Memory Prior to 5 1359377 Device The technical embodiment is a flash memory card. The memory addressing device allows the CPU to execute code and access the data stored thereon without first downloading the content into the RAM. This direct execution resides on a memory addressing device. The method of the code is called "execute-in-place". In order to provide live execution functionality to an application executing on an operating system that supports virtual memory, the operating system must control the paging mechanism such that certain virtual addresses of the application's address space are mapped to address by memory. Set the system memory address within the supported address range.

其他先前技術電腦系統提供虛擬化能力。虛擬化係藉 由一在一單一電腦系統上執行之軟體程式實施,其通常係 稱為「超營理器(hypervisor)」)’但允許多個「客戶(guest)」Other prior art computer systems provide virtualization capabilities. Virtualization is implemented by a software program executed on a single computer system, which is often referred to as a "hypervisor" but allows multiple "guests".

(虛擬)操作系統各在一個別之「虛擬機器」中並行地執行。 各虛擬機器對於在内執行之操作系統看似其本身係一真實 電腦系統,完整地具有CPU、RAM及輸入/輸出(ι/〇 )裝 置。存取至此等虛擬組件係由超管理器截取且翻譯成為存 取至真實組件。此允許電腦系統之資源在多個客戶操作系子 統間共享,提供用於增加系統資源之全部使用性。' '、 …认州皿狹1G -电腼糸統之缺點在於, ==在相同超管理Μ執行之多數客戶操作:統 以保持=:各客戶操作系統將會分别地分配虛… -等内谷,且超管理器因而可能必須 多數相回内谷之 之ΜιΐΓ 於實體RAMt。此意即可用於其他目的 -隐體較少’其限制能有效地同步執行之 數。因此,-些先前技術超管理器提供 :…充 V 7目多個客方 6 存取之實體記憶體的區段(共享記憶體區段)。藉由 或資料檔案儲存至—共享記憶體區段中 多個客方 。該等槽案而無須先下載内容進入虛擬ram。該 &段對於/ 、戶操作系統而言看似實體記憶體定址裝 資料及程式檔案通常係使用一標準檔案系統佈 上’一些操作系統係能使用多個對於不同使 係最佳化之不同檔案系統。為允許此,先前技術操 通*係經結構化成為多數組件。在一些操作系統中 中央稽案及記憶體管理組件、複數檔案系統驅動 數1/0裝置驅動器。因此,藉由使用適當之成對檔案 動器及I/O裝置驅動器結合該中央檔案和記憶體管s 件’操作系統允許使用在任何已支援1/0裝置上之相 後槽案系統佈局。然而,先前技術操作系統無法使 精案系統驅動器’以_允許現場執行之方式存取記 址裝置。存取記憶體定址裝置之現場執行支援係依 方式實施。 事實上’一些先前技術操作系統實施完全不允 準槽案系統佈局被用以在記憶體定址裝置上儲存資 尺其需要在此等裝置上之資料依專用於該裝置之方 置。此配置可能具有多數缺點’尤其是對於兼使用 及記憶體定址裝置之電腦系統》支援不同檔案系統 使得系統管理更形困難。可能需要不同工具來格式 理、備份及儲存不同佈局。可能難以自一〗/〇裝置邊 存棺案集至一記憶體定址裝置,或反之亦然。記憶 將程式 可同步 :等共享 置。 局儲存 用方案 作系統 ,係有 器及複 ;系統驅 【組 :何已支 用現存 憶體定 一單一 許一標 料;而 式配 I/O裝置 佈局可 化、管 i移一現 體定址 裝置所需之特— ’疋佈局可能未提供以標準檔案系統佈局出現 另特徵(如實施複雜存取控制及特權檢查)。 ^ 先月’丨技術實施(用於Linux或zSeries之XIP2FS檔 案糸統)提供用於儲在 R健存程式和資料之支援至一使用第二延 I檔案***(ext2)格式之虛擬記憶體定址裝置(由z/vm超 管理器提供之共享記憶體區段),該格式係由Li nux操作系 統提供之該等標準檔案系統格式其-。然而,此方法仍具 有刖文中所述之大多數缺點:其他標準Linux操作系統格式 址無法使用,且此外XIP2FS不提供ext2之所有特徵(如 XIP2FS未支援寫入存取)。 XIP2FS之另一缺點在於其未整合至上述操作系統之 組件結構中;即便XIP2FS使用ext2檔案系統佈局存取檔 案,XIP2FS並未使用Linus ext2檔案系統驅動器以如此進 行,而是再實施需要存取ex t2檔案系統佈局之存取邏輯。 此再次造成XIP2FS不支援ext2之所有特徵,因為僅有完整 ext2邏輯之一子集被再實施。至於另外之缺點,Linux操作 系統之標準ext2檔案系統組件已隨著時間發展且加入新特 徵;例如設有Linux核心版本2.6之ext2檔案系統驅動器的 版本,其係加入支援快速存取極大之目錄結構以及更複雜 之存取控制機制。XIP2FS並未自動地受益於對ext2驅動器 之此等增強;所有需求特徵須在XIP2FS程式碼内再實施。 【發明内容】 本發明之目的在於提供一種藉由一操作系統提供現場 8 1359377 執行功能之方法,其避免上述先前技術的缺點。 本發明揭示一種提供用於實施現場執行功能之新穎系 統和方法的操作系統。The (virtual) operating systems are each executed in parallel in a separate "virtual machine". Each virtual machine's internal operating system appears to be a real computer system with a complete CPU, RAM, and input/output (ι/〇) device. Access to such virtual components is intercepted by the hypervisor and translated into access to real components. This allows the resources of the computer system to be shared among multiple customer operating systems, providing full usability for increased system resources. ' ', ... 认 州 窄 1G - 腼糸 之 之 之 = = = = = = = = = = = = = = = = = = = = = = = = = = = = 多数 = 多数 多数 多数 多数 多数 多数 多数Valley, and the hypervisor may therefore have to go back to the physical RAMt. This can be used for other purposes - less hidden entities' whose limits can be effectively synchronized. Therefore, some prior art hypervisors provide: ... a section of physical memory accessed by multiple clients 6 (shared memory segments). Save to multiple clients in the shared memory section by using or data files. These slots do not need to download content to enter the virtual ram first. The & segment appears to be a physical memory address for the / operating system and the program file is usually distributed using a standard file system. 'Some operating systems can use multiple different systems to optimize the difference. File system. To allow this, prior art operations* have been structured into most components. In some operating systems, the central audit file and memory management component, and the multiple file system drive number 1/0 device drivers. Therefore, the use of the appropriate pair of archivers and I/O device drivers in conjunction with the central archive and memory device s operating system allows the use of a phased slot system layout on any supported 1/0 device. However, prior art operating systems were unable to enable the fine system driver to access the addressing device in a manner that allows for field execution. The on-site execution support of the access memory addressing device is implemented in a manner. In fact, some prior art operating system implementations do not allow the slot system layout to be used to store the resources on the memory addressing device. The data on the devices need to be dedicated to the device. This configuration may have many disadvantages, especially for computer systems that use both memory and memory addressing devices. Supporting different file systems makes system management more difficult. Different tools may be required to format, back up, and store different layouts. It may be difficult to store a file set from a device to a memory address device, or vice versa. Memory Programs can be synchronized: etc. Bureau storage system for the system, with the device and complex; system drive [group: He has used the existing memory to define a single standard material; and the I/O device layout can be changed, the tube i moves a current body addressing device What's needed—The layout may not provide additional features in the standard file system layout (such as implementing complex access control and privilege checking). ^ The first month's technology implementation (XIP2FS file system for Linux or zSeries) provides support for storing R-storage programs and data to a virtual memory addressing device using the second extended file system (ext2) format. (Shared memory section provided by the z/vm hypervisor), which is the standard file system format provided by the Linux operating system. However, this method still has most of the disadvantages described in the text: other standard Linux operating system formats are not available, and XIP2FS does not provide all the features of ext2 (such as XIP2FS does not support write access). Another disadvantage of XIP2FS is that it is not integrated into the component structure of the above operating system; even if XIP2FS uses the ext2 file system layout to access files, XIP2FS does not use the Linus ext2 file system driver to do so, but implements the need to access ex The access logic of the t2 file system layout. This again causes XIP2FS to not support all of the features of ext2 because only a subset of the full ext2 logic is reimplemented. As for the other drawbacks, the standard ext2 file system component of the Linux operating system has evolved over time and added new features; for example, the version of the ext2 file system driver with Linux kernel version 2.6 has been added to support the directory structure with fast access. And more complex access control mechanisms. XIP2FS does not automatically benefit from such enhancements to ext2 drives; all required features must be implemented within the XIP2FS code. SUMMARY OF THE INVENTION It is an object of the present invention to provide a method for providing on-site 8 1359377 execution functions by an operating system that avoids the disadvantages of the prior art described above. An operating system for providing a novel system and method for performing on-site execution functions is disclosed.

本發明所依據之先前技術操作系統包含一具有至一應 用程式之介面的記憶體/檔案管理器、至少一具有一至記憶 體/檔案管理器之檔案系統I/O介面的檔案系統驅動器、至 少一具有一至檔案系統驅動器之裝置I/O介面的裝置驅動 器,其中該至少一裝置驅動器提供存取至至少一 I/O式之裝 置、至少一具有一至檔案系統驅動器之裝置I/O介面的裝置 驅動器,其中該至少一裝置驅動器提供存取至至少一記憶 體定址裝置,其令該操作系統提供一現場執行功能以存取 至少一記憶體定址裝置。 該先前技術操作系統係藉由以下新穎和進步性功能組 件延伸,用於實施現場執行功能:The prior art operating system on which the present invention is based includes a memory/file manager having an interface to an application, at least one file system driver having a file system I/O interface to a memory/file manager, at least one A device driver having a device I/O interface to a file system driver, wherein the at least one device driver provides access to at least one I/O device, at least one device driver having a device I/O interface to a file system driver And wherein the at least one device driver provides access to the at least one memory addressing device that causes the operating system to provide a live execution function to access the at least one memory addressing device. This prior art operating system is extended by the following novel and progressive functional components for implementing on-site execution functions:

一檔案系統直接存取介面,其係在該記憶體/檔案管理 器及至少一檔案系統驅動器間,其中該檔案系統直接存取 介面提供在一特定偏移擷取一特定檔案之内容的系統記憶 體位址的功能,其中該檔案駐留在該記憶體定址裝置上, 一裝置直接存取介面,其係在該至少一檔案系統驅動 器及提供存取該至少一記憶體定址裝置之該至少一裝置驅 動器間,其中該裝置直接存取介面提供擷取至少一記憶體 定址裝置之一特定區塊的系統記憶體位址之功能, 其中該現場執行功能係藉由使用該檔案系統直接存取 介面及該裝置直接存取介面,由該記憶體/檔案管理器、該 至少一檔案系統驅動器、及提供存取至該至少一記憶體定 9 1359377 址裝置之該至少一裝置驅動器提供。 【實施方式】a file system direct access interface between the memory/file manager and at least one file system driver, wherein the file system direct access interface provides system memory for capturing the content of a particular file at a specific offset a function of a body address, wherein the file resides on the memory addressing device, a device direct access interface, the at least one file system driver and the at least one device driver providing access to the at least one memory addressing device The device directly accessing the interface provides a function of capturing a system memory address of a specific block of at least one of the memory addressing devices, wherein the live execution function uses the file system to directly access the interface and the device The direct access interface is provided by the memory/file manager, the at least one file system driver, and the at least one device driver providing access to the at least one memory device. [Embodiment]

第1 A圖類示一電腦系統1〇之方塊圖。電腦系統1〇可為 -個人電腦、_主機型電腦、或任何其他類型之電腦或資 料處理系統,電腦系統丨〇亦可為一由在另—電腦系統上執 行之超管理器所提供的虛擬機器’如後續所述。電腦系統 10包括一中央處理單元(CPU)11、隨機存取記憶體 (RAM)12、一記憶體定址裝置13及_1/〇式之裝置以。在一 具體實施例中,記憶體定址裝置13可為快閃記憶卡。在其 他具體實施例中’記憶體定址裝置丨3可為任何可由CPU丄i 直接存取用於記憶體操作之裝置。在—具體實施例中,I/〇 式之裝置14可為一硬碟機。在其他具體實施例中,1/〇式之 裝置14可為任何允許使用1/〇操作將資料拷貝至/自ram 1 2之裝置。電腦系統1 〇亦可包括記憶體定址裝置丨3及/或 I/O式之裝置14之多數實例》CPU 11、RAM 12及裝置13與 1 4係耦合至一系統匯流排i 5。CPU 11可直接存取ram 1 2 及記憶體定址裝置1 3,用於記憶體操作。I/O式之裝置i 4 無法由CPU Π直接存取用於記憶體操作,然而資料可使用 I/O操作自裝置14拷貝至RAM 12,且反之亦然。電腦系統 1 〇執行一操作系統(後續更詳細討論),其允許執行一或多 數應用程式;該操作系統藉由應用程式管理且調節存取至 電腦系統10之各種資源(CPU 11、RAM 12、裝置13與14)。 在一些具體實施例中,電腦系統1 〇可為一由在另一電 10 1359377 腦系統上執行之超管理器仿真的虛擬機器。第1B圖描述此 一具體實施例,其中電腦系統10由一虛擬CPU11、虛擬 RAM12、及虛擬裝置13及14組成。所有虛擬組件係由超管 理益21提供,其係—在另一電腦系統20上執行之軟體程 式’電腦系統20本身由CPU、ram及裝置組成。超管理器 21提供虛擬组件10_14 ,其完全係軟體,或藉由使用由電腦 系統20提供之虛擬化硬體協助功能。除了虛擬機器1〇,其 他虛擬機器22亦可在超管理器21下並行地在電腦系統2〇上 執行。在一具體實施例中,超管理器21可為由ibm公司所 製造且銷售之Z/VM軟體程式,其係在一 IBM之eServer zSenes主機型電腦上執行。在此具體實施例中,電腦系統 10可為由ζ/VM提供之虛擬機器,且記憶體定址裝置13可為 不連續儲存區段(DCS S) ’其係由Z/VM下定義且可用於虛擬 機器。DSCC係由Z/VM管理之記憶體的一區段其同時可 用於一或多數虛擬機器;即使係使Dcss可同時用於多數虛 擬機器’ z/VM總是僅保持一在電腦系統2〇的真實ram中之 DCSS内容的單一拷貝。Figure 1A shows a block diagram of a computer system. The computer system can be a personal computer, a host computer, or any other type of computer or data processing system, and the computer system can also be a virtual provided by a hypervisor executing on another computer system. The machine 'as described later. The computer system 10 includes a central processing unit (CPU) 11, a random access memory (RAM) 12, a memory addressing device 13, and a _1/device. In a specific embodiment, the memory addressing device 13 can be a flash memory card. In other embodiments, the 'memory addressing device 丨3 can be any device that can be directly accessed by the CPU 丄i for memory operation. In a particular embodiment, the I/〇 device 14 can be a hard disk drive. In other embodiments, the 1/〇 device 14 can be any device that allows data to be copied to/from ram 1 2 using a 1/〇 operation. The computer system 1 can also include a plurality of instances of the memory addressing device 及3 and/or the I/O type device. The CPU 11, the RAM 12, and the devices 13 and 14 are coupled to a system bus i5. The CPU 11 can directly access the ram 1 2 and the memory addressing device 13 for memory operation. The I/O type device i 4 cannot be directly accessed by the CPU for memory operations, however the data can be copied from the device 14 to the RAM 12 using I/O operations, and vice versa. The computer system 1 executes an operating system (discussed in more detail later) that allows execution of one or more applications; the operating system manages and regulates various resources accessed to the computer system 10 by the application (CPU 11, RAM 12, Devices 13 and 14). In some embodiments, computer system 1 can be a virtual machine emulated by a hypervisor executing on another electrical system. Figure 1B depicts this embodiment in which computer system 10 is comprised of a virtual CPU 11, virtual RAM 12, and virtual devices 13 and 14. All virtual components are provided by Supervisor 21, which is a software program executed on another computer system 20. The computer system 20 itself consists of a CPU, a ram, and a device. The hypervisor 21 provides a virtual component 10_14 that is fully software or by using the virtualized hardware assistance functionality provided by the computer system 20. In addition to the virtual machine 1, other virtual machines 22 can also be executed in parallel on the computer system 2 under the hypervisor 21. In one embodiment, hypervisor 21 may be a Z/VM software program manufactured and sold by IBM Corporation, which is executed on an IBM eServer zSenes host computer. In this particular embodiment, computer system 10 can be a virtual machine provided by ζ/VM, and memory addressing device 13 can be a discontinuous storage section (DCS S) 'which is defined by Z/VM and is available for Virtual machine. DSCC is a section of memory managed by Z/VM that can be used for one or more virtual machines at the same time; even if Dcss can be used for most virtual machines at the same time, z/VM always keeps only one in the computer system. A single copy of the DCSS content in the real ram.

可由CPU 11直接存取用 成電腦系統1 0之系統記憶體 於記憶體操作之所有組件構 位址空間3 0,如第1 c圖中所 示。RAM 12和記憶體定址裝置13係系統記憶體位址空間3〇 之。P刀’此外,其他組件(未顯示)可為系統記憶體位址空 間之部分,諸如唯讀記憶體(R〇M)或一視頻卡圖框緩衝 器。由CPU 11執行之每-程式指令及由cpu "執行之指令 所存取的所有記憶體資外斗,必須於執行發生時出現在系統 11 1359377 記憶體位址空間3 0内。為了增加可用記憶體之明顯大小,The CPU 11 can directly access all of the components of the memory of the computer system 10 for memory operation, the address space 30, as shown in Fig. 1c. The RAM 12 and the memory addressing device 13 are system memory address spaces. P-knife' In addition, other components (not shown) may be part of the system memory address space, such as read-only memory (R〇M) or a video card frame buffer. Each memory program executed by the CPU 11 and all memory objects accessed by the instructions executed by the CPU " must appear in the memory address space 30 of the system 11 1359377 when execution occurs. In order to increase the apparent size of the available memory,

且保護在相同電腦系統上並行執行之不同應用程式,免於 意外地修改各其他記憶體,操作系統將一「虛擬位址空間」 提供予各應用程式,且提供存取至虛擬位址空間内系統記 憶體位址空間之已選定部分。雖然CPU 1 1係執行應用程式 碼,其可僅存取出現在應用之虛擬位址空間中的記憶體。 為了在一虛擬位址空間及系統記憶體位址空間間翻譯,虛 擬位址空間及系統記憶體位址空間二者被分成相等大小之 塊,通常稱為^頁」。And protect different applications running in parallel on the same computer system, without accidentally modifying each other memory, the operating system provides a "virtual address space" to each application and provides access to the virtual address space. The selected portion of the system memory address space. Although the CPU 1 1 executes the application code, it can access only the memory that appears in the virtual address space of the application. In order to translate between a virtual address space and a system memory address space, both the virtual address space and the system memory address space are divided into equally sized blocks, commonly referred to as ^pages.

第1 C圖描述電腦系統1 0之系統記憶體位址空間3 0。此 外,其顯示一應用程式之虛擬位址空間31。對於可在虛擬 位址空間3 1内定址之各頁,則必須存在一描述該頁實際狀 態之頁描述符。該頁在任何瞬時可亦可不駐留在系統記憶 體位址空間3 0中。若該頁係出現在系統記憶體位址空間3 0 中*則頁描述符將會指示該事實且將指示該頁在系統記憶 體位址空間3 0中之位置。若該頁不出現在系統記憶體位址 空間30中,該描述符將會指示該事實,且將會含有允許操 作系統將預期經由此頁存取之應用程式内容定位的額外資 訊。用於一虛擬位址空間之所有頁描述符的集合係稱為一 頁表。用於一虛擬位址空間之頁表係由該操作系統維持。 雖然CPU 11係執行虛擬位址空間3 1中之應用程式 碼,由CPU 11存取之每一記憶體位址係使用用於虛擬位址 空間3 1之頁表,自一虛擬位址空間3 1中之虛擬位址翻譯成 一系統記憶體位址空間3 0内的系統記憶體位址。此翻譯係 12 1359377 藉由一分頁機制施行,其可為一硬體或軟體實施或二者之 組合。對於某些具體實施例,該分頁機制係藉由cpu u中 出現之一分頁單元實施。當CPU u存取虛擬位址空間31中 目前未具有一在系統記憶體位址空間3〇内之對應頁的一頁 時,分頁機制造成CPU 11產生一頁錯失中斷。該中斷造成 稱為「頁錯失處置益」之操作系統碼將所需内容帶入系統 記憶體位址空間30内之一些頁内,且更新頁表以映射該虛 擬頁至系統記憶體位址空間30内之此頁。該應用可接著持 續執行且存取該頁。此過程通常係稱為「需求分頁」。 在第1 C圖中所示之範例情況中,虛擬位址空間3丨目前 保持四頁。三頁(32a-32C)含有目前正執行中之應用程式 碼,一頁(32d)含有由該應用存取之資料。包含在頁32a32c 中之應用程式碼係自駐留於區塊34a-34c中I/O式之裝置14 上的應用程式檔案載入。應用程式碼頁32a及32b係事實上 目前出現在系統記憶體位址空間3〇中且駐留在RAM丨2之 頁33a和33b中;同樣地,資料頁32d係出現在系統記憶體位 址空間中且駐留在RAM 12之頁33d中。應用程式碼頁32C 係目前未出現在系統記憶體位址空間3〇中。一旦應用存取 頁32c時’操作系統之頁錯失處置器將會分配一 ram丨2中 之新頁33c(未顯示),施行一 1/〇操作以將區塊34(;之内容拷 貝入33c ’且更新頁表以映射虛擬位址空間31之頁32c至系 統記憶體位址空間30的頁33ce對於頁32a與32b,此過程係 已在第ic圖所示之事例中完成。資料頁32d/33d保持由應用 在執行時產生之内容,其係未自1/〇式之裝置14下載。 13 1359377Figure 1C depicts the system memory address space 30 of the computer system 10. In addition, it displays an application's virtual address space 31. For pages that can be addressed within virtual address space 31, there must be a page descriptor describing the actual state of the page. The page may or may not reside in the system memory address space 30 at any instant. If the page appears in system memory address space 3 0 then the page descriptor will indicate the fact and will indicate the location of the page in system memory address space 30. If the page does not appear in the system memory address space 30, the descriptor will indicate the fact and will contain additional information that allows the operating system to locate the application content that is expected to be accessed via the page. The set of all page descriptors for a virtual address space is called a page table. The page table for a virtual address space is maintained by the operating system. Although the CPU 11 executes the application code in the virtual address space 31, each memory address accessed by the CPU 11 uses a page table for the virtual address space 31, from a virtual address space 3 1 The virtual address in the translation is translated into a system memory address within a system memory address space 30. This translation system 12 1359377 is implemented by a paging mechanism, which can be a hardware or software implementation or a combination of both. For some embodiments, the paging mechanism is implemented by one of the paging units present in the cpu u. When the CPU u accesses a page in the virtual address space 31 that does not currently have a corresponding page within the system memory address space 3, the paging mechanism causes the CPU 11 to generate a one-page miss interrupt. The interrupt causes an operating system code called "page missed benefit" to bring the desired content into some pages within the system memory address space 30, and updates the page table to map the virtual page to the system memory address space 30. This page. The application can then continue to execute and access the page. This process is often referred to as "demand paging." In the example case shown in Figure 1C, the virtual address space 3丨 currently holds four pages. Three pages (32a-32C) contain the application code currently being executed, and one page (32d) contains the data accessed by the application. The application code contained in page 32a32c is loaded from the application archive resident on device I/O type 14 in blocks 34a-34c. The application code pages 32a and 32b are actually present in the system memory address space 3〇 and reside in the pages 33a and 33b of the RAM丨2; likewise, the data page 32d appears in the system memory address space and Remains in page 33d of RAM 12. The application code page 32C is currently not present in the system memory address space. Once the application access page 32c is applied, 'the operating system page miss handler will allocate a new page 33c (not shown) in the ram 2, and perform a 1/〇 operation to copy the contents of the block 34 (; 'And update the page table to map page 32c of virtual address space 31 to page 33ce of system memory address space 30 for pages 32a and 32b, this process has been completed in the example shown in Figure ic. Data page 32d/ 33d maintains the content generated by the application at the time of execution, which is not downloaded from the device 1 of the 1/1 type. 13 1359377

如第1C圖所見,當cpu 11執行一駐留在〗/〇式之裝置 14上的應用程式時,RAM 12之頁係需要保持其執行中之應 用程式瑪。然而,若應用程式駐留在一記憶體定址裝置上 時則不需要’此使得更多RAM 12之頁可用於其他目的(或 另外允許電腦系統10以RAM之較小總量實行其預期之任 務)。此過程通常係稱為「現場執行」。第1D圖描述在虛擬 位址空間31上執行之相同應用,如第1C圖所示,然而現應 用駐留在記憶體定址裝置13而非I/O式之裝置14上,且係現 場執行。如第1D圖中所示,來自應用程式檔案之應用程式 碼駐留在記憶體定址裝置13之區塊35a-c中。因為記憶體定 址裝置1 3係出現在系統記憶體位址空間3 0中,區塊3 5 a及 3 5b可分别直接映射至虛擬位址空間3丨之頁32a和32b。同樣 地’一旦應用存取頁32c’操作系統之頁錯失處置器將會單 純地建立另一在虛擬位址空間31之頁3 2c及系統記憶體位 址空間30的頁35c間之映射;操作系統無須分配在ram 12 中之任何頁。然而’應注意的係資料頁32d係映射至RAM 1 2 之頁33d,正如在第1C圖中所示之方案中。 第1 E圖顯現一未使用本發明之先前技術操作系統4 〇 的組件結構。僅顯示實施第1C及1D圖中所示需求分頁及現 場執行功能所需的該等組件。操作系統40含有一記憶體/ 檔案管理器41 ’其處置經由介面48來自應用程式49之請 求’以存取駐留在I/O式之裝置14或記憶體定址裝置丨3上的 檔案。為了存取在I/O式之裝置14上的檔案,記憶體/檔案 管理器41經由被案系統I/O介面45與檔案***驅動器43相 14 1359377 互作用,其依次經由裝置I/O介面46與裝置驅動器44相互作 用。操作系統40可含有檀案系統驅動器之多數版本,各負 責處置一特定檔案系統類型;每一檔案系統驅動器實施相 同檀案系統I/O介面45。同樣地,操作系統4〇可含有裝置驅 動器之多數版本’各負責處置一特定裝置類型;每一檔案 系統驅動器實施相同裝置I/O介面46 »As seen in Figure 1C, when the CPU 11 executes an application residing on the device 14, the page of the RAM 12 needs to maintain its executing application. However, if the application resides on a memory addressing device, then this does not require 'this allows more pages of RAM 12 to be used for other purposes (or otherwise allows computer system 10 to perform its intended task in a smaller total amount of RAM) . This process is often referred to as "site execution." Figure 1D depicts the same application executed on virtual address space 31, as shown in Figure 1C, but the application now resides on memory addressing device 13 rather than I/O-type device 14, and is performed on-site. As shown in Figure 1D, the application code from the application file resides in blocks 35a-c of memory addressing device 13. Since the memory addressing device 13 appears in the system memory address space 30, the blocks 35a and 35b can be directly mapped to the pages 32a and 32b of the virtual address space 3, respectively. Similarly, once the page of the application access page 32c's operating system misses the handler, it will simply create another mapping between the page 32c of the virtual address space 31 and the page 35c of the system memory address space 30; There is no need to assign any page in ram 12. However, the data page 32d that should be noted is mapped to page 33d of RAM 1 2, as in the scheme shown in Figure 1C. Figure 1E shows a component structure that does not use the prior art operating system of the present invention. Only those components required to implement the demand paging and field execution functions shown in Figures 1C and 1D are shown. Operating system 40 includes a memory/file manager 41' that handles requests from application 49 via interface 48 to access files residing on I/O device 14 or memory addressing device 丨3. In order to access the file on the I/O type device 14, the memory/file manager 41 interacts with the file system driver 43 via the file system I/O interface 45, which in turn passes through the device I/O interface. 46 interacts with device driver 44. Operating system 40 may contain most versions of the hacking system drivers, each responsible for handling a particular file system type; each file system drive implementing the same hacking system I/O interface 45. Similarly, the operating system 4 can contain a majority of the version of the device driver' each responsible for handling a particular device type; each file system driver implements the same device I/O interface 46 »

在如第1E圖中所示之操作系統4〇的組件結構中,裝置 驅動器44(及所有裝置驅動器)之責任係自1/〇式之裝置上 的特定位置將資料拷貝進入RAM,且反之亦然。裝置驅動 器並不瞭解有關裝置之内容或此等内容組織之方式。駐留 在裝置上之資料通常係分成稱為「區塊(bl〇ck)」之塊其 各由一「區塊號碼」辨識》裝置I/O介面46允許請求一裝置 驅動器以從一由區塊號碼B辨識之區塊拷貝進入在位址A 處開始之RAM的區塊,或反之亦然。In the component architecture of the operating system shown in FIG. 1E, the responsibility of the device driver 44 (and all device drivers) is to copy data into the RAM from a specific location on the device, and vice versa. Of course. The device driver does not know the content of the device or how it is organized. The data residing on the device is usually divided into blocks called "blocks" which are each identified by a "block number". The device I/O interface 46 allows a device driver to be requested from a block. The block copy identified by number B enters the block of RAM starting at address A, or vice versa.

為允許結構化儲存資料於一裝置上,操作系統4〇提供 檔案系統驅動器。一檔案系統驅動器允許存取已儲存在一 裝置上之資料,成為一「檔案」之集纟,其各提供位元組 之一有序序列的抽象化。每一檔案係藉著一些由檔案系統 提供之方法辨識,通常稱為「檔名」。該檔案系統持續追蹤 各擋案之哪些位元組被儲存在下方裝置的哪些區塊中。需 要施行此記錄維持之資訊通常係稱為「檔案系統元資料」, 且其本身係儲存在下方裝置中。檔案系統元資料之特定佈 局隨檔案系統而異。在如第…圖中所示之操作系統4〇的組 件結構中,擋案系統驅動器43(及所有檔案系統驅動器)之 15 1359377To allow structured storage of data on a device, the operating system provides a file system driver. A file system driver allows access to data already stored on a device and becomes a collection of "archives" each providing an abstraction of an ordered sequence of one of the bytes. Each file is identified by a method provided by the file system, often referred to as a "file name." The file system continuously tracks which bytes of each file are stored in which blocks of the lower device. Information that needs to be maintained for this record is often referred to as "file system metadata" and is stored in the device below. The specific layout of the file system metadata varies with the file system. In the component structure of the operating system shown in the figure..., the file system driver 43 (and all file system drivers) 15 1359377

責任係實施所有需要的邏輯,以處置該檔案系統元資料饰 局。檔案系統I/O介面45允許請求一檔案系統驅動器自藉由 一些檔名辨識之檔案F來拷貝資料(在檔案F内一特定偏移 處開始)進入在位址A處開始的RAM之區塊中,且反之亦 然。為處置此一請求,檔案系統驅動器將會諮詢檔案系統 元資料,以決定下方裝置之哪一區塊B保持著對應於檔案F 中偏移0之資料,且使用處置下方裝置之裝置驅動器的裝 置I/O介面46,以在該裝置之區塊B及記憶體的特定區塊間 拷貝。Responsibility implements all the logic required to dispose of the file system metadata. The file system I/O interface 45 allows a file system driver to request a file to be copied from a file F identified by some file names (starting at a specific offset in file F) into the block of RAM starting at address A. Medium, and vice versa. In order to process this request, the file system driver will consult the file system metadata to determine which block B of the lower device holds the data corresponding to the offset 0 in file F, and uses the device driver for the device underlying the device. The I/O interface 46 is copied between block B of the device and a particular block of memory.

在如第1 E圖中所示之操作系統40的組件結構中,第1 C 圖中所示之需求分頁功能係因此實施如下:當一應用存取 目前未出現在系統記憶體位址空間中之一頁時,操作系統 之頁錯失處置器(通常係記憶體/檔案管理器4 1之部分)將 自頁描述符決定該應用預期該頁具有之内容。頁描述符藉 由規定欲發現該等内容之一檔案F及檔案F内的一偏移Ο辨 識該等内容。記憶體/檔案管理器41接著會分配RAM 1 2中 之一新頁3 3'c,且經由檔案系統I/O介面45自檔案系統驅動 器43請求,以自檔案F内之偏移Ο將資料拷貝至該新頁中。 如上述,檔案系統驅動器43將會諮詢檔案系統元資料,以 決定下方裝置(在此案例中為I/O式之裝置14)之哪一區塊B 保持該資料,且接著使用裝置驅動器44之裝置I/O介面46, 以將該資料拷貝進入該新頁中。一旦該I/O操作已完成,記 憶體/檔案管理器4 1將據以更新該頁表。 然而,因為先前技術檔案系統I/O介面4 5係不適合該目 16 1359377In the component structure of the operating system 40 as shown in FIG. 1E, the demand paging function shown in FIG. 1C is thus implemented as follows: when an application access does not currently appear in the system memory address space. On one page, the operating system's page miss handler (usually part of the memory/file manager 41) will determine from the page descriptor what the application expects the page to have. The page descriptor identifies the content by specifying an offset in the file F and the file F. The memory/file manager 41 will then allocate a new page 3 3'c in the RAM 1 2 and request it from the file system driver 43 via the file system I/O interface 45 to offset the data from the file F. Copy to this new page. As described above, the file system driver 43 will consult the file system metadata to determine which block B of the lower device (in this case, the I/O type device 14) holds the data, and then uses the device driver 44. The device I/O interface 46 is configured to copy the material into the new page. Once the I/O operation has been completed, the memory/file manager 41 will update the page table accordingly. However, because the prior art file system I/O interface 4 5 is not suitable for the project 16 1359377

的,故可能無法使用檔案系統驅動器43施行現場執行存取 存取駐留在記憶體定址裝置13上之檔案。而是,在第1ES 中所示之操作系統40的组件结構中,現場執行存取係由 XIP管理器42處置,其係緊密地整合於記憶體/檔案管理器 41内,且直接存取記憶體定址裝置13。χΙΡ管理器42係因 此負責實際存取記憶體定址裝置13,且處置儲存於該裝置 上之資料的檔案系統佈局。可能無法使用任何除了由X IP 管理器42支援者之外的其他檔案系統佈局’來存取在記憶 體定址裝置13上的資料,即使操作系統40將另提供一用於 此一檔案系統之檔案系統驅動器。Therefore, it may be impossible to perform the on-site execution access using the file system driver 43 to access the file residing on the memory addressing device 13. Rather, in the component structure of the operating system 40 shown in the 1ES, the on-site execution access is handled by the XIP manager 42, which is tightly integrated into the memory/file manager 41 and directly accesses the memory. Body addressing device 13. The UI manager 42 is therefore responsible for the actual access to the memory addressing device 13 and the file system layout of the data stored on the device. It may not be possible to use any file system layout other than the X IP Manager 42 supporter to access the data on the memory addressing device 13, even though the operating system 40 will additionally provide a file for this file system. System drive.

本發明移除此限制。第2八圖顯示使用本發明實施現場 執行存取至記憶體定址裝置13之操作系統5〇的組件結構。 當與第1 E圖t所示之先前技術操作系統4〇相比較時,操作 系統5 0維持至電腦系統1 〇所有硬體組件(ram 1 2、I/O式之 裝置1 4 5己憶體疋址裝置1 3)的相同介面。其亦使用至應用 程式49之相同介面48。記憶體/檔案管理器51係一由先前技 術(參見第1E圖)提供之記憶體/檔案管理器41的修改版 本,且檔案系統驅動器52係由先前技術(參見第“圖)之檔 案系統驅動器43的-修改版本。操作系統5〇亦提供存取記 隐體疋址裝置1 3之裝置驅動器53。應注意的係操作系統4〇 一先則技術版本亦可能已提供_同樣存取記憶體定址 裝置13之裝置驅動n,但此等驅動器僅實施裝置介面 46(參^第^圖)且因而無法提供現場執行功能。此功能係 由XIP管理器42提供,然而其直接存取記憶體定址裝置13 17 1359377 而無須使用任何裝置驅動器。如第2A圖中所示,本發明不 再需要一 XIP管理器組件。而是,現現場執行功能係整合 至現存組件記憶體/檔案管理器51、檔案系統驅動器52及裝 置驅動器53中。此係藉由使用二新介面而可行:由樓案系 統驅動器52提供之檔案系統直接存取介面54,及由裝置驅 動器53提供之裝置直接存取介面55。裝置直接存取介面55 之核心特徵在於提供一擷取系統記憶體位址空間内出現之 記憶體定址裝置的一區塊B之系統記憶體位址a的構件。同 樣地’標案系統直接存取介面54之核心特徵在於提供一掏 取在偏移0處一檔案F之内容的系統記憶體位址A之構件, 其中稽案F駐留在出現於系統記憶體位址空間内之一記憶 體定址裝置上。此等直接存取介面之使用將更詳細討論於 下。 如第2A圖中所示’操作系統5〇透過與應用程式49之介 面48互動。介面48之一部分係由需求分頁請求組成,該請 求係藉由應用程式49存取其目前未映射至系統記憶體位址 空間30之一頁的虛擬位址空間31之一頁而觸發(應注意的 係虛擬位址空間3 1及系統記憶體位址空間3 〇係顯示於第 1C及1D圖中’其中虛擬位址空間31對應於應用49之虛擬位 址空間)。介面4 8之其他部分由請求(系統呼叫)組成’該請 求係由應用程式4 9請求操作系統5 〇讀 '寫或是存取駐留在 I/O式之裝置14或*己憶體定址裝置13上之稽案内容。記憶體 /棺案管理器51係經由介面48處置由應用程式49之請求的 操作系統5 0之組件。為了存取駐留在1/〇式之裝置丨4或記憶 18 1359377 體定址裝置13上的檔案之内容,記憶體/檔案管理器η經由 擋案系統I/O介面45及/或檔案系統直接存取介面54與檔I案 系統驅動器52互動。操作系統5〇可含有檔案系統驅動器/之 多數版本,其各負責處置一特定檔案系統佈局。所有檔案 系統驅動器實施相同檔案系統1/0介面45,且一些標案系統 驅動器另實施檔案系統直接存取介面54,其係適於施行現 場執行存取駐留在記憶體定址裝置上之檔案。擋案系統驅 動器52經由裝置I/O介面46及/或裝置直接存取介面55與裝 置驅動器44和53互動。操作系統5〇可含有裝置驅動器之多 數版本,其各負責處置一特定類型之裝置。所有裝置驅動 器實施相同裝置I/O介面46,且用於記憶體定址裝置13之裝 置驅動器可另外實施裝置直接存取介面55’其係適於施行 現場執行存取至駐留在記憶體定址裝置13上之檔案。 對於提供I/O介面45及直接存取介面54二者之檔案系 統驅動器,記憶體/檔案管理器5 1係兼能施行正規存取及現 場執仃存取至由此等檔案系統驅動器處置之檔案。第a和 2 C |^| ® … 文詳細描述施行正規及現場執行存取所需之控制的 抓程。第2D圖將詳述自二種方法選擇哪一種用於任何特定 構案存取。 第2马圖插述當操作系統5 〇處置一請求以存取駐留在 I/O式之裝置丨4上的檔案時之控制流程。應注意的係此控制 程係與由先前技術搡作系統4〇用於一對應存取者相同。 控制"_L程之步驟係依序由動作60a-f表示。在此所示之特定 動作對麾於第1C圖所示情況,其係在應用49已嘗試存取虛 19 擬位址空間31之頁32c後。因為此頁目前係未映射至系統記 憶體位址空間30之任何頁,故會產生一頁錯失中斷,且由 操作系統50之記憶體/檔案管理器5丨組件處置。此係由第2b 圖中動作60a表示。記憶體/檔案管理器51自用於頁.32c之頁 插述符讀取,該頁32c係應用預期其内容應對應於在偏移〇 處之檔案F的内谷。其決定檔案F駐留在—由檔案系統驅動 器52處置之檔案系統上。其更決定檔案?不支援現場執行 (此以下將詳細說明)。其接著分配R AM丨2中之一自由頁 33c且決定其系統記憶體位址A,及經由檔案系統驅動器μ 之檔案系統I/O介面45請求將在偏移〇處之檔案F的内容拷 貝進入於系統記憶體位址A處之頁内(動作6〇b)。檔索*** 驅動器52決定在檔案F之偏移〇處的資料駐留在1/〇式之裝 置14的區塊B上,且裝置驅動器44係負責存取ι/〇式之裝置 14。其接著經由裝置驅動器44之裝置1/〇介面^,請求將 式之裝置Μ的區塊B拷貝至在系統記憶體位址a處之頁中 (動作60c)。裝置驅動器44影響一在裝置1/〇介面46上之 操作61以施行該拷貝一旦1/〇操作61已完成裝置驅動器 44經由裝置1/0介面46向㈣***驅動器如告完成(動作 6〇d),其同樣經由檔案系統1/〇介面45向記憶體/檔案管理 器51報告完成(動作6〇e)。記憶體/檔案管理器η最後建立 一虛擬位址空間31之頁32c的映射,至系統記憶體位址空間 30之位址A處的頁33c,其現保持所請求之内容(動作6〇〇。 第2C圖同樣描述當操作系統50處置—請求以施行一 現場執行存取一駐留在記憶體定址之裝置13上的檔案時之 20 1359377 _制流程應主意的係此流程不同於由先前技術操作系統 40用於對應存取者’且使用由本發明所述之新穎直接存取 介面》更應注意的係一些至記憶體^址之裝置13的存取 可能不適。現場執行存取;在此等案例中,一正規存取 至標案會施行以取代之,其使用如第2B圖所示及上述的等 效控制流程。此jjA jU: Φ s J订在於裝置驅動器53亦實施裝置I/O介面 46,正如同I置驅動器44所為。 第2C圖中所不之控制流程步驟係依序由動作7〇a_f表 不在此所不之特定動作對應於第i D圖所示的情況,其係 在應用49已嘗試存取虛擬位址空間31之頁3k後。如第;2B 圖中所不會產生—頁錯失中斷,且由記憶體/樓案管理器51 處置(動作70a),其再度自用於頁32c之頁描述符讀取該 頁3 2c係應用預期其内容應對應於在偏移〇處之該等檔案f 的内容。其再度決定檔案F駐留在由檔案系統驅動器52處 置之檔案系統上。其更決定檔案F不支援現場執行(以下詳 ,.田說明)。其現經由檔案系統驅動器5 2之檔案系統直接存取 "面,请求擷取在偏移〇處之檔索F的内容之系統記憶體位 址(動作70b)。檔案系統驅動器52決定在偏移〇處的該等檔 案F之内谷駐留在記憶體定址裝置13的區塊B上,且裝置驅 動器53係負責存取記憶體定址裝置13。其接著經由裝置驅 動器53之裝置直接存取介面55,請求擷取記憶體定址裝置 1 3之區塊B的系統記憶體位址(動作70c) »裝置驅動琴53決 定記憶體定址裝置13之區塊B對應於系統記憶體位址空間 3〇的頁35c’且將其位址a經由襞置直接存取介面55回覆予 21 1359377 標案系統驅動|§52(動作7〇d)’其同樣將位址a經由檔案系 統直接存取介面54回覆予記憶體/檔案管理器51(動作 7〇e)。記憶體/檔案管理器51最後建立一虛擬位址空間31之 頁32c的映射至系統記憶體位址空間3〇之位址a處的頁 35c(動作 70f)。 第2D圖顯示描述當決定是否使用檔案系統1/〇介面或 檔案系統直接存取介面以存取一檔案F時,在操作系統5〇 内之控制流程。操作系統首先決定哪一檔案系統驅動器係 負貝保持檔案F之檔案系統FS。若該檔案系統驅動器完全 不支援檀案系統直接存取介面,則使用稽案系統了 / 〇介面。 否則,操作系統決定哪一裝置驅動器係負責檔案系統FS下 方之裝置D。若裝置驅動器完全不支援裝置直接存取介 面’則同樣使用檔案系統I/O介面。否則,操作系統決定樓 案系統FS是否由用於現場執行存取至檔案ρ之使用者配 置。若是,則使用檔案系統直接存取介面,否則使用檔案 系統I/O介面。在一些具體實施例中,使用者可僅選擇允許 現場執行存取在FS上之所有檔案或完全不存取◦在其他具 體實施例中’使用者可針對各單一檔案分别地作成該選 擇。此外’在一些具體實施例中,若其他可配置檔案系統 參數已由使用者設定成與現場執行可匹配之值時,其才可 能被允許現場執行存取;例如其可能必須配置該檔案系統 區塊大小成為一等於系統記憶體頁大小或其倍數之值。 應注意的係操作系統無須執行第2D圖所示之完整決 策邏輯,用於每一單一存取至檔案而是一旦當檔案ρ首 22 1359377 先被存取且記憶在與檔案F相關之操作系統資料結構中, 則可作成該選擇;後續存取將再使用儲存在該等資料結構 内之決策的結果。 第3 A至I圖顯示在Linux操作系統中之本發明的另—更 詳細具體實施例。本發明藉由延伸標準操作系統1/〇組件結 構之介面而非將其完全取代,來將現場執行功能整合至標 準操作系統1/〇組件結構内。Linux提供關於施行以下UoL 作之組件層: 裝置驅動器層,其允許存取一備份儲存裝置而無須瞭 解相關之特定硬體, 檔案系統層,其允許使用一邏輯檔案圖來存取備份儲 存’而無須有關特定一備份儲存裝置之認知, §己憶體管理層’其允許執行一應用而無須由該應用瞭 解有關操作系統使用之虛擬記憶體及動態位址翻譯技術。 第3 A圖顯示在許多現代操作系統中實施之裝置抽象 化。此實例顯示一在Linux中之裝置驅動器。該make_reqUest 功能被呼叫以提交請求,來將資料讀自/寫至該裝置。該 request一queue及do_request功能係L i n u X内部最佳化之部分。裝置 驅動器將會在「調度請求+過程請求+中斷處置器今調度 請求」迴圈中執行’直至所有提交予其之工作均已完成。 裝置驅動器層其允許提交讀取或寫入請求。此層之經 常使用者係檔案系統的讀取頁/寫入頁操作,其將資料轉移 至/自播案。為了將資料定址,會使用一實體區塊號碼。 本發明提供一至裝置驅動器層之介面的延伸,其顯示 23 1359377 於第3B圖中。在維持現存介面之完整性的同時,該延伸提 供一可用以取得一直接參考裝置上資料的功能。此參考可 用以存取在裝置上之資料,而無須提交請求且等待其完 成°此延伸視需要可藉由存取記憶體定址裝置之裝置驅動 器實施。新操作direct一access取得一實體區塊號碼,類似於 make_request’但不轉移任何資料。而是回覆一參考予該資料。 此參考可用以自此時將任何資料讀或寫至該實體區塊,直 至該裝置係再次關閉/未安裝,而與裝置驅動器層無進一步 互動。可視需要使用新介面,傳統介面對於使用 者而言係維持其完整性,其不支援如不如裝置驅動器。傳 統介面對於支援通用檔案系統係重要的,其用以轉移檔案 系統元資料(i節點、目錄項目等)。 第3 C圖顯示一在Linux中之通用檔案系統如何使用裝 置驅動器之make_request功能來實施記憶體位址操作。讀取頁/ 寫入頁功能使用get—block功能(當處理多頁時重複)以辨識與 主頁有關之裝置上的實體區塊號碼。如第3A圖中所示之 make_request功能係用以存取資料。在Linux中,檔案系統通常 使用位址空間操作連同檔案系統資料庫功能,以施行如 sys_read()及sys_write()之檔案操作。視需要可使用此等位址空間 操作和系統資料庫功能,但大多數通用檔案系統使用其 等。位址空間操作 readpage〇、readpages()、writepage()及 writepages()係 用以讀/寫資料之一或多數記憶體頁至/自裝置驅動器。為 了定址一記憶體頁,會使用一邏輯檔案處置及一偏移。此 定址係藉由擋案系統翻譯成實體區塊號碼。 24 1359377The present invention removes this limitation. Fig. 2 is a diagram showing the component structure of an operating system 5 that performs on-site access to the memory addressing device 13 using the present invention. When compared with the prior art operating system shown in FIG. 1E, the operating system 50 is maintained to the computer system 1 and all hardware components (ram 1 2, I/O type device 1 4 5 recalled) The same interface of the body address device 1 3). It also uses the same interface 48 to the application 49. The memory/file manager 51 is a modified version of the memory/file manager 41 provided by the prior art (see Figure 1E), and the file system driver 52 is a file system driver of the prior art (see Figure). 43-modified version. The operating system 5〇 also provides a device driver 53 for accessing the secret file device 13. The system should be noted that the operating system may also provide the same access memory. The device of the addressing device 13 drives n, but these drivers only implement the device interface 46 (and thus the field) and thus cannot provide on-site execution functionality. This functionality is provided by the XIP manager 42, however its direct access memory addressing The device 13 17 1359377 does not require the use of any device driver. As shown in Figure 2A, the present invention eliminates the need for a XIP manager component. Instead, the on-site execution functionality is integrated into the existing component memory/file manager 51, Archive system driver 52 and device driver 53. This is possible by using two new interfaces: the file system direct access interface 54 provided by the building system driver 52, and The device provided by the driver 53 directly accesses the interface 55. The core feature of the device direct access interface 55 is to provide a system memory address a of a block B of the memory addressing device appearing in the memory address space of the system. Component. Similarly, the core feature of the 'targeting system direct access interface 54 is to provide a component of the system memory address A that captures the contents of a file F at offset 0, where the instance F resides in the system memory. The memory addressing device is located in one of the memory address spaces. The use of such direct access interfaces will be discussed in more detail below. As shown in Figure 2A, the 'operating system 5' interacts with the interface 48 of the application 49. One of the portions 48 is composed of a demand paging request that is triggered by the application 49 accessing a page of the virtual address space 31 that is not currently mapped to one page of the system memory address space 30 (should be noted) The virtual address space 3 1 and the system memory address space 3 are shown in the 1C and 1D diagrams where the virtual address space 31 corresponds to the virtual address space of the application 49. Interface 4 8 The other part consists of a request (system call) 'This request is requested by the application 49 to read the 'write' or access to the I/O-type device 14 or the *remembering device 13 The content of the audit file. The memory/file manager 51 handles the components of the operating system 50 requested by the application 49 via the interface 48. In order to access the device resident in the 1/〇 device 或 4 or the memory 18 1359377 The contents of the file on the device 13, the memory/file manager n interacts with the file system driver 52 via the file system I/O interface 45 and/or the file system direct access interface 54. The operating system 5 can contain files Most versions of the system drive/each are responsible for handling a particular file system layout. All file system drives implement the same file system 1/0 interface 45, and some of the file system drivers additionally implement a file system direct access interface 54, which is suitable for performing on-site execution access to files residing on the memory address device. The file system driver 52 interacts with the device drivers 44 and 53 via the device I/O interface 46 and/or the device direct access interface 55. The operating system 5 can contain a number of versions of the device drivers, each of which is responsible for handling a particular type of device. All device drivers implement the same device I/O interface 46, and the device drivers for the memory addressing device 13 may additionally implement a device direct access interface 55' that is adapted to perform on-site execution access to reside in the memory addressing device 13 The file on it. For a file system driver providing both an I/O interface 45 and a direct access interface 54, the memory/file manager 51 can perform both formal access and on-site access to the file system driver. file. The a and 2 C |^| ® ... describe in detail the implementation of the control required to perform formal and on-site access. Figure 2D will detail which of the two methods is chosen for any particular configuration access. The second horse maps the control flow when the operating system 5 processes a request to access the file residing on the I/O type device 4. It should be noted that this control system is the same as that used by the prior art system 4 for a corresponding accessor. The steps of controlling "_L are sequentially represented by actions 60a-f. The specific actions shown here are for the case shown in Figure 1C, after the application 49 has attempted to access page 32c of the virtual address space 31. Because this page is currently unmapped to any page of the system memory address space 30, a one-page missed interrupt is generated and handled by the memory/file manager 5 component of the operating system 50. This is indicated by action 60a in Figure 2b. The memory/file manager 51 is read from the page for page .32c. The page 32c application expects its content to correspond to the inner valley of the file F at the offset 。. It is determined that the file F resides on the file system that is processed by the file system driver 52. Which determines the file? On-site execution is not supported (this will be explained in more detail below). It then assigns one of the free pages 33c of R AM丨2 and determines its system memory address A, and requests the copy of the file F at the offset file via the file system I/O interface 45 of the file system driver μ. Within the page of system memory address A (action 6〇b). The cable system driver 52 determines that the data at the offset of the file F resides on block B of the device 1 of the type 1 and the device driver 44 is responsible for accessing the device 14 of the type. It then requests the block B of the device to be copied to the page at the system memory address a via the device 1/device interface of the device driver 44 (act 60c). The device driver 44 affects an operation 61 on the device 1/〇 interface 46 to perform the copy once the 1/〇 operation 61 has completed the device driver 44 via the device 1/0 interface 46 to the (4) system driver (action 6〇d) It is also reported to the memory/file manager 51 via the file system 1/〇 interface 45 (action 6〇e). The memory/file manager η finally establishes a mapping of page 32c of a virtual address space 31 to page 33c at address A of system memory address space 30, which now holds the requested content (action 6). Figure 2C also depicts that when the operating system 50 handles the request to perform a live execution access to a file residing on the memory addressed device 13, the process should be different from the prior art operation. The system 40 is used to correspond to the accessor 'and use the novel direct access interface of the present invention' to note that access to the device 13 to the memory location may be uncomfortable. On-site access is performed; In the case, a regular access to the standard will be implemented instead, using the equivalent control flow as shown in Figure 2B and above. This jjA jU: Φ s J is based on the device driver 53 also implements the device I/O The interface 46 is exactly the same as the I-position driver 44. The control flow steps in the second embodiment of FIG. 2 are sequentially indicated by the operation 7〇a_f, and the specific operation corresponding to the i-th diagram is corresponding to the case. Attempted to access in application 49 After the page 3k of the pseudo address space 31, as shown in the second; FIG. 2B, a page miss interrupt is generated and is handled by the memory/stall manager 51 (action 70a), which is again described on page 32c. The reading of the page 3 2c application expects that its content should correspond to the contents of the files f at the offset 。. It again determines that the file F resides on the file system handled by the file system driver 52. F does not support on-site execution (detailed, . Tian description). It now directly accesses the system memory location of the file F at the offset file via the file system driver's file system. Address (action 70b). The file system driver 52 determines that the valleys of the files F at the offset buffer reside on the block B of the memory addressing device 13, and the device driver 53 is responsible for accessing the memory addressing device 13 Then, the device directly accesses the interface 55 via the device driver 53, and requests to retrieve the system memory address of the block B of the memory addressing device 13 (Act 70c). The device driver 53 determines the region of the memory addressing device 13. Block B corresponds to the system Page 35c' of the memory address space 3〇 and replies its address a via the device direct access interface 55 to the 21 1359377 standard system driver|§52 (action 7〇d)' which also passes the address a via the file The system direct access interface 54 replies to the memory/file manager 51 (action 7〇e). The memory/file manager 51 finally creates a mapping of the page 32c of a virtual address space 31 to the system memory address space 3〇. Page 35c at address a (action 70f). Figure 2D shows the description in the operating system 5 when deciding whether to use the file system 1/〇 interface or the file system direct access interface to access a file F. Control process. The operating system first determines which file system drive is the file system FS that holds the file F. If the file system driver does not support the direct access interface of the Tan file system at all, then the file system / interface is used. Otherwise, the operating system determines which device driver is responsible for device D under file system FS. If the device driver does not support the device direct access interface at all, the file system I/O interface is also used. Otherwise, the operating system determines whether the architectural system FS is configured by the user for performing on-site access to the file ρ. If so, use the file system direct access interface, otherwise use the file system I / O interface. In some embodiments, the user may only choose to allow the site to perform access to all files on the FS or not at all. In other specific embodiments, the user may make the selection separately for each individual file. In addition, in some embodiments, if other configurable file system parameters have been set by the user to match the value of the field execution, they may be allowed to perform access in the field; for example, they may have to configure the file system area The block size becomes a value equal to the system memory page size or a multiple thereof. It should be noted that the operating system does not need to perform the complete decision logic shown in Figure 2D for each single access to the file, but once the file ρ head 22 1359377 is accessed first and is stored in the operating system associated with file F In the data structure, the selection can be made; subsequent accesses will reuse the results of the decisions stored in the data structures. Figures 3A through I show additional, more detailed embodiments of the present invention in the Linux operating system. The present invention integrates field execution functions into a standard operating system 1/〇 component structure by extending the interface of the standard operating system 1/〇 component structure rather than completely replacing it. Linux provides a component layer for implementing the following UoL: device driver layer, which allows access to a backup storage device without having to know the specific hardware associated with it, the file system layer, which allows access to backup storage using a logical file map' There is no need to be aware of a particular backup storage device, § the memory management layer's permission to execute an application without the need for the application to understand the virtual memory and dynamic address translation techniques used by the operating system. Figure 3A shows device abstraction implemented in many modern operating systems. This example shows a device driver in Linux. The make_reqUest function is called to submit a request to read/write data to the device. The request-queue and do_request functions are part of the internal optimization of L i n u X. The device driver will execute in the "Schedule Request + Process Request + Interrupt Processor Today Dispatch Request" loop until all work submitted to it has been completed. The device driver layer allows submission of read or write requests. The normal user of this layer is the read page/write page operation of the file system, which transfers the data to/self-cast. In order to address the data, a physical block number is used. The present invention provides an extension of the interface to the device driver layer, which is shown in Fig. 3B. While extending the integrity of the existing interface, the extension provides a function to obtain a direct reference to the data on the device. This reference can be used to access data on the device without having to submit a request and wait for it to complete. This extension can be implemented by a device driver that accesses the memory addressing device as needed. The new operation direct-access obtains a physical block number, similar to make_request' but does not transfer any data. Instead, reply to the reference to the information. This reference can be used to read or write any material to the physical block from this point until the device is turned off/not installed again, without further interaction with the device driver layer. The new interface can be used as needed. The traditional interface maintains its integrity for the user and does not support the device driver. The traditional interface is important for supporting the general file system, which is used to transfer file system metadata (i nodes, directory items, etc.). Figure 3C shows how a general file system in Linux uses the make_request function of the device driver to implement memory address operations. The Read Page/Write Page function uses the get-block function (repeat when processing multiple pages) to identify the physical block number on the device associated with the home page. The make_request function as shown in Figure 3A is used to access data. In Linux, file systems typically use address space operations along with file system database functions to perform file operations such as sys_read() and sys_write(). These address space operations and system database functions are available as needed, but most general file systems use them. Address space operations readpage〇, readpages(), writepage(), and writepages() are used to read/write data or most memory pages to/from device drivers. In order to address a memory page, a logical file disposition and an offset are used. This location is translated into a physical block number by the file system. 24 1359377

本發明藉由一名為get_xip_page之功能提供一延伸至位址 空間操作介面,其允許擷取一參考至一既定記憶體頁後的 儲存器,如第3D圖中所示。此功能使用一檔案處置及一偏 移用於定址,藉由呼叫該get_block功能將其翻譯成為一實體 區塊號碼,且自裝置驅動器層之direct_access功能(如第3 B圖中 所述)擷取一參考至該實體區塊後的儲存器。此參考現可在 任何時間用以將任何資料讀自或寫至該實體區塊,直至該 檔案被刪節,或該檔案係未安裝而與檔案系統或裝置驅動 器層無進一步互動時。當支援時,新介面之使用係強制, 針對資料完整性原因,傳統readpage(s)/writepage(s)介面或新 get_xip_page介面任一介面被支援用於一檔案。檀案系統係依 據每一檔案為基礎自由選擇。The present invention provides an extended-to-address space operation interface for a function of get_xip_page that allows a reference to a memory after a predetermined memory page, as shown in Figure 3D. This function uses a file disposition and an offset for addressing, which is translated into a physical block number by calling the get_block function, and is retrieved from the direct_access function of the device driver layer (as described in Figure 3B). A reference to the storage after the physical block. This reference can now be used to read or write any material to the physical block at any time until the file is truncated, or if the file is not installed and there is no further interaction with the file system or device driver layer. When supported, the use of the new interface is mandatory. For the sake of data integrity, either the traditional readpage(s)/writepage(s) interface or the new get_xip_page interface is supported for a file. The Tan file system is free to choose based on each file.

Readpage(s)/writepage(s)功能之主使用者係檔案系統資料庫 功能。第3 E圖顯示檔案系統資料庫功能如何施行Linux中一 通用檔案系統之讀類型檔案操作。 該generic_file_read功能施行有關sys_read()系統+叫之權案操The main user of the Readpage(s)/writepage(s) function is the file system database function. Figure 3E shows how the file system database function performs a read type file operation of a general file system in Linux. The generic_file_read function implements the sys_read() system + called the right operation.

作。 該generic_file_readv功能施行有關sys_readv()系統呼叫之棺案 操作。 該generic_file_aio_read功能施行有關不同步10系統呼叫之 讀取操作。 該generic_file_sendfile檔案操作施行有關sys_sendfile()系統呼叫 之檔案操作。 所有此等功能間接地呼叫generic_mapping_read,其使用 25 1359377 readpage⑻功能(如第3C圖中所示)以自裝置讀取一或多數 頁。雖然此等功能係視需要用於一檔案系統,大多數通用 檔案系統使用其等而非進行檔案操作之其本身的實施。 第3G圖顯示檔案系統資料庫功能如何施行Linux中之 一通用檔案系統的寫類型檔案操作。 該generic_file_write功能施行有關sys_write〇系統呼叫之稽案 操作。Work. The generic_file_readv function performs a file operation on the sys_readv() system call. The generic_file_aio_read function performs a read operation on asynchronous 10 system calls. The generic_file_sendfile file operation performs file operations on sys_sendfile() system calls. All of these functions indirectly call generic_mapping_read, which uses the 25 1359377 readpage(8) function (as shown in Figure 3C) to read one or more pages from the device. While such functionality is required for a file system, most general file systems use their own implementation rather than performing their own file operations. Figure 3G shows how the file system repository function performs a write type file operation of a general file system in Linux. The generic_file_write function performs auditing operations on sys_write〇 system calls.

該generic_file_writev功能施行有關sys_writev〇系統呼叫之樓 案操作。 該generic_file_aio_write功能施行有關不同步IO系統呼叫之 寫入操作。 所有此等功能間接地呼叫generic_file_direct_write(當選項 0_DIRECT被用於打開主檔案時)或 generic_file_buffered_write。二 功能使用writepage(s)功能以將一或多數頁寫入裝置。The generic_file_writev function performs the operation of the sys_writev〇 system call. The generic_file_aio_write function performs write operations on asynchronous IO system calls. All of these functions call generic_file_direct_write indirectly (when option 0_DIRECT is used to open the main archive) or generic_file_buffered_write. The second function uses the writepage(s) function to write one or more pages to the device.

本發明提供延伸至資料庫功能以使得當獲得支援時其 等能使用get_xip_page介面。第3F圖顯示進行至用於讀操作之 稽案系統資料庫功能的延伸。取決於get_xip_page位址空間操 作是否出現,generic_mapping_read功能或新 do_xip_mapping_read 功能 會用以施行該功能。該do_xip_mapping_read功能使用get_xip_page位 址空間操作以擷取一參考至裝置上的主資料。為了資料轉 移,此參考係直接使用而不施行I/O操作。第3H圖顯示進 行至用於寫操作之檔案系統資料庫功能的延伸。取決於 get_xip_page位址空間操作是否出現, generic_file_buffered_write/generic_file_direct_write 或新 do—xip_mapping write功 26 1359377 能係用以施行該操作。該generic_file_xip writeiyj作田 ~ ~ ~ 刀两使用 getjip^write 頁位址空間操作以擷取一參考至裝置上的 — 土貧科。為了資 料轉移,此參考係直接使用而不施行1/〇操作。 所有實施get一xip_page位址空間操作之檔安 〜悔茱系統無須進一 步之瑪改變以用由資料庫功能實施之所有標案操作施行現 場執行存取。第3F、3H、和31顯示已延伸之資料庫功能如 何取決於get—xiP_page位址空間操作是否實施而實施其功能。 當實施get_xiPJ)age位址空間操作時,所有資料庫功能使用自 get_xip_page擷取之參考施行將所有資料直接轉移至儲存裝 置•第31圖顯示延伸進行至用於檔案系統映射之檔案系統 資料庫功能。該應用已存取其目前未出現之虛擬記憶體位 址空間的一部分。Linux之標準架構相依及核心記憶體管理 功能係用以處置所產生之頁錯失。與正規處理不同的係, 標案系統已針對有關主頁之標案安裝glemap_xjp_n0page處置 器。此處置器使用get一xip_page以擷取一參考至裝置上之主資 料。此參考係返回至do_no」5age功能,其在應用之虛擬位址空 間頁表中產生一頁表項目,以允許該應用直接使用在裝置 上之資料’無須進一步涉及該操作系統。頁表項目可在後 續當檔案系統被選為專用時在寫入機制上進行拷貝(標準 機制應用)。 現場執行效果能達到係因為應用二進制檔案及共享資 料庫已在Linux中置於檔案映射,且因此置於上述頁錯失機 制。 上述延伸維持Linux操作系統之1/〇相關組件中之整體 27 1359377 結構及層隔離的完整柯.壯里蹄善 疋堡14 ·裝置驅動器層將實體區 射至該裝置,但 /、播案或其他邏輯物件一起運 系統在邏輯檔案及音# 东及實體區塊號碼定址間施行映射 裝置之内部結構―把播· 稱起運作。另一方面,資料轉移 置:當使用新延 時’裝置驅動器不轉移任何資 係直接在檔案操作資斜雇从处士姑。 F買料庫功能中轉移。此解決方 包括對於裝置駆動器層及通用標案系統之極少且 變任何通用檔案系統可易於獲得現場執行 勢,如減少記憶體消耗及增加效能。 【圖式簡單說明】The present invention provides an extension to the database function so that it can use the get_xip_page interface when support is obtained. Figure 3F shows an extension of the function of the auditing system database for the read operation. The generic_mapping_read function or the new do_xip_mapping_read function is used to perform this function depending on whether the get_xip_page address space operation occurs. The do_xip_mapping_read function uses the get_xip_page address space operation to retrieve a reference to the master data on the device. For data transfer, this reference is used directly without performing I/O operations. Figure 3H shows an extension to the file system repository function for write operations. Depending on whether the get_xip_page address space operation occurs, generic_file_buffered_write/generic_file_direct_write or the new do-xip_mapping write function 26 1359377 can be used to perform this operation. The generic_file_xip writeiyj is used in the field. The getjip^write page address space operation is used to retrieve a reference to the device. For the purpose of data transfer, this reference is used directly without performing a 1/〇 operation. All implementations of the get-xip_page address space operation ~ Repentance system does not require further step-by-step changes to perform field execution accesses with all the scripting operations performed by the database function. 3F, 3H, and 31 show how the extended library functionality performs its function depending on whether the get-xiP_page address space operation is implemented. When the get_xiPJ)age address space operation is implemented, all database functions use the reference implementation from get_xip_page to transfer all data directly to the storage device. • Figure 31 shows the extension to the file system database function for file system mapping. . The application has accessed a portion of its virtual memory address space that is not currently present. Linux's standard architecture dependencies and core memory management functions are used to handle page misses. Unlike the formal processing, the standard system has installed the glemap_xjp_n0page handler for the title of the home page. The handler uses get-xip_page to retrieve a reference to the master material on the device. This reference is returned to the do_no"5age function, which generates a one-page table entry in the virtual address space page table of the application to allow the application to directly use the material on the device' without further involvement of the operating system. The page table entry can be copied on the write mechanism (standard mechanism application) when the file system is selected as dedicated. The on-site execution can be achieved because the application binary file and shared library have been placed in the file mapping in Linux, and therefore placed on the above page missed mechanism. The above extension maintains the overall 1/〇 related components of the Linux operating system. 27 1359377 Structure and Layer Isolation Complete Ke. Zhuang Lihu Shanbao 14 · Device Driver Layer will physically touch the device to the device, but /, broadcast or The other logical objects are transported together to implement the internal structure of the mapping device between the logical file and the sound and the physical block number addressing. On the other hand, data transfer: When using the new delay, the device driver does not transfer any assets directly from the file operation. F buys the library function transfer. This solution includes very few for the device actuator layer and the common standard system and any general file system can easily obtain on-site execution potential, such as reducing memory consumption and increasing performance. [Simple description of the map]

本發明以上以;5M 线# 及額外之目的、特徵和優勢乐 洋載之說明書瞭解。 本發明之新顆鸦· μ & & α 、特徵係在隨附申請專利範圍^ 而’本發明本身及使用 1之用之杈佳模式、進一步之g 將可藉由結合附圖 _ , 闼閲碩呀翏考不範性具體, 工坪述而更加瞭解,其中: 第1 A圖顯示一實 ^ , 頁知本發明所需之電腦系統ί 環境成A S第1A圖所示電腦系統之j 第!⑽_具體實把例中之客戶操作系 體及需求分U能, 作以提供之虛 能,第1D圖顯示由先前技術操作***提供之現場 塊號碼映 作。檔案 ,但不與 本身係倒 料。資料 法之優勢 僅非侵入 機制之優 可自以上 提出。然 的及其優 '施例之以 i方塊圖, :擬機器 統, 擬記憶 執行功 28 第IE圖顯示一實施現場執行之先前技術操作系味組 件結構, ^ . 第2 A圖顯示一使用本發明實施現場執行之操作系統 的級件結構, 第2B圖顯示透過第2A圖之操作系統的組件控制之流 程’其係用以依據本發明存取一 I/O式之裝置,The present invention is described above with the 5M line # and additional purposes, features, and advantages of the specification. The new crows of the present invention, μ && alpha, and the features are in the scope of the accompanying claims, and the invention itself and the preferred mode of use 1 and further g will be incorporated by reference to the accompanying drawings.硕 Read the master 翏 翏 翏 翏 翏 翏 翏 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工 工j No.! (10) _ The actual operating system and requirements in the example are divided into U, for the virtual energy provided, and Figure 1D shows the live block number mapping provided by the prior art operating system. File, but not inverted with itself. Advantages of the data method Only the advantages of the non-invasive mechanism can be raised from the above. And its excellent example of the i block diagram, : the quasi-mechanical system, the quasi-memory execution work 28 IE diagram shows a prior art operation of the implementation of the system component structure, ^. Figure 2 A shows a use The present invention implements a stage structure of an operating system executed on site, and FIG. 2B shows a flow of component control through an operating system of FIG. 2A for accessing an I/O type device according to the present invention.

第2C圖顯示透過第2A圖之組件的控制之流程,其係用 以依據本發明施行現場執行存取至一記憶體家址裝置, 第2D圖顯示由第2A圖之操作系統的決策邏輯,里 ,、1尔用 以自第2B及2C圖所述之二控制流程選擇其一使用, 第3A圖顯示在先前技術Linux操作系統中實施之裝置 抽象化, 第3B圖顯示在實施本發明之Linux操作系統中進行至 裝置驅動器層之延伸,Figure 2C shows the flow of control through the components of Figure 2A for performing on-site access to a memory home device in accordance with the present invention, and Figure 2D shows the decision logic of the operating system from Figure 2A, Here, 1 is used to select one of the control processes described in Figures 2B and 2C, Figure 3A shows the device abstraction implemented in the prior art Linux operating system, and Figure 3B shows the implementation of the present invention. Extending to the device driver layer in the Linux operating system,

第3 C圖顯示一通用稽案系統如何提供一位址空間操 作,以將一或多數頁寫至/讀取自先前技術Linux操作系統 中之裝置, 第3D圖顯示在實施本發明之Linux操作系統中進行至 樓案系統之位址空間操作的延伸, 第3E圖顯不對於先前技術Linux操作系統中之通用稽 案系統,該檔案系統資料庫功能如何施行讀類型檔案操作 第3F圖顯示在實施本發明之Linux操作系統中進行至 用於讀類型操作之樓案系統資料庫功能的延伸, 第3G圖顯示對於先前技術Linux操作系統中之通用檔 29 1359377 案系統,該檔案系統資料庫功能如何施行寫類型檔案操作, 第3H圖顯示在實施本發明之Linux操作系統中進行至 用於寫類型操作之檔案系統資料庫功能的延伸, 第31圖顯示在實施本發明之Linux操作系統中進行至 用於檔案記憶體映射之檔案系統資料庫功能的延伸。Figure 3C shows how a general auditing system provides a bit space operation to write one or more pages to/from devices in prior art Linux operating systems, and Figure 3D shows the Linux operations in implementing the present invention. The extension of the address space operation to the building system in the system, Figure 3E shows no way to the general auditing system in the prior art Linux operating system, how the file system database function performs the reading type file operation. An extension of the function of the building system database for reading type operations in the Linux operating system embodying the present invention, and FIG. 3G shows the file system database function for the general file 29 1359377 system in the prior art Linux operating system. How to perform a write type file operation, FIG. 3H shows an extension to the file system database function for writing type operations in the Linux operating system embodying the present invention, and FIG. 31 shows the execution in the Linux operating system embodying the present invention. Extension to the file system database function for file memory mapping.

【主要元件符號說明】 10 電腦系統 11 中央處理單元/CPU 12 隨機存取記憶體/RAM 13 記憶體定址裝置 14 I/O式之裝置 15 系統匯流排 20 電腦系統 21 超管理器 22 虛擬機器 30 系統記憶體位址空間 3 1 虛擬位址空間 32 頁 33 頁 34 區塊 35 區塊 40 操作系統 41 記憶體/檔案管理器 42 XIP管理器 43 檔案系統驅動器 44 裝置驅動器 45 檔案系統I/O介面 46 裝置I/O介面 48 介面 49 應用程式 50 操作系統 5 1 記憶體/檔案管理器 52 檔案系統驅動器 53 裝置驅動器 54 檔案系統直接存取介面 55 裝置直接存取介面 f 30[Description of main component symbols] 10 Computer system 11 Central processing unit/CPU 12 Random access memory/RAM 13 Memory addressing device 14 I/O type device 15 System bus 20 Computer system 21 Super manager 22 Virtual machine 30 System Memory Address Space 3 1 Virtual Address Space 32 Page 33 Page 34 Block 35 Block 40 Operating System 41 Memory/File Manager 42 XIP Manager 43 File System Driver 44 Device Driver 45 File System I/O Interface 46 Device I/O Interface 48 Interface 49 Application 50 Operating System 5 1 Memory/File Manager 52 File System Driver 53 Device Driver 54 File System Direct Access Interface 55 Device Direct Access Interface f 30

Claims (1)

1359377 m-io. - 年月日修正本 第和Ί!;Η號專利案ico年7了月修正 i 十、申請專利範圍: 1. 一種提供現場執行功能的系統(50),其包含: 一記憶體/檔案管理器(51),其具有一至一應用程式 (49)之介面(48); 至少一檔案系統驅動器(52),其具有一至該記憶體 /檔案管理器(5 1)之檔案系統I/O介面(45); 至少一裝置驅動器(44),其具有一至該檔案系統驅 動器(52)之裝置I/O介面(4 6),其中該至少一裝置驅動器 (4 4)提供存取至至少一 I/O式之裝置(14); 至少一裝置驅動器(53),其具有一至該檔案系統驅 動器(5 2)之裝置I/O介面(4 6),其中該至少一裝置驅動器 (5 3)提供存取至至少一記憶體定址裝置(13); 其中該操作系統提供一現場執行功能以存取至少 一記憶體定址裝置(1 3) 其特徵在於 一檔案系統直接存取介面(5 4 ),其係介於該記憶體 /檔案管理器(5 1)及該至少一檔案系統驅動器(52)間,其 中該檔案系統直接存取介面(5 4)提供以在一特定偏移 擷取一特定檔案之該等内容的該系統記憶體位址的該 功能,其中該檔案駐留在該記憶體定址裝置(13)上; 一裝置直接存取介面(5 5),其係介於該至少一檔案 系統驅動器(5 2)及提供存取至該至少一記憶體定址裝 置(13)之該至少一裝置驅動器(53)間,其中該裝置直接 存取介面(55)提供用以擷取至少一記憶體定址裝置(13) 31 1359377 I 之一特定區塊的該系統記憶體位址之該功能; 其中該現場執行功能係藉由使用該檔案系統直接 存取介面(54)及該裝置直接存取介面(55),由該記憶體/ 檔案管理器(5 1)、該至少一檔案系統驅動器(52)、及提 供存取至該至少一記憶體定址裝置(13)之該至少一裝 置驅動器(53)所提供。 2.如申請專利範圍第1項所述之系統,其中該系統係一操 作系統之部分,或由該操作系統提供。 3 .如申請專利範圍第1項所述之系統,其中該記憶體/檔 案管理器(51)使用該檔案系統直接存取介面(5 4)或該檔 案系統I/O介面(45),提供存取至藉由該檔案系統驅動 器(52)所管理之檔案。 4.如申請專利範圍第1項所述之系統,其中該檔案系統驅 動器(5 2)藉由在一特定偏移擷取一特定檔案之該等内 容的系統記憶體位址來實施該檔案系統直接存取介面 (5 4),其中該等内容駐留在該記憶體定址裝置(13)之某 一區塊上,存取該等内容係藉由該裝置驅動器提供,其 係藉由使用由該裝置驅動器所提供之該裝置直接存取 介面以擷取該區塊之系統記憶體位址。 5 .如申請專利範圍第1項所述之系統,其中該記憶體/檔 32 1359377 案管理器(51)藉由使用由該檔案系統驅動器(52)所提供 之該檔案系統直接存取介面(54)以在該偏移擷取該檔 案之該等内容的系統記憶體,且使用該位址以現場執行 該等内容,來實施現場執行存取至一在一特定偏移之特 定檔案,其中該檔案駐留在一由該檔案系統驅動器(52) 處置之檔案系統上,且該檔案系統駐留在該記憶體定址 裝置(13)上。 6. —種用於提供一現場執行功能之電腦系統,其特徵是具 有如申請專利範圍第1至5項中任一項所述之系統。 7 ·如申請專利範圍第6項所述之電腦系統,其具有一控制 一或多數虛擬機器之超管理器(hypervisor),其中至少 一虛擬機器執行一如申請專利範圍第1至5項所述之系 統。 8. 如申請專利範圍第7項所述之電腦系統,其中該記憶體 定址裝置(13)係藉著一由該超管理器所提供之共享記 憶體區段,具體化成該等虛擬機器其一或多數。 9. 一種用於由如申請專利範圍第1至5項中任一項所述之 系統自動地提供一現場執行功能的方法,其中該系統接 受一用於藉由一應用程式存取一檔案之請求,且決定是 否使用用於存取該檔案之該現場執行功能,其中該方法 33 135.9377 * · * » 包含以下步驟: 決定保持該檔案之檔案系統; 決定管理該檔案系統之檔案系統驅動器(52)是否 提供該檔案系統直接存取介面(54); 若該檔案系統驅動器(5 2)不提供該檔案系統直接 存取介面(5 4 ),則不使用現場執行; 若該檔案系統驅動器提供該檔案系統直接存取介 面(5 4),則決定該檔案駐留於其上之該裝置; 決定管理該裝置(13)之該裝置驅動器(53)是否提供 該裝置直接存取介面(55); 若該裝置驅動器不提供該裝置直接存取介面 (5 5 ),則不使用現場執行; 決定該檔案系統是否經配置以啟動現場執行功 能;及 使用該檔案系統直接存取介面(54)以提供現場執 行功能。 1 0. —種電腦程式產品,其係儲存在一數位電腦之該内部記 憶體中,該產品含有軟體程式碼之部分,以在該產品係 在該電腦上執行時執行如申請專利範圍第9項所述之 提供一現場執行功能的方法。 341359377 m-io. - Year of the month revised this paragraph and Ί!; Η Patent ico year 7 months revised i X. Patent application scope: 1. A system (50) that provides on-site execution functions, including: a memory/file manager (51) having an interface (48) of one to one application (49); at least one file system driver (52) having a file to the memory/file manager (51) System I/O interface (45); at least one device driver (44) having a device I/O interface (46) to the file system driver (52), wherein the at least one device driver (4 4) provides Obtaining at least one I/O type device (14); at least one device driver (53) having a device I/O interface (46) to the file system driver (52), wherein the at least one device driver (5) providing access to at least one memory addressing device (13); wherein the operating system provides a live execution function to access at least one memory addressing device (13) characterized by a file system direct access interface (5 4 ), which is between the memory/file manager (5 1) and the Between at least one file system driver (52), wherein the file system direct access interface (54) provides the function of capturing the system memory address of the content of a particular file at a particular offset, wherein The file resides on the memory addressing device (13); a device direct access interface (5 5) is interposed between the at least one file system driver (52) and provides access to the at least one memory addressing device (13) between the at least one device driver (53), wherein the device direct access interface (55) provides the system memory for capturing a specific block of at least one memory addressing device (13) 31 1359377 I The function of the physical address; wherein the live execution function is performed by using the file system direct access interface (54) and the device direct access interface (55), by the memory/file manager (5 1), the At least one file system driver (52), and at least one device driver (53) providing access to the at least one memory addressing device (13). 2. The system of claim 1, wherein the system is part of, or provided by, an operating system. 3. The system of claim 1, wherein the memory/file manager (51) uses the file system direct access interface (54) or the file system I/O interface (45) to provide Access to files managed by the file system driver (52). 4. The system of claim 1, wherein the file system driver (52) implements the file system directly by extracting a system memory address of the content of a particular file at a particular offset. An access interface (54), wherein the content resides on a certain block of the memory addressing device (13), and the access to the content is provided by the device driver by using the device The device provided by the driver directly accesses the interface to retrieve the system memory address of the block. 5. The system of claim 1, wherein the memory/file 32 1359377 case manager (51) directly accesses the interface by using the file system provided by the file system driver (52) ( 54) performing a field execution access to a particular file at a particular offset by extracting the system memory of the content of the file at the offset and using the address to perform the content in the field. The file resides on a file system disposed by the file system drive (52) and resides on the memory addressing device (13). A computer system for providing a field execution function, characterized by the system of any one of claims 1 to 5. 7. The computer system of claim 6, which has a hypervisor that controls one or more virtual machines, wherein at least one virtual machine performs as described in claims 1 to 5 of the patent application. The system. 8. The computer system of claim 7, wherein the memory addressing device (13) is embodied as a virtual memory device by a shared memory segment provided by the hypervisor. Or a majority. A method for automatically providing a live execution function by the system of any one of claims 1 to 5, wherein the system accepts a file for accessing an archive by an application Requesting and deciding whether to use the on-site execution function for accessing the file, wherein the method 33 135.9377 * · * » comprises the steps of: deciding to maintain the file system of the file; determining the file system driver managing the file system (52) Whether to provide the file system direct access interface (54); if the file system driver (52) does not provide the file system direct access interface (5 4), then the field execution is not used; if the file system driver provides the The file system direct access interface (5 4) determines the device on which the file resides; determines whether the device driver (53) managing the device (13) provides the device direct access interface (55); The device driver does not provide the device direct access interface (5 5 ), and does not use the field execution; determines whether the file system is configured to initiate the on-site execution function Using the file system and direct access interface (54) functions to perform on-site. 1 0. A computer program product stored in the internal memory of a digital computer, the product containing a portion of the software code for execution when the product is executed on the computer as claimed in claim 9 The method of providing a live execution function as described in the section. 34
TW95111326A 2005-04-05 2006-03-30 System and method for providing execute-in-place f TWI359377B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
EP05102679 2005-04-05

Publications (2)

Publication Number Publication Date
TW200703102A TW200703102A (en) 2007-01-16
TWI359377B true TWI359377B (en) 2012-03-01

Family

ID=37077656

Family Applications (1)

Application Number Title Priority Date Filing Date
TW95111326A TWI359377B (en) 2005-04-05 2006-03-30 System and method for providing execute-in-place f

Country Status (3)

Country Link
JP (1) JP4921018B2 (en)
CN (1) CN100405295C (en)
TW (1) TWI359377B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8099274B2 (en) * 2007-03-30 2012-01-17 International Business Machines Corporation Facilitating input/output processing of one or more guest processing systems
CN102571845A (en) * 2010-12-20 2012-07-11 南京中兴新软件有限责任公司 Data storage method and device of distributed storage system
KR20120070326A (en) * 2010-12-21 2012-06-29 한국전자통신연구원 A apparatus and a method for virtualizing memory
JP5905316B2 (en) * 2012-03-30 2016-04-20 株式会社日立情報通信エンジニアリング Embedded system and program
JP5619198B2 (en) * 2013-02-04 2014-11-05 株式会社フィックスターズ Information processing apparatus, information processing method, and program
JP2014206884A (en) * 2013-04-15 2014-10-30 株式会社フィックスターズ Information processor, information processing method, and program
JPWO2015033767A1 (en) * 2013-09-04 2017-03-02 株式会社フィックスターズ File management apparatus, program, and file management method
WO2016082196A1 (en) * 2014-11-28 2016-06-02 华为技术有限公司 File access method and apparatus and storage device

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0778766B2 (en) * 1992-09-25 1995-08-23 インターナショナル・ビジネス・マシーンズ・コーポレイション Method and apparatus for controlling direct execution of program in external storage device using randomly accessible and rewritable memory
JPH10240584A (en) * 1997-02-24 1998-09-11 Yazaki Corp File manager and file managing method, and data base file system and data base file managing method
US6574747B2 (en) * 2000-06-02 2003-06-03 Microsoft Corporation Extensible execute in place (XIP) architecture and related methods
US7239311B2 (en) * 2002-09-26 2007-07-03 The United States Government As Represented By The Secretary Of The Navy Global visualization process (GVP) and system for implementing a GVP
CN1304961C (en) * 2005-03-11 2007-03-14 清华大学 Memory virtualized management method based on metadata server

Also Published As

Publication number Publication date
JP2006294028A (en) 2006-10-26
CN1848082A (en) 2006-10-18
JP4921018B2 (en) 2012-04-18
TW200703102A (en) 2007-01-16
CN100405295C (en) 2008-07-23

Similar Documents

Publication Publication Date Title
US7506095B2 (en) System and method for providing execute-in-place functionality
US8037279B2 (en) Method and system for cross-domain data sharing
TWI359377B (en) System and method for providing execute-in-place f
US8370835B2 (en) Method for dynamically generating a configuration for a virtual machine with a virtual hard disk in an external storage device
JP5238685B2 (en) Query and describe discrete areas of flash storage
US8095772B2 (en) Large memory pages for shared libraries
EP3382557B1 (en) Method and apparatus for persistently caching storage data in a page cache
JP2004326801A (en) Method, system and computer program for executing file copy on writing
US11010355B2 (en) Layer-based file access method and apparatus of virtualization instance
CN111919201B (en) Hybrid memory system
KR102443600B1 (en) hybrid memory system
US9928000B2 (en) Memory mapping for object-based storage devices
JP2002268933A (en) Cluster system
US8892810B2 (en) Semiconductor device and memory protection method
EP3446221B1 (en) Adapted block translation table (btt)
US10901910B2 (en) Memory access based I/O operations
US8275980B2 (en) Server computer, computer system, and file management method
CN103842962A (en) Method for improving booting of a computing device
KR102443593B1 (en) hybrid memory system
CN113243008A (en) Distributed VFS with shared page cache
US20100268921A1 (en) Data collection prefetch device and methods thereof
JP4625271B2 (en) Cache device for network boot
US20230027307A1 (en) Hypervisor-assisted transient cache for virtual machines

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees