首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 359 毫秒
1.
静态分析由于并不执行源代码,导致无法获取变量在实际运行中的取值,进而对一些和变量取值相关的缺陷检测带来了一定困难.利用符号执行和区间运算技术,虽然可以模拟程序实际执行时变量的可能取值范围,但对于结构体、数组等,由于不能对其成员进行独立描述,导致数据流无法支持域敏感分析,对和其成员变量相关的缺陷的检测难以实现,产生很多漏报.基于域敏感指向分析的区间运算模型,在域敏感指向分析模型的基础上对其进行了改进,将复杂数据类型拆分成独立的成员变量进行分析,并提出一种关联抽象取值集的类型系统,该系统可以保守的描述程序在动态执行时变量的可能取值.结合赋值语句的抽象语法定义,给出了该类型系统在数据流计算时的具体推导算法,并将其应用在缺陷检测系统(DTSGCC和DTSCPP)中.选用DTSCPP作为实验平台,对6个C++开源工程进行了测试,并对其数据进行了统计分析,结果表明该方法可以减少漏报,且测试效率与非域敏感版本相当.  相似文献   

2.
为权衡对矩阵运算静态分析的精度和效率,针对程序中表示矩阵的变量,提出一种基于抽象解释的抽象与分析算法,即区间向量抽象域。将矩阵变量抽象为一个区间向量对,即行区间向量和列区间向量,矩阵各元素的值范围是由这两个区间向量对应元素的交集表示;设计在该抽象域上的操作以及迁移函数。通过对区间向量抽象域的计算,较好地权衡矩阵元素值范围分析的精确度和分析效率。实验结果表明,该抽象域能够较精确地分析程序中矩阵各元素的值范围,与现有的分析数组的抽象域相比,在分析精度和效率之间取得了合理权衡。  相似文献   

3.
在软件日益丰富的信息时代,程序的正确性验证问题需要深入地研究。提出了基于抽象解释和数值熵协同的数值程序正确性分析方法。利用抽象解释理论框架对数值程序进行抽象解释分析,提取不变量的抽象域区间;在抽象域区间上进行数值熵运算;运行程序获取数值变量的实际取值,计算数值熵;将抽象域区间数值熵和实际数值熵信息进行对比分析,准确地判断程序的正确性等性质。单纯的抽象解释分析只可以近似得到数值变量的取值范围,而引入数值熵算法,在取值范围的基础上对程序静态分析的准确性进一步检验,同时也做到了对程序的正确性验证。通过C语言程序实例,对抽象解释基础上的熵值分析方法进行了验证,证明了该分析方法的可行性和正确性。  相似文献   

4.
变量区间分析是程序代码数据流分析的重要部分。固件反汇编代码存在字节运算和位运算两类运算,当变量取值范围较大时,依次迭代法不能高效地分析经位运算后的结果的取值区间。提出一种快速位运算方法,即根据变量取值区间范围,先将变量转化为不确定位形式再进行位运算;提出一种区间生成算法,即把不确定位形式转化为区间来实现字节运算。实验结果表明,该基于位运算的固件代码变量区间分析方法在程序变量取值范围较大时效率远远高于依次迭代法,而且在各种变量取值区间范围内所需时间稳定,并随着区间范围的增大,其有略微下降趋势。  相似文献   

5.
详细介绍了C语言程序设计中容易遇到的几个疑难问题及其解决方法,并给出了示例。包括如何正确设置开发环境,缓冲区的数据要及时清理,输入结构体变量的float型成员的值可先赋给一个中间变量,给结构体指针变量赋值前应该先分配内存空间,代表空值的NULL的拼写形式不能随意改变。  相似文献   

6.
详细介绍了C语言程序设计中容易遇到的几个疑难问题及其解决方法,并给出了示例。包括如何正确设置开发环境.缓冲区的数据要及时清理,输入结构体变量的float型成员的值可先赋给一个中间变量,给结构体指针变量赋值前应该先分配内存空间。代表空值的NULL的拼写形式不能随意改变。  相似文献   

7.
考虑物流网络需求的不确定性,利用区间参数度量不确定性变量与参数,建立区间需求模式下的物流网络双层规划模型,设计了一种含区间参数与变量的递阶优化遗传算法,通过定义问题求解的风险系数与最大决策偏差,给出适合物流网络结构的区间运算准则,实现模型的确定性转化。以区间松弛变量与0-1决策变量定义初始种群,通过两阶遗传操作运算,求解不同情景下双层规划目标的区间最优解与节点决策方案。算例测试表明算法求解的可操作性更强,求解结果具有区间最优解与情景决策的优越性。  相似文献   

8.
研究了连续型不确定性物流网络节点选址及算法问题。针对物流网络需求的不确定性,以区间的形式度量各种变量,建立基于重心法的物流网络区间节点决策模型。考虑物流网络实践应用性特征,对区间解的性质判定及关系比较进行标定,实现求解模型的确定性转换。将区间运算与遗传算法相结合,设计问题求解的区间迭代遗传算法。算例测试比较分析表明,该算法具有区间决策的优越性,实践可操作性更强。  相似文献   

9.
蒋曹清  肖芳雄  高荣  应时  文静 《计算机科学》2015,42(12):175-180
面向服务软件中服务间消息的变量值可能存在无穷域的情况,从而导致模型检测时产生状态空间爆炸问题。为了使终止性验证在实践上可行,需要约减模型状态空间的大小,使得计算时间和空间需求合理。为此,基于抽象解释的区间抽象理论扩展了经典区间抽象域方法,并在统一的区间抽象域方法上借助异常控制流图对变量进行区间分析,在此基础上逆向分析得到服务间消息的变量区间集。变量区间上任意值相对于终止性验证是等价性,因此从每一个变量区间集中选取一个代表值,可组成服务间消息变量的约减值,从而为异常处理的终止性验证提供了约减的初始配置,有效避免了状态空间爆炸。  相似文献   

10.
激进域敏感基于合并的指针分析   总被引:5,自引:1,他引:4  
指针分析是静态程序分析的基础,指针分析的精度直接影响后续的程序分析和优化.域敏感性用来描述指针分析是否需要区分结构体对象的不同域成员.文中提出一种激进的基于合并的域敏感指针分析方法,利用目标机器模型中的数据布局信息进行高层分析,使用基地址和偏移的组合来激进地表示一个结构体域成员以能更精确地区分结构体的不同域成员.文中还对原有类型推导规则做了重要改进,尽量避免在合并类型变量时造成的精度损失.为了保证新类型推导规则的正确性,方法将所有的结构体赋值操作转换成对每个结构体成员的赋值操作.大量实验数据表明,该方法分析精度显著高于以往方法而运行开销几乎相当.该方法还将域成员的激进表示集成至编译器的中间表示中以获得可移植性.  相似文献   

11.
C语言DSP电机控制功能模块由一结构体类型来组织,内含输入变量,历史变量、参数变量、输出变量、功能函数的指针变量。通过声明结构体类型、定义结构体变量,赋予结构体变量初值,调用其功能函数来实现其模块功能。通过用DSP控制两个电机C语言程序的开发可看出,用功能函数共享和移植的方法,可充分利用现有现成或成熟的软件资源,快速、高效、可靠地开发新的程序、模块和软件。  相似文献   

12.
缓冲区溢出目前已成为最常见的软件安全漏洞之一,从源代码形式来看,常见的缓冲区溢出漏洞主要有两种类型:数据拷贝和格式化字符串造成的缓冲区溢出.分析了常见缓冲区溢出漏洞发生的原因,给出了格式化字符串存储长度的计算方法,介绍了一种基于源代码静态分析的缓冲区溢出检测算法,该算法首先对源代码进行建模,构造其抽象语法树、符号表、控制流图、函数调用图,在此基础上运用区间运算技术来分析和计算程序变量及表达式的取值范围,并在函数间分析中引入函数摘要来代替实际的函数调用.最后使用该方法对开源软件项目进行检测,结果表明该方法能够有效地、精确地检测缓冲区溢出.  相似文献   

13.
There are many software reliability models that are based on the times of occurrences of errors in the debugging of software. It is shown that it is possible to do asymptotic likelihood inference for software reliability models based on order statistics or nonhomogeneous Poisson processes, with asymptotic confidence levels for interval estimates of parameters. In particular, interval estimates from these models are obtained for the conditional failure rate of the software, given the data from the debugging process. The data can be grouped or ungrouped. For someone making a decision about when to market software, the conditional failure rate is an important parameter. The use of interval estimates is demonstrated for two data sets that have appeared in the literature  相似文献   

14.
This paper proposes a methodology for sampling-based design optimization in the presence of interval variables. Assuming that an accurate surrogate model is available, the proposed method first searches the worst combination of interval variables for constraints when only interval variables are present or for probabilistic constraints when both interval and random variables are present. Due to the fact that the worst combination of interval variables for probability of failure does not always coincide with that for a performance function, the proposed method directly uses the probability of failure to obtain the worst combination of interval variables when both interval and random variables are present. To calculate sensitivities of the constraints and probabilistic constraints with respect to interval variables by the sampling-based method, behavior of interval variables at the worst case is defined by the Dirac delta function. Then, Monte Carlo simulation is applied to calculate the constraints and probabilistic constraints with the worst combination of interval variables, and their sensitivities. A merit of using an MCS-based approach in the X-space is that it does not require gradients of performance functions and transformation from X-space to U-space for reliability analysis, thus there is no approximation or restriction in calculating sensitivities of constraints or probabilistic constraints. Numerical results indicate that the proposed method can search the worst case probability of failure with both efficiency and accuracy and that it can perform design optimization with mixture of random and interval variables by utilizing the worst case probability of failure search.  相似文献   

15.
Integrating computer-based learning into the medical school curriculum is hampered by students' propensity to print all digitally available material. The research presented here examines print vs. on-screen consumption of information. In interviews with medical school students variables?Time/Convenience Issues; Habituated Learning Styles and Document Formatting?emerged as patterns repeated by five or more subjects when asked 'why do you print instead of reading material on the screen?' These variables suggest there may be both hardware and software applications that could enhance the utility of student laptops. For example, less cumbersome computers with software allowing simultaneous multi-document use and annotating might be valuable features for students. Several variables, however, are outside the control of academic computing; for example, habituated learning from print and student time constraints. These findings provide a foundation to develop hardware and software design that would encourage on-screen use of information.  相似文献   

16.
化工过程动态仿真软件的一般结构   总被引:3,自引:1,他引:2  
在作者新近提出的化工过程系统学分类方法的基础上,本文给出了化工过程动态仿真软件的一般结构。该结构将所有变量区分为操作内容、阀门开度和过程数据三个大类,分别建立数据库进行维护,数据高度共享,执行效率高。以动态数据库为核心,易于实现面向对象的程序设计,程序模块细化,可组装性能高。  相似文献   

17.
The use of multilevel models for the estimation of the propensity score for data with a hierarchical structure and unobserved cluster-level variables is proposed. This approach is compared with models that ignore the hierarchy, and models in which the hierarchy is represented by a fixed parameter for each cluster. It is shown, by simulation, that simple models with dummy variables outperform both random effect models and models ignoring the hierarchy in terms of balance of cluster-level unobserved covariates and omitted variable bias. The representation of the clusters by fixed or random effects defines a model more general than would be ideal if the relevant cluster-level variables were available. The general conclusion confirms that when conducting propensity score analysis it is safer to specify a more general model than pursuing model parsimony.  相似文献   

18.
19.
Authorware是较为常用的多媒体课件制作软件之一,它的开发工具直观、简单、易用,具有强大的交互功能、方便的向导功能、完美支持多种媒体、强大的变量、函数和ActiveX功能。同时它也有其本身的局限性,无法完成复杂的结构与属性设置以及复杂的交互操作等。通过实例阐述如何借助VB编程工具来创建ActiveX控件,更好地扩展Authorware的功能。  相似文献   

20.
潘晔  任广伟 《微机发展》2006,16(12):52-54
基于MVC设计模式的软件框架逐渐兴起,成为Web架构的开发主流。为了在此架构基础上进一步提高模块结构和组件的重用,提高软件开发的效率,使得架构更加易于扩展和维护,文中基于AOSD(Aspect-Oriented Software Develop-ment)方法来规划Web架构,利用AOSD的动态和静态的用例分析方法,来有效地实现关注点的分离,并使用方面来包装关注点,实现对当前流行的Web框架的改进。利用面向方面的分析和编程方法来规划架构,令Web应用程序的开发更加灵活、高效。  相似文献   

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

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