[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-16 Thread Serge Pavlov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1ddd5863088b: [clang] Missed rounding mode use in constant evaluation (authored by sepavloff). Changed prior to commit: https://reviews.llvm.org/D137719?vs=474304&id=475999#toc Repository: rG LLVM Gi

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-16 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. Thanks! Comment at: clang/test/AST/const-fpfeatures.c:37 float _Complex C1d = C0; // CHECK: @C1d = {{.*}} { float, float } { float 1.00e+00, float 1.00e+00 } aaron.ballman wrote: > Should we add a test without the `-fexperi

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-16 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. Looks good to me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137719/new/ https://reviews.llvm.org/D137719 __

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-16 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: jcranmer-intel. aaron.ballman added a subscriber: jcranmer-intel. aaron.ballman added a comment. The changes look correct to me, but adding @jcranmer-intel for floating-point expertise. Comment at: clang/test/AST/const-fpfeatures.c:37 float _Co

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-14 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. Ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137719/new/ https://reviews.llvm.org/D137719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-09 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 474304. sepavloff added a comment. Remove accidentally added file Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137719/new/ https://reviews.llvm.org/D137719 Files: clang/lib/AST/ExprConstant.cpp clang/te

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-09 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 474303. sepavloff added a comment. Removed unused parateters from HandleIntToFloatCast Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137719/new/ https://reviews.llvm.org/D137719 Files: clang/lib/AST/ExprCo

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-09 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/ExprConstant.cpp:2653 + APFloat::opStatus St = Result.convertFromAPInt(Value, Value.isSigned(), RM); + return checkFloatingPointResult(Info, E, St); } tbaeder wrote: > `SrcType` was already unused before

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-09 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/ExprConstant.cpp:2653 + APFloat::opStatus St = Result.convertFromAPInt(Value, Value.isSigned(), RM); + return checkFloatingPointResult(Info, E, St); } `SrcType` was already unused before, but not so is `

[PATCH] D137719: [clang] Missed rounding mode use in constant evaluation

2022-11-09 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff created this revision. sepavloff added reviewers: rjmccall, efriedma, aaron.ballman. Herald added a project: All. sepavloff requested review of this revision. Herald added a project: clang. Integer-to-float conversion was handled in constant evaluator with default rounding mode. This cha