- May 03, 2023
-
-
Jean Perier authored
Lower vector subscripted designators as values when they appear outside of the assignment left-hand side and input IO contexts. This matches Fortran semantics where vector subscripted designators cannot be written to outside of the two contexts mentioned above: they are passed/taken by value where they appear. This patch uses the added hlfir.element_addr to lower vector designators in lowering. But when reaching the end of the designator lowering, the hlfir.element_addr is turned into an hlfir.elemental when lowering is not asking for the hlfir.elemental_addr. This approach allows lowering vector subscripted in the same way in while visiting the designator, and only adapt to the context at the edge. The part where lowering uses the hlfir.elemental_addr will be done in further patch as it requires lowering assignments in the new hlfir.region_assign op, and there is not codegen yet for these new operations. Differential Revision: https://reviews.llvm.org/D149480
-
Jean Perier authored
See the operation description in HLFIROps.td. Depends on D149442 Differential Revision: https://reviews.llvm.org/D149449
-
Jean Perier authored
hlfir.region_assign is a Region based version of hlfir.assign: the right-hand side and left-hand-side are evaluated in their own region, and an optional region can be added to implement user defined assignment. This will be used for: - assignments inside where and forall - user defined assignments - assignments to vector subscripted entities. Rational: Forall and Where lowering requires solving an expression/assignment evaluation scheduling problem based on data dependencies between the variables being assigned and the one used in the expressions. Keeping left-hand side and right-hand side in their own region will make it really easy to analyse the dependency and move around the expression evaluation as a whole. Operation DAGs are hard to scissor out when the LHS and RHS evaluation are lowered in the same block. The pass dealing with further forall/where lowering in HLFIR will need to succeed. It is not acceptable for them to fail splitting the RHS/LHS evaluation code. Keeping them in independent block is an approach that cannot fail. For user defined assignments, having a region allows implementing all the call details in lowering, and even to allow inlining of the user assignment, before it is decided if a temporary for the LHS or RHS is required or not. The operation description mention "hlfir.elemental_addr" (operation that will be used for vector subscripted LHS) and "ordered assignment trees" (concept/inetrface that will be used to represent forall/where structure in HLFIR). These will be pushed in follow-up patch, but I do not want t scissor out the descriptions. Differential Revision: https://reviews.llvm.org/D149442
-
pvanhout authored
Small split change from D146023. Migrate elf-notes to v4 and fix llvm-readobj to work with PAL metadata. Reviewed By: kzhuravl Differential Revision: https://reviews.llvm.org/D146119
-
Mehdi Amini authored
There was a discrepancy where the flag was honored when passed through the command line, but not when passed through the API, which was leading to a python test failing.
-
Martin Storsjö authored
This reverts commit 63f0fdc2. Since f1431bbf, this environment variable is always set up by lit itself, so individual test suites don't need to set it. Differential Revision: https://reviews.llvm.org/D149356
-
Siva Chandra Reddy authored
We previously used a more stricter -nostdlib option which was also removing compiler-rt/libgcc. Reviewed By: jhuber6 Differential Revision: https://reviews.llvm.org/D149683
-
Wenzhi Cui authored
llvm::CodeGen was missing so add them to deps Reviewed By: csigg Differential Revision: https://reviews.llvm.org/D149720
-
Mehdi Amini authored
Some mid-air collision between a change in the generic format and this new python test.
-
Kai Sasaki authored
Element-wise log(exp) does no operation so that we can fold it into no-op effectively. Reviewed By: eric-k256 Differential Revision: https://reviews.llvm.org/D149632
-
Fangrui Song authored
-
Craig Topper authored
We don't have i1 vector shuffle lowering.
-
Shengchen Kan authored
This reverts part of D149033 and rG8f966cedea594d9a91e585e88a80a42c04049e6c. The added test case is kept to avoid future regression. Reviewed By: vzakhari, vdonaldson Differential Revision: https://reviews.llvm.org/D149639
-
Mehdi Amini authored
This is part of an on-going migration to adopt Properties inside MLIR. Differential Revision: https://reviews.llvm.org/D148298
-
Mehdi Amini authored
This is part of an on-going migration to adopt Properties inside MLIR. Differential Revision: https://reviews.llvm.org/D148297
-
Mehdi Amini authored
This is part of an on-going migration to adopt Properties inside MLIR. Differential Revision: https://reviews.llvm.org/D148296
-
Zhouyi Zhou authored
In head comment of CurPPLexer field of class Preprocessor, 'The current top of the stack what we're lexing from' should be 'The current top of the stack that we're lexing from'. Differential Revision: https://reviews.llvm.org/D149709
-
Anshil Gandhi authored
Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D149568
-
Nico Weber authored
This should've been part of 8221c316.
-
Nico Weber authored
This adds all the CodeGen deps all over the place. I ran git show 9cfeba5b > foo2.txt to get the original patch into a text file and then ran #!/usr/bin/env python3 import os in_cmake = False for l in open('foo2.txt'): if l.startswith('+++ b/'): cmake = l[len('+++ b/'):-1] in_cmake = 'CMakeLists.txt' in cmake if not in_cmake: continue prefix = 'llvm/utils/gn/secondary/' gn_file = os.path.join(prefix, os.path.dirname(cmake), 'BUILD.gn') if l.startswith('+ '): add = l[1:].strip() if add == 'CodeGen': try: with open(gn_file) as f: contents = f.read() except: print(f'skipping {gn_file}') continue contents = contents.replace(' deps = [', ' deps = ["//llvm/lib/CodeGen",') with open(gn_file, 'w') as f: f.write(contents) to update all the GN files. (I manually removed the dep on CodeGen that this added to llvm-min-tblgen.) Finally, I ran git ls-files '*.gn' '*.gni' | xargs llvm/utils/gn/gn.py format to fix up the formatting.
-
Nico Weber authored
I ran: git ls-files '*.gn' '*.gni' | xargs llvm/utils/gn/gn.py format
-
Mingming Liu authored
instruction CSE'ed another. - This should be a part of D148877. Before that patch, !prof is not added to known-id-set [1], and turns out unknown types of metadata are dropped in the implementation [2]. - This test is mainly added to make sure there won't be regressions for this kind of pattern. The pattern is observed it in application code; looks like the result of indirect call is used as function arguments initially; after the function is inlined load-after-store CSE opportunity is exposed. [1] https://github.com/llvm/llvm-project/blob/f478721231bdb71ba8f0f6fb21673b9b7f652add/llvm/lib/Transforms/Utils/Local.cpp#L2727-L2741 [2] https://github.com/llvm/llvm-project/blob/ade3c6a6a88ed3a9b06c076406f196da9d3cc1b9/llvm/lib/Transforms/Utils/Local.cpp#L2639 Differential Revision: https://reviews.llvm.org/D149396
-
Mingming Liu authored
Differential Revision: https://reviews.llvm.org/D149390
-
Yeting Kuo authored
Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D149334
-
Alex Langford authored
As far as I can tell, this just computes the filename of the FileSpec, which is already conveniently stored in m_filename. We can use FileSpec::GetFilename() instead. Differential Revision: https://reviews.llvm.org/D149663
-
Alex Langford authored
FileSpec::GetFileNameExtension returns a StringRef. In some cases we are calling it and then storing the result in a local. To prevent cases where we store the StringRef, mutate the Filespec, and then try to use the stored StringRef afterwards, I've audited the callsites and made adjustments to mitigate: Either marking the FileSpec it comes from as const (to avoid mutations) or by not storing the StringRef in a local if it makes sense not to. Differential Revision: https://reviews.llvm.org/D149671
-
Nico Weber authored
Doesn't yet add all the CodeGen deps all over the place.
-
Nico Weber authored
-
Nico Weber authored
Apparently `\b` stopped working with --pickaxe-regex for some reason.
-
Nico Weber authored
-
Nico Weber authored
-
Joseph Huber authored
The `add_libc_test` option allows us to enable both kinds of tests in a single option. However, some tests cannot be made hermetic with the current approach. Such as tests that rely on system utilities or libraries. This patch adds two options `UNIT_TEST_ONLY` and `HERMETIC_TEST_ONLY` to offer more fine-grained control over which version gets built. This makes it explicit which version a test supports and why. Depends on D149662 Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D149691
-
Joseph Huber authored
This changes over the string unit tests to the new `add_libc_test` framework. The one test that wasn't changes was the memory utils because it overran the static buffer used for the hermetic test's bump pointer. Depends on D149656 Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D149662
-
Joseph Huber authored
Currently we use `assert` as a stand-in for the typical test assertions. This is because these functions exist outside of the base test class so we can't use the typical assertion methods. The presence of these asserts makes it difficult to compile these tests in a standalone format. This patch removes all occurrences. Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D149656
-
Muhammad Omair Javaid authored
This patch add or removes XFAIL decorator from various tests which were marked xfail for windows. since 44363f2f various tests have started passing but introduced a couple of new failures. Weight is in favor of new XPasses and I have removed XFail decorator from them. Also some new tests have started failing for which we need to file separate bugs. I have marked them xfail for now and will add the bug id after investigating the issue. Differential Revision: https://reviews.llvm.org/D149235
-
Matt Arsenault authored
If we know one operand is positive for maxnum, or one is negative for minnum, the result will have the same sign.
-
Nico Weber authored
-
Nick Desaulniers authored
This reverts commit c117c2c8. itaniumDemangle calls std::strlen with the results of std::string_view::data() which may not be NUL-terminated. This causes lld/test/wasm/why-extract.s to fail when "expensive checks" are enabled via -DLLVM_ENABLE_EXPENSIVE_CHECKS=ON. See D149675 for further discussion. Back this out until the individual demanglers are converted to use std::string_view.
-
Okwan Kwon authored
A func may not have a body. Differential Revision: https://reviews.llvm.org/D149688
-
Teresa Johnson authored
Now that the runtime tracks the lifetime access density directly, we can use that directly in the threshold checks instead of less accurately computing from other statistics. Differential Revision: https://reviews.llvm.org/D149684
-