Skip to content

Commit f693d47

Browse files
authored
copy the PtrCmpMode when copying an icmp (#1288)
1 parent 2a6f34a commit f693d47

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

ir/instr.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3032,7 +3032,10 @@ expr ICmp::getTypeConstraints(const Function &f) const {
30323032
}
30333033

30343034
unique_ptr<Instr> ICmp::dup(Function &f, const string &suffix) const {
3035-
return make_unique<ICmp>(getType(), getName() + suffix, cond, *a, *b, flags);
3035+
auto dup = make_unique<ICmp>(getType(), getName() + suffix, cond, *a, *b,
3036+
flags);
3037+
dup->setPtrCmpMode(pcmode);
3038+
return dup;
30363039
}
30373040

30383041

0 commit comments

Comments
 (0)