- Feb 18, 2021
-
-
Fraser Cormack authored
This patch fixes a codegen crash introduced in fde24661, where the DAGCombiner started generating optimized MULH[SU] or [SU]MUL_LOHI nodes unless the target opted out. The AArch64 backend cannot currently select any of these nodes, so ensure that they are not generated in the first place. This issue was raised by @huihuiz in D94501. Reviewed By: paulwalker-arm Differential Revision: https://reviews.llvm.org/D96849
-
Djordje Todorovic authored
This reverts rG8ee7c7e0. One test is failing, I'll reland this as soon as possible.
-
Alex Hoppen authored
As suggested by Nico in https://reviews.llvm.org/D96049, move check for libproc from CMakeLists to config-ix.cmake Reviewed By: thakis Differential Revision: https://reviews.llvm.org/D96713 Note: Also removes the CMAKE_REQUIRED_LIBRARIES which doesn't appear to be necessary.
-
Djordje Todorovic authored
As discussed on the RFC [0], I am sharing the set of patches that enables checking of original Debug Info metadata preservation in optimizations. The proof-of-concept/proposal can be found at [1]. The implementation from the [1] was full of duplicated code, so this set of patches tries to merge this approach into the existing debugify utility. For example, the utility pass in the original-debuginfo-check mode could be invoked as follows: $ opt -verify-debuginfo-preserve -pass-to-test sample.ll Since this is very initial stage of the implementation, there is a space for improvements such as: - Add support for the new pass manager - Add support for metadata other than DILocations and DISubprograms [0] https://groups.google.com/forum/#!msg/llvm-dev/QOyF-38YPlE/G213uiuwCAAJ [1] https://github.com/djolertrk/llvm-di-checker Differential Revision: https://reviews.llvm.org/D82545
-
Chen Zheng authored
This patch makes StorageMappingClass/SymbolType member optional in class MCSectionXCOFF. Non-csect sections like debug sections have no such properties. Reviewed By: hubert.reinterpretcast Differential Revision: https://reviews.llvm.org/D96641
-
Haojian Wu authored
OpaqueValueExpr doesn't correspond to the concrete syntax, it has invalid source location, ignore them. Reviewed By: kbobyrev Differential Revision: https://reviews.llvm.org/D96112
-
Yang Fan authored
GCC warning: ``` [3397/3703] Building CXX object tools/llvm-profgen/CMakeFiles/llvm-profgen.dir/llvm-profgen.cpp.o In file included from /llvm-project/llvm/include/llvm/ADT/STLExtras.h:19, from /llvm-project/llvm/include/llvm/ADT/StringRef.h:12, from /llvm-project/llvm/include/llvm/ADT/Twine.h:13, from /llvm-project/llvm/tools/llvm-profgen/ErrorHandling.h:12, from /llvm-project/llvm/tools/llvm-profgen/llvm-profgen.cpp:13: /llvm-project/llvm/include/llvm/ADT/Optional.h: In instantiation of ‘void llvm::optional_detail::OptionalStorage<T, <anonymous> >::emplace(Args&& ...) [with Args = {const std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, llvm::sampleprof::LineLocation>}; T = const std::pair<std::__cxx11::basic_string<char>, llvm::sampleprof::LineLocation>; bool <anonymous> = false]’: /llvm-project/llvm/include/llvm/ADT/Optional.h:79:7: ... -
Alex Zinenko authored
The functions translating enums to LLVM IR are generated in a single file included in many places, not all of which use all translations. Generate functions with "unused" attribute to silence compiler warnings. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D96880
-
Juneyoung Lee authored
-
Andy Wingo authored
For relocatable output that needs the indirect function table, identify the well-known function table. This allows us to properly fix the limits on the imported table, and in a followup will allow the element section to reference the indirect function table even if it's not assigned to table number 0. Adapt tests for import reordering. Differential Revision: https://reviews.llvm.org/D96770
-
Andy Wingo authored
Before, --importTable forced the creation of an indirect function table, whether it was needed or not. Now it only imports a table if needed. Differential Revision: https://reviews.llvm.org/D96872
-
Raphael Isemann authored
[lldb][NFC] Silence missing case warnings in TypeSystemClang::GetTypeBitAlign due to new RISC-V V types Those types were added in D92715. This just silences the warning but doesn't actually add support for those types to LLDB.
-
Kazu Hirata authored
-
Kazu Hirata authored
This patch eliminates pesky "No newline at end of file" messages from git diff.
-
Kazu Hirata authored
-
Jason Molenda authored
Add a new state for UnwindPlan::Row which indicates that any register not listed is not defined, and should not be found in stack frames newer than this one and passed up the stack. Mostly intended for use with architectural default unwind plans that are used for jitted stack frames, where we have no unwind information or start address. lldb has no way to tell if registers were spilled in the jitted frame & overwritten, so passing register values up the stack is not safe to show the user. Architectural default unwind plans are also used as a fast unwind plan on x86_64 in particular, and are used as the fallback unwind plans when lldb thinks it may be able to work around a problem which causes the unwinder to stop walking the stack early. For fast unwind plans, when we don't find a register location in the arch default unwind plan, we fall back to computing & using the full unwind plan. One small part of this patch is to know that a register marked as Undefined in the fast unwind plan is a special case, and we should continue on to the full unwind plan to find what the real unwind rule is for this register. Differential Revision: https://reviews.llvm.org/D96829 <rdar://problem/70398009>
-
Fangrui Song authored
To make a kind of metadata section usage work, we want to drop the `__start_/__stop_ references retain C identifier name sections` rule from LLD (see D96914). If an application has no `__llvm_prf_data` input section surviving --gc-sections, LLD will error for undefined hidden `{__start_,__stop_}__llvm_prf_*` from `libclang_rt.profile-*`. Other `__llvm_prf_*` sections have similar issues. Making the references weak can address the problem. This probably enables the opportunity to drop zero size dummy sections in `InstrProfilingPlatformLinux.c`. Reviewed By: davidxl Differential Revision: https://reviews.llvm.org/D96936 -
Fangrui Song authored
ST_Data is used to model BFD `BFD_OBJECT`. A STT_TLS symbol does not have the `BFD_OBJECT` flag in BFD. This makes sense because a STT_TLS symbol is like in a different address space, normal data/object properties do not apply on them. With this change, a STT_TLS symbol will not be displayed as 'O'. This new behavior matches objdump. Differential Revision: https://reviews.llvm.org/D96735
-
Martin Storsjö authored
The root_path function has to be changed to return the parsed bit as-is; otherwise a path like "//net" gets a root path of "//net/", as the root name, "//net", gets the root directory (an empty string) appended, forming "//net/". (The same doesn't happen for the root dir "c:" though.) Differential Revision: https://reviews.llvm.org/D91178
-
Yang Fan authored
GCC warning: ``` /llvm-project/llvm/lib/MC/ELFObjectWriter.cpp: In member function ‘uint64_t {anonymous}::ELFWriter::writeObject(llvm::MCAssembler&, const llvm::MCAsmLayout&)’: /llvm-project/llvm/lib/MC/ELFObjectWriter.cpp:1137:38: warning: enumeral and non-enumeral type in conditional expression [-Wextra] 1137 | write(uint32_t(Group->isComdat() ? ELF::GRP_COMDAT : 0)); | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~ ``` -
Stanislav Mekhanoshin authored
Remove hsa-gfx90a-v3.s until D95638. It unexpectedly passes on s390x.
-
Yang Fan authored
GCC warning: ``` /llvm-project/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp: In member function ‘virtual llvm::MCSection* llvm::TargetLoweringObjectFileELF::getSectionForLSDA(const llvm::Function&, const llvm::MCSymbol&, const llvm::TargetMachine&) const’: /llvm-project/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp:871:8: warning: variable ‘IsComdat’ set but not used [-Wunused-but-set-variable] 871 | bool IsComdat = false; | ^~~~~~~~ ``` -
Vitaly Buka authored
-
Wang, Pengfei authored
Zero AMX config buffer for non AVX512 cases. Differential Revision: https://reviews.llvm.org/D96927
-
Fangrui Song authored
sys/cdefs.h is a glibc internal header which is not supposed to be included by applications. (Some libc implementations provide this file for compatibility.) Android features.h includes sys/cdefs.h, so we can include features.h instead. This change makes `ninja gwp_asan` build on musl.
-
Mehdi Chinoune authored
Reviewed By: Meinersbur Differential Revision: https://reviews.llvm.org/D94707
-
Igor Kudrin authored
This fixes an issue when "-gdwarf-N" switch was ignored if it was given before another debug option. Differential Revision: https://reviews.llvm.org/D96865
-
Wang, Pengfei authored
-
Craig Topper authored
The type legalizer can call this code based on the scalar type so we need to verify the vector type is a scalable vector. I think due to how type legalization visits nodes, the vector type will have already been legalized so we don't have an issue with using MVT here like we did for EXTRACT_VECTOR_ELT. I've added a test just in case.
-
Fangrui Song authored
D14468 added these dummy sections. This patch adds `__attribute__((used))` so that when compiled by GCC>=11 or (expected, D96838) Clang>=13 on some ELF platforms, these sections will get SHF_GNU_RETAIN to make sure they will not be discarded by ld --gc-sections. We are trying to get rid of LLD's "__start_/__stop_ references retain C identifier name sections" rule. If LLD drops the rule in the future (we will retain compatibility for `__llvm_prf_*` for a while), `__llvm_prf_*` will need to have the SHF_GNU_RETAIN flag, otherwise: ``` // __llvm_prf_cnts/__llvm_prf_data usually exist, but {names,vnds} may not exist. // Such diagnostics will happen with {cnts,data} as well if no input object file is instrumented. % clang++ -fprofile-generate a.cc -fuse-ld=lld -Wl,--gc-sections ld.lld: error: undefined hidden symbol: __start___llvm_prf_names >>> referenced by InstrProfilingPlatformLinux.c >>> InstrProfilingPlatformLinux.c.o:(__llvm_profile_begin_names) in archive /tmp/RelA/lib/clang/13.0.0/lib/linux/libclang_rt.profile-x86_64.a ... ``` Differential Revision: https://reviews.llvm.org/D96902 -
Joseph Huber authored
Floating point conversions inside vectorized loops have performance implications but are very subtle. The user could specify a floating point constant, or call a function without realizing that it will force a change in the vector width. An example of this behaviour is seen in https://godbolt.org/z/M3nT6c . The vectorizer should indicate when this happens becuase it is most likely unintended behaviour. This patch adds a simple check for this behaviour by following floating point stores in the original loop and checking if a floating point conversion operation occurs. Reviewed By: fhahn Differential Revision: https://reviews.llvm.org/D95539
-
Craig Topper authored
[RISCV] Guard the ISD::EXTRACT_VECTOR_ELT handling in ReplaceNodeResults against fixed vectors and non-MVT types. The type legalizer is calling this code based on the scalar type so we need to verify the input type is a scalable vector. The vector type has also not been legalized yet when this is called so we need to use EVT for it.
-
Aart Bik authored
Rationale: Narrower types for overhead storage yield a smaller memory footprint for sparse tensors and thus needs to be supported. Also, more value types need to be supported to deal with all kinds of kernels. Since the "one-size-fits-all" sparse storage scheme implementation is used instead of actual codegen, the library needs to be able to support all combinations of desired types. With some crafty templating and overloading, the actual code for this is kept reasonably sized though. Reviewed By: bixia Differential Revision: https://reviews.llvm.org/D96819
-
Hsiangkai Wang authored
Add the types for the RISC-V V extension builtins. These types will be used by the RISC-V V intrinsics which require types of the form <vscale x 1 x i64>(LMUL=1 element size=64) or <vscale x 4 x i32>(LMUL=2 element size=32), etc. The vector_size attribute does not work for us as it doesn't create a scalable vector type. We want these types to be opaque and have no operators defined for them. We want them to be sizeless. This makes them similar to the ARM SVE builtin types. But we will have quite a bit more types. This patch adds around 60. Later patches will add another 230 or so types representing tuples of these types similar to the x2/x3/x4 types in ARM SVE. But with extra complexity that these types are combined with the LMUL concept that is unique to RISCV. For more background see this RFC http://lists.llvm.org/pipermail/llvm-dev/2020-October/145850.html Authored-by:
Roger Ferrer Ibanez <roger.ferrer@bsc.es> Co-Authored-by:
Hsiangkai Wang <kai.wang@sifive.com> Differential Revision: https://reviews.llvm.org/D92715
-
Stanislav Mekhanoshin authored
LoadStoreOptimizer was using uninitialized SCC value for instructions where it is unsupported.
-
Eric Schweitz authored
Differential Revision: https://reviews.llvm.org/D96912
-
Chen Zheng authored
We are going to support debug sections for XCOFF. So the csect properties are not necessary. This patch makes these properties optional. Reviewed By: hubert.reinterpretcast Differential Revision: https://reviews.llvm.org/D95931
-
Eric Schweitz authored
Differential Revision: https://reviews.llvm.org/D96908
-
Marco Vanotti authored
This change adds support for the dwarf PC register column in arm64, allowing CFI directives to make use of it. As of the last revision of the DWARF for ARM 64-bit architecture[0], the pc register has been added as a valir register, with number 32. This allows libunwinder to restore both pc and lr, which is useful for stack switches and signal contexts. [0]: https://github.com/ARM-software/abi-aa/blob/f52e1ad3f81254497a83578dc102f6aac89e52d0/aadwarf64/aadwarf64.rst Reviewed By: phosek, #libunwind Differential Revision: https://reviews.llvm.org/D96901
-
Joerg Sonnenberger authored
This matches the platform default for GCC. It primarily matters when the integrated assembler is not used as there is no default CPU defined for ARMv7-A and GNU as is upset with -mcpu=generic.
-