[llvm-dev] Hash of a module
Artur Pilipenko via llvm-dev
llvm-dev at lists.llvm.org
Mon Dec 21 04:36:31 PST 2015
Are you going to run some of the existing passes? Why can’t you just use the returned change-made value from the passes?
> On 20 Dec 2015, at 15:43, Russell Wallace via llvm-dev <llvm-dev at lists.llvm.org> wrote:
> I want to run a bunch of optimizations, iteratively, that is keep running until things stop changing (to make sure all optimization opportunities are taken). As far as I know, there is no way to copy a module or compare modules by value, so it occurs to me that a practical solution might be to take the hash code of the module and see if that changes.
> A problem is that hash algorithms are designed to work on streams of bytes, not compound objects.
> First attempt at a solution: iterate through all instructions in all functions and hash the instruction kinds. I can think of some possible changes that would fail to be captured by that.
> Is there any already known solution?
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
More information about the llvm-dev