首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 297 毫秒
1.
2.
The steadily growing embedded-systems market comprises many application domains in which real-time constraints must be satisfied. To guarantee that these constraints are met, the analysis of the worst-case execution time (WCET) of software components is mandatory. In general WCET analysis needs additional control-flow information, which may be provided manually by the user or calculated automatically by program analysis. For flexibility and simplicity reasons it is desirable to specify the flow information at the same level at which the program is developed, i.e., at the source level. In contrast, to obtain precise WCET bounds the WCET analysis has to be performed at machine-code level. Mapping and transforming the flow information from the source-level down to the machine code, where flow information is used in the WCET analysis, is challenging, even more so if the compiler generates highly optimized code. In this article we present a method for transforming flow information from source code to machine code. To obtain a mapping that is safe and accurate, flow information is transformed in parallel to code transformations performed by an optimizing compiler. This mapping is not only useful for transforming manual code annotations but also if platform-independent flow information is automatically calculated at the source level. We show that our method can be applied to every type of semantics-preserving code transformation. The precision of this flow-information transformation allows its users to calculate tight WCET bounds.  相似文献   

3.
Gordon Stevenson 《Software》1980,10(5):393-403
This paper describes a general purpose optimizer used to construct a new code generator for an existing Coral 66 compiler. The optimizer is recursive and gives the one pass code generator some of the advantages of a multiple pass scheme by ‘pipelining’ short sequences of linear intermediate code at each activation level.  相似文献   

4.
Metamorphic software changes its internal structure across generations with its functionality remaining unchanged. Metamorphism has been employed by malware writers as a means of evading signature detection and other advanced detection strategies. However, code morphing also has potential security benefits, since it can serve to increase the “genetic diversity” of software. We have created a metamorphic code generator within the LLVM compiler framework. LLVM is a three-phase compiler that supports multiple source languages and target architectures. It uses a common intermediate representation (IR) bytecode in its optimizer. Consequently, any supported high-level programming language is transformed to this IR bytecode as part of the LLVM compilation process. Our metamorphic generator functions at the IR bytecode level, which provides many advantages over morphing at the assembly or source code level. The morphing techniques that we employ include dead code insertion and transposition, where the dead code is actually executed within the morphed code, making its detection and removal more challenging. We have verified the effectiveness of our code morphing using hidden Markov model analysis.  相似文献   

5.
Many techniques have been developed over the years to detect code clones in different software systems to maintain security measures. These techniques often require the source code to compare the subject system against a very large data set of big code. This paper presents index-based features extraction technique (IBFET) to detect code clones at a very large-scale level to billions of LOC at file level granularity. We performed preprocessing, indexing, and clone detection for more than 324 billion of LOC using a Hadoop distributed environment, which is quite faster and more efficient as compared to existing distributed indexing and clone detection techniques; meanwhile, it detects all three types of clones efficiently. The MapReduce rule of divide and conquer is used for a count and retrieve the similar features between different systems. We evaluated the execution time, scalability, precision, and recall of IBFET by using a well-known clone detection data set IJaDataset and BigCloneBench; furthermore, we compared the results with other state-of-the-art tools. Our approach is faster, flexible, scalable, and provides accurate results with high authenticity and can be implemented at a large-scale level.  相似文献   

6.
针对智能化漏洞检测,从源代码程序依赖图中根据漏洞特征提取图结构源代码切片,将图结构切片信息表征后利用图神经网络模型进行漏洞检测工作。实现了切片级的漏洞检测,并在代码行级预测漏洞行位置。为了验证系统的有效性,分别与静态漏洞检测系统、基于序列化文本信息和基于图结构化信息的漏洞检测系统做比较,实验结果表明,所提系统在漏洞检测能力上有较高准确性,并且在漏洞代码行预测工作上有较好表现。  相似文献   

7.
The recent advent of multithreaded architectures holds many promises: the exploitation of intrathread locality and the latency tolerance of multithreaded synchronization can result in a more efficient processor utilization and higher scalability. The challenge for a code generation scheme is to make effective use of the underlying hardware by generating large threads with a large degree of internal locality without limiting the program level parallelism or increasing latency. Top-down code generation, where threads are created directly from the compiler's intermediate form, is effective at creating a relatively large thread. However, having only a limited view of the code at any one time limits the quality of threads generated. These top-down generated threads can therefore be optimized by global, bottom-up optimization techniques. In this paper, we introduce the Pebbles multithreaded model of computation and analyze a code generation scheme whereby top-down code generation is combined with bottom-up optimizations. We evaluate the effectiveness of this scheme in terms of overall performance and specific thread characteristics such as size, length, instruction level parallelism, number of inputs, and synchronization costs.  相似文献   

8.
针对传统软件监控方法中模块化不好、缺乏灵活性的缺点,文中的模型中,将组件技术中的概念和方法应用于面向方面的技术中,提出了一个模块化、灵活性好的软件监控模型。在模型中将监控功能封装为一个面向方面的组件,有效解决了传统监控方法中因在应用代码中插入监控功能代码所产生的代码混乱与分散问题,也避免了因在组件和方面两个维度上考虑监控问题所产生的代码混乱与分散问题。  相似文献   

9.
张杨  东春浩  刘辉  葛楚妍 《软件学报》2022,33(5):1551-1568
目前已有的代码坏味检测方法仅依赖于代码结构信息和启发式规则, 对嵌入在不同层次代码中的语义信息关注不够, 而且现有的代码坏味检测方法准确率还有进一步提升的空间. 针对该问题, 提出一种基于预训练模型和多层次信息的代码坏味检测方法DeepSmell, 首先采用静态分析工具提取程序中的代码坏味实例和多层次代码度量信息, 并...  相似文献   

10.
针对目前虚拟服务器的安全问题进行研究。设计了一种新的Web虚拟服务器应用安全的解决方案,在代码一级对其攻击进行检测和防护。即一方面,确定代码位置,利用特定的API调用在其前后对用户输入相关的参数进行判断是否含有可能的攻击存在并进行相应的处理;另一方面在应用源代码或中间代码文件中插入本方案的检测代码,以实现防护的功能。  相似文献   

11.
肖成龙  林军  王珊珊  王宁 《计算机应用》2018,38(7):2024-2031
针对在高层次综合(HLS)过程中性能提升、功耗降低困难等问题,提出了一种面向高层次综合的自定义指令自动识别方法。在高层次综合过程之前实现对自定义指令的枚举和选择,从而为高层次综合提供通用的自定义指令识别方法。首先,将高层次源代码转换为控制数据流图(CDFG),实现了对源代码的预处理;其次,基于控制数据流图内的数据流图(DFG),采用子图枚举算法以自底而上的方式枚举出所有连通凸子图,有效提高了用户可灵活修改约束条件的能力;然后,分别从面积、性能和代码量三个角度考虑,利用子图选择算法选择部分最佳子图作为最终的自定义指令;最后,用所选的自定义指令重新生成新代码作为高层次综合工具的输入。与传统高层次综合相比,采用基于出现频率的模式选择可平均减少19.1%的面积,采用基于关键路径的子图选择可平均减少22.3%的时延。此外,与TD算法相比,所提算法的枚举效率平均提升70.8%。实验结果表明,自定义指令自动识别方法使高层次综合在电路设计中能够显著地提升性能,减少面积和代码量。  相似文献   

12.
针对现有代码克隆检测方法通常存在标记表示单一而抽象语法树构造复杂的问题,提出一种结合分层特征的代码克隆检测方法。使用双层双向长短时记忆网络提取行级和全局代码层次的深层语义信息,挖掘目标代码的语义特征。引入注意力机制调整重要标记及代码行的影响权重,增强语义形式的代码克隆检测效果,并采用softmax分类器识别克隆代码。实验结果表明,该方法的召回率和精确度分别为91%和97%,相比NICAD、CCIS、CCLearner方法对于复杂语义形式的克隆代码具有更好的检测效果。  相似文献   

13.
Integrity constraints (including key, referential and domain constraints) are unique features of database applications. Integrity constraints are crucial for ensuring accuracy and consistency of data in a database. It is important to perform integrity constraint enforcement (ICE) at the application level to reduce the risk of database corruption. We have conducted an empirical analysis of open-source PHP database applications and found that ICE does not receive enough attention in real-world programming practice. We propose an approach for automatic detection of ICE violations at the application level based on identification of code patterns. We define four patterns that characterize the structures of code implementing integrity constraint enforcement. Violations of these patterns indicate the missing of integrity constraint enforcement. Our work contributes to quality improvement of database applications. Our work also demonstrates that it is feasible to effectively identify bugs or problematic code by mining code patterns in a specific domain/application area.  相似文献   

14.
Reverse engineering of computer software has assumed greater importance in recent years because of the need to examine legacy code to remove the year 2000 bug. There are different types of reverse engineering based on the level of abstraction of the code to be reengineered; machine code, assembly code, source code or even CASE code. We describe the different types of reverse engineering and the extent of copyright protection for software. The most common uses of reverse engineering are described. This provides for a comparative overview of the legal standing on reverse engineering at the international level. We propose challenges to the global electronic community in relation to existing and future legislation in the area of reverse engineering and protection of digital works.  相似文献   

15.
针对底层虚拟机混淆器(OLLVM)在指令混淆层面只支持指令替换一种算法,且仅支持5种运算符和13种替换方案的问题,设计了一种改进版的指令混淆框架InsObf,以加强OLLVM指令层面的混淆效果。InsObf包含指令加花和指令替换,其中指令加花首先对基本块的指令进行依赖分析,然后插入叠加跳转和虚假循环两种花指令;指令替换在OLLVM的基础上,拓展至13种运算符,共计52种指令替换方案。在底层虚拟机(LLVM)上实现了框架原型后,通过实验表明,与OLLVM相比,InsObf在时间开销增长约10个百分点,空间开销增长约20个百分点的情况下,圈复杂度和抗逆向能力均可提高近4倍;与同样基于OLLVM改进的Armariris和Hikari相比,InsObf在同一量级的时空开销下,可以提供更高的代码复杂度。因此,InsObf可提供指令层级的有效保护。  相似文献   

16.
Approaches to runtime checking have to track the execution of a software system and therefore have to deal with generating and processing execution events. Often these techniques are applied at the code level – either by inserting new source code prior to the compilation or by modifying the target code, e.g. Java byte code, before running the program.The jassda [4,3] framework and tool enable runtime checking of Java programs against a CSP-like specification. For generating events it uses the Java Debug Interface (JDI) and thus no modifications to the code are necessary. Another advantage is that events are generated on demand, i.e. dynamically at runtime it is determined which events to generate for the current debug run without modifying the program itself. This paper shows how this event generation is done by the jassda framework.  相似文献   

17.
S. Saxena  J. A. Field 《Software》1985,15(3):277-303
This paper discusses a method for developing efficient and portable software for 8-bit microprocessors used in real-time applications. The technique used is to design an ‘intermediate level language’ (ILL) which defines low-level primitives to support the real-time application programming and the constructs of high level languages. Thus, the high level language (HLL) program goes through two stages of translation; first to the ILL code and then to the machine code of a microprocessor. The ILL instruction set developed bridges the gap between high level languages and the poor instruction set of microprocessors. This allows the development of optimized and portable code for the microprocessors. The ILL operations, data types, data organization, control structures, synchronization, communication and multi-tasking facilities are described. The effectiveness of this technique is shown by comparing the code generated by the ILL approach with the code available for a sample real-time application written directly in assembly level language.  相似文献   

18.
于国防  王莉 《计算机工程》2010,36(7):182-184
针对动态数字图像的识别问题,提出基于二级复合链码的七段数字识别方法。对细化后的目标图像进行第1级8方向Freeman链码描述,在此基础上,进行第2级4方向Freeman链码描述,得到的复合链码与七段数字具有单一映射关系。在无线瓦斯检测系统中的应用结果表明,该方法具有较高的识别率和执行效率。  相似文献   

19.
Reverse engineering of computer software has assumed greater importance in recent years because of the need to examine legacy code to remove the year 2000 bug. There are different types of reverse engineering based on the level of abstraction of the code to be reengineered; machine code, assembly code, source code or even CASE code. We describe the different types of reverse engineering and the extent of copyright protection for software. The most common uses of reverse engineering are described. This provides for a comparative overview of the legal standing on reverse engineering at the international level. We propose challenges to the global electronic community in relation to existing and future legislation in the area of reverse engineering and protection of digital works. This revised version was published online in June 2006 with corrections to the Cover Date.  相似文献   

20.
周光有  谢琦  余啸 《软件学报》2024,35(6):2863-2879
代码搜索是当下自然语言处理和软件工程交叉领域的一个重要分支. 开发高效的代码搜索算法能够显著提高代码重用的能力, 从而有效提高软件开发人员的工作效率. 代码搜索任务是以描述代码片段功能的自然语言作为输入, 在海量代码库中搜索得到相关代码片段的过程. 基于序列模型的代码搜索方法DeepCS虽然取得了很好的效果, 但这种方法不能捕捉代码的深层语义. 基于图嵌入的代码搜索方法GraphSearchNet能缓解这个问题, 但没有对代码与文本进行细粒度匹配, 也忽视了代码图和文本图的全局关系. 为了解决以上局限性, 提出基于关系图卷积网络的代码搜索方法, 对构建的文本图和代码图编码, 从节点层面对文本查询和代码片段进行细粒度匹配, 并应用神经张量网络捕捉它们的全局关系. 在两个公开数据集上的实验结果表明, 所提方法比先进的基线模型DeepCS和GraphSearchNet搜索精度更高.  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号