brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.6 KiB · 65ed1be Raw
51 lines · plain
1llvm-diff - LLVM structural 'diff'2==================================3 4.. program:: llvm-diff5 6SYNOPSIS7--------8 9**llvm-diff** [*options*] *module 1* *module 2* [*global name ...*]10 11DESCRIPTION12-----------13 14**llvm-diff** compares the structure of two LLVM modules, primarily15focusing on differences in function definitions.  Insignificant16differences, such as changes in the ordering of globals or in the17names of local values, are ignored.18 19An input module will be interpreted as an assembly file if its name20ends in '.ll';  otherwise it will be read in as a bitcode file.21 22If a list of global names is given, just the values with those names23are compared; otherwise, all global values are compared, and24diagnostics are produced for globals which only appear in one module25or the other.26 27**llvm-diff** compares two functions by comparing their basic blocks,28beginning with the entry blocks.  If the terminators seem to match,29then the corresponding successors are compared; otherwise they are30ignored.  This algorithm is very sensitive to changes in control flow,31which tend to stop any downstream changes from being detected.32 33**llvm-diff** is intended as a debugging tool for writers of LLVM34passes and frontends.  It does not have a stable output format.35 36EXIT STATUS37-----------38 39If **llvm-diff** finds no differences between the modules, it will exit40with 0 and produce no output.  Otherwise it will exit with a non-zero41value.42 43BUGS44----45 46Many important differences, like changes in linkage or function47attributes, are not diagnosed.48 49Changes in memory behavior (for example, coalescing loads) can cause50massive detected differences in blocks.51