svenvh added inline comments.
Comment at: lib/Sema/SemaChecking.cpp:3732
// If this is an implicit conversion from float -> double, remove it.
if (ImplicitCastExpr *Cast = dyn_cast(OrigArg)) {
The comment should mention float -> float now as well.
neil.hickey removed rL LLVM as the repository for this revision.
neil.hickey updated this revision to Diff 77961.
neil.hickey added a comment.
Fixes to tests and removal of incorrect check to stop float to float casts if
types match. This was still needed as it was an lvalue to rvalue cast.
This revision was automatically updated to reflect the committed changes.
Closed by commit rL286815: Improve handling of floating point literals in
OpenCL to only use doubleā¦ (authored by neil.hickey).
Changed prior to commit:
https://reviews.llvm.org/D24235?vs=77600=77783#toc
Repository:
neil.hickey updated this revision to Diff 77600.
neil.hickey added a comment.
Improving now confusing comment.
https://reviews.llvm.org/D24235
Files:
lib/Sema/SemaExpr.cpp
lib/Sema/SemaType.cpp
test/CodeGenOpenCL/fpmath.cl
test/SemaOpenCL/extensions.cl
Index:
svenvh added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:3431
+.getSupportedOpenCLOpts()
+.cl_khr_fp64) ||
getOpenCLOptions().cl_khr_fp64)) {
yaxunl wrote:
> neil.hickey wrote:
> > yaxunl
yaxunl added inline comments.
Comment at: test/SemaOpenCL/extensions.cl:28
+#ifdef FP64
+// expected-no-diagnostics
+#endif
expected-no-diagnostics applies to the whole file. better move to the beginning
of the file.
otherwise LGTM. Thanks!
neil.hickey updated this revision to Diff 76587.
neil.hickey added a comment.
Sorry for the delay. It looks like the code to handle extensions was changed
since Neil Henning added the check against opencl 1.2. Perhaps the best
approach is just to remove the check.
yaxunl added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:3431
@@ -3410,1 +3430,3 @@
+.getSupportedOpenCLOpts()
+.cl_khr_fp64) ||
getOpenCLOptions().cl_khr_fp64)) {
neil.hickey wrote:
>
neil.hickey added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:3431
@@ -3410,1 +3430,3 @@
+.getSupportedOpenCLOpts()
+.cl_khr_fp64) ||
getOpenCLOptions().cl_khr_fp64)) {
yaxunl wrote:
>
yaxunl added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:3431
@@ -3410,1 +3430,3 @@
+.getSupportedOpenCLOpts()
+.cl_khr_fp64) ||
getOpenCLOptions().cl_khr_fp64)) {
This check
neil.hickey added a reviewer: tstellarAMD.
neil.hickey updated this revision to Diff 71837.
neil.hickey added a comment.
Herald added subscribers: yaxunl, wdng.
There was a bug whereby an implicitcast was being applied from float to float,
this caused issues later on in builin processing which
neil.hickey added a comment.
committed @ 281714
https://reviews.llvm.org/D24235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
neil.hickey closed this revision.
neil.hickey added a comment.
Commit merged to trunk
https://reviews.llvm.org/D24235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.
LGTM! Thanks!
https://reviews.llvm.org/D24235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
neil.hickey added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:837
@@ +836,3 @@
+ .getSupportedOpenCLOpts()
+ .cl_khr_fp64) ||
+ getOpenCLOptions().cl_khr_fp64)) {
Anastasia wrote:
> Could we merge this and two lines
Anastasia added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:832
@@ -831,2 +831,3 @@
BTy->getKind() == BuiltinType::Float))
-E = ImpCastExprToType(E, Context.DoubleTy, CK_FloatingCast).get();
+ {
+if (getLangOpts().OpenCL &&
This
neil.hickey updated this revision to Diff 70527.
neil.hickey added a comment.
Added a CodeGen test as well as fixed an issue with vararg type promotion
https://reviews.llvm.org/D24235
Files:
lib/Sema/SemaExpr.cpp
lib/Sema/SemaType.cpp
test/CodeGenOpenCL/fpmath.cl
Anastasia added a comment.
Could we add a CodeGen test as well to check that the constants generated are
in the right precision format?
https://reviews.llvm.org/D24235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
18 matches
Mail list logo