Author: jlebar
Date: Mon Oct 10 11:26:33 2016
New Revision: 283771
URL: http://llvm.org/viewvc/llvm-project?rev=283771=rev
Log:
Use unique_ptr for VTableBuilder::VFTableLayouts map.
Reviewers: timshen
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25423
Modified:
Author: jlebar
Date: Mon Oct 10 11:26:19 2016
New Revision: 283768
URL: http://llvm.org/viewvc/llvm-project?rev=283768=rev
Log:
[AST] Convert MangleNumberingContext to a unique_ptr.
Summary: It doesn't need to be refcounted anymore, either.
Reviewers: timshen
Subscribers: cfe-commits
Author: jlebar
Date: Mon Oct 10 11:26:08 2016
New Revision: 283766
URL: http://llvm.org/viewvc/llvm-project?rev=283766=rev
Log:
[Sema] Use unique_ptr instead of raw pointers in the late-parsed templates map.
Summary:
This is possible now that MapVector supports move-only values.
Depends on
jlebar added inline comments.
Comment at: llvm/lib/IR/LLVMContextImpl.cpp:106
for (auto : CDSConstants)
delete CDSConstant.second;
CDSConstants.clear();
jlebar wrote:
> timshen wrote:
> > Do you want to change this one as well?
> Sure, but this one
jlebar marked an inline comment as done.
jlebar added inline comments.
Comment at: llvm/lib/IR/LLVMContextImpl.cpp:106
for (auto : CDSConstants)
delete CDSConstant.second;
CDSConstants.clear();
timshen wrote:
> Do you want to change this one as well?
wrote:
> This broke bootstrap builds, I reverted it for now in r283747.
>
> On Sat, Oct 8, 2016 at 6:16 PM, Justin Lebar via cfe-commits
> <cfe-commits@lists.llvm.org> wrote:
>>
>> Author: jlebar
>> Date: Sat Oct 8 17:16:12 2016
>> New Revision: 283680
&g
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
The decltype(declval) dance in the iterator traits is necessary because
DenseMap iterators aren't over std::pairs, but rather are over a
pair-like type defined in DenseMap. It used to work
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25426
Files:
clang/include/clang/Analysis/AnalysisContext.h
clang/lib/Analysis/AnalysisDeclContext.cpp
Index: clang/lib/Analysis/AnalysisDeclContext.cpp
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
Herald added a subscriber: klimek.
https://reviews.llvm.org/D25425
Files:
clang/lib/ASTMatchers/Dynamic/Marshallers.h
clang/lib/ASTMatchers/Dynamic/Registry.cpp
Index:
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25424
Files:
clang/include/clang/AST/VTableBuilder.h
clang/lib/AST/VTableBuilder.cpp
Index: clang/lib/AST/VTableBuilder.cpp
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25423
Files:
clang/include/clang/AST/VTableBuilder.h
clang/lib/AST/VTableBuilder.cpp
Index: clang/lib/AST/VTableBuilder.cpp
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25422
Files:
clang/include/clang/AST/VTableBuilder.h
clang/lib/AST/VTableBuilder.cpp
clang/lib/CodeGen/MicrosoftCXXABI.cpp
Index:
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25421
Files:
clang/include/clang/AST/VTableBuilder.h
clang/lib/AST/VTableBuilder.cpp
Index: clang/lib/AST/VTableBuilder.cpp
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
It doesn't need to be refcounted anymore, either.
https://reviews.llvm.org/D25420
Files:
clang/include/clang/AST/ASTContext.h
clang/include/clang/AST/MangleNumberingContext.h
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25419
Files:
llvm/lib/IR/Constants.cpp
llvm/lib/IR/LLVMContextImpl.cpp
llvm/lib/IR/LLVMContextImpl.h
Index: llvm/lib/IR/LLVMContextImpl.h
jlebar created this revision.
jlebar added a reviewer: timshen.
jlebar added a subscriber: cfe-commits.
jlebar added a dependency: D25404: [ADT] Let MapVector handle non-copyable
values..
This is possible now that MapVector supports move-only values.
Depends on https://reviews.llvm.org/D25404.
jlebar added a comment.
Although these pass the CUDA test-suite tests (which I haven't yet committed
because they're broken without this change), I could use some help running the
libcxx tests.
I cannot find any documentation explaining how to run the libcxx tests with
just-built clang.
t; -ffast-math
>>> -ffinite-math-only. GCC can do it. Clang gets std::isnan.
>>> https://godbolt.org/g/vZB55a
>>>
>>> By the way, the changes you made to libc++ unfortunately break this
>>> patch with libc++, because e.g. __libcpp_isnan is not a device
jlebar created this revision.
jlebar added a reviewer: hfinkel.
jlebar added a subscriber: cfe-commits.
This makes these functions available on host and device, which is
necessary to compile for the device.
https://reviews.llvm.org/D25403
Files:
libcxx/include/cmath
Index:
tps://reviews.llvm.org/D24300
>>
>> On Sat, Oct 8, 2016 at 3:36 PM, Hal Finkel <hfin...@anl.gov> wrote:
>> > Hi Justin,
>> >
>> > This is neat!
>> >
>> > I see a bunch of uses of std::isinf, etc. here. It tends to be
>> > important t
Author: jlebar
Date: Sat Oct 8 19:27:39 2016
New Revision: 283683
URL: http://llvm.org/viewvc/llvm-project?rev=283683=rev
Log:
[CUDA] Don't install cuda_wrappers/{algorithm,complex} into the main include
dir.
This is obviously wrong -- if we do this, then all compiles will pick up
these
> optimized away. Can you please check that they do? If not, you might mirror
> what I've done in r283051 for libc++, which is similar to what libstdc++ ends
> up doing, so that we use __builtin_isnan/isinf/isfinite.
>
> Thanks again,
> Hal
>
> ----- Original Message
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283680: [CUDA] Support and std::min/max on the
device. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24979?vs=72719=74053#toc
Repository:
rL LLVM
Author: jlebar
Date: Sat Oct 8 17:16:12 2016
New Revision: 283680
URL: http://llvm.org/viewvc/llvm-project?rev=283680=rev
Log:
[CUDA] Support and std::min/max on the device.
Summary:
We do this by wrapping and .
Tests are in the test-suite.
Reviewers: tra
Subscribers: jhen, beanz,
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283679: [CUDA] Rename cuda_builtin_vars.h to
__clang_cuda_builtin_vars.h. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24978?vs=72685=74054#toc
Repository:
rL LLVM
Author: jlebar
Date: Sat Oct 8 17:16:08 2016
New Revision: 283679
URL: http://llvm.org/viewvc/llvm-project?rev=283679=rev
Log:
[CUDA] Rename cuda_builtin_vars.h to __clang_cuda_builtin_vars.h.
Summary: This matches the idiom we use for our other CUDA wrapper headers.
Reviewers: tra
Author: jlebar
Date: Sat Oct 8 17:15:58 2016
New Revision: 283677
URL: http://llvm.org/viewvc/llvm-project?rev=283677=rev
Log:
[CUDA] Add #pragma clang force_cuda_host_device_{begin,end} pragmas.
Summary:
These cause us to consider all functions in-between to be __host__
__device__.
You can
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283678: [CUDA] Declare our __device__ math functions in the
same inline namespace as… (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24977?vs=72684=74052#toc
Repository:
rL
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283677: [CUDA] Add #pragma clang
force_cuda_host_device_{begin,end} pragmas. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24975?vs=72734=74051#toc
Repository:
rL LLVM
jlebar marked 2 inline comments as done.
jlebar added a comment.
In https://reviews.llvm.org/D24975#565054, @rsmith wrote:
> Please add a test to test/PCH for the serialization code. Otherwise, LGTM.
Test added. It caught a bug, too. :)
Thank you for the review.
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283637: [CUDA] Do a better job at detecting wrong-side
calls. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24573?vs=71381=74030#toc
Repository:
rL LLVM
Author: jlebar
Date: Fri Oct 7 20:07:11 2016
New Revision: 283637
URL: http://llvm.org/viewvc/llvm-project?rev=283637=rev
Log:
[CUDA] Do a better job at detecting wrong-side calls.
Summary:
Move CheckCUDACall from ActOnCallExpr and BuildDeclRefExpr to
DiagnoseUseOfDecl. This lets us catch some
Author: jlebar
Date: Thu Oct 6 14:47:56 2016
New Revision: 283487
URL: http://llvm.org/viewvc/llvm-project?rev=283487=rev
Log:
[Sema] Replace smart quote with "'" in comment.
Looks like the smart quote was copy/pasted from the C++ standard.
The smart quote was not encoded as valid UTF-8 (?),
Author: jlebar
Date: Tue Oct 4 19:27:38 2016
New Revision: 283280
URL: http://llvm.org/viewvc/llvm-project?rev=283280=rev
Log:
[CUDA] Add missing ':' to noexcept.cu test.
Modified:
cfe/trunk/test/CodeGenCUDA/nothrow.cu
Modified: cfe/trunk/test/CodeGenCUDA/nothrow.cu
URL:
Author: jlebar
Date: Tue Oct 4 18:41:49 2016
New Revision: 283272
URL: http://llvm.org/viewvc/llvm-project?rev=283272=rev
Log:
[CUDA] Mark device functions as nounwind.
Summary:
This prevents clang from emitting 'invoke's and catch statements.
Things previously mostly worked thanks to
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283271: [CUDA] Destroy deferred diagnostics before
destroying the ASTContext's… (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25260?vs=73578=73580#toc
Repository:
rL LLVM
Author: jlebar
Date: Tue Oct 4 18:41:45 2016
New Revision: 283271
URL: http://llvm.org/viewvc/llvm-project?rev=283271=rev
Log:
[CUDA] Destroy deferred diagnostics before destroying the ASTContext's
PartialDiagnostic allocator.
Summary:
This will let us (in a separate patch) allocate deferred
jlebar updated this revision to Diff 73579.
jlebar marked an inline comment as done.
jlebar added a comment.
Update tests.
https://reviews.llvm.org/D25166
Files:
clang/lib/CodeGen/CGCall.cpp
clang/lib/CodeGen/CGException.cpp
clang/test/CodeGenCUDA/convergent.cu
jlebar updated this revision to Diff 73578.
jlebar added a comment.
Update comment.
https://reviews.llvm.org/D25260
Files:
clang/include/clang/AST/ASTContext.h
clang/lib/CodeGen/CodeGenModule.cpp
Index: clang/lib/CodeGen/CodeGenModule.cpp
jlebar updated this revision to Diff 73577.
jlebar added a comment.
Move everything into codegen.
https://reviews.llvm.org/D25166
Files:
clang/lib/CodeGen/CGCall.cpp
clang/lib/CodeGen/CGException.cpp
clang/test/CodeGenCUDA/convergent.cu
clang/test/CodeGenCUDA/device-var-init.cu
jlebar updated this revision to Diff 73576.
jlebar marked an inline comment as done.
jlebar added a comment.
Rebase atop https://reviews.llvm.org/D25260, which obviates the need for this
ugly PD allocation dance.
https://reviews.llvm.org/D25139
Files:
jlebar added inline comments.
> rnk wrote in Sema.h:9258
> The ASTContext should outlive IRgen, since the AST is allocated in its arena.
> Is there a separate diagnostic memory pool that I don't know about?
You're right, this is a silly bug. Fixed in a separate patch,
This revision was automatically updated to reflect the committed changes.
Closed by commit rL283120: [CUDA] Disallow overloading destructors. (authored
by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D24571?vs=71379=73413#toc
Repository:
rL LLVM
jlebar added inline comments.
> rnk wrote in Sema.h:9238
> I'm concerned that this usage pattern isn't going to be efficient because you
> build the complete diagnostic before calling the bool conversion operator to
> determine that it doesn't need to be emitted. I think you want to construct
jlebar updated this revision to Diff 73315.
jlebar marked an inline comment as done.
jlebar added a comment.
Address review comments, and rebase atop https://reviews.llvm.org/D24573.
https://reviews.llvm.org/D25139
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
Author: jlebar
Date: Mon Oct 3 11:48:23 2016
New Revision: 283120
URL: http://llvm.org/viewvc/llvm-project?rev=283120=rev
Log:
[CUDA] Disallow overloading destructors.
Summary:
We'd attempted to allow this, but turns out we were doing a very bad
job. :)
Making this work properly would be a
Author: jlebar
Date: Mon Oct 3 11:48:27 2016
New Revision: 283121
URL: http://llvm.org/viewvc/llvm-project?rev=283121=rev
Log:
[CUDA] Clean up some comments in Sema::IsOverload. NFC
Modified:
cfe/trunk/lib/Sema/SemaOverload.cpp
Modified: cfe/trunk/lib/Sema/SemaOverload.cpp
URL:
jlebar added inline comments.
> rnk wrote in SemaOverload.cpp:1131
> I feel like we should exit early on destructors here, before we do any target
> checks. The assert also feels kind of trivial because we only come into this
> overload machinery if looking up New's DeclarationName found Old.
jlebar added a comment.
In https://reviews.llvm.org/D25166#559117, @rnk wrote:
> It feels like the right thing is to disable EH in device side compilation,
> but obviously that won't work because it would reject try/throw in host code.
Exactly.
> I think instead of doing that, we should make
jlebar created this revision.
jlebar added a reviewer: tra.
jlebar added a subscriber: cfe-commits.
This prevents clang from emitting 'invoke's and catch statements.
Things previously mostly worked thanks to TryToMarkNoThrow() in
CodeGenFunction. But this is not a proper IPO, and it doesn't
Author: jlebar
Date: Sun Oct 2 10:24:50 2016
New Revision: 283068
URL: http://llvm.org/viewvc/llvm-project?rev=283068=rev
Log:
[CUDA] Allow extern __shared__ on empty-length arrays.
"extern __shared__ int x[]" is OK.
Modified:
cfe/trunk/lib/Sema/SemaDeclAttr.cpp
jlebar created this revision.
jlebar added reviewers: tra, rnk.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25150
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDecl.cpp
clang/test/SemaCUDA/device-var-init.cu
jlebar updated this revision to Diff 73172.
jlebar added a comment.
Update to new CUDADiagIfHostCode API.
https://reviews.llvm.org/D25143
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCUDA/bad-attributes.cu
Index:
jlebar updated this revision to Diff 73171.
jlebar added a comment.
Tweak API a bit.
Now we rely on an implicit conversion to bool. Which is not great, I know, but
in practice I think works better than an explicit named function.
https://reviews.llvm.org/D25139
Files:
Author: jlebar
Date: Fri Sep 30 18:57:34 2016
New Revision: 282986
URL: http://llvm.org/viewvc/llvm-project?rev=282986=rev
Log:
[CUDA] Disallow __constant__ local variables.
Reviewers: tra, rnk
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25129
Modified:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282985: [CUDA] Disallow 'extern __shared__' variables.
(authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25125?vs=73136=73167#toc
Repository:
rL LLVM
Author: jlebar
Date: Fri Sep 30 18:57:38 2016
New Revision: 282987
URL: http://llvm.org/viewvc/llvm-project?rev=282987=rev
Log:
[CUDA] Harmonize asserts in SemaCUDA, NFC.
Modified:
cfe/trunk/lib/Sema/SemaCUDA.cpp
Modified: cfe/trunk/lib/Sema/SemaCUDA.cpp
URL:
Author: jlebar
Date: Fri Sep 30 18:57:30 2016
New Revision: 282985
URL: http://llvm.org/viewvc/llvm-project?rev=282985=rev
Log:
[CUDA] Disallow 'extern __shared__' variables.
Also add a test that we disallow
__constant__ __shared__ int x;
because it's possible to break this without breaking
jlebar added inline comments.
> tra wrote in DiagnosticSemaKinds.td:6727
> It's not clear whether you mean global storage class or global namespace.
> The code checks for global storage, but error message is could be interpreted
> either way, IMO.
>
> I'll leave phrasing up to you.
> It's not
jlebar created this revision.
jlebar added reviewers: tra, rnk.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25143
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCUDA/bad-attributes.cu
Index:
jlebar updated this revision to Diff 73165.
jlebar added a comment.
Add CUDADiagIfHostCode().
https://reviews.llvm.org/D25139
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
clang/lib/Sema/SemaCUDA.cpp
clang/lib/Sema/SemaExprCXX.cpp
jlebar created this revision.
jlebar added a reviewer: rnk.
jlebar added subscribers: tra, cfe-commits.
Together these let you easily create diagnostics that
- are never emitted for host code
- are always emitted for __device__ and __global__ functions, and
- are emitted for __host__ __device__
jlebar added inline comments.
> tra wrote in DiagnosticSemaKinds.td:6727
> Nit: Technically they are allowed in namespace scope.
That's still a "global variable"? Or do you think calling it such will be
confusing?
https://reviews.llvm.org/D25129
jlebar created this revision.
jlebar added reviewers: tra, rnk.
jlebar added a subscriber: cfe-commits.
https://reviews.llvm.org/D25129
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCUDA/bad-attributes.cu
Index:
jlebar updated this revision to Diff 73136.
jlebar added a comment.
Fix typo (and add a test to catch it).
https://reviews.llvm.org/D25125
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCUDA/bad-attributes.cu
jlebar created this revision.
jlebar added a reviewer: rnk.
jlebar added subscribers: tra, cfe-commits.
https://reviews.llvm.org/D25125
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/Sema/SemaDeclAttr.cpp
clang/test/SemaCUDA/extern-shared.cu
Index:
Author: jlebar
Date: Fri Sep 30 15:17:37 2016
New Revision: 282927
URL: http://llvm.org/viewvc/llvm-project?rev=282927=rev
Log:
[CUDA] Fix implicit-device-lambda.cu after r282911.
This commit added a warning that we're (correctly) hitting in this test.
Just ignore it.
Modified:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282910: [CUDA] Fix up MaybeParseGNUAttributes call used for
out-of-place attributes on… (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25114?vs=73104=73122#toc
Repository:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282911: [CUDA] Emit a warning if a CUDA host/device/global
attribute is placed after '(. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25115?vs=73105=73123#toc
Repository:
Author: jlebar
Date: Fri Sep 30 14:55:59 2016
New Revision: 282912
URL: http://llvm.org/viewvc/llvm-project?rev=282912=rev
Log:
[CUDA] Remove incorrect comment in CUDASetLambdaAttrs.
I'd said that nvcc doesn't allow you to add __host__ or __device__
attributes on lambdas in all circumstances,
Author: jlebar
Date: Fri Sep 30 14:55:55 2016
New Revision: 282911
URL: http://llvm.org/viewvc/llvm-project?rev=282911=rev
Log:
[CUDA] Emit a warning if a CUDA host/device/global attribute is placed after
'(...)'.
Summary:
This is probably the sane place for the attribute to go, but nvcc
Author: jlebar
Date: Fri Sep 30 14:55:48 2016
New Revision: 282910
URL: http://llvm.org/viewvc/llvm-project?rev=282910=rev
Log:
[CUDA] Fix up MaybeParseGNUAttributes call used for out-of-place attributes on
CUDA lambdas.
Summary: There's an overload that we can use to make this a bit cleaner.
jlebar created this revision.
jlebar added a reviewer: rnk.
jlebar added subscribers: tra, cfe-commits.
This is probably the sane place for the attribute to go, but nvcc
specifically rejects it. Other GNU-style attributes are allowed in this
position (although judging from the warning it emits
jlebar created this revision.
jlebar added a reviewer: rnk.
jlebar added subscribers: tra, cfe-commits.
There's an overload that we can use to make this a bit cleaner.
https://reviews.llvm.org/D25114
Files:
clang/lib/Parse/ParseExprCXX.cpp
Index: clang/lib/Parse/ParseExprCXX.cpp
jlebar added inline comments.
> rnk wrote in ParseExprCXX.cpp:1135
> Does nvcc support __declspec style attributes? Maybe we should check for
> those too?
nvcc doesn't seem to support __declspec attributes.
I have no strong opinion on whether or not we should add them ourselves, though
I
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282880: [CUDA] Make lambdas inherit __host__ and __device__
attributes from the scope… (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25105?vs=73073=73089#toc
Repository:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282879: [CUDA] Handle attributes on CUDA lambdas appearing
between [...] and (...). (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25103?vs=73085=73088#toc
Repository:
rL
Author: jlebar
Date: Fri Sep 30 12:14:44 2016
New Revision: 282878
URL: http://llvm.org/viewvc/llvm-project?rev=282878=rev
Log:
[CUDA] Add missing comment on Sema::CheckCUDAVLA.
Modified:
cfe/trunk/include/clang/Sema/Sema.h
Modified: cfe/trunk/include/clang/Sema/Sema.h
URL:
Author: jlebar
Date: Fri Sep 30 12:14:53 2016
New Revision: 282880
URL: http://llvm.org/viewvc/llvm-project?rev=282880=rev
Log:
[CUDA] Make lambdas inherit __host__ and __device__ attributes from the scope
in which they're created.
Summary: NVCC compat. Fixes bug 30567.
Reviewers: tra
Author: jlebar
Date: Fri Sep 30 12:14:48 2016
New Revision: 282879
URL: http://llvm.org/viewvc/llvm-project?rev=282879=rev
Log:
[CUDA] Handle attributes on CUDA lambdas appearing between [...] and (...).
Summary: This is ugh, but it makes us compatible with NVCC. Fixes bug 26341.
Reviewers:
jlebar updated this revision to Diff 73085.
jlebar marked an inline comment as done.
jlebar added a comment.
Don't hallucinate a function declarator.
https://reviews.llvm.org/D25103
Files:
clang/lib/Parse/ParseExprCXX.cpp
clang/test/Parser/lambda-attr.cu
Index:
jlebar created this revision.
jlebar added a reviewer: tra.
jlebar added subscribers: rnk, cfe-commits.
NVCC compat. Fixes bug 30567.
https://reviews.llvm.org/D25105
Files:
clang/include/clang/Sema/Sema.h
clang/lib/Sema/SemaCUDA.cpp
clang/lib/Sema/SemaLambda.cpp
jlebar created this revision.
jlebar added a reviewer: rnk.
jlebar added subscribers: tra, cfe-commits.
This is ugh, but it makes us compatible with NVCC. Fixes bug 26341.
https://reviews.llvm.org/D25103
Files:
clang/lib/Parse/ParseExprCXX.cpp
clang/test/Parser/lambda-attr.cu
Index:
Author: jlebar
Date: Thu Sep 29 19:38:45 2016
New Revision: 282822
URL: http://llvm.org/viewvc/llvm-project?rev=282822=rev
Log:
Move UTF functions into namespace llvm.
Summary:
This lets people link against LLVM and their own version of the UTF
library.
I determined this only affects llvm,
jlebar added a comment.
I'm sorry to put more stuff on your plate, Richard, but you already have
context on this, so you may be the best person to review this. Unfortunately
people keep hitting the bug fixed here (and being confused), so it's maybe not
as much of an edge case as I thought.
This revision was automatically updated to reflect the committed changes.
jlebar marked an inline comment as done.
Closed by commit rL282646: [CUDA] Disallow exceptions in device code. (authored
by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25036?vs=72872=72918#toc
Author: jlebar
Date: Wed Sep 28 17:45:54 2016
New Revision: 282646
URL: http://llvm.org/viewvc/llvm-project?rev=282646=rev
Log:
[CUDA] Disallow exceptions in device code.
Reviewers: tra
Subscribers: cfe-commits, jhen
Differential Revision: https://reviews.llvm.org/D25036
Added:
Author: jlebar
Date: Wed Sep 28 17:45:58 2016
New Revision: 282647
URL: http://llvm.org/viewvc/llvm-project?rev=282647=rev
Log:
[CUDA] Disallow variable-length arrays in CUDA device code.
Reviewers: tra
Subscribers: cfe-commits, jhen
Differential Revision: https://reviews.llvm.org/D25050
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282647: [CUDA] Disallow variable-length arrays in CUDA
device code. (authored by jlebar).
Changed prior to commit:
https://reviews.llvm.org/D25050?vs=72914=72919#toc
Repository:
rL LLVM
jlebar created this revision.
jlebar added a reviewer: tra.
jlebar added subscribers: jhen, cfe-commits.
https://reviews.llvm.org/D25050
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
clang/lib/Sema/SemaCUDA.cpp
clang/lib/Sema/SemaType.cpp
jlebar marked an inline comment as done.
Comment at: clang/lib/Sema/SemaExprCXX.cpp:688
@@ +687,3 @@
+ if (getLangOpts().CUDA)
+CheckCUDAExceptionExpr(OpLoc, "throw");
+
tra wrote:
> Do you need/want to check returned result?
We could, and we could return
jlebar created this revision.
jlebar added a reviewer: tra.
jlebar added subscribers: jhen, cfe-commits.
https://reviews.llvm.org/D25036
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
clang/lib/Sema/SemaCUDA.cpp
clang/lib/Sema/SemaExprCXX.cpp
jlebar added a comment.
> What happens if there are trailing tokens after the pragma?
Added code to make this an error.
https://reviews.llvm.org/D24975
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
jlebar updated this revision to Diff 72734.
jlebar marked 2 inline comments as done.
jlebar added a comment.
Address Richard's comments.
I'm fairly neutral on whether we want to make it an error not to match all of
your "begin" pragmas with "end"s. I checked pragma push_macro, and it looks
like
jlebar updated this revision to Diff 72719.
jlebar added a comment.
Herald added a subscriber: mehdi_amini.
s/libgcc/runtime/
https://reviews.llvm.org/D24979
Files:
clang/lib/Driver/ToolChains.cpp
clang/lib/Headers/CMakeLists.txt
clang/lib/Headers/__clang_cuda_complex_builtins.h
jlebar updated this revision to Diff 72717.
jlebar marked 2 inline comments as done.
jlebar added a comment.
Address Richard Smith's review comments:
- Change macro format.
- Add tests (these Just Worked).
https://reviews.llvm.org/D24975
Files:
jlebar added inline comments.
Comment at: lib/Headers/__clang_cuda_runtime_wrapper.h:139
@@ -137,1 +138,3 @@
+// CUDA 8.0.41 relies on __USE_FAST_MATH__ and __CUDA_PREC_DIV's values
+// Previous versions used to check thether they are defined or not.
Nit,
jlebar added a comment.
> I' personally would prefer to force-include these files. I suspect it will
> not change things much as we already include a lot.
We have already had bugs filed by users whose root cause was that we #included
more things than nvcc #includes. I know exact
jlebar added a comment.
> That is way too much knowledge about details of standard library
> implementation.
Honestly I think this looks a lot scarier than it is. Or, to be specific, I
think we are already relying on implementation details much more implicit and
fragile than what is
jlebar created this revision.
jlebar added a reviewer: tra.
jlebar added subscribers: cfe-commits, jhen.
Herald added subscribers: mgorny, beanz.
We do this by wrapping and .
Tests are in the test-suite. support to come separately.
https://reviews.llvm.org/D24979
Files:
201 - 300 of 819 matches
Mail list logo