[llvm-mca] Return the total number of cycles from method Pipeline::run().

If a user only cares about the overall latency, then the best/quickest way is to
change method Pipeline::run() so that it returns the total number of cycles to
the caller.

When the simulation pipeline is run, the number of cycles (or an error) is
returned from method Pipeline::run().
The advantage is that no hardware event listener is needed for computing that
latency. So, the whole process should be faster (and simpler - at least for that
particular use case).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@347767 91177308-0d34-0410-b5e6-96231b3b80d8
3 files changed