]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tools/tinyos/safe/tos-ramsize
minor change
[tinyos-2.x.git] / tools / tinyos / safe / tos-ramsize
index 06344845c4259bb64148d944b1d627509bfed33c..023e88eb69a0aad8f71a5fb86ee5057522ac9de7 100755 (executable)
@@ -1,6 +1,6 @@
 #!/usr/bin/perl -w
 
-# Copyright (c) 2003 University of Utah and the Flux Group.
+# Copyright (c) 2003-2009 University of Utah and the Flux Group.
 # All rights reserved.
 # 
 # Permission to use, copy, modify, distribute, and sell this software
 # Author: John Regehr (regehr@cs.utah.edu)
 # Revised by: Xuejun Yang on 01/10/2009 
 
+# For more information:
+#   http://docs.tinyos.net/index.php/Stack_Analysis
+
 use strict;
 use warnings;
 use Getopt::Long;
 
 # TODO: 
 #
-# flesh out the man page
+# support TOSThreads
+#
+# support msp430
+#
+# optionally don't do recursion checking
+#
+# print path to WC stack depth, perhaps graphically
+#
+# make it possible to specify chips individually
 #
-# make a page on the TinyOS wiki
+# make it possible to explicitly specify which interrupts are atomic
+# or not
 #
 # tighten results by keeping track of depths inside and out of
 # atomic sections
 #
+# print stack used at thread blocking points
+#
 # support overriding the default heuristic for detecting atomic
 # interrupts
 #
 # get rid of hard-coded non-terminating functions, just derive this
 # when no "ret" is executed
 #
-# test for tightness / soundness using randprog and Avrora
+# test for tightness / soundness using randprog + Avrora
 #
 # read config info from a file
 #   chip parameters
 #   libc information
 #   recursion and interrupt info
-#
-# support TOSThreads
-#
-# support msp430
-#
-# enumerate soundness requirements
-#   stores to SP are direct and use "out"
-#   no reentrant interrupts
-#   outs to SREG are for ending atomic blocks, seis are enabling interrupts for real
-#   return instructions go back to their callers' successors
-#   special-cases are correct
 
 ##########################################################################
 
@@ -104,6 +107,8 @@ my %ICALL_TARGETS = (
 # also look below for __prologue_saves__ and __epilogue_restores__
 my %SPECIAL = (
 
+    "TinyThreadSchedulerP__switchThreads" => 10,
+
     # these have icalls
     #"__eewr_block" => 35,
     #"__eerd_block" => 35,
@@ -1205,7 +1210,7 @@ sub make_fine_grain_cfg () {
        }
 
        if ($insn eq "ijmp") {
-           $diehere{$addr} = "cannot process raw ijmp at $hex_addr";
+           $diehere{$addr} = "cannot process raw indirect jump at $hex_addr";
        } elsif ($insn eq "ret" || $insn eq "reti") {
            # no control flow from here in our model
        } elsif (is_branch ($addr) || is_skip ($addr) || is_jmp ($addr)) {
@@ -1240,7 +1245,7 @@ sub make_fine_grain_cfg () {
                    $target = $label_to_addr{$target_func};
                    die "tos-ramsize FAIL" if (!defined($target));
                } else {
-                   $diehere{$addr} = "cannot process raw icall at $hex_addr";
+                   $diehere{$addr} = "cannot process raw indirect call at $hex_addr";
                }
            }
            if (defined($target)) {