[PATCH] D51596: Fixed bug in MachineInstr::hasPropertyInBundle

Mikael Nilsson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 3 23:21:01 PDT 2018


mikael added a comment.

I'm not sure it can be reproduced in an in-tree target.  But it is easy to give you an example when this happens:

You would need a target that uses bundle instructions and uses one of the flags 'Convergent', 'Trap' or 'Add'. If you call e.g MachineInstr.h:isConvergent on bundles the issue occurs.

Following the code path for isConvergent leads us to the following code snippet:

  // MCFlag == 32 because Convergent == 32
  return hasPropertyInBundle(1ULL << MCFlag, Type);

The resulting value of the shift does not fit in the 'Mask' argument.


Repository:
  rL LLVM

https://reviews.llvm.org/D51596





More information about the llvm-commits mailing list