pytorch
361eed6a - Use JIT op registration directly for lite interpreter. (#34070)

Commit
4 years ago
Use JIT op registration directly for lite interpreter. (#34070) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/34070 The first step to make all operators available for lite interpreter. The original code used manual registration for lite interpreter ops with a "_" prefix, for two reasons: 1. To minimize the build size. 2. To avoid duplicate registration in OSS (majorly feature testing and unit tests). Now since we have more and more models to support, the manual registration way is not practical. To make this process automatic while keeping the binary size under control, we plan to: 1. Make all necessary ops callable from lite interpreter. 2. The binary size would be increased because of step 1. Use ljk53 's custom build to selectively build the binary with ops used in specific models. The ops will be automatically collected using get_opnames. 3. The temporary "register_mobile_ops.cpp" can be removed. Test Plan: Imported from OSS Differential Revision: D20291596 Pulled By: iseeyuan fbshipit-source-id: 553b4699619cd71fea20658f3bc8c2d48852ef5c
Author
Martin Yuan
Parents
Loading