teemperor marked an inline comment as done. teemperor added inline comments.
================ Comment at: lldb/packages/Python/lldbsuite/test/commands/expression/ir-interpreter/TestIRInterpreter.py:54 + # Shifting longer than size of a type also doesn't work. + if rhs.value <= 0 or rhs.value >= 7: + return False ---------------- shafik wrote: > I may be missing something here but this looks like it should be `32` instead > of `7` or rather `sizeof(int)*8` > > When we say doesn't work do we mean undefined behavior? Good catch, originally that was supposed to be `> 7` so that we don't overflow any data type (assuming we ever extend the test to char). But I can change it to `>= 32` until we actually use any 8-bit type. And 'doesn't work' means that it will literally cause the test to fail and this test stops working. The interpreter will do something else than the JIT in these cases which is a bug. We probably should detect UB when interpreting these expressions and throw an error, but that's a whole new story. This is more about adding testing to the existing code. Repository: rLLDB LLDB CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67227/new/ https://reviews.llvm.org/D67227 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits