mirror of
				https://github.com/python/cpython.git
				synced 2025-11-04 07:31:38 +00:00 
			
		
		
		
	Issue #14900: Add aliases for sorting params for pstat to follow column names from pstat output.
Patch by Arne Babenhauserheide.
This commit is contained in:
		
							parent
							
								
									2ef4584e6d
								
							
						
					
					
						commit
						c3e5b10ae7
					
				
					 1 changed files with 4 additions and 0 deletions
				
			
		| 
						 | 
					@ -159,8 +159,11 @@ def dump_stats(self, filename):
 | 
				
			||||||
    # along with some printable description
 | 
					    # along with some printable description
 | 
				
			||||||
    sort_arg_dict_default = {
 | 
					    sort_arg_dict_default = {
 | 
				
			||||||
              "calls"     : (((1,-1),              ), "call count"),
 | 
					              "calls"     : (((1,-1),              ), "call count"),
 | 
				
			||||||
 | 
					              "ncalls"    : (((1,-1),              ), "call count"),
 | 
				
			||||||
 | 
					              "cumtime"   : (((3,-1),              ), "cumulative time"),
 | 
				
			||||||
              "cumulative": (((3,-1),              ), "cumulative time"),
 | 
					              "cumulative": (((3,-1),              ), "cumulative time"),
 | 
				
			||||||
              "file"      : (((4, 1),              ), "file name"),
 | 
					              "file"      : (((4, 1),              ), "file name"),
 | 
				
			||||||
 | 
					              "filename"  : (((4, 1),              ), "file name"),
 | 
				
			||||||
              "line"      : (((5, 1),              ), "line number"),
 | 
					              "line"      : (((5, 1),              ), "line number"),
 | 
				
			||||||
              "module"    : (((4, 1),              ), "file name"),
 | 
					              "module"    : (((4, 1),              ), "file name"),
 | 
				
			||||||
              "name"      : (((6, 1),              ), "function name"),
 | 
					              "name"      : (((6, 1),              ), "function name"),
 | 
				
			||||||
| 
						 | 
					@ -168,6 +171,7 @@ def dump_stats(self, filename):
 | 
				
			||||||
              "pcalls"    : (((0,-1),              ), "primitive call count"),
 | 
					              "pcalls"    : (((0,-1),              ), "primitive call count"),
 | 
				
			||||||
              "stdname"   : (((7, 1),              ), "standard name"),
 | 
					              "stdname"   : (((7, 1),              ), "standard name"),
 | 
				
			||||||
              "time"      : (((2,-1),              ), "internal time"),
 | 
					              "time"      : (((2,-1),              ), "internal time"),
 | 
				
			||||||
 | 
					              "tottime"   : (((2,-1),              ), "internal time"),
 | 
				
			||||||
              }
 | 
					              }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def get_sort_arg_defs(self):
 | 
					    def get_sort_arg_defs(self):
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue