Print this page
11506 smatch resync

@@ -15,10 +15,11 @@
     sys.exit(1)
 
 def usage():
     print "%s" %(sys.argv[0])
     print "<function> - how a function is called"
+    print "info <type> - how a function is called, filtered by type"
     print "return_states <function> - what a function returns"
     print "call_tree <function> - show the call tree"
     print "where <struct_type> <member> - where a struct member is set"
     print "type_size <struct_type> <member> - how a struct member is allocated"
     print "data_info <struct_type> <member> - information about a given data type"

@@ -53,11 +54,10 @@
              101: "PARAM_CLEARED",
              103: "PARAM_LIMIT",
              104: "PARAM_FILTER",
             1001: "PARAM_VALUE",
             1002: "BUF_SIZE",
-            1003: "USER_DATA",
             1004: "CAPPED_DATA",
             1005: "RETURN_VALUE",
             1006: "DEREFERENCE",
             1007: "RANGE_CAP",
             1008: "LOCK_HELD",

@@ -77,11 +77,26 @@
             1025: "PARAM_SET",
             1026: "PARAM_USED",
             1027: "BYTE_UNITS",
             1028: "COMPARE_LIMIT",
             1029: "PARAM_COMPARE",
-            8017: "USER_DATA2",
+            1030: "EXPECTS_TYPE",
+            1031: "CONSTRAINT",
+            1032: "PASSES_TYPE",
+            1033: "CONSTRAINT_REQUIRED",
+            1034: "BIT_INFO",
+            1035: "NOSPEC",
+            1036: "NOSPEC_WB",
+            1037: "STMT_CNT",
+            1038: "TERMINATED",
+            1039: "SLEEP",
+            1040: "NO_SLEEP_CNT",
+            1041: "SMALLISH",
+            1042: "FRESH_MTAG",
+
+            8017: "USER_DATA",
+            9017: "USER_DATA_SET",
             8018: "NO_OVERFLOW",
             8019: "NO_OVERFLOW_SIMPLE",
             8020: "LOCKED",
             8021: "UNLOCKED",
             8023: "ATOMIC_INC",

@@ -195,10 +210,12 @@
         return 2**31 - 1
     elif txt == "s16max":
         return 2**15 - 1
     elif txt == "u64max":
         return 2**64 - 1
+    elif txt == "ptr_max":
+        return 2**64 - 1
     elif txt == "u32max":
         return 2**32 - 1
     elif txt == "u16max":
         return 2**16 - 1
     else:

@@ -587,23 +604,23 @@
     usage()
 
 if len(sys.argv) == 2:
     func = sys.argv[1]
     print_caller_info("", func)
+elif sys.argv[1] == "info":
+    my_type = ""
+    if len(sys.argv) == 4:
+        my_type = sys.argv[3]
+    func = sys.argv[2]
+    print_caller_info("", func, my_type)
 elif sys.argv[1] == "call_info":
     if len(sys.argv) != 4:
         usage()
     filename = sys.argv[2]
     func = sys.argv[3]
     caller_info_values(filename, func)
     print_caller_info(filename, func)
-elif sys.argv[1] == "user_data":
-    func = sys.argv[2]
-    print_caller_info(filename, func, "USER_DATA")
-elif sys.argv[1] == "param_value":
-    func = sys.argv[2]
-    print_caller_info(filename, func, "PARAM_VALUE")
 elif sys.argv[1] == "function_ptr" or sys.argv[1] == "fn_ptr":
     func = sys.argv[2]
     print_fn_ptrs(func)
 elif sys.argv[1] == "return_states":
     func = sys.argv[2]