首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 31 毫秒
1.
2.
《Computers & Geosciences》2003,29(9):1091-1100
This paper introduces a hybrid method to update legacy programs, thus combining the visual interactivity of window programs with the qualities of legacy code. Because migration from C, Fortran or Pascal to another programming language is very time-consuming and error-prone, it can be more beneficial to integrate legacy executable files into a visual interactive window shell. Such a shell program is described in this work. Its main part is a multi-file manager with an executable file as the main building block and MyFile as the base class of the resulting UML model. The window shell chosen here runs under the Microsoft Windows 9x/NT/2k/XP operating systems, and the program language to implement the designed shell is Visual Basic. The final shell program was tested with different types of executable files for earth satellite orbit determination, tidal acceleration computation and deformation analysis.  相似文献   

3.
One of the most appealing features of constraint programming is its rich constraint language for expressing combinatorial optimization problems. This paper demonstrates that traditional combinators from constraint programming have natural counterparts for local search, although their underlying computational model is radically different. In particular, the paper shows that constraint combinators, such as logical and cardinality operators, reification, and first-class expressions can all be viewed as differentiable objects. These combinators naturally support elegant and efficient modelings, generic search procedures, and partial constraint satisfaction techniques for local search. Experimental results on a variety of applications demonstrate the expressiveness and the practicability of the combinators.  相似文献   

4.
Model-driven software modernization is a discipline in which model-driven development (MDD) techniques are used in the modernization of legacy systems. When existing software artifacts are evolved, they must be transformed into models to apply MDD techniques such as model transformations. Since most modernization scenarios (e.g., application migration) involve dealing with code in general-purpose programming languages (GPL), the extraction of models from GPL code is an essential task in a model-based modernization process. This activity could be performed by tools to bridge grammarware and MDD technical spaces, which is normally carried out by dedicated parsers. Grammar-to-Model Transformation Language (Gra2MoL) is a domain-specific language (DSL) tailored to the extraction of models from GPL code. This DSL is actually a text-to-model transformation language which can be applied to any code conforming to a grammar. Gra2MoL aims to reduce the effort needed to implement grammarware-MDD bridges, since building dedicated parsers is a complex and time-consuming task. Like ATL and RubyTL languages, Gra2MoL incorporates the binding concept needed to write mappings between grammar elements and metamodel elements in a simple declarative style. The language also provides a powerful query language which eases the retrieval of scattered information in syntax trees. Moreover, it incorporates extensibility and grammar reuse mechanisms. This paper describes Gra2MoL in detail and includes a case study based on the application of the language in the extraction of models from Delphi code.  相似文献   

5.
大量遗留的串行代码需要进行并行化改造,而并行程序复杂性及并行计算平台多样性导致改造成本较高.为此,设计了一种基于标记语言的三层并行编程框架,完成了从串行程序层到并行中间代码层、并行中间代码层到目标并行编程语言程序层的二个转换阶段.采用对串行代码进行语言标记的方法来实现并行中间代码层,该代码层实际是共享存储、分布式存储并行平台编程语言的一种抽象.该框架还实现了一种性能标记方法,可用于并行参数自动寻优.用于雷达数据处理的实验结果表明,实现了对应并行代码的生成,且并行加速比与人工实现的并行代码相当.  相似文献   

6.
Different program understanding algorithms often use different representational frameworks and take advantage of numerous heuristic tricks. This situation makes it is difficult to compare these approaches and their performance. This paper addresses this problem by proposing constraint satisfaction as a general framework for describing program understanding algorithms, demonstrating how to tranform a complex existing program understanding algorithm into an instance of a constraint satisfaction problem, and showing how facilitates better understanding of its performance.  相似文献   

7.
An approach to recovering design-level UML class models from C++ source code to support program comprehension is presented. A set of mappings are given that focus on accurately identifying such elements as relationship types, multiplicities, and aggregation semantics. These mappings are based on domain knowledge of the C++ language and common programming conventions and idioms. Additionally, formal concept analysis is used to detect design-level attributes of UML classes. An application implementing these mappings is used to reverse engineer a moderately sized, open-source application and the resultant class model is compared against those produced by other UML reverse engineering tools. This comparison shows that the presented mapping rules effectively produce meaningful and semantically accurate UML models.  相似文献   

8.
9.
Reverse engineering of program code is the process of constructing a higher level abstraction of an implementation in order to facilitate the understanding of a system that may be in a “legacy” or “geriatric” state. Changing architectures and improvements in programming methods, including formal methods in software development and object-oriented programming, have prompted a need to reverse engineer and re-engineer program code. This paper describes the application of the strongest postcondition predicate transformer (sp) as the formal basis for the reverse engineering of imperative program code.  相似文献   

10.
Christine Gaspin 《Constraints》2001,6(2-3):201-221
A characteristic common to several problems of molecular biology consists in the satisfaction of a set of constraints coming from different sources of biological knowledge. In this paper, we present two problems that take advantage of a constraint satisfaction formulation. The first problem deals with the representation and visualization of RNA secondary structures. The program RNASEARCH implements an original backtracking based algorithm that evaluates at each node the satisfaction of spatial constraints with the aim at drawing a representation without overlap between secondary structural elements. The second problem addresses the determination of RNA secondary structure in accordance with data. With the program SAPSSARN, the application of classic filtering algorithm is used and we discuss a new search algorithm which computes only so called saturated secondary structures. The main result certainly is the possibility to relax the constraint of the absence of secondary structural elements forbidden in secondary structures computed with dynamic programming based approaches: pseudoknots. Finally, we show how each program takes advantage from the other through a protocol driven by constraints.  相似文献   

11.
程序设计语言的相互转换技术可以被广泛运用在软件维护、遗留系统的升级改造以及软件逆向工程等领域中。文中先对现有的几种移植方法进行了分析和研究,分析表明在将程序库移植到Java中和将它们与Java整合时,这些方法暴露出了各自的局限性和不足。借鉴语言转换经验,制定了转换的设计原则并探讨了将C语言转换到Java语言的过程中需要解决的一些问题,以及这个转换系统的设计思想和实现方法。文中所阐述的内容为实现异种程序设计语言的程序代码转换,提高程序代码的可移植性和重用性提供了有意义的思路和实现方法。  相似文献   

12.
张晔  陆余良 《计算机科学》2017,44(Z11):348-352
符号约束描述了程序中的变量关系,被广泛运用于模型检测、符号执行等程序的静态分析方法中。将符号约束应用于可编程逻辑控制器(PLC)程序的正确性验证,能够发现程序中的逻辑错误。人工计算符号约束不仅冗杂枯燥,而且错误率高。针对语句表形式的PLC程序,提出一种基于符号约束的正确性验证方法,通过分析PLC源代码的控制流及数据流,构造程序的控制流图并将其转换为静态单赋值形式的三地址码,最后使用迭代计算的方法求出每个变量的符号约束。  相似文献   

13.
刘有耀  杨鹏程 《计算机应用》2016,36(9):2422-2426
针对当前大量遗产代码无法重复利用的问题,设计一种新的编译工具将C的串行代码转换为基于MPI+OpenMP的混合并行编程代码,降低了并行编程的开发成本。首先,通过对JavaCC的优化,实现一种可以解析C语言的词法和语法分析器,进行源代码分析并生成抽象语法树;其次,根据语法树对源代码进行控制依赖性和数据依赖性分析,产生可并行化的语句块分区;再次,按照提出的并行代码生成方法得到目标代码;最后,基于Visual Studio 2010构建目标代码仿真验证环境。实验结果表明,该工具可以较为理想地实现串行代码自动并行化,与手工编写的代码在加速比上的误差为8.2%~18.4%。  相似文献   

14.
15.
并发约束程序设计语言COPS及其执行模型   总被引:1,自引:0,他引:1  
约束程序设计尤其是约束逻辑程序设计与并发约束程序设计在AI程序设计领域占据着越来越重要的位置。传统逻辑程序设计的基“计算即为定理证明”的计算风格虽获得了简洁优美的操作语义特性,但也付出了执行效率低的代价,当应用系统规模增大时,其性能严重下降以致崩溃。针对传统逻辑程序设计的这种可伸缩性问题,设计了一个基于并发约束程序设计概念的说明性语言COPS,旨在从语言设计与执行模型两方面降低说明性程序的不确定性,提高搜索与运行效率。在语言设计方面,通过引入确定性语言成分,避免不确定计算用于确定性目标所浪费的系统开销;在执行模型方面,在目标的并发穿叉执行与数据驱动的并发同步机制的基础上,实现“优先执行确定目标”策略与“最少假定”策略,作为约束传播的延伸,最大幅度地剪枝搜索空间,降低搜索复杂性。COPS提供的知识表示、推理与并发机制使其成为构造agent程序的理想语言。论文给出COPS语言的语法规范与执行模型的操作语义描述。  相似文献   

16.
CSPCONS is a programming language that supports program execution over multiple Prolog processes with constraints. The language is an extended version of Csp-ii, a version of Prolog that supports channel-based communicating processes and TCP/IP communication, that is based on the CSP model introduced by Hoare. Cspcons inherits all the advanced features of Csp-ii and extends it by introducing constraint solving capabilities to the processes. In Cspcons each Prolog process has one or more solvers attached and each solver is independent from the others, following the original Csp-ii model, thus resulting to a communicating sequential constraint logic programming system. Such a model can facilitate greatly the implementation of distributed CLP applications. This paper describes the original Csp-ii system along with details of the extensions that resulted to the Cspcons system and presents an example demonstrating the applicability of the system to distributed constraint satisfaction problems.  相似文献   

17.
基于程序理解的编程题自动评分方法   总被引:3,自引:0,他引:3  
针对传统的编程题自动评分方法没有考虑学生程序是怎样实现编程任务的,以及不能从程序文本的语法结构和语义角度衡量学生程序与正确答案的接近程度等问题,提出一种基于程序理解的自动评分方法.以程序理解的一般过程及基本策略为依据,结合人工阅卷的思维过程,建立评分模型.评分过程可划分为3个阶段:首先将程序代码转换成系统依赖图中间表示形式;然后,对系统依赖图进行标准化转换,消除程序表达方式的多样性;最后,匹配标准化后的学生程序与模板程序系统依赖图并根据匹配结果给出评分.该方法被应用于"C语言编程题自动评分系统"中.实验结果表明:它可以根据学生程序的语法和语义衡量学生程序实现编程任务的正确程度,具有较高的准确性.  相似文献   

18.
In this paper we describe the results of a study of the insertion of checkpoints within a legacy software system in the aerospace domain. The purpose of the checkpoints was to improve program fault-tolerance during program execution by rolling back system control to a saved state from which program execution can continue. The study used novice programmers for the determination of where the checkpoints were to be added. The focus was on the programmer’s understanding of the code, since this affected how the checkpoints were placed. The results should provide guidance to those interested in improving the fault-tolerance of legacy software systems, especially those written in older, nearly obsolescent programming languages.  相似文献   

19.
Knowledge-based program analysis   总被引:1,自引:0,他引:1  
《Software, IEEE》1990,7(1):74-81
Automatic program analysis is regarded here as both the mechanized process of understanding high-level concepts from program text and the use of those concepts to guide program maintenance. A knowledge-based program analysis tool called PAT, which realizes this concept, is described. PAT uses an object-oriented framework to represent programming concepts and a heuristic-based concept-recognition mechanism to derive high-level functional concepts from the source code. As an example, a segment of a much larger program written in a Pascal-like language is analyzed using PAT  相似文献   

20.
For maintainers involved in understanding and reengineering large software, locating source code fragments that match certain patterns is a critical task. Existing solutions to the problem are few, and they either involve manual, painstaking scans of the source code using tools based on regular expressions, or the use of large, integrated software engineering environments that include simple pattern-based query processors in their toolkits. We present a framework in which pattern languages are used to specify interesting code features. The pattern languages are derived by extending the source programming language with pattern-matching symbols. We describe SCRUPLE, a finite state machine-based source code search tool, that efficiently implements this framework. We also present experimental performance results obtained from a SCRUPLE prototype, and the user interface of a source code browser built on top of SCRUPLE  相似文献   

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

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