Assertion failed: (Offset.getBitWidth() == DL.getPointerBaseSizeInBits(getPointerAddressSpace()) && "The offset must have exactly as many bits as our pointer."), function accumulateConst antOffset, file /home/kg365/workspace/cheri/cheri-build/llvm/lib/IR/Operator.cpp, line 39.
Reduced test case:
// RUN: %cheri_purecap_cc1 -emit-obj -target-cpu mips4 -cheri-size 256 -Os -std=c++1z -fdeprecated-macro -fvisibility hidden -fvisibility-inlines-hidden -pthread -vectorize-loops -vectorize-slp -o - %s
class a {
public:
a(float);
float b, c, e, d;
};
a operator*(a &h, float) { return h.d; }
inline a operator-(a) {}
float f;
void g(a h) {
a i(h);
-i = i * f;
}
I get the following assertion failure:
Reduced test case:
Full reproducer: https://gist.github.com/kgudka/ec70fc06fc9ff567c0be6ea7e9d4acc5