From 1c0693c45ecc2ea7c30dbea744ecbbd2323185d2 Mon Sep 17 00:00:00 2001 From: yeom Date: Sun, 3 Apr 2011 21:13:35 +0000 Subject: [PATCH] changes: build conflict graphs that have line number information of stall sites --- Robust/src/Analysis/OoOJava/ConflictGraph.java | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Robust/src/Analysis/OoOJava/ConflictGraph.java b/Robust/src/Analysis/OoOJava/ConflictGraph.java index d8e72529..b015625d 100644 --- a/Robust/src/Analysis/OoOJava/ConflictGraph.java +++ b/Robust/src/Analysis/OoOJava/ConflictGraph.java @@ -1,6 +1,7 @@ package Analysis.OoOJava; import java.io.BufferedWriter; +import java.io.File; import java.io.FileWriter; import java.util.Collection; import java.util.HashMap; @@ -768,7 +769,15 @@ public class ConflictGraph { attributes += "label=\"" + node.getID() + "\\n"; if (node.isStallSiteNode()) { - attributes += "STALL SITE" + "\\n" + "\"]"; + String srcFileName = node.getVar().getType().getClassDesc().getSourceFileName(); + int separatorIdx = srcFileName.lastIndexOf(File.separator); + if (separatorIdx > 0) { + srcFileName = srcFileName.substring(separatorIdx + 1); + } + node.stallSite.getNumLine(); + attributes += + "STALL SITE" + "\\n" + srcFileName + ":" + node.getStallSiteFlatNode().getNumLine() + + "\\n" + "\"]"; } else { attributes += "LIVE-IN" + "\\n" + "\"]"; } -- 2.34.1