You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Classic clang codegen sets the nsw flag for the add and sub operations produced for inc, dec, and minus operators on signed integer operations. When lowering through CIR, this flag is not set.
For example:
int f(int b) {
return ++b;
}
Classic codegen produces:
%inc = add nsw i32 %0, 1
CIR codegen produces:
%5 = add i32 %4, 1
It's not clear to me whether the CIR should also have an attribute for this.