[PATCH] D91383: [BasicAA] Make alias GEP positive offset handling symmetric

Mikael Holmén via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 17 23:46:24 PST 2020


uabelho added a comment.

Hello!

The following hits an assertion with this patch. If I run

  opt -S -o - aa.ll -aa-eval

I get

  opt: ../lib/Analysis/AliasAnalysisEvaluator.cpp:180: void llvm::AAEvaluator::runInternal(llvm::Function &, llvm::AAResults &): Assertion `AR == AA.alias(*I2, I2Size, *I1, I1Size) && "AA query not symmetric"' failed.

with aa.ll being

  define void @dll(i32* %outputdata_p) {
  entry:
    br label %while.body
  
  while.body:                                       ; preds = %cond.end, %entry
    %outputdata_p.addr.042 = phi i32* [ %outputdata_p, %entry ], [ %incdec.ptr6, %cond.end ]
    br label %cond.end
  
  cond.end:                                         ; preds = %while.body
    %incdec.ptr6 = getelementptr inbounds i32, i32* %outputdata_p.addr.042, i32 1
    br i1 undef, label %while.body, label %crit_edge44
  
  crit_edge44:                                      ; preds = %cond.end
    %split45 = phi i32* [ %incdec.ptr6, %cond.end ]
    unreachable
  }


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D91383/new/

https://reviews.llvm.org/D91383



More information about the llvm-commits mailing list