中国科学院软件研究所机构知识库
Advanced  
ISCAS OpenIR  > 基础软件国家工程研究中心  > 学位论文
Subject: 计算机科学技术
Title:
Wine兼容关键代码的检测及应用方法研究
Author: 黄译萱
Issued Date: 2019-05
Supervisor: 李明树
Major: 计算机软件与理论
Degree Grantor: 中国科学院大学
Place of Degree Grantor: 北京
Degree Level: 硕士
Keyword: Windows应用兼容 ; Wine ; 代码克隆检测
Abstract:

Linux在服务器、嵌入式以及高性能计算领域的市场占有率上优势明显,但是在桌面领域与Windows差距甚大。Windows因其用户界面和操作方式早已成为人们的使用习惯,占据了广阔的桌面市场;而Linux应用程序和设备驱动程序不足的问题严重阻碍了其在桌面市场的拓展。开源应用Wine的出现使在Linux系统上便捷地使用Windows应用程序成为可能。

Wine作为一个在Linux系统上运行Windows应用程序的兼容层,已能兼容大量Windows应用程序。对开源应用程序Wine进行分析对于开发兼容操作系统而言有重大意义。Wine主体工作是对Windows应用程序接口(Application Programming Interface,API)的仿真,以复现Windows编程逻辑。而Wine对Windows API的“翻译”最终都会涉及到Windows操作系统机制到Linux操作系统机制的转换,本文将这些与操作系统机制转换相关的代码称为兼容关键代码。兼容关键代码对于开发Windows应用兼容系统具有重要意义,但实际上,在Wine中查找到这类兼容关键代码十分困难。

本文研究工作主要包括以下三个方面:

Wine兼容关键代码的检测。本文通过分析Wine的源代码,对比Wine与ReactOS DLL的相关情况,提出了基于源代码克隆检测的Wine兼容关键代码检测方法,该方法通过检测ReactOS对Wine的代码克隆,排除明显的兼容非关键代码,从而缩小兼容关键代码的范围。另外,作为上述方法的补充,本文针对Wine Server组件提出了基于函数调用关系检测兼容关键代码的方法,该方法通过检测函数调用图中Linux系统调用的位置,检测兼容关键代码。

Wine兼容关键代码资源库的设计与实现。Wine兼容关键代码数量庞大且复杂,为方便应用兼容关键代码相关信息,本文设计并实现了Wine兼容关键代码资源库,用于检测、存储和展示Wine兼容关键代码。本文设计了资源库结构,设计并实现了用于检测功能的Wine兼容关键代码检测工具和用于展示功能的Wine兼容关键代码资源库可视化访问工具。

Wine兼容关键代码的分析和应用。在Wine兼容关键代码资源库的基础上,本文对Wine兼容关键代码进行整理,将Wine兼容关键代码划分为4类,然后针对每一类别代码提供了实例和分析。本文将Wine预留内存关键代码扩展为Linux系统调用,提高了Wine的启动性能。本文还对Wine xmlite.DLL关键代码进行了分析,并对其进行了重新设计,优化了代码结构。

 

English Abstract:

Linux has a significantly greater share in the market of servers, embedded systems and high-performance computing. But it is much more outperformed by Windows in the desktop market. Windows has occupied a vast desktop market because its user interface and operation mode have long been used by people, while the shortage of Linux application and device driver has seriously hindered the expansion of Linux in the desktop market. The advent of the open source application Wine addresses the gap and possibly enable the convenient use of Windows applications on Linux.

As a compatibility layer running on Linux, Wine has been able to support the execution of a large number of Windows applications. The analysis of Wine is of great significance for the development of compatible operating systems. The essential idea of Wine is to simulate Windows APIs to reproduce Windows programming logic. And, wine's "translation" of Windows APIs will eventually involve the conversion of Windows operating system mechanisms to that of Linux. In this thesis, the code related to such conversion is referred to Compatibility Key Code. Compatibility key code is important to develop a Windows-compatible system. But in fact, it's very difficult to find such compatibility key code in Wine.

The main research work of this thesis includes:

The detection of Wine's compatibility key code. Through the analysis of the source code of Wine and comparison of Wine and ReactOS DLLs, this thesis proposes a Wine's compatibility key code detection method based on code clone detection. This method detects the code clones of Wine by ReactOS, eliminates the obvious non-critical compatibility, and narrows the range of compatibility key code. In addition, as a supplement, this thesis also proposes a Wine's compatibility key code detection method based on function-call relationship, which detects compatibility key code by detecting the location of Linux syscall functions in call graph.

The design and implementation of a resource library of Wine's compatibility key code. There is numerous compatibility key code in Wine. For the convenient application of the compatibility key code and its related information, this thesis designs and builds a resource library of Wine's compatibility key code to detect, store and display them. Specifically, this thesis designs the database of the resource library. In addition, this thesis designs and implementes a Wine compatibility key code detection tool and a visual access tool for the resource library Wine compatibility key code.

The analysis and usage of Wine's compatibility key code. Based on the resource library of Wine's compatibility key code, this thesis divides the Wine-compatible key code into 4 categories, and then provides examples and analysis for each category. This thesis refactors the reserved memory key code into a Linux system call, which improves the startup performance of the Wine. This thesis also analyzes and redesigns the key code of Wine xmlite.DLL to optimize its code structure.

 

Language: 中文
Content Type: 学位论文
URI: http://ir.iscas.ac.cn/handle/311060/19144
Appears in Collections:基础软件国家工程研究中心_学位论文

Files in This Item:
File Name/ File Size Content Type Version Access License
硕士学位论文.pdf(6643KB)学位论文--限制开放 联系获取全文

description.institution: 中国科学院软件研究所

Recommended Citation:
黄译萱. Wine兼容关键代码的检测及应用方法研究[D]. 北京. 中国科学院大学. 2019-05-01.
Service
Recommend this item
Sava as my favorate item
Show this item's statistics
Export Endnote File
Google Scholar
Similar articles in Google Scholar
[黄译萱]'s Articles
CSDL cross search
Similar articles in CSDL Cross Search
[黄译萱]‘s Articles
Related Copyright Policies
Null
Social Bookmarking
Add to CiteULike Add to Connotea Add to Del.icio.us Add to Digg Add to Reddit
所有评论 (0)
暂无评论
 
评注功能仅针对注册用户开放,请您登录
您对该条目有什么异议,请填写以下表单,管理员会尽快联系您。
内 容:
Email:  *
单位:
验证码:   刷新
您在IR的使用过程中有什么好的想法或者建议可以反馈给我们。
标 题:
 *
内 容:
Email:  *
验证码:   刷新

Items in IR are protected by copyright, with all rights reserved, unless otherwise indicated.

 

 

Valid XHTML 1.0!
Copyright © 2007-2019  中国科学院软件研究所 - Feedback
Powered by CSpace