Reduce actor submission python overhead (#5949)

This commit is contained in:
Philipp Moritz
2019-10-23 00:11:32 -07:00
committed by GitHub
parent 875c84ed63
commit 09d05bb3fa
15 changed files with 57 additions and 69 deletions
+3 -3
View File
@@ -895,7 +895,7 @@ cdef class CoreWorker:
c_vector[CTaskArg] args_vector
c_vector[CObjectID] return_ids
with profiling.profile("submit_task"):
with self.profile_event("submit_task"):
prepare_resources(resources, &c_resources)
task_options = CTaskOptions(num_return_vals, c_resources)
ray_function = CRayFunction(
@@ -954,7 +954,7 @@ cdef class CoreWorker:
c_vector[CTaskArg] args_vector
c_vector[CObjectID] return_ids
with profiling.profile("submit_task"):
with self.profile_event("submit_task"):
prepare_resources(resources, &c_resources)
task_options = CTaskOptions(num_return_vals, c_resources)
ray_function = CRayFunction(
@@ -991,7 +991,7 @@ cdef class CoreWorker:
return resources_dict
def profile_event(self, event_type, dict extra_data):
def profile_event(self, event_type, object extra_data=None):
cdef:
c_string c_event_type = event_type.encode("ascii")