[PATCH] D25891: [llvm] Convert iterable SmallPtrSet's to SmallSetVector's in Codegen

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 24 08:50:46 PDT 2016


Iteration order isn't always related to output - do these specific
containers iteration orders cause nondeterminism, or is this an attempt to
fix things pre-emptively? (the latter might be overly aggressive - we may
not want to use deterministic ordered containers 'just in case', but only
when we know the iteration order is important)

On Fri, Oct 21, 2016 at 6:48 PM Mandeep Singh Grang via llvm-commits <
llvm-commits at lists.llvm.org> wrote:

> mgrang created this revision.
> mgrang added reviewers: t.p.northover, chandlerc, hfinkel.
> mgrang added a subscriber: llvm-commits.
> mgrang set the repository for this revision to rL LLVM.
> Herald added subscribers: qcolombet, MatzeB.
>
> Iteration of SmallPtrSet's are a cause of non-determinism in codegen
> because
> the iteration order is not fixed. This results in different codegen from
> run-to-run, release vs release+asserts and on linux vs windows.
>
>
>
> The fix is to use SmallSetVector where the iteration order is
> deterministic.
>
>
> Repository:
>   rL LLVM
>
> https://reviews.llvm.org/D25891
>
> Files:
>   include/llvm/CodeGen/LiveRangeEdit.h
>   lib/CodeGen/CodeGenPrepare.cpp
>   lib/CodeGen/InlineSpiller.cpp
>   lib/CodeGen/MachineBlockPlacement.cpp
>   lib/CodeGen/MachinePipeliner.cpp
>   lib/CodeGen/MachineVerifier.cpp
>   lib/CodeGen/OptimizePHIs.cpp
>   lib/CodeGen/PHIElimination.cpp
>   lib/CodeGen/PrologEpilogInserter.cpp
>   lib/CodeGen/RegAllocBase.h
>   lib/CodeGen/RegAllocGreedy.cpp
>   lib/CodeGen/RegAllocPBQP.cpp
>   lib/CodeGen/SelectionDAG/SelectionDAG.cpp
>   lib/CodeGen/SjLjEHPrepare.cpp
>   lib/CodeGen/SplitKit.cpp
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161024/a6d404ee/attachment.html>


More information about the llvm-commits mailing list