pytorch
3969391c - [caffe2] move the SaveOp implementation from a header to a .cc file

Commit
3 years ago
[caffe2] move the SaveOp implementation from a header to a .cc file Summary: Move the `SaveOp` code from `load_save_op.h` to `load_save_op.cc`. Previously this implementation was all in the templatized `SaveOp` class, even though most of the logic didn't depend on the template parameters. Having this code be in the header file slows down the build, and forces more files to be rebuilt than necessary when changing the SaveOp code. Having this code be in a template class can also increase the generated code size be larger than needed, as we don't need separate copies instantiated for each context type. Test Plan: buck test //caffe2/caffe2/python/operator_test:load_save_test Reviewed By: mraway Differential Revision: D26641600 fbshipit-source-id: 84ebe8164ffac1e4a691be41147f0c5d8e890e09
Author
Parents
Loading