- Sep 09, 2016
-
-
Albert Gutowski authored
Reviewers: thakis, Prazek, compnerd, rnk Subscribers: majnemer, cfe-commits Differential Revision: https://reviews.llvm.org/D24311 llvm-svn: 280997
-
- Sep 08, 2016
-
-
Simon Pilgrim authored
llvm-svn: 280921
-
Simon Pilgrim authored
llvm-svn: 280917
-
Peter Collingbourne authored
- Simplify signature of CreateVTableInitializer function. - Move vtable component builder to a separate function. - Remove unnecessary accessors from VTableLayout class. This is in preparation for a future change that will alter the type of the vtable initializer. Differential Revision: https://reviews.llvm.org/D22642 llvm-svn: 280897
-
- Sep 07, 2016
-
-
Reid Kleckner authored
Move the logic for doing this from the ABI argument lowering into EmitParmDecl, which runs for all parameters. Our codegen is slightly suboptimal in this case, as we may leave behind a dead store after optimization, but it's 32-bit inalloca, and this fixes the bug in a robust way. Fixes PR30293 llvm-svn: 280836
-
Reid Kleckner authored
If the virtual method comes from a secondary vtable, then the type of the 'this' parameter should be i8*, and not a pointer to the complete class. In the MS ABI, the 'this' parameter on entry points to the vptr containing the virtual method that was called, so we use i8* instead of the normal type. We had a mismatch where the CGFunctionInfo of the call didn't match the CGFunctionInfo of the declaration, and this resulted in some assertions, but now both sides agree the type of 'this' is i8*. Fixes one issue raised in PR30293 llvm-svn: 280815
-
Matt Arsenault authored
^M and extra space llvm-svn: 280786
-
- Sep 06, 2016
-
-
Leny Kholodov authored
llvm-svn: 280718
-
Leny Kholodov authored
Use llvm::DINode::DIFlags type (strongly typed enum) for debug flags instead of unsigned int to avoid problems on platforms with sizeof(int) < 4: we already have flags with values > (1 << 16). Patch by: Victor Leschuk <vleschuk@gmail.com> Differential Revision: https://reviews.llvm.org/D23767 llvm-svn: 280701
-
Alexey Bader authored
Summary: Remove access qualifiers on images in arg info metadata: * kernel_arg_type * kernel_arg_base_type Image access qualifiers are inseparable from type in clang implementation, but OpenCL spec provides a special query to get access qualifier via clGetKernelArgInfo with CL_KERNEL_ARG_ACCESS_QUALIFIER. Besides that OpenCL conformance test_api get_kernel_arg_info expects image types without access qualifier. Patch by Evgeniy Tyurin. Reviewers: bader, yaxunl, Anastasia Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D23915 llvm-svn: 280699
-
- Sep 01, 2016
-
-
Honggyu Kim authored
Since some profiling tools, such as gprof, ftrace, and uftrace, use -pg option to generate a mcount function call at the entry of each function. Function invocation can be detected by this hook function. But mcount insertion is done before function inlining phase in clang, sometime a function that already has a mcount call can be inlined in the middle of another function. This patch adds an attribute "counting-function" to each function rather than emitting the mcount call directly in frontend so that this attribute can be processed in backend. Then the mcount calls can be properly inserted in backend after all the other optimizations are completed. Link: https://llvm.org/bugs/show_bug.cgi?id=28660 Reviewers: hans, rjmccall, hfinkel, rengolin, compnerd Subscribers: shenhan, cfe-commits Differential Revision: https://reviews.llvm.org/D22666 llvm-svn: 280355
-
Honggyu Kim authored
llvm-svn: 280337
-
Nick Lewycky authored
-fprofile-dir=path allows the user to specify where .gcda files should be emitted when the program is run. In particular, this is the first flag that causes the .gcno and .o files to have different paths, LLVM is extended to support this. -fprofile-dir= does not change the file name in the .gcno (and thus where lcov looks for the source) but it does change the name in the .gcda (and thus where the runtime library writes the .gcda file). It's different from a GCOV_PREFIX because a user can observe that the GCOV_PREFIX_STRIP will strip paths off of -fprofile-dir= but not off of a supplied GCOV_PREFIX. To implement this we split -coverage-file into -coverage-data-file and -coverage-notes-file to specify the two different names. The !llvm.gcov metadata node grows from a 2-element form {string coverage-file, node dbg.cu} to 3-elements, {string coverage-notes-file, string coverage-data-file, node dbg.cu}. In the 3-element form, the file name is already "mangled" with .gcno/.gcda suffixes, while the 2-element form left that to the middle end pass. llvm-svn: 280306
-
- Aug 31, 2016
-
-
Reid Kleckner authored
Classes with no virtual methods or whose virtual methods were all inherited from virtual bases don't have a vfptr at offset zero. We were crashing attempting to get the layout of that non-existent vftable. We don't need any vshape info in this case because the debugger can infer it from the base class information. The current class may not introduce any virtual methods if we are in this situation. llvm-svn: 280287
-
Reid Kleckner authored
The shape is really just the number of methods in the vftable, since we don't support 16 bit far calls. All calls are near. Encode this number in the size of the artificial __vtbl_ptr_type DIDerivedType that we generate. For DWARF, this will be a normal pointer, but for codeview this will be a wide pointer that gets pattern matched into a VFTableShape record. Insert this type into the element list of all dynamic classes when emitting CodeView, so that the backend can emit the shape even if the vptr lives in a primary base class. Fixes PR28150 llvm-svn: 280255
-
Igor Kudrin authored
In most cases these code regions are just redundant, but sometimes they could be assigned to the counter of the parent code region instead of the counter of the nested block. Differential Revision: https://reviews.llvm.org/D23987 llvm-svn: 280199
-
- Aug 30, 2016
-
-
Sjoerd Meijer authored
to CC1, which are translated to function attributes and can e.g. be mapped on build attributes FP_exceptions and FP_denormal. Setting these build attributes allows better selection of floating point libraries. Differential Revision: https://reviews.llvm.org/D23840 llvm-svn: 280064
-
Hal Finkel authored
The PPC64 DWARF register-size table did not match the ABI specification (or GCC, for that matter). Fix that, and add a regression test. Fixes PR27931. llvm-svn: 280053
-
Kostya Serebryany authored
[sanitizer-coverage] add two more modes of instrumentation: trace-div and trace-gep, mostly usaful for value-profile-based fuzzing; clang part llvm-svn: 280044
-
- Aug 29, 2016
-
-
Igor Kudrin authored
If there were several nested statements arranged in a way that all of them end up with the same macro, then the expansion of this macro was assigned with all the corresponding counters of these statements. As a result, the wrong counter value was shown for the macro in llvm-cov. This patch fixes the issue by preventing adding a counter for an expanded source range if it already has an assigned counter, which is expected to come from the most specific statement. Differential Revision: https://reviews.llvm.org/D23160 llvm-svn: 279962
-
- Aug 26, 2016
-
-
Reid Kleckner authored
Otherwise we can't handle secondary base classes at offsets greater than 2**24. This agrees with libstdc++abi. We could extend this change to other LLP64 platforms, but then we would want to update libc++abi and it would require additional review. Fixes PR29116 llvm-svn: 279786
-
- Aug 25, 2016
-
-
Reid Kleckner authored
Fixes PR20569 llvm-svn: 279774
-
Reid Kleckner authored
This isn't exactly what MSVC does, unfortunately. MSVC does not pass objects with destructors but no copy constructors by address. More ARM expertise is required to really understand what should be done here. Fixes PR29136. llvm-svn: 279764
-
- Aug 24, 2016
-
-
David Blaikie authored
In cases where .dwo/.dwp files are guaranteed to be available, skipping the extra online (in the .o file) inline info can save a substantial amount of space - see the original r221306 for more details there. llvm-svn: 279651
-
Adam Nemet authored
llvm-svn: 279608
-
- Aug 23, 2016
-
-
Adrian Prantl authored
llvm-svn: 279490
-
Adrian Prantl authored
in isDefinedInClangModule() and assume that the incomplete definition is not defined in the module. This broke the -gmodules self host recently. rdar://problem/27894367 llvm-svn: 279485
-
- Aug 22, 2016
-
-
Matt Arsenault authored
Structs are currently handled as pointer + byval, which makes AMDGPU LLVM backend generate incorrect code when structs are used. This patch changes struct argument to be handled directly and without flattening, which Clover (Mesa 3D Gallium OpenCL state tracker) will be able to handle. Flattening would expand the struct to individual elements and pass each as a separate argument, which Clover can not handle. Furthermore, such expansion does not fit the OpenCL programming model which requires to explicitely specify each argument index, size and memory location. Patch by Vedran Miletić llvm-svn: 279463
-
David Blaikie authored
llvm-svn: 279445
-
- Aug 19, 2016
-
-
Yaxun Liu authored
There was a premature cast to pointer type in emitPointerArithmetic which caused assertion in tests with assertion enabled. llvm-svn: 279206
-
Changpeng Fang authored
Summary: int __builtin_amdgcn_ds_swizzle (int a, int imm); while imm is a constant. Differential Revision: http://reviews.llvm.org/D23682 llvm-svn: 279165
-
- Aug 18, 2016
-
-
Justin Bogner authored
llvm-svn: 279159
-
Saleem Abdulrasool authored
llvm-svn: 279154
-
Yaxun Liu authored
due to regressions in test/CodeGen/exprs.c on certain platforms. llvm-svn: 279127
-
Yaxun Liu authored
Pointers of certain GPUs in AMDGCN target in private address space is 32 bit but pointers in other address spaces are 64 bit. size_t type should be defined as 64 bit for these GPUs so that it could hold pointers in all address spaces. Also fixed issues in pointer arithmetic codegen by using pointer specific intptr type. Differential Revision: https://reviews.llvm.org/D23361 llvm-svn: 279121
-
Diana Picus authored
This reverts commit r279003 as it breaks some of our buildbots (e.g. clang-cmake-aarch64-quick, clang-x86_64-linux-selfhost-modules). The error is in OpenMP/teams_distribute_simd_ast_print.cpp: clang: /home/buildslave/buildslave/clang-cmake-aarch64-quick/llvm/include/llvm/ADT/DenseMap.h:527: bool llvm::DenseMapBase<DerivedT, KeyT, ValueT, KeyInfoT, BucketT>::LookupBucketFor(const LookupKeyT&, const BucketT*&) const [with LookupKeyT = clang::Stmt*; DerivedT = llvm::DenseMap<clang::Stmt*, long unsigned int>; KeyT = clang::Stmt*; ValueT = long unsigned int; KeyInfoT = llvm::DenseMapInfo<clang::Stmt*>; BucketT = llvm::detail::DenseMapPair<clang::Stmt*, long unsigned int>]: Assertion `!KeyInfoT::isEqual(Val, EmptyKey) && !KeyInfoT::isEqual(Val, TombstoneKey) && "Empty/Tombstone value shouldn't be inserted into map!"' failed. llvm-svn: 279045
-
Adrian Prantl authored
rdar://problem/24504815 llvm-svn: 279004
-
Kelvin Li authored
This patch is to implement sema and parsing for 'teams distribute simd’ pragma. This patch is originated by Carlo Bertolli. Differential Revision: https://reviews.llvm.org/D23528 llvm-svn: 279003
-
- Aug 17, 2016
-
-
Adrian Prantl authored
The previous condition would erroneously mark all CXXRecordDecls that didn't have any fields as being defined in a clang module. This patch fixes the condition to only apply to explicit template instantiations. <rdar://problem/27771823> llvm-svn: 278952
-
Adrian Prantl authored
This affects functions with the C++11 [[ noreturn ]] and C11 _Noreturn specifiers. Patch by Victor Leschuk! https://reviews.llvm.org/D23168 llvm-svn: 278942
-