- Feb 05, 2020
-
-
Tyker authored
-
Craig Topper authored
This time with correct types for the data result from the SUB. Original commit message: Our normal lowering for ISD::SETCC uses X86ISD::SUB to enable CSE unless the RHS is 0. optimizeCompareInstr called by the peephole pass can turn subs with unused results into cmps to clean this up. This commit makes other places that create X86ISD::CMP have the same behavior.
-
River Riddle authored
This allows for reusing the internal state of the printer, which is more efficient and also allows for using type aliases
-
Teresa Johnson authored
Summary: It can be useful to tune the default inline threshold without overriding other inlining thresholds (e.g. in code compiled for size). The existing `-inline-threshold` flag overrides other thresholds, so it is insufficient in codebases where there is a mix of code compiled for size and speed. Patch by Michael Holman <michael.holman@microsoft.com> Reviewers: eraman, tejohnson Reviewed By: tejohnson Subscribers: tejohnson, mtrofin, davidxl, hiraditya, haicheng, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D73217
-
Matt Arsenault authored
-
Matt Arsenault authored
-
Paula Toth authored
Reviewers: sivachandra, abrachet Reviewed By: sivachandra, abrachet Subscribers: libc-commits, MaskRay, tschuett Tags: #libc-project, #llvm Differential Revision: https://reviews.llvm.org/D72248
-
Tyker authored
Summary: Changes: - Calls to consteval function are now evaluated in constant context but IR is still generated for them. - Add diagnostic for taking address of a consteval function in non-constexpr context. - Add diagnostic for address of consteval function accessible at runtime. - Add tests Reviewers: rsmith, aaron.ballman Reviewed By: rsmith Subscribers: mgrang, riccibruno, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D63960
-
Aaron Watry authored
Fixes a wimpy-mode CTS failure for asin(float). Passes non-wimpy for both float/double on RX580. Signed-off-by:
Aaron Watry <awatry@gmail.com> Tested-by:
Jan Vesely <jan.vesely@rutgers.edu> Reviewed-by:
Jan Vesely <jan.vesely@rutgers.edu>
-
Matt Arsenault authored
shouldOptimizeForSize is showing up in a profile, spending around 10% of the pass time in one function. This should probably not be so slow, but the much cheaper attribute check should be done first anyway.
-
aartbik authored
Summary: A few details were missing in the description. These changes makes the documented code "compile". Reviewers: nicolasvasilache, andydavis1 Reviewed By: nicolasvasilache, andydavis1 Subscribers: merge_guards_bot, mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, Joonsoo, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D73923
-
Jonathan Coe authored
Summary: Add comments to the list of tokens that can follow the ']' at the end of a C# attribute specifier to prevent comments after attribute specifiers from being formatted as continuations. Reviewers: MyDeveloperDay, krasimir Reviewed By: MyDeveloperDay Tags: #clang-format Differential Revision: https://reviews.llvm.org/D73977
-
Matt Arsenault authored
Prepare to accurately track the future denormal-fp-math attribute changes. The way to actually set these separately is not wired in yet. This is just a mechanical change, and mostly still assumes the input and output mode match. This should be refined for some cases. For example, fcanonicalize lowering should use the flushing variant if either input or output flushing is enabled
-
Vedant Kumar authored
-
Vedant Kumar authored
In order to synthesize tail call frames, the stack frame list must not be empty (otherwise, there is no "previous" frame to infer a tail call from). This case is hard to hit. To trigger it, we must first fail to push `unwind_frame_sp` because we either fail to get its SymbolContext, or given its SymbolContext the GetParentOfInlineScope call fails. This causes m_concrete_frames_fetched to be incremented while m_frames remains empty. Then, the next frame in the stack may fail within SynthesizeTailCallFrames. This crash arose during a kernel debugging session. rdar://59147051
-
Jacques Pienaar authored
-
Fangrui Song authored
Make usage more consistent, and make it possible to enable LongOptionsUseDoubleDash.
-
Matt Arsenault authored
The usage of the Imm out argument from SelectSMRDOffset is pretty confusing. Stop trying to reject CI immediates in the case where the offset field can be used. It's not an illegal way to encode the immediate, so just prefer the better encoding pattern with AddedComplexity. We probably don't even really need the different opcodes for the different offset types anymore, but that will be more work to cleanup. The SMRD non-buffer load patterns could also use a cleanup to be done separately.
-
Matt Arsenault authored
-
Simon Pilgrim authored
We weren't account for load latencies in the SSE42/AES/CLMUL schedule classes
-
Matt Arsenault authored
-
Yitzhak Mandelbaum authored
Summary: Spells out some `auto`s explicitly and adds another test for the matcher `isExpandedFromMacro`. Reviewers: aaron.ballman Subscribers: gribozavr, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D73975
-
Hiroshi Yamauchi authored
Summary: Add a debug check for frequency queries for unknown blocks (typically blocks that are created after BFI is computed but their frequencies are not communicated to BFI.) This is useful for detecting and debugging missed BFI updates. This is debug build only and disabled behind a flag. Reviewers: davidxl Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D73920
-
Sanjay Patel authored
Existing tests: rG5d04e008 rG2a191cf8 ...should verify that the underlying analysis doesn't improve too much without updating this user code.
-
Matt Arsenault authored
AMDGPU and x86 at least both have separate controls for whether denormal results are flushed on output, and for whether denormals are implicitly treated as 0 as an input. The current DAGCombiner use only really cares about the input treatment of denormals.
-
Stephen Neuendorffer authored
-
Fangrui Song authored
Similar to D73680 (AArch64 BTI). A local linkage function whose address is not taken does not need ENDBR32/ENDBR64. Placing the patch label after ENDBR32/ENDBR64 has the advantage that code does not need to differentiate whether the function has an initial ENDBR. Also, add 32-bit tests and test that .cfi_startproc is at the function entry. The line information has a general implementation and is tested by AArch64/patchable-function-entry-empty.mir Reviewed By: nickdesaulniers Differential Revision: https://reviews.llvm.org/D73760
-
Fangrui Song authored
Reviewed By: hans Differential Revision: https://reviews.llvm.org/D73937
-
David Spickett authored
Differential Revision: https://reviews.llvm.org/D73972
-
Peter Collingbourne authored
By subtracting 1 from Size at the beginning we can simplify the subsequent calculations. This also saves 4 instructions on aarch64 and 9 instructions on x86_64, but seems to be perf neutral. Differential Revision: https://reviews.llvm.org/D73936
-
Yonghong Song authored
Linux commit https://github.com/torvalds/linux/commit/1cf5b23988ea0086a252a5c8b005b075f1e9b030#diff-289313b9fec99c6f0acfea19d9cfd949 uses "#pragma clang attribute push (__attribute__((preserve_access_index)), apply_to = record)" to apply CO-RE relocations to all records including the following pattern: #pragma clang attribute push (__attribute__((preserve_access_index)), apply_to = record) typedef struct { int a; } __t; #pragma clang attribute pop int test(__t *arg) { return arg->a; } The current approach to use struct type in the relocation record will result in an anonymous struct, which make later type matching difficult in bpf loader. In fact, current BPF backend will fail the above program with assertion: clang: ../lib/Target/BPF/BPFAbstractMemberAccess.cpp:796: ... Assertion `TypeName.size()' failed. The patch use the base lvalue type for the "base" value to annotate preservee_{struct,union}_access_index intrinsics. In the above example, the type will be "__t" which preserved the type name. Differential Revision: https://reviews.llvm.org/D73900
-
Cameron McInally authored
Fix incorrect spacing for `denormal-fp-math` and `denormal-fp-math-f32`. No other changes.
-
Stephen Neuendorffer authored
Summary: This patch is a step towards enabling BUILD_SHARED_LIBS=on, which builds most libraries as DLLs instead of statically linked libraries. The main effect of this is that incremental build times are greatly reduced, since usually only one library need be relinked in response to isolated code changes. The bulk of this patch is fixing incorrect usage of cmake, where library dependencies are listed under add_dependencies rather than under target_link_libraries or under the LINK_LIBS tag. Correct usage should be like this: add_dependencies(MLIRfoo MLIRfooIncGen) target_link_libraries(MLIRfoo MLIRlib1 MLIRlib2) A separate issue is that in cmake, dependencies between static libraries are automatically included in dependencies. In the above example, if MLIBlib1 depends on MLIRlib2, then it is sufficient to have only MLIRlib1 in the target_link_libraries. When compiling with shared libraries, it is necessary to have both MLIRlib1 and MLIRlib2 specified if MLIRfoo uses symbols from both. Reviewers: mravishankar, antiagainst, nicolasvasilache, vchuravy, inouehrs, mehdi_amini, jdoerfert Reviewed By: nicolasvasilache, mehdi_amini Subscribers: Joonsoo, merge_guards_bot, jholewinski, mgorny, mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, csigg, arpith-jacob, mgester, lucyrfox, herhut, aartbik, liufengdb, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D73653
-
Yonghong Song authored
Linux commit https://github.com/torvalds/linux/commit/1cf5b23988ea0086a252a5c8b005b075f1e9b030#diff-289313b9fec99c6f0acfea19d9cfd949 uses "#pragma clang attribute push (__attribute__((preserve_access_index)), apply_to = record)" to apply CO-RE relocations to all records including the following pattern: #pragma clang attribute push (__attribute__((preserve_access_index)), apply_to = record) typedef struct { int a; } __t; #pragma clang attribute pop int test(__t *arg) { return arg->a; } The current approach to use struct/union type in the relocation record will result in an anonymous struct, which make later type matching difficult in bpf loader. In fact, current BPF backend will fail the above program with assertion: clang: ../lib/Target/BPF/BPFAbstractMemberAccess.cpp:796: ... Assertion `TypeName.size()' failed. clang will change to use the type of the base of the member access which will preserve the typedef modifier for the preserve_{struct,union}_access_index intrinsics in the above example. Here we adjust BPF backend to accept that the debuginfo type metadata may be 'typedef' and handle them properly. Differential Revision: https://reviews.llvm.org/D73902
-
Yitzhak Mandelbaum authored
Summary: This revision adds a matcher `isExpandedFromMacro` that determines whether a statement is (transitively) expanded from a given macro. Reviewers: gribozavr Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D73965
-
Justin Hibbits authored
rG2c4620ad inadvertently added redundancies in selection of GT and LE predicates for SPE. Correct this. Partially addresses PR 44768.
-
David Spickett authored
Differential Revision: https://reviews.llvm.org/D73469
-
Sam McCall authored
Summary: This is a fairly ugly hack - we back off several features for any variable whose type isn't deduced, to avoid computing/caching linkage. Better suggestions welcome. Fixes https://github.com/clangd/clangd/issues/274 Reviewers: kadircet, kbobyrev Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D73960
-
Sam McCall authored
This reverts commit ed98994f. Removed the accidental double-mutex-unlock.
-
Kazushi (Jam) Marukawa authored
Summary: fp16 (half) load+fpext and fptrunc+store isel legalization and tests. Also, ExternalSymbolSDNode operand printing (tested by fp16 lowering). Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D73899
-