-
Notifications
You must be signed in to change notification settings - Fork 790
LLVM pulldown #981
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
vladimirlaz
merged 3,521 commits into
intel:sycl
from
vladimirlaz:private/vlazarev/llvmspirv_pulldown
Dec 30, 2019
Merged
LLVM pulldown #981
vladimirlaz
merged 3,521 commits into
intel:sycl
from
vladimirlaz:private/vlazarev/llvmspirv_pulldown
Dec 30, 2019
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This is needed for calling the generator on a .td file that contains both OpInterface definitions and op definitions with DeclareOpInterfaceMethods<...> Traits. PiperOrigin-RevId: 285465784
This is more efficient, and allows for these to fire in more situations: e.g. createOrFold, DialectConversion, etc. PiperOrigin-RevId: 285476837
Make the declarative C++ builder API simpler to use so we can start chaining these ops together. PiperOrigin-RevId: 285496266
This removes a warning and fixes a potential ABI issue on Windows. PiperOrigin-RevId: 285502010
PiperOrigin-RevId: 285574334
- bring op description comment in sync with the doc - fix misformat in doc Signed-off-by: Uday Bondhugula <[email protected]> Closes tensorflow/mlir#317 COPYBARA_INTEGRATE_REVIEW=tensorflow/mlir#317 from bondhugula:quickfix 7fcd945b318c973b2488b702874c87526855c8ef PiperOrigin-RevId: 285574527
PiperOrigin-RevId: 285724678
…onvention During the conversion from the standard dialect to the LLVM dialect, memref-typed arguments are promoted from registers to memory and passed into functions by pointer. This had been introduced into the lowering to work around the abesnce of calling convention modeling in MLIR to enable better interoperability with LLVM IR generated from C, and has been exerciced for several months. Make this promotion the default calling covention when converting to the LLVM dialect. This adds the documentation, simplifies the code and makes the conversion consistent across function operations and function types used in other places, e.g. in high-order functions or attributes, which would not follow the same rule previously. PiperOrigin-RevId: 285751280
ExtractSlicesOp extracts slices of its vector operand and with a specified tiling scheme. This operation centralizes the tiling scheme around a single op, which simplifies vector op unrolling and subsequent pattern rewrite transformations. PiperOrigin-RevId: 285761129
…ring to LLVM Similar to insert/extract vector instructions but (1) work on 1-D vectors only (2) allow for a dynamic index %c3 = constant 3 : index %0 = vector.insertelement %arg0, %arg1[%c : index] : vector<4xf32> %1 = vector.extractelement %arg0[%c3 : index] : vector<4xf32> PiperOrigin-RevId: 285792205
PiperOrigin-RevId: 285799680
This PR targest issue tensorflow/mlir#295. It exposes the already existing subiew promotion pass as a declarative pattern Change-Id: If901ebef9fb53fcd0b12ecc536f6b174ce320b92 Closes tensorflow/mlir#315 COPYBARA_INTEGRATE_REVIEW=tensorflow/mlir#315 from tetuante:issue295 8e5f268b6d85f31015c33505329dbd7a4db97ac5 PiperOrigin-RevId: 285801463
The conversion from the Loops dialect to the Standard dialect, also known as loop-to-cfg lowering, has been historically a function pass. It can be required on non-Standard function Ops, in particular the recently introduced GPU functions. Make the conversion an operation pass instead of a function pass. PiperOrigin-RevId: 285814560
This keeps the IR valid and consistent as it is expected that each block should have a valid parent region/operation. Previously, converted blocks were kept floating without a valid parent region. PiperOrigin-RevId: 285821687
This updates the lowering pipelines from the GPU dialect to lower-level dialects (NVVM, SPIRV) to use the recently introduced gpu.func operation instead of a standard function annotated with an attribute. In particular, the kernel outlining is updated to produce gpu.func instead of std.func and the individual conversions are updated to consume gpu.funcs and disallow standard funcs after legalization, if necessary. The attribute "gpu.kernel" is preserved in the generic syntax, but can also be used with the custom syntax on gpu.funcs. The special kind of function for GPU allows one to use additional features such as memory attribution. PiperOrigin-RevId: 285822272
PiperOrigin-RevId: 285830394
This CL adds more Linalg EDSC ops and tests to support building pointwise operations along with conv and dilated_conv. This also fixes a bug in the existing linalg_matmul EDSC and beefs up the test. The current set of ops is already enough to build an interesting, albeit simple, model used internally. PiperOrigin-RevId: 285838012
PiperOrigin-RevId: 285849308
…csAttr. Scope and Memory Semantics attributes need to be serialized as a constant integer value and the <id> needs to be used to specify the value. Fix the auto-generated SPIR-V (de)serialization to handle this. PiperOrigin-RevId: 285849431
Some changes to the dialect generation script to allow specification of different base class to derive from in ODS. PiperOrigin-RevId: 285859230
… and InsertSlicesOp (instead of less structured chain of StridedSliceOps and InsertStridedSliceOps). PiperOrigin-RevId: 285968051
This is a general code cleanup and should be a NFC. PiperOrigin-RevId: 285972718
…according to the unrolling/slicing scheme of its ExtractSlicesOp user. PiperOrigin-RevId: 285975613
PiperOrigin-RevId: 285982330
This class provides a simplified mechanism for defining a switch over a set of types using llvm casting functionality. More specifically, this allows for defining a switch over a value of type T where each case corresponds to a type(CaseT) that can be used with dyn_cast<CaseT>(...). An example is shown below: // Traditional piece of code: Operation *op = ...; if (auto constant = dyn_cast<ConstantOp>(op)) ...; else if (auto return = dyn_cast<ReturnOp>(op)) ...; else ...; // New piece of code: Operation *op = ...; TypeSwitch<Operation *>(op) .Case<ConstantOp>([](ConstantOp constant) { ... }) .Case<ReturnOp>([](ReturnOp return) { ... }) .Default([](Operation *op) { ... }); Aside from the above, TypeSwitch supports return values, void return, multiple types per case, etc. The usability is intended to be very similar to StringSwitch. (Using c++14 template lambdas makes everything even nicer) More complex example of how this makes certain things easier: LogicalResult process(Constant op); LogicalResult process(ReturnOp op); LogicalResult process(FuncOp op); TypeSwitch<Operation *, LogicalResult>(op) .Case<ConstantOp, ReturnOp, FuncOp>([](auto op) { return process(op); }) .Default([](Operation *op) { return op->emitError() << "could not be processed"; }); PiperOrigin-RevId: 286003613
[{ matched with }], rather than ]} Closes tensorflow/mlir#320 COPYBARA_INTEGRATE_REVIEW=tensorflow/mlir#320 from jinmingjian:patch-1 6b0870d02284f023bda2b28380960eb31d34f3b6 PiperOrigin-RevId: 286007638
User(TupleGetOp(ExtractSlicesOp(InsertSlicesOp(TupleOp(Producer))) -> User(Producer) PiperOrigin-RevId: 286020249
The conversion procedure has been updated to reflect the most recent MemRef descriptor proposal, but the documentation was only updated for the type conversion, omitting the address computation section. Make sure the two sections agree. PiperOrigin-RevId: 286022684
This function has become redundant with MemRefDescriptor::getElementType and is no longer necessary. Use the MemRefDescriptor pervasively to concentrate descriptor-related logic in one place and drop the utility function. PiperOrigin-RevId: 286024168
The syntax for LLVM dialect types changed twice since this document was introduced. First, the quoted types are only prefixed with the dialect name `!llvm` rather than with `!llvm.type`. Second, for types that are simple enough (e.g., MLIR identifiers), the pretty form can be used instead of the quoted form. The relevant commits updated the dialect documentation, but not the conversion documentation. Use the valid type names in the conversion documentation. PiperOrigin-RevId: 286026153
This adds --strict-whitespace --match-full-lines flags to improve the testing and reveal formatting issues we have. Differential revision: https://reviews.llvm.org/D71895
…ed to v4i32->v4f32 under avx512. With avx512vl we get v4i32->v4f32 uint_to_fp instructions. With avx512f we get v16i32->v16f32 instructions which we can use to emulate v4i32->v4f32.
I accidentally broke formatting in the previous revision.
Summary: `mlir-translate -import-llvm test.ll` was going into segmentation fault if `test.ll` had `float` or `double` constants. For example, ``` %3 = fadd double 3.030000e+01, %0 ``` Now, it is handled in `Importer::getConstantAsAttr` (similar behaviour as normal integers) Added tests for FP arithmetic Reviewers: ftynse, mehdi_amini Reviewed By: ftynse, mehdi_amini Subscribers: shauheen, mehdi_amini, rriddle, jpienaar, burmako, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71912
Summary: Fix this warning: ` [69/106] Building CXX object tools/mlir/lib/Dialect/StandardOps/CMakeFiles/MLIRStandardOps.dir/Ops.cpp.o /home/uday/llvm-project/mlir/lib/Dialect/StandardOps/Ops.cpp: In member function ‘virtual mlir::PatternMatchResult {anonymous}::ViewOpShapeFolder::matchAndRewrite(mlir::ViewOp, mlir::PatternRewriter&) const’: /home/uday/llvm-project/mlir/lib/Dialect/StandardOps/Ops.cpp:2575:14: warning: variable ‘dynamicOffsetOperandCount’ set but not used [-Wunused-but-set-variable] 2575 | unsigned dynamicOffsetOperandCount = 0; ` Reviewers: rriddle, mehdi_amini, ftynse Reviewed By: ftynse Subscribers: jpienaar, burmako, shauheen, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71922
Trivial patch, reviewed and accepted on tensorflow/mlir#336 before MLIR merge.
This patch adds skipif decorator to TestWatchLocationWithWatchSet.py. Decorator will trigger for aarch64-linux as this test passes randomly causing buildbot failure.
Add printing of __private address space to TypePrinter to allow it appears in diagnostics and AST dumps as all other language addr spaces. Tags: #clang Differential Revision: https://reviews.llvm.org/D71272
There ended up being two result registers, which would fail on select. It was really defing a new temp register in the correct def position, instead of the correct result register.
Summary: This commit updates links to SPIR-V dialect code to LLVM monorepo on GitHub. It also points to the operation doc on mlir.llvm.org. Reviewers: mravishankar, denis13, ftynse Reviewed By: ftynse Subscribers: merge_guards_bot, mehdi_amini, rriddle, jpienaar, burmako, shauheen, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71926
Including two tests These callbacks were added late to the 5.0 specification, an implementation is missing. Reviewed By: jdoerfert Differential Review: https://reviews.llvm.org/D70395
…cript Summary: [DA] Move common code in checkSrcSubscript and checkDstSubscript to a new function checkSubscript. This avoids duplicate code and possible out of sync in the future. Reviewers: sebpop, jmolloy, reames Reviewed By: sebpop Subscribers: bmahjour, hiraditya, llvm-commits, amehsan Tags: #llvm Differential Revision: https://reviews.llvm.org/D71087 Patch by zhongduo.
Reviewers: aaron.ballman Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D71842
CONFLICT (content): Merge conflict in clang/lib/AST/TypePrinter.cpp
This patch extends the current shape propagation and shape aware lowering to also support binary operators. Those operators are uniform with respect to their shape (shape of the input operands is the same as the shape of their result). Reviewers: anemet, Gerolf, reames, hfinkel, andrew.w.kaylor Reviewed By: anemet Differential Revision: https://reviews.llvm.org/D70898
There is some inconsistency between opencl and c11 atomic fetch max/min after https://reviews.llvm.org/D46386 https://reviews.llvm.org/D55562 It is not reasonable to have such inconsistencies. This patch fixes that. Differential Revision: https://reviews.llvm.org/D71725
We returning a full set, we should use ResultBitWidth. Otherwise we might it assertions when the resulting constant ranges are used later on. Reviewers: nikic, spatel, reames Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D71937
Summary: Add support for NetBSD 9.0 and newer versions of interceptors operating on struct statvfs: fstatvfs, fstatvfs1, getmntinfo, getvfsstat, statvfs, statvfs1. The default promoted interceptors are for NetBSD 9.99.26. Older ones (currently 9.0) are kept in a new NetBSD specific file: /sanitizer_common_interceptors_netbsd_compat.inc. This file defines compat interceptors and mangles `INIT_*` macros, concatenating the current interceptors and the compat ones. This redefinition is not elegant, but it avoids preprocessor madness. Define struct_statvfs90_sz for the compat purposes. Reviewers: mgorny, kcc, vitalybuka, joerg Reviewed By: mgorny Subscribers: dberris, llvm-commits, #sanitizers Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D71700
This test was XFAILed because of symlinks, but some versions of ln -s seem to work on Windows, so the test was unexpectedly passing on our bot: http://lab.llvm.org:8011/builders/clang-x64-windows-msvc/builds/13233 Unexpected Passing Tests (1): Clang :: VFS/subframework-symlink.m I don't know how or why, but it seems dependent on system configuration, and is not something worth debugging. Avoid the problem by marking the test UNSUPPORTED: system-windows instead of XFAIL: system-windows.
CONFLICT (content): Merge conflict in clang/test/VFS/subframework-symlink.m
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.