ginkgo
ginkgo copied to clipboard
Rename Executor::get_master()
Similar to the name changes of the default git branch from master to main^1^3, I propose to deprecate the current exec->get_master()
and introduce a renamed version. I don't know why this function was named this way, but it seems non-descriptive to me. Its main function is to get an executor running on the host CPU that is connected to the current executor running on a device. I don't think we use the name master
anywhere else in this context. Instead, we use the term host
.
I would propose the function:
get_host()
I think it's more descriptive, and it does not have the negative connotations of the current function. Also, it would be more consistent with copy_val_to_host
.
I intend this issue as a starting point for a discussion, so any thoughts and feedback is welcome!
:+1: I think host
is a good name. This would be interface breaking, so I guess we add the new function name, deprecate get_master()
and remove it in the next main release.
Almost all of our external library interfaces use this function, so we should be a bit careful in directly removing it without any warning.
@pratikvn This is also what I would propose, sorry if that was not clear enough. Adding a deprecation warning and introducing the new functions should be easy enough, although a lot of, if not all, user code would then complain.