- Jun 24, 2017
-
-
Evgeniy Stepanov authored
Add ASan report to the "debug message" field in Android tombstones. llvm-svn: 306184
-
Vedant Kumar authored
Add warn_drv_object_size_disabled_O0 to the invalid command line argument group. This should fix some bot failures: lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-ubuntu-fast/builds/13241/steps/test/logs/stdio llvm-svn: 306183
-
Lang Hames authored
llvm-svn: 306182
-
Vedant Kumar authored
This check currently isn't able to diagnose any issues at -O0, not is it likely to [1]. Disabling the check at -O0 leads to substantial compile time and binary size savings. [1] [cfe-dev] Disabling ubsan's object size check at -O0 Differential Revision: https://reviews.llvm.org/D34563 llvm-svn: 306181
-
Sean Callanan authored
Also un-xfailed a testcase that was affected by this. Thanks to Jason Molenda for the patch. <rdar://problem/32827216> llvm-svn: 306180
-
Zachary Turner authored
llvm-svn: 306179
-
Rafael Espindola authored
llvm-svn: 306178
-
Rafael Espindola authored
processFixupValue is called on every relaxation iteration. applyFixup is only called once at the very end. applyFixup is then the correct place to do last minute changes and value checks. While here, do proper range checks again for fixup_arm_thumb_bl. We used to do it, but dropped because of thumb2. We now do it again, but use the thumb2 range. llvm-svn: 306177
-
Rafael Espindola authored
Revert "[ORC] Remove redundant semicolons from DEFINE_SIMPLE_CONVERSION_FUNCTIONS uses." Revert "[ORC] Move ORC IR layer interface from addModuleSet to addModule and fix the module type as std::shared_ptr<Module>." They broke ExecutionEngine/OrcMCJIT/test-global-ctors.ll on linux. llvm-svn: 306176
-
Reid Kleckner authored
This reverts commit r306137. It has problems on code like this: struct __declspec(dllimport) Foo { int a; int get_a() { return a; } }; template <int (Foo::*Getter)()> struct HasValue { int operator()(Foo *p) { return (p->*Getter)(); } }; int main() { Foo f; f.a = 3; int x = HasValue<&Foo::get_a>()(&f); } llvm-svn: 306175 -
Petar Jovanovic authored
After fixing (r306173) a failing test in the lld test suite (r306173), reland r306095. Original commit message: [mips] Fix register positions in the aui/daui instructions Swapped the position of the rt and rs register in the aui/daui instructions for mips32r6 and mips64r6. With this change, the format of the generated instructions complies with specifications and GCC. Patch by Milos Stojanovic. llvm-svn: 306174
-
Petar Jovanovic authored
r306095 in LLVM has changed register positions for instruction aui. This change updates the test that checks for aui. llvm-svn: 306173
-
Yan Wang authored
Summary: The url in the doc is wrong. Fix the url. Reviewers: chh Reviewed By: chh Subscribers: srhines, xazax.hun Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D34573 llvm-svn: 306172
-
Reid Kleckner authored
We would return an error in getVaPtr if the RVA table being dumped was the last data in the .rdata section. Avoid the issue by subtracting one from the offset and adding it back to get an open interval again. llvm-svn: 306171
-
Geoff Berry authored
llvm-svn: 306170
-
Eugene Zelenko authored
[DebugInfo] Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes (NFC). llvm-svn: 306169
-
Lang Hames authored
llvm-svn: 306168
-
Zachary Turner authored
llvm-svn: 306167
-
Lang Hames authored
module type as std::shared_ptr<Module>. llvm-svn: 306166
-
Yan Wang authored
Summary: A common source of security bugs is code that opens a file descriptors without using the O_CLOEXEC flag. (Without that flag, an opened sensitive file would remain open across a fork+exec to a lower-privileged SELinux domain, leaking that sensitive data.). Add a new Android module and one checks in clang-tidy. -- open(), openat(), and open64() should include O_CLOEXEC in their flags argument. [android-file-open-flag] Links to part2 and part3: https://reviews.llvm.org/D33745 https://reviews.llvm.org/D33747 Reviewers: chh, alexfh, aaron.ballman, hokein Reviewed By: alexfh, hokein Subscribers: jbcoe, joerg, malcolm.parsons, Eugene.Zelenko, srhines, mgorny, xazax.hun, cfe-commits, krytarowski Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D33304 llvm-svn: 306165
-
Vedant Kumar authored
Differential Revision: https://reviews.llvm.org/D34298 llvm-svn: 306164
-
Vedant Kumar authored
This patch makes ubsan's nonnull return value diagnostics more precise, which makes the diagnostics more useful when there are multiple return statements in a function. Example: 1 |__attribute__((returns_nonnull)) char *foo() { 2 | if (...) { 3 | return expr_which_might_evaluate_to_null(); 4 | } else { 5 | return another_expr_which_might_evaluate_to_null(); 6 | } 7 |} // <- The current diagnostic always points here! runtime error: Null returned from Line 7, Column 2! With this patch, the diagnostic would point to either Line 3, Column 5 or Line 5, Column 5. This is done by emitting source location metadata for each return statement in a sanitized function. The runtime is passed a pointer to the appropriate metadata so that it can prepare and deduplicate reports. Compiler-rt patch (with more tests): https://reviews.llvm.org/D34298 Differential Revision: https://reviews.llvm.org/D34299 llvm-svn: 306163 -
Anna Thomas authored
This reverts commit r306157. It caused some timeouts in clang tests. Perhaps unreachable loops have far too many phi nodes. Reverting and investigating. llvm-svn: 306162
-
Vadzim Dambrouski authored
Summary: Change data layout string so it would be compatible with MSP430 EABI. Depends on D34561 Reviewers: asl, awygle Reviewed By: asl Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D34562 llvm-svn: 306161
-
Zachary Turner authored
llvm-svn: 306160
-
Vadzim Dambrouski authored
Summary: Without this patch some types have incorrect size and/or alignment according to the MSP430 EABI. Reviewers: asl, awygle Reviewed By: asl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D34561 llvm-svn: 306159
-
Nirav Dave authored
llvm-svn: 306158
-
Anna Thomas authored
Currently, the implementation of delete dead loops has a special case when the loop being deleted is never executed. This special case (updating of exit block's incoming values for phis) can be run as a prepass for non-executable loops before performing the actual deletion. llvm-svn: 306157
-
Erich Keane authored
llvm-svn: 306156
-
Craig Topper authored
[APInt] Make the single word cases of isMaxSignedValue/isMinSignedValue just compare with the expected value rather than counting bits. NFCI llvm-svn: 306155
-
Craig Topper authored
[APInt] Use trailing bit counting methods instead of population count method in isAllOnesValue, isMaxSigendValue, and isMinSignedValue. NFCI The trailing bit methods will early out if they find a bit of the opposite while popcount must always look at all bits. I also assume that more CPUs implement trailing bit counting with native instructions than population count. llvm-svn: 306154
-
Craig Topper authored
[APInt] Move the single word cases of countTrailingZeros and countLeadingOnes inline for consistency with countTrailingOnes and countLeadingZeros. NFCI llvm-svn: 306153
-
Craig Topper authored
llvm-svn: 306152
-
Craig Topper authored
[CorrelatedValuePropagation] Remove comment about iterating switch cases in reverse order. This is no longer being done after r298791. NFC llvm-svn: 306151
-
Zachary Turner authored
This is useful when you want to look at a specific chunk of a stream or look for discontinuities, and you need to know the list of blocks occupied by a stream. llvm-svn: 306150
-
Erich Keane authored
(possible implicit) noexcept specifier Throwing in the destructor is not good (C++11 change try to not allow see below). But in reality, those codes are exist. C++11 [class.dtor]p3: A declaration of a destructor that does not have an exception-specification is implicitly considered to have the same exception specification as an implicit declaration. With this change, the application worked before may now run into runtime termination. My goal here is to emit a warning to provide only possible info to where the code may need to be changed. First there is no way, in compile time to identify the “throw” really throw out of the function. Things like the call which throw out… To keep this simple, when “throw” is seen, checking its enclosing function(only destructor and dealloc functions) with noexcept(true) specifier emit warning. Here is implementation detail: A new member function CheckCXXThrowInNonThrowingFunc is added for class Sema in Sema.h. It is used in the call to both BuildCXXThrow and TransformCXXThrowExpr. The function basic check if the enclosing function with non-throwing noexcept specifer, if so emit warning for it. The example of warning message like: k1.cpp:18:3: warning: ''~dependent_warn'' has a (possible implicit) non-throwing noexcept specifier. Throwing exception may cause termination. [-Wthrow-in-dtor] throw 1; ^ k1.cpp:43:30: note: in instantiation of member function 'dependent_warn<noexcept_fun>::~dependent_warn' requested here dependent_warn<noexcept_fun> f; // cause warning Differential Revision: https://reviews.llvm.org/D33333 llvm-svn: 306149 -
Zachary Turner authored
This patch dumps the raw bytes of the pdb name map which contains the mapping of stream name to stream index for the string table and other reserved streams. llvm-svn: 306148
-
Brian Gesiak authored
Summary: opt-stats.py and opt-viewer.py's argument parsers both take a positional argument 'yaml_files'. Positional arguments in Python's argparse module are required by default, so the subsequent checks for `len(args.yaml_files) == 0` are unnecessary -- if the length was zero, then the call to `parser.parse_args()` would have thrown an error already. Because there is no way for `len(args.yaml_files)` to be zero at these points, removing the code is NFC. Reviewers: anemet, davidxl Reviewed By: anemet Subscribers: llvm-commits, fhahn Differential Revision: https://reviews.llvm.org/D34567 llvm-svn: 306147
-
Zachary Turner authored
Normally we can only make sense of the content of a PDB in terms of streams and blocks, but in some cases it may be useful to dump bytes at a specific absolute file offset. For example, if you know that some interesting data is at a particular location and you want to see some surrounding data. llvm-svn: 306146
-
Krzysztof Parzyszek authored
This breaks passing of aligned function arguments. llvm-svn: 306145
-