[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-15 Thread Sven van Haastregt via cfe-commits
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.

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-15 Thread Neil Hickey via cfe-commits
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.

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-14 Thread Neil Hickey via cfe-commits
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:

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-11 Thread Neil Hickey via cfe-commits
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:

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-10 Thread Sven van Haastregt via cfe-commits
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

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-07 Thread Yaxun Liu via cfe-commits
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!

[PATCH] D24235: [OpenCL] Improve double literal handling

2016-11-01 Thread Neil Hickey via cfe-commits
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.

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-20 Thread Yaxun Liu via cfe-commits
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: >

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-20 Thread Neil Hickey via cfe-commits
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: >

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-19 Thread Yaxun Liu via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-19 Thread Neil Hickey via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-16 Thread Neil Hickey via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-16 Thread Neil Hickey via 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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-09 Thread Anastasia Stulova via 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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-09 Thread Neil Hickey via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-07 Thread Anastasia Stulova via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-07 Thread Neil Hickey via cfe-commits
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

Re: [PATCH] D24235: [OpenCL] Improve double literal handling

2016-09-05 Thread Anastasia Stulova via cfe-commits
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