torch/cutorch — pull request #94 by soumith (2014-12-31 03:24:18+00:00)
Title: more copy optimizations, and additions to unit tests

More optimizations, by @wickedfoo

- Now if the dimensions can be folded for the copy, they are, which makes the indexing math cheaper.
- More robust tests, now compares results against float, and makes sure no copy kernel is triggered except the one for the test.