commit | 926fb685deadfed2042163145ac52311914bf5c2 | [log] [tgz] |
---|---|---|
author | Mehdi Amini <[email protected]> | Tue Aug 13 02:12:42 2019 |
committer | A. Unique TensorFlower <[email protected]> | Tue Aug 13 02:13:12 2019 |
tree | 6af2d1fc60691dbd3e216fd38180795470c07654 | |
parent | 532c652d6c5490f9d5380fc7d40837e6414c2ef8 [diff] |
Express ownership transfer in PassManager API through std::unique_ptr (NFC) Since raw pointers are always passed around for IR construct without implying any ownership transfer, it can be error prone to have implicit ownership transferred the same way. For example this code can seem harmless: Pass *pass = .... pm.addPass(pass); pm.addPass(pass); pm.run(module); PiperOrigin-RevId: 263053082