[PATCH] D105020: [SLP]Improve graph reordering.
Alexey Bataev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 3 08:11:06 PDT 2021
ABataev added a comment.
In D105020#2922419 <https://reviews.llvm.org/D105020#2922419>, @phawkins wrote:
> I bisected a miscompilation in XLA to this change.
>
> Repro:
>
> - grab the three files in this gist: https://gist.github.com/hawkinsp/93de2fcb1a4d13ca01c826288bde4b9b
> - build clang at this revision
>
> At this commit
>
> clang driver.cc module_0000.primitive_computation_broadcast_in_dim.3.ir-no-opt.ll -o a.out
> ./a.out buffer-assignment.txt
>
> (no optimization)
>
> and
>
> clang -O3 -march=haswell driver.cc module_0000.primitive_computation_broadcast_in_dim.3.ir-no-opt.ll -o a.out
> ./a.out buffer-assignment.txt
>
> produce different outputs: the first 4 values differ.
>
> At the previous revision, both produce identical outputs.
>
> A quick inspection of the optimized IR seems to show it reading memory out of bounds. Disabling SLP vectorization also fixes the problem.
Thanks, I suspect what is the cause of the bug, hope to prepare a fix later today.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105020/new/
https://reviews.llvm.org/D105020
More information about the llvm-commits
mailing list