Skip to content

Commit

Permalink
[llvm-stress][opaque pointers] Remove use of deprecated constructor
Browse files Browse the repository at this point in the history
(See also D76269.)
  • Loading branch information
efriedma-quic committed Apr 4, 2020
1 parent 3ccd454 commit 501ec31
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion llvm/tools/llvm-stress/llvm-stress.cpp
Expand Up @@ -343,7 +343,9 @@ struct LoadModifier: public Modifier {
void Act() override {
// Try to use predefined pointers. If non-exist, use undef pointer value;
Value *Ptr = getRandomPointerValue();
Value *V = new LoadInst(Ptr, "L", BB->getTerminator());
PointerType *Tp = cast<PointerType>(Ptr->getType());
Value *V = new LoadInst(Tp->getElementType(), Ptr, "L",
BB->getTerminator());
PT->push_back(V);
}
};
Expand Down

0 comments on commit 501ec31

Please sign in to comment.