Report better errors when kernel or dispatch key are missing (#18302)
authorSebastian Messmer <messmer@fb.com>
Sat, 30 Mar 2019 07:03:46 +0000 (00:03 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Sat, 30 Mar 2019 07:07:28 +0000 (00:07 -0700)
commit24752eb7b827607ad0ff65e89d6c25b5bf48896a
tree4ccc45cc2e88a0bfe5db4dd8ca4ac590b6dd21b1
parent48e7f989171622db4aeaa44bbd23aa771f0e6972
Report better errors when kernel or dispatch key are missing (#18302)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18302

These might be use cases we want to support in the future, but they don't work yet.
Let's at least report an error instead of doing segfaults or worse.

Reviewed By: dzhulgakov

Differential Revision: D14572346

fbshipit-source-id: 49262ce131493bc887defe2978d8b22f202cd8cc
aten/src/ATen/core/dispatch/DispatchTable.h
aten/src/ATen/core/op_registration/op_registration.cpp
aten/src/ATen/core/op_registration/op_registration_test.cpp [new file with mode: 0644]