com.ibm.wala.ipa.callgraph.impl.Util.makeRTABuilder()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(2.8k)|赞(0)|评价(0)|浏览(143)

本文整理了Java中com.ibm.wala.ipa.callgraph.impl.Util.makeRTABuilder()方法的一些代码示例,展示了Util.makeRTABuilder()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Util.makeRTABuilder()方法的具体详情如下:
包路径:com.ibm.wala.ipa.callgraph.impl.Util
类名称:Util
方法名:makeRTABuilder

Util.makeRTABuilder介绍

暂无

代码示例

代码示例来源:origin: wala/WALA

public static CallGraph buildRTA(AnalysisOptions options, IAnalysisCacheView cache, IClassHierarchy cha, AnalysisScope scope)
  throws IllegalArgumentException, CancelException {
 StopwatchGC S = null;
 if (CHECK_FOOTPRINT) {
  S = new StopwatchGC("build RTA graph");
  S.start();
 }
 CallGraphBuilder<InstanceKey> builder = Util.makeRTABuilder(options, cache, cha, scope);
 CallGraph cg = builder.makeCallGraph(options, null);
 if (CHECK_FOOTPRINT) {
  S.stop();
  System.err.println(S.report());
 }
 return cg;
}

代码示例来源:origin: SAP/vulnerability-assessment-tool

builder = Util.makeRTABuilder(options, cache, this.cha, this.scope);
} else if (cg_algorithm.equals("0-CFA")) {
  builder = Util.makeZeroCFABuilder(options, cache, this.cha, this.scope);

代码示例来源:origin: wala/WALA

CallGraphBuilder<InstanceKey> rtaBuilder = Util.makeRTABuilder(options, new AnalysisCacheImpl(), cha, scope);
final CallGraph cg = rtaBuilder.makeCallGraph(options, null);

代码示例来源:origin: wala/WALA

CallGraphBuilder<InstanceKey> rtaBuilder = Util.makeRTABuilder(options, new AnalysisCacheImpl(), cha, scope);
final CallGraph cg = rtaBuilder.makeCallGraph(options, null);

代码示例来源:origin: wala/WALA

@Test public void testTypeBasedArrayAlias() throws ClassHierarchyException, IllegalArgumentException, CancelException, IOException {
 AnalysisScope scope = CallGraphTestUtil.makeJ2SEAnalysisScope(TestConstants.WALA_TESTDATA, CallGraphTestUtil.REGRESSION_EXCLUSIONS);
 ClassHierarchy cha = ClassHierarchyFactory.make(scope);
 Iterable<Entrypoint> entrypoints = com.ibm.wala.ipa.callgraph.impl.Util
   .makeMainEntrypoints(scope, cha, TestConstants.ARRAY_ALIAS_MAIN);
 AnalysisOptions options = CallGraphTestUtil.makeAnalysisOptions(scope, entrypoints);
 // RTA yields a TypeBasedPointerAnalysis
 CallGraphBuilder<InstanceKey> builder = Util.makeRTABuilder(options, new AnalysisCacheImpl(),cha, scope);
 CallGraph cg = builder.makeCallGraph(options, null);
 PointerAnalysis<InstanceKey> pa = builder.getPointerAnalysis();
 
 CGNode node = findNode(cg, "testMayAlias1");
 PointerKey pk1 = pa.getHeapModel().getPointerKeyForLocal(node, 1);
 PointerKey pk2 = pa.getHeapModel().getPointerKeyForLocal(node, 2);
 Assert.assertTrue(mayAliased(pk1, pk2, pa));
 
 node = findNode(cg, "testMayAlias2");
 pk1 = pa.getHeapModel().getPointerKeyForLocal(node, 1);
 pk2 = pa.getHeapModel().getPointerKeyForLocal(node, 2);
 Assert.assertTrue(mayAliased(pk1, pk2, pa));
 
 node = findNode(cg, "testMayAlias3");
 pk1 = pa.getHeapModel().getPointerKeyForLocal(node, 1);
 pk2 = pa.getHeapModel().getPointerKeyForLocal(node, 2);
 Assert.assertTrue(mayAliased(pk1, pk2, pa));
}

相关文章