parameters: (cls, kernel, task)
docstring: Enumerates event filters per task.
          Uses smear-safe APIs throughout as these data structures
          see a signifcant amount of smear
docstring_summary: Enumerates event filters per task.
          Uses smear-safe APIs throughout as these data structures
          see a signifcant amount of smear
docstring_tokens: Enumerates event filters per task . Uses smear - safe APIs throughout as these data structures see a signifcant amount of smear
function: def _get_task_kevents(cls, kernel, task):
          """
          Enumerates event filters per task.
          Uses smear-safe APIs throughout as these data structures
          see a signifcant amount of smear
          """
          fdp = task.p_fd
  
          for kn in cls._walk_klist_array(kernel, fdp, "fd_knlist", "fd_knlistsize"):
              yield kn
  
          for kn in cls._walk_klist_array(kernel, fdp, "fd_knhash", "fd_knhashmask"):
              yield kn
  
          try:
              p_klist = task.p_klist
          except exceptions.InvalidAddressException:
              return
  
          for kn in mac.MacUtilities.walk_slist(p_klist, "kn_link"):
              yield kn
function_tokens: def _get_task_kevents ( cls , kernel , task ) : fdp = task . p_fd for kn in cls . _walk_klist_array ( kernel , fdp , "fd_knlist" , "fd_knlistsize" ) : yield kn for kn in cls . _walk_klist_array ( kernel , fdp , "fd_knhash" , "fd_knhashmask" ) : yield kn try : p_klist = task . p_klist except exceptions . InvalidAddressException : return for kn in mac . MacUtilities . walk_slist ( p_klist , "kn_link" ) : yield kn