]> sourceware.org Git - frysk.git/commitdiff
Improve fstack, et.al., output; add Frame.toPrint PrintStackOptions param.
authorAndrew Cagney <cagney@redhat.com>
Tue, 10 Jun 2008 17:21:49 +0000 (13:21 -0400)
committerAndrew Cagney <cagney@redhat.com>
Tue, 10 Jun 2008 17:33:46 +0000 (13:33 -0400)
This changes the following in fstack et.al.:

-> prints the shared library by default

-> prints FUNC() _at_ FILE#line

-> tightens tests to explicit check for parameter names, and not
   values (and adds framework for adding a -print values option).

-> makes ferror consistent with other utilities - print an abi frame
   by default

-> for -rich, don't print local variable information

With this in place fstack et.al. support:

  default: a raw ABI stack backtrace
  lite: a minimial debug-info stack backtrace
  rich: a full inline stack backtrace

The patches size comes from me replacing a some what arbitrary and
confusing list of boolean flags to Frame.toPrint et.al. with
Print*StackOptions classes.

frysk-core/frysk/bindir/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* TestFstack.java (testBackTraceWithRich()): Mark as unresolved;
bug 6616.
* ferror.java: Use PrintDebugInfoStackOptions; don't specify the
default stack options.
* ftrace.java: Ditto.
* fstack.java: Ditto.

frysk-core/frysk/debuginfo/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* DebugInfoFrame.java (toPrint(PrintWriter,boolean,boolean)): Delete.
(toPrint(PrintWriter,DebugInfoStackOptions)): New.
* PrintParameterOptions.java: New.
* VirtualDebugInfoFrame.java: Ditto.
* PrintDebugInfoStackOptions.java: Rename PrintStackOptions,
extend frysk.stack.PrintStackOptions.
* TestFrameDebugInfo.java: Update.

frysk-core/frysk/ftrace/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* Ftrace.java: Use PrintDebugInfoStackOptions.
* Reporter.java: Ditto.

frysk-core/frysk/proc/dead/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* TestLinuxCore.java: Use PrintDebugInfoStackOptions.

frysk-core/frysk/scopes/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* Function.java (printParameters): Add boolean printValues
parameter.

frysk-core/frysk/stack/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* Frame.java (toPrint(PrintWriter,PrintStackOptions)): Replace
toPrint(PrintWriter,boolean,boolean).
(toPrint(PrintWriter)): Delete.
* PrintStackOptions.java: New.
* StackFactory.java: Use.

frysk-core/frysk/util/ChangeLog
2008-06-10  Andrew Cagney  <cagney@redhat.com>

* TestStackTraceAction.java: Use PrintDebugInfoStackOptions.
* StackPrintUtil.java: Ditto.
* StacktraceAction.java: Ditto.
* FCatch.java: Ditto.
* StressTestStackTraceAction.java: Ditto.

29 files changed:
frysk-core/frysk/bindir/ChangeLog
frysk-core/frysk/bindir/TestFstack.java
frysk-core/frysk/bindir/ferror.java
frysk-core/frysk/bindir/fstack.java
frysk-core/frysk/bindir/ftrace.java
frysk-core/frysk/debuginfo/ChangeLog
frysk-core/frysk/debuginfo/DebugInfoFrame.java
frysk-core/frysk/debuginfo/DebugInfoStackFactory.java
frysk-core/frysk/debuginfo/PrintDebugInfoStackOptions.java [moved from frysk-core/frysk/debuginfo/PrintStackOptions.java with 66% similarity]
frysk-core/frysk/debuginfo/TestFrameDebugInfo.java
frysk-core/frysk/debuginfo/VirtualDebugInfoFrame.java
frysk-core/frysk/ftrace/ChangeLog
frysk-core/frysk/ftrace/Ftrace.java
frysk-core/frysk/ftrace/Reporter.java
frysk-core/frysk/hpd/StackCommands.java
frysk-core/frysk/proc/dead/ChangeLog
frysk-core/frysk/proc/dead/TestLinuxCore.java
frysk-core/frysk/scopes/ChangeLog
frysk-core/frysk/scopes/Function.java
frysk-core/frysk/stack/ChangeLog
frysk-core/frysk/stack/Frame.java
frysk-core/frysk/stack/PrintStackOptions.java [new file with mode: 0644]
frysk-core/frysk/stack/StackFactory.java
frysk-core/frysk/util/ChangeLog
frysk-core/frysk/util/FCatch.java
frysk-core/frysk/util/StackPrintUtil.java
frysk-core/frysk/util/StacktraceAction.java
frysk-core/frysk/util/StressTestStackTraceAction.java
frysk-core/frysk/util/TestStackTraceAction.java

index 0429ed3532c8d2b239d8f331bd53afa818d53ca3..226c6d7c4675f0115efc0edbaf08e4094fb05906 100644 (file)
@@ -1,3 +1,12 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * TestFstack.java (testBackTraceWithRich()): Mark as unresolved;
+       bug 6616.
+       * ferror.java: Use PrintDebugInfoStackOptions; don't specify the
+       default stack options.
+       * ftrace.java: Ditto.
+       * fstack.java: Ditto.
+
 2008-06-04  Sami Wagiaalla  <swagiaal@redhat.com>
 
        * TestFstep.java: Marked tests are unresolved.
index aafeb66a918e015938c7f9866dff25ac3948dc6a..837aa3ea6a3461482d0bf8079980d9c91518d8be 100644 (file)
@@ -90,7 +90,7 @@ public class TestFstack extends TestLib {
        TearDownExpect e = fstack("funit-stack-outlined", new String[] {
                "-print", "debug-names,params"
            });
-       e.expect("\\#0 .* in third\\(int arg3\\) .*\\/funit-stack-outlined\\.c#");
+       e.expect("\\#0 .* in third\\(int arg3\\) at funit-stack-outlined\\.c#");
        e.expect("\\#1");
     }
 
@@ -136,11 +136,13 @@ public class TestFstack extends TestLib {
     }
 
     public void testBackTraceWithRich() {
+       if (unresolved(6616))
+           return;
        TearDownExpect e = fstack("funit-stack-inlined",
                                  new String[] { "-rich" });
-        e.expect("\\#0 .* third\\(int arg3.*\\)");
-        e.expect("\\#1 .* second\\(int arg2.*\\)");
-        e.expect("\\#2 .* first\\(int arg1.*\\)");
+        e.expect("\\#0 .* third\\(int arg3\\)");
+        e.expect("\\#1 .* second\\(int arg2\\)");
+        e.expect("\\#2 .* first\\(int arg1\\)");
         e.expect("\\#3 .* main\\(\\)");
     }
 
index ed0cbdb555a6618d031d377f95eb35c438647b16..3592edd61066862eedde5a3853b6faa74e9d7a24 100644 (file)
@@ -43,7 +43,7 @@ import java.io.PrintWriter;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.isa.syscalls.Syscall;
 import frysk.proc.Action;
 import frysk.proc.Task;
@@ -58,8 +58,8 @@ import gnu.classpath.tools.getopt.OptionGroup;
 
 public class ferror {
     
-    private static final PrintStackOptions stackPrintOptions
-       = new PrintStackOptions().setRich();
+    private static final PrintDebugInfoStackOptions stackPrintOptions
+       = new PrintDebugInfoStackOptions();
     private static final PrintWriter printWriter = new PrintWriter(System.out);
     private static Pattern writePattern;
     private static OptionGroup[] options() {
index a59bd43b7891f4b3d4e570bba3b26a56f18bc350..89988a98730c3a52c8c57611204896461a456aa3 100644 (file)
@@ -42,7 +42,7 @@ package frysk.bindir;
 import java.io.PrintWriter;
 import java.util.Iterator;
 import java.util.TreeMap;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.event.Event;
 import frysk.event.ProcEvent;
 import frysk.proc.Proc;
@@ -55,8 +55,8 @@ import gnu.classpath.tools.getopt.OptionGroup;
 public final class fstack {
 
   private static PrintWriter printWriter = new PrintWriter(System.out);  
-    private static PrintStackOptions stackPrintOptions
-       = new PrintStackOptions();
+    private static PrintDebugInfoStackOptions stackPrintOptions
+       = new PrintDebugInfoStackOptions();
   private static final Log fine = Log.fine(fstack.class);
   
     public static void main(String[] args) {
index 86cb8fcf4dc70ec5183dbf06e9e20c448387a412..34baff7271bcecc1b08ff0d964122ded4e026a21 100644 (file)
@@ -52,7 +52,7 @@ import gnu.classpath.tools.getopt.OptionException;
 import gnu.classpath.tools.getopt.OptionGroup;
 import inua.util.PrintWriter;
 
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.expr.FQIdentParser;
 import frysk.expr.FQIdentifier;
 import frysk.ftrace.AddrRule;
@@ -94,8 +94,8 @@ class ftrace {
     private final FtraceController controller = new FtraceController();
     private boolean allowInterpTracing = false;
 
-    private final PrintStackOptions stackPrintOptions
-       = new PrintStackOptions();
+    private final PrintDebugInfoStackOptions stackPrintOptions
+       = new PrintDebugInfoStackOptions();
     private final Ftrace tracer = new Ftrace(stackPrintOptions);
 
     private interface RuleMatcher {
index f74532f07a053ae55a9900df615956edc2f57e4e..649fe3130ee508805a908c7b8edc91c724367764 100644 (file)
@@ -1,3 +1,13 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * DebugInfoFrame.java (toPrint(PrintWriter,boolean,boolean)): Delete.
+       (toPrint(PrintWriter,DebugInfoStackOptions)): New.
+       * PrintParameterOptions.java: New.
+       * VirtualDebugInfoFrame.java: Ditto.
+       * PrintDebugInfoStackOptions.java: Rename PrintStackOptions,
+       extend frysk.stack.PrintStackOptions.
+       * TestFrameDebugInfo.java: Update.
+
 2008-06-06  Andrew Cagney  <cagney@redhat.com>
 
        * DebugInfo.java: Let DwflDie adjust for bias.
index 02ecdca6a6aef4cd64c03717c05844f248bf2d33..ea0b1b7d345c0682bf8f0740f0332f8a74c123a9 100644 (file)
 
 package frysk.debuginfo;
 
+import frysk.util.ArchFormatter;
 import java.io.PrintWriter;
 import java.util.Iterator;
 import java.util.LinkedList;
-
 import lib.dwfl.DwarfDie;
 import lib.dwfl.Dwfl;
 import lib.dwfl.DwflDie;
@@ -186,39 +186,31 @@ public class DebugInfoFrame extends FrameDecorator {
     }
     private LineXXX lineXXX;
     
-    public void toPrint(PrintWriter writer, boolean printParameters,
-                boolean fullpath){
+    public void toPrint(PrintWriter writer,
+                       PrintDebugInfoStackOptions options) {
         Function subprogram = this.getSubprogram();
-
         if (subprogram != null) {
-           writer.print("0x");
-           String addr = Long.toHexString(this.getAddress());
-           int padding = 2 * this.getTask().getISA().wordSize() - addr.length();
-          
-           for (int i = 0; i < padding; ++i)
-               writer.print('0');
-          
-           writer.print(addr);
-           writer.print(" in " + subprogram.getName() + "(");
-           if (printParameters) {
-               subprogram.printParameters(writer, this);
+           writer.write(ArchFormatter.toHexString(getTask(), getAddress()));
+           writer.print(" in ");
+           writer.print(subprogram.getName());
+           writer.print("(");
+           if (options.printParameters()) {
+               subprogram.printParameters(writer, this, options.printValues());
            }
-           writer.print(") ");
-          
-           if (fullpath) {
+           writer.print(") at ");
+           if (options.printFullPaths()) {
                SourceLocation line = this.getLine();
                writer.print(line.getFile().getPath());
                writer.print("#");
                writer.print(line.getLine());
            } else {
                SourceLocation line = this.getLine();
-               writer.print(".../"+line.getFile().getName());
+               writer.print(line.getFile().getName());
                writer.print("#");
                writer.print(line.getLine());
            }
-          
         } else {
-            super.toPrint(writer, true, fullpath);
+            super.toPrint(writer, options);
         }
     }
     
index 7023da6215bf8be9c792d3e6f1eaddb6e78024c5..4adec653947f8e2ebac632d48e6cfc2dcb59d4d8 100644 (file)
@@ -51,9 +51,6 @@ import frysk.stack.StackFactory;
  */
 public class DebugInfoStackFactory {
 
-    public static final PrintStackOptions DEFAULT
-       = new PrintStackOptions().setRich();
-
     /**
      * Create an ABI stack backtrace, make the simpler debug-info
      * methods.
@@ -100,29 +97,31 @@ public class DebugInfoStackFactory {
        return innermostFrame;
     }
 
-    public static final void printTaskStackTrace (PrintWriter printWriter, Task task, PrintStackOptions options)
-    {
-      if (task != null){
-        printWriter.println("Task #" + task.getTid());
-        DebugInfoFrame frame = createDebugInfoStackTrace(task);
-        printStackTrace(printWriter, frame, options);
-      }
-      printWriter.flush();
+    public static final void printTaskStackTrace(PrintWriter printWriter,
+                                                Task task,
+                                                PrintDebugInfoStackOptions options) {
+       if (task != null) {
+           printWriter.println("Task #" + task.getTid());
+           DebugInfoFrame frame = createDebugInfoStackTrace(task);
+           printStackTrace(printWriter, frame, options);
+       }
+       printWriter.flush();
     }
 
-    public static final void printVirtualTaskStackTrace (PrintWriter printWriter, Task task, PrintStackOptions options)
-    {
-      if (task != null){
-        printWriter.println("Task #" + task.getTid());
-        DebugInfoFrame frame = createVirtualStackTrace(task);
-        printStackTrace(printWriter,frame, options);
-      }
-      printWriter.flush();
+    public static final void printVirtualTaskStackTrace(PrintWriter printWriter,
+                                                       Task task,
+                                                       PrintDebugInfoStackOptions options) {
+       if (task != null) {
+           printWriter.println("Task #" + task.getTid());
+           DebugInfoFrame frame = createVirtualStackTrace(task);
+           printStackTrace(printWriter,frame, options);
+       }
+       printWriter.flush();
     }
 
     public static void printStackTrace(PrintWriter writer,
                                       DebugInfoFrame topFrame,
-                                     PrintStackOptions options) {
+                                      PrintDebugInfoStackOptions options) {
         
        int count = 0;
         for (DebugInfoFrame frame = topFrame; frame != null;
@@ -142,8 +141,7 @@ public class DebugInfoStackFactory {
 
            frame.printLevel(writer);
            writer.print(" ");
-           frame.toPrint(writer, options.printParams(),
-                         options.printFullPaths());
+           frame.toPrint(writer, options);
            writer.println();
            if (options.printLocals()) {
                frame.printScopes(writer);
similarity index 66%
rename from frysk-core/frysk/debuginfo/PrintStackOptions.java
rename to frysk-core/frysk/debuginfo/PrintDebugInfoStackOptions.java
index acae8e00b0e15be4af48c16cd91419da8909280b..c2110e1584687ff6de32267532a517bf553372e7 100644 (file)
 
 package frysk.debuginfo;
 
-public class PrintStackOptions {
+import frysk.stack.PrintStackOptions;
 
-    private int numberOfFrames = 10;
+public class PrintDebugInfoStackOptions extends PrintStackOptions {
 
-    private boolean printFullPaths = false;
-
-    private boolean printParams = false;
-    private boolean printLocals = false;
-    private boolean printLibraries = false;
-    private boolean printInlineFunctions = false;
-    private boolean printDebugNames = false;
-    
-    public PrintStackOptions() {
+    public PrintDebugInfoStackOptions() {
+       // Note, the super calls clear.
     }
     
+    private boolean printParameters;
+    private boolean printLocals;
+    private boolean printInlineFunctions;
+    private boolean printDebugNames;
+    private boolean printValues;
+    
     /**
-     * Set things up for a light-weight, or low-cost, back-trace by
-     * limiting things to just the elf information.
+     * Clear all options.
      */
-    public PrintStackOptions setLite() {
-       printParams = false;
+    public void clear() {
+       super.clear();
+       printParameters = false;
        printLocals = false;
-       printLibraries = true;
        printInlineFunctions = false;
-       printDebugNames = true;
-       return this;
+       printDebugNames = false;
+       printValues = false;
+    }
+
+    /**
+     * Set things up for a light-weight, or low-cost, back-trace by
+     * limiting things to just the elf information.
+     */
+    public void setLite() {
+       setAbi();
+       setPrintDebugNames(true);
     }
 
     /**
      * Set things up for a rich, or detailed, back-trace by including
      * inline frames and parameter information.
      */
-    public PrintStackOptions setRich() {
-       printParams = true;
-       printLocals = true;
-       printLibraries = true;
-       printInlineFunctions = true;
-       printDebugNames = true;
-       return this;
+    public void setRich() {
+       setAbi();
+       setPrintParameters(true);
+       setPrintInlineFunctions(true);
+       setPrintDebugNames(true);
     }
 
     /**
-     * Specify the number of frames to include in the back-trace, 0 to
-     * include all frames.
+     * Print the parameter list (see also printValues).
      */
-    public void setNumberOfFrames(int numberOfFrames) {
-       this.numberOfFrames = numberOfFrames;
+    public boolean printParameters() {
+       return printParameters;
     }
-    public int numberOfFrames() {
-       return numberOfFrames;
+    public void setPrintParameters(boolean printParameters) {
+       this.printParameters = printParameters;
     }
 
-    public void setPrintParams(boolean printParams) {
-       this.printParams = printParams;
+    /**
+     * Print paramter and variable values (rather than just their
+     * names).
+     */
+    public boolean printValues() {
+       return printValues;
     }
-    public boolean printParams() {
-       return printParams;
+    public void setPrintValues(boolean printValues) {
+       this.printValues = printValues;
     }
 
-    public void setPrintLocals(boolean printLocals) {
-       this.printLocals = printLocals;
-    }
+    /**
+     * Print the function's local variables.
+     */
     public boolean printLocals() {
        return printLocals;
     }
-
-    public void setPrintFullPaths(boolean printFullPaths) {
-       this.printFullPaths = printFullPaths;
-    }
-    public boolean printFullPaths() {
-       return printFullPaths;
+    public void setPrintLocals(boolean printLocals) {
+       this.printLocals = printLocals;
     }
 
-    public void setPrintLibraries(boolean printLibraries) {
-       this.printLibraries = printLibraries;
-    }
-    public boolean printLibraries() {
-       return printLibraries;
+    /**
+     * Print inline function instances.
+     */
+    public boolean printInlineFunctions() {
+       return printInlineFunctions;
     }
-
     public void setPrintInlineFunctions(boolean printInlineFunctions) {
        this.printInlineFunctions = printInlineFunctions;
     }
-    public boolean printInlineFunctions() {
-       return printInlineFunctions;
-    }
 
-    public void setPrintDebugNames(boolean printDebugNames) {
-       this.printDebugNames = printDebugNames;
-    }
+    /**
+     * Print function and variable names using debug, rather than ABI,
+     * information.
+     */
     public boolean printDebugNames() {
        return printDebugNames;
     }
+    public void setPrintDebugNames(boolean printDebugNames) {
+       this.printDebugNames = printDebugNames;
+    }
 
-    public boolean elfOnly() {
-       return ! (printLocals || printInlineFunctions || printParams
+    public boolean abiOnly() {
+       return ! (printLocals
+                 || printInlineFunctions
+                 || printParameters
+                 || printValues
                  || printDebugNames);
     }
-    
 }
index 439218fec5501397baf4ee6d12e9bcb94b8ff8a6..ec0c65d691722a72bb2f29d6dfd217f4a59e71a7 100644 (file)
@@ -45,7 +45,6 @@ import java.util.Iterator;
 import java.util.LinkedList;
 
 import javax.naming.NameNotFoundException;
-
 import lib.dwfl.DwTag;
 import lib.dwfl.DwarfDie;
 import lib.dwfl.Dwfl;
@@ -85,9 +84,9 @@ public class TestFrameDebugInfo extends TestLib {
     
     StringWriter stringWriter = new StringWriter();
     DebugInfoFrame frame = DebugInfoStackFactory.createDebugInfoStackTrace(task);
-    PrintStackOptions options = new PrintStackOptions();
+    PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
     options.setNumberOfFrames(20);
-    options.setPrintParams(true);
+    options.setPrintParameters(true);
     options.setPrintLocals(true);
     options.setPrintFullPaths(true);
     DebugInfoStackFactory.printStackTrace(new PrintWriter(stringWriter),frame, options);
@@ -307,9 +306,9 @@ public class TestFrameDebugInfo extends TestLib {
       Task task = (new DaemonBlockedAtSignal("funit-stack-inlined" + ext)).getMainTask();
     StringWriter stringWriter = new StringWriter();
     
-    PrintStackOptions options = new PrintStackOptions();
+    PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
     options.setNumberOfFrames(0);
-    options.setPrintParams(true);
+    options.setPrintParameters(true);
     options.setPrintLocals(true);
     options.setPrintFullPaths(true);
     DebugInfoStackFactory.printVirtualTaskStackTrace(new PrintWriter(stringWriter), task, options);
@@ -326,9 +325,9 @@ public class TestFrameDebugInfo extends TestLib {
     
       Task task = (new DaemonBlockedAtSignal("funit-stack-inlined")).getMainTask();
     
-    PrintStackOptions options = new PrintStackOptions();
+    PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
     options.setNumberOfFrames(0); 
-    options.setPrintParams(true);
+    options.setPrintParameters(true);
     options.setPrintLocals(true);
     options.setPrintFullPaths(true);
     
index ae3ed76db20ebe464a20488d45852d21afe97989..7fb60392d319c7b43be3da2b4c77483f23a7ac23 100644 (file)
@@ -52,9 +52,9 @@ public class VirtualDebugInfoFrame extends DebugInfoFrame {
        super(inner, decorated);
     }
 
-    public void toPrint(PrintWriter writer, boolean printParameters,
-                boolean fullpath) {
-       super.toPrint(writer, printParameters, fullpath);
+    public void toPrint(PrintWriter writer,
+                       PrintDebugInfoStackOptions options) {
+       super.toPrint(writer, options);
        writer.print(" [inline]");
     }
 
index 19fd300ac97b299ca9c86d9e6565128ced98dc7d..a6f9abb0a90cfc40515ddd62f43497e02b63b351 100644 (file)
@@ -1,3 +1,8 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * Ftrace.java: Use PrintDebugInfoStackOptions.
+       * Reporter.java: Ditto.
+
 2008-06-05  Petr Machata  <pmachata@redhat.com>
 
        * Ftrace.java: Fix race in attaching various task observers.
index 68ecadb01d3502a16866c8b1e6bef2a8d1be55a1..17d81ba9faa1c8885b52c287a4ce0dbb588c6d8c 100644 (file)
@@ -47,7 +47,7 @@ import java.util.Set;
 
 import inua.util.PrintWriter;
 
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.dwfl.ObjectFile;
 import frysk.event.Event;
 import frysk.isa.signals.Signal;
@@ -75,9 +75,9 @@ public class Ftrace {
     static private final Log finest = LogFactory.finest(Ftrace.class);
     static private final Log warning = LogFactory.warning(Ftrace.class);
 
-    private final PrintStackOptions stackPrintOptions;
+    private final PrintDebugInfoStackOptions stackPrintOptions;
 
-    public Ftrace(PrintStackOptions stackPrintOptions) {
+    public Ftrace(PrintDebugInfoStackOptions stackPrintOptions) {
        this.stackPrintOptions = stackPrintOptions;
     }
 
index 3ed019b168f303c6721cfdc817d8bb63d0786754..cbc95bd39c297c244125d578ad003ca1ed16c761 100644 (file)
@@ -43,7 +43,7 @@ import java.util.HashMap;
 
 import inua.util.PrintWriter;
 
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.proc.Task;
 import frysk.util.ArchFormatter;
 import frysk.util.StackPrintUtil;
@@ -54,10 +54,12 @@ class Reporter
     private Object lastItem = null;
     private Task lastTask = null;
     private HashMap levelMap = new HashMap();
-    private final PrintStackOptions stackPrintOptions;
+    private final PrintDebugInfoStackOptions stackPrintOptions;
     private final boolean showPC;
 
-    public Reporter(PrintWriter writer, PrintStackOptions stackPrintOptions, boolean show) {
+    public Reporter(PrintWriter writer,
+                   PrintDebugInfoStackOptions stackPrintOptions,
+                   boolean show) {
        this.writer = writer;
        this.stackPrintOptions = stackPrintOptions;
        this.showPC = show;
index 8fd8a9feda0a26a0f4ed54cd5d75ddda4e562094..9e80d37cef961e8c02220d745ee708a98f34c371 100644 (file)
@@ -1,6 +1,6 @@
 // This file is part of the program FRYSK.
 //
-// Copyright 2005, 2006, 2007 Red Hat Inc.
+// Copyright 2005, 2006, 2007, 2008 Red Hat Inc.
 //
 // FRYSK is free software; you can redistribute it and/or modify it
 // under the terms of the GNU General Public License as published by
@@ -41,10 +41,9 @@ package frysk.hpd;
 
 import java.util.Iterator;
 import java.util.List;
-
 import frysk.debuginfo.DebugInfoFrame;
 import frysk.debuginfo.DebugInfoStackFactory;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.proc.Task;
 
 abstract class StackCommands extends ParameterizedCommand {
@@ -71,9 +70,10 @@ abstract class StackCommands extends ParameterizedCommand {
 
     static private void printStack(CLI cli, DebugInfoFrame frame,
                                   int stopLevel, Options options) {
-       PrintStackOptions printStackOptions = new PrintStackOptions();
+       PrintDebugInfoStackOptions printStackOptions
+           = new PrintDebugInfoStackOptions();
        printStackOptions.setNumberOfFrames(stopLevel);
-       printStackOptions.setPrintParams(true);
+       printStackOptions.setPrintParameters(true);
        printStackOptions.setPrintLocals(options.printLocals);
        printStackOptions.setPrintFullPaths(true);
        
index a66b5dde044eb0122662be74dd8106d5fb4b9e3d..f42839c20b018fe73091db4f68d885849666bf68 100644 (file)
@@ -1,3 +1,7 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * TestLinuxCore.java: Use PrintDebugInfoStackOptions.
+
 2008-06-04  Andrew Cagney  <cagney@redhat.com>
 
        * LinuxCoreInfo.java (constructAuxv): Eliminate use of
index d6fd1e3f15ca596d9c243ce5e05ed763dd771b9a..baeac701ee558940b89f49d04ac89424dd66a1ec 100644 (file)
@@ -50,7 +50,7 @@ import java.util.Iterator;
 import lib.dwfl.DwflModule;
 import lib.dwfl.SymbolBuilder;
 import frysk.config.Prefix;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.dwfl.DwflCache;
 import frysk.event.Event;
 import frysk.event.RequestStopEvent;
@@ -111,7 +111,7 @@ public class TestLinuxCore extends TestLib {
        // relative -> absolute converstion is occuring.
        StacktraceAction coreStacktrace;
        StringWriter coreStackOutput = new StringWriter();
-       PrintStackOptions options = new PrintStackOptions();
+       PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
        options.setNumberOfFrames(20);
 
        // Create a stackktrace of a the corefile process
@@ -211,7 +211,7 @@ public class TestLinuxCore extends TestLib {
     StacktraceAction coreStacktrace;
     StringWriter liveStackOutput = new StringWriter();
     StringWriter coreStackOutput = new StringWriter();
-    PrintStackOptions options = new PrintStackOptions();
+    PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
     options.setNumberOfFrames(20);
     
     // Create a Stacktrace of the blocked live process
@@ -263,7 +263,6 @@ public class TestLinuxCore extends TestLib {
     assertEquals("Compare stack traces",
                 liveStackOutput.getBuffer().toString(),
                 coreStackOutput.getBuffer().toString());
-
   }
 
   private static class PrintEvent implements Event
index 670e7f53f5d56c4f5097fea83a8f14eb8231914a..ff21a6f56902da5e63a0e8984bf05a00ceae2ecf 100644 (file)
@@ -1,3 +1,8 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * Function.java (printParameters): Add boolean printValues
+       parameter.
+
 2008-06-06  Andrew Cagney  <cagney@redhat.com>
 
        * TestScopeFactory.java: Let DwflDie adjust for bias.
index 71d3f8a869a5884cf5535f79ea24e1d92d9c43db..cc4c4268aecfb90b1b5e122fc495626a60230fda 100644 (file)
@@ -227,19 +227,17 @@ public class Function extends NamedScope {
 
     }
     
-    public void printParameters (PrintWriter writer, DebugInfoFrame frame)
-    {
-      
-      Iterator iterator = this.parameters.iterator();
-      while(iterator.hasNext()) {
-        Variable parameter = (Variable) iterator.next();
-       parameter.toPrint(writer, frame);
-       writer.flush();
-        if(parameters.indexOf(parameter) < (this.parameters.size()-1)){
-            writer.print(",");
-        }
-      }
-      
+    public void printParameters(PrintWriter writer, DebugInfoFrame frame,
+                               boolean printValues) {
+       Iterator iterator = this.parameters.iterator();
+       while(iterator.hasNext()) {
+           Variable parameter = (Variable) iterator.next();
+           parameter.toPrint(writer, frame);
+           writer.flush();
+           if(parameters.indexOf(parameter) < (this.parameters.size()-1)){
+               writer.print(",");
+           }
+       }
     }
     
 }
index 4f95b4b55a2eff42eabb4931dc4928f99c452e0f..28e41a31e3475cffb9176d25596e96e51ebb2a53 100644 (file)
@@ -1,3 +1,11 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * Frame.java (toPrint(PrintWriter,PrintStackOptions)): Replace
+       toPrint(PrintWriter,boolean,boolean).
+       (toPrint(PrintWriter)): Delete.
+       * PrintStackOptions.java: New.
+       * StackFactory.java: Use.
+
 2008-06-03  Andrew Cagney  <cagney@redhat.com>
 
        * TestFrame.java: Use DwflModule.getModules() and not
index 285aee72f3917a1ed7890d91ee2935c25e981e11..11d3cf71692437f5aebf7db80205004e87583340 100644 (file)
@@ -46,7 +46,6 @@ import java.io.StringWriter;
 import lib.dwfl.Dwfl;
 import lib.dwfl.DwflModule;
 import frysk.dwfl.DwflCache;
-import frysk.dwfl.DwflFactory;
 import frysk.isa.registers.Register;
 import frysk.proc.Task;
 import frysk.rsl.Log;
@@ -150,15 +149,7 @@ public abstract class Frame {
      * Write a simple string representation of this stack frame.
      * @param printWriter
      */
-    public void toPrint (PrintWriter writer) {
-       toPrint(writer, true, true);
-    }
-
-    /**
-     * Write a simple string representation of this stack frame.
-     * @param printWriter
-     */
-    public void toPrint (PrintWriter writer, boolean printSource, boolean fullpath) {
+    public void toPrint(PrintWriter writer, PrintStackOptions options) {
        writer.write(ArchFormatter.toHexString(getTask(), getAddress()));
        // the symbol, if known append (), ..
        Symbol symbol = getSymbol();
@@ -166,22 +157,22 @@ public abstract class Frame {
        writer.write(symbol.getDemangledName());
        if (symbol != SymbolFactory.UNKNOWN)
            writer.write(" ()");
-       
-       if(printSource){
+       if (options.printLibraryNames()){
            // the library if known ...
-           File library = new File(getLibraryName());
+           String library = getLibraryName();
+       System.err.println("library: " + library);
            if (library != null) {
                writer.print(" from ");
-       
-               if(DwflFactory.isVDSO(this.getTask().getProc(), this.getTask().getProc().getMap(getAdjustedAddress()))
-                       || library.getName().contains("[stack]")){
-                   writer.print(library.getName());
-               }else{
-               
-                   if(fullpath){
-                       writer.print(library.getPath());
-                   }else{
-                       writer.print(".../"+library.getName());
+               if (library.startsWith("[")) {
+                   // Things like [vdso], [stack], ...
+                   writer.print(library);
+               } else {
+                   // Should there be separate libraryFullPath?
+                   if (options.printFullPaths()) {
+                       writer.print(library);
+                   } else {
+                       // Discard the path
+                       writer.print(new File(library).getName());
                    }
                    
                }
@@ -195,7 +186,7 @@ public abstract class Frame {
        if (dwflModule != null) {
            return dwflModule.getName();
        } else {
-           return "Unknown";
+           return null;
        }
     }
 
@@ -209,7 +200,7 @@ public abstract class Frame {
          PrintWriter pw = new PrintWriter(sw);
          pw.print(this.getClass().getName());
          pw.print('[');
-         toPrint(pw, false, false);
+         toPrint(pw, PrintStackOptions.DEFAULT);
          pw.print(']');
          pw.flush();
          return sw.toString();
diff --git a/frysk-core/frysk/stack/PrintStackOptions.java b/frysk-core/frysk/stack/PrintStackOptions.java
new file mode 100644 (file)
index 0000000..ea400f2
--- /dev/null
@@ -0,0 +1,103 @@
+// This file is part of the program FRYSK.
+//
+// Copyright 2007, 2008, Red Hat Inc.
+//
+// FRYSK is free software; you can redistribute it and/or modify it
+// under the terms of the GNU General Public License as published by
+// the Free Software Foundation; version 2 of the License.
+//
+// FRYSK is distributed in the hope that it will be useful, but
+// WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with FRYSK; if not, write to the Free Software Foundation,
+// Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+//
+// In addition, as a special exception, Red Hat, Inc. gives You the
+// additional right to link the code of FRYSK with code not covered
+// under the GNU General Public License ("Non-GPL Code") and to
+// distribute linked combinations including the two, subject to the
+// limitations in this paragraph. Non-GPL Code permitted under this
+// exception must only link to the code of FRYSK through those well
+// defined interfaces identified in the file named EXCEPTION found in
+// the source code files (the "Approved Interfaces"). The files of
+// Non-GPL Code may instantiate templates or use macros or inline
+// functions from the Approved Interfaces without causing the
+// resulting work to be covered by the GNU General Public
+// License. Only Red Hat, Inc. may make changes or additions to the
+// list of Approved Interfaces. You must obey the GNU General Public
+// License in all respects for all of the FRYSK code and other code
+// used in conjunction with FRYSK except the Non-GPL Code covered by
+// this exception. If you modify this file, you may extend this
+// exception to your version of the file, but you are not obligated to
+// do so. If you do not wish to provide this exception without
+// modification, you must delete this exception statement from your
+// version and license this file solely under the GPL without
+// exception.
+
+package frysk.stack;
+
+public class PrintStackOptions {
+
+    static final PrintStackOptions DEFAULT = new PrintStackOptions();
+
+    private int numberOfFrames = 10;
+
+    private boolean printFullPaths;
+    private boolean printLibraryNames;
+    
+    public PrintStackOptions() {
+       clear();
+    }
+
+    /**
+     * Clear all stack options, a very raw ABI stack trace will be
+     * produced.
+     */
+    public void clear() {
+       printFullPaths = false;
+       printLibraryNames = false;
+    }
+    
+    /**
+     * Generate an ABI backtrace using ELF symbols and shared library
+     * names.
+     */
+    public void setAbi() {
+       clear();
+       printFullPaths = false;
+       printLibraryNames = true;
+    }
+
+    /**
+     * Specify the number of frames to include in the back-trace, 0 to
+     * include all frames.
+     */
+    public void setNumberOfFrames(int numberOfFrames) {
+       this.numberOfFrames = numberOfFrames;
+    }
+    public int numberOfFrames() {
+       return numberOfFrames;
+    }
+
+    public void setPrintFullPaths(boolean printFullPaths) {
+       this.printFullPaths = printFullPaths;
+    }
+    public boolean printFullPaths() {
+       return printFullPaths;
+    }
+
+    public void setPrintLibraryNames(boolean printLibraryNames) {
+       this.printLibraryNames = printLibraryNames;
+    }
+    public boolean printLibraryNames() {
+       return printLibraryNames;
+    }
+
+    public boolean abiOnly() {
+       return true;
+    }
+    
+}
index 358adb280fe99d18bb4aee84cc2d0d51ba316eb2..c1e05e53fa5b0c0802dd2937471d9ba389f349cf 100644 (file)
@@ -44,7 +44,6 @@ import java.io.PrintWriter;
 import java.util.WeakHashMap;
 
 import lib.unwind.Cursor;
-import frysk.debuginfo.PrintStackOptions;
 import frysk.proc.Task;
 
 public class StackFactory
@@ -87,23 +86,25 @@ public class StackFactory
     }
 
     public static final void printTaskStackTrace(PrintWriter writer,
-                                                Task task, PrintStackOptions options) {
+                                                Task task,
+                                                PrintStackOptions options) {
        if (task != null) {
            writer.print("Task #");
            writer.print(task.getTid());
            writer.println();
            Frame frame = StackFactory.createFrame(task);
            for (int i = 0; frame != null; frame = frame.getOuter(),i++) {
-               
-               if (options.numberOfFrames() > 0 && i >= options.numberOfFrames()) {
+               if (options.numberOfFrames() > 0
+                   && i >= options.numberOfFrames()) {
                    writer.println("...");
                    break;
+               } else if (options.numberOfFrames() < 0
+                          && i >= -options.numberOfFrames()) {
+                   break;
                }
-               
                frame.printLevel(writer);
                writer.print(" ");
-               frame.toPrint(writer, options.printLibraries(),
-                             options.printFullPaths());
+               frame.toPrint(writer, options);
                writer.println();
            }
        }
@@ -114,7 +115,7 @@ public class StackFactory
        for (; frame != null; frame = frame.getOuter()) {
            frame.printLevel(writer);
            writer.print(" ");
-           frame.toPrint(writer);
+           frame.toPrint(writer, PrintStackOptions.DEFAULT);
            writer.println();
        }
     }
index bf953198d2414114bfb903d69501ab7b39503e6b..2e2f1c650c7a8e04fb361536111131a8df44ecfb 100644 (file)
@@ -1,3 +1,11 @@
+2008-06-10  Andrew Cagney  <cagney@redhat.com>
+
+       * TestStackTraceAction.java: Use PrintDebugInfoStackOptions.
+       * StackPrintUtil.java: Ditto.
+       * StacktraceAction.java: Ditto.
+       * FCatch.java: Ditto.
+       * StressTestStackTraceAction.java: Ditto.
+
 2008-05-20  Andrew Cagney  <cagney@redhat.com>
 
        * CommandlineParser.java (isCoreFile(String))
index 476ffe826d1c90f027cbfb13791f122b511b30d0..3157ed9af4ccea27fd9b079ac8f1d22722c2bacf 100644 (file)
@@ -43,7 +43,7 @@ import java.io.PrintWriter;
 import java.io.StringWriter;
 import java.util.HashMap;
 
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.isa.signals.Signal;
 import frysk.proc.Action;
 import frysk.proc.Task;
@@ -54,7 +54,8 @@ import gnu.classpath.tools.getopt.OptionGroup;
 public class FCatch {
     private static final Log fine = Log.fine(FCatch.class);
 
-    private final PrintStackOptions stackPrintOptions = new PrintStackOptions();
+    private final PrintDebugInfoStackOptions stackPrintOptions
+       = new PrintDebugInfoStackOptions();
 
     private PrintWriter printWriter = new PrintWriter(System.out);
     HashMap signaledTasks = new HashMap();
index a4b85ac68785f5e6ac46ab94b7cbfc8c4e20b9c5..6f1f1003122f3b774559a9a771a491bd569f1ca8 100644 (file)
@@ -47,7 +47,7 @@ import java.util.StringTokenizer;
 import gnu.classpath.tools.getopt.Option;
 import gnu.classpath.tools.getopt.OptionException;
 import gnu.classpath.tools.getopt.OptionGroup;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 
 /**
  * Framework for printing stack backtraces; both providing a standard
@@ -58,7 +58,10 @@ public class StackPrintUtil {
      * Create, in a separate group, the standard set of stack-print
      * options provided by utilities.
      */
-    public static OptionGroup options(final PrintStackOptions options) {
+    public static OptionGroup options(final PrintDebugInfoStackOptions options) {
+       // Set the default, which matches the documentation; and is
+       // consistent across all utilities.
+       options.setAbi();
        OptionGroup group = new OptionGroup("Stack print options");
        group.add(new Option("number-of-frames",
                             ("number of frames to print.  Specify '0' or"
@@ -90,11 +93,12 @@ public class StackPrintUtil {
        group.add(new Option
                  ("print", "select the back-trace information to display\n"
                   + "OPTION is:\n"
-                  + "debug-names: use debug-info names (e.g., DWARF)\n"
+                  + "debug-names: print debug-info names (e.g., DWARF)\n"
                   + "full-path: include the full (untruncated) path to files\n"
                   + "inline: include inlined frames\n"
-                  + "locals: include each functions local variables\n"
-                  + "params: include function parameters\n"
+                  + "locals: include each function's local variables\n"
+                  //+ "params: include function parameters\n"
+                  + "values: include values of parameters and variables\n"
                   + "OPTIONs can be negated by prefixing a '-'",
                   "OPTION,...") {
                public void parsed(String arg) throws OptionException {
@@ -117,7 +121,9 @@ public class StackPrintUtil {
                        } else if (name.equals("locals")) {
                            options.setPrintLocals(val);
                        } else if (name.equals("params")) {
-                           options.setPrintParams(val);
+                           options.setPrintParameters(val);
+                       } else if (name.equals("values")) {
+                           options.setPrintValues(val);
                        } else {
                            throw new OptionException
                                ("unknown -print OPTION: " + name);
@@ -132,9 +138,9 @@ public class StackPrintUtil {
      * Given a task, a writer, and the selected stack-print-options,
      * produce a stack back-trace.
      */
-    public static void print(Task task, PrintStackOptions options,
+    public static void print(Task task, PrintDebugInfoStackOptions options,
                             PrintWriter printWriter) {
-          if (options.elfOnly()) {
+          if (options.abiOnly()) {
               StackFactory.printTaskStackTrace(printWriter, task, options);
           } else if (options.printInlineFunctions()) {
              DebugInfoStackFactory.printVirtualTaskStackTrace(printWriter,
index e3b9a70ed8ef99c6d62c0880281a3af81dbefc22..9b83662f35b9f77082573dcaa79153d35f4efb01 100644 (file)
@@ -45,7 +45,7 @@ import java.util.Iterator;
 import java.util.TreeMap;
 import frysk.rsl.Log;
 import frysk.debuginfo.DebugInfoStackFactory;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.event.Event;
 import frysk.event.RequestStopEvent;
 import frysk.event.SignalEvent;
@@ -77,7 +77,7 @@ public abstract class StacktraceAction implements ProcBlockObserver {
 
   private Event event;
 
-  PrintStackOptions options;
+  PrintDebugInfoStackOptions options;
   
   /**
    * Runs a stacktrace on the given process.
@@ -97,14 +97,14 @@ public abstract class StacktraceAction implements ProcBlockObserver {
    *            file path is printed other wise only the name of the file is printed.
    * @throws ProcException
    */
-  public StacktraceAction (PrintWriter printWriter, Proc theProc, Event theEvent, PrintStackOptions options)
-  {
-     event = theEvent;
-     
-     this.options = options;
-     this.printWriter = printWriter;
-     Manager.eventLoop.add(new InterruptEvent(theProc));
-  }  
+    public StacktraceAction (PrintWriter printWriter, Proc theProc,
+                            Event theEvent,
+                            PrintDebugInfoStackOptions options) {
+       event = theEvent;
+       this.options = options;
+       this.printWriter = printWriter;
+       Manager.eventLoop.add(new InterruptEvent(theProc));
+    }
 
   public final void existingTask (Task task)
   {
@@ -126,27 +126,27 @@ public abstract class StacktraceAction implements ProcBlockObserver {
               "because", w);
   }
 
-  private final void printTasks ()
-  {
-    fine.log(this, "printTasks");
-    Iterator iter = sortedTasks.values().iterator();
-    while (iter.hasNext())
-      {
-       Task task =  (Task) iter.next();
-       
-       if(options.elfOnly()){
-           StackFactory.printTaskStackTrace(printWriter,task,options);
-       }else{
-           if(options.printInlineFunctions()){
-               DebugInfoStackFactory.printVirtualTaskStackTrace(printWriter,task,options);
-           }else{
-               DebugInfoStackFactory.printTaskStackTrace(printWriter,task,options);
-           }
+    private final void printTasks() {
+       fine.log(this, "printTasks");
+       Iterator iter = sortedTasks.values().iterator();
+       while (iter.hasNext()) {
+           Task task =  (Task) iter.next();
+           
+           if (options.abiOnly()) {
+               StackFactory.printTaskStackTrace(printWriter,task,options);
+           } else {
+               if (options.printInlineFunctions()) {
+                   DebugInfoStackFactory
+                       .printVirtualTaskStackTrace(printWriter,task,options);
+               } else {
+                   DebugInfoStackFactory
+                       .printTaskStackTrace(printWriter, task, options);
+               }
        }
-       printWriter.println();
-      }
-    fine.log(this, "exiting printTasks");
-  }
+           printWriter.println();
+       }
+       fine.log(this, "exiting printTasks");
+    }
 
   public void flush(){
       this.printWriter.flush();
index c4542395821233c4bde6291d137560bf851ad9cf..75ccf5fb7aacac6cb560eb3b6823883b8856567b 100644 (file)
@@ -43,7 +43,7 @@ package frysk.util;
 import java.io.PrintWriter;
 import java.io.StringWriter;
 import frysk.rsl.Log;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.event.Event;
 import frysk.event.RequestStopEvent;
 import frysk.proc.Manager;
@@ -80,9 +80,9 @@ public class StressTestStackTraceAction extends TestLib {
     FunitThreadsOffspring ackProc = new FunitThreadsOffspring(threads);
     final Proc proc = ackProc.assertRunToFindProc();
 
-    PrintStackOptions options = new PrintStackOptions();
+    PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
     options.setNumberOfFrames(20);
-    options.setPrintParams(true);
+    options.setPrintParameters(true);
     
     StacktraceAction stacker = new StacktraceAction(new PrintWriter(stringWriter),proc, new Event()
     {
index 0db2626d28143ca940c7b2ab9795d82c8f13c74e..5951727bc25ce3e27b20db78fd60e04b40b01f4b 100644 (file)
@@ -43,7 +43,7 @@ package frysk.util;
 import java.io.PrintWriter;
 import java.io.StringWriter;
 import frysk.rsl.Log;
-import frysk.debuginfo.PrintStackOptions;
+import frysk.debuginfo.PrintDebugInfoStackOptions;
 import frysk.event.RequestStopEvent;
 import frysk.proc.Manager;
 import frysk.proc.Proc;
@@ -78,10 +78,10 @@ public class TestStackTraceAction extends TestLib {
 
     static void multiThreaded(SlaveOffspring ackProc,
                              int numSecondaryThreads) {
-       PrintStackOptions options = new PrintStackOptions();
+       PrintDebugInfoStackOptions options = new PrintDebugInfoStackOptions();
        options.setNumberOfFrames(20);
        options.setPrintFullPaths(true);
-       options.setPrintLibraries(true);
+       options.setPrintLibraryNames(true);
 
        StringWriter stringWriter = new StringWriter();
       
This page took 0.0757 seconds and 5 git commands to generate.