summaryrefslogtreecommitdiffstats
path: root/llvm/utils
Commit message (Collapse)AuthorAgeFilesLines
* Re-apply r286384, "X86: Introduce the "relocImm" ComplexPattern, which ↵Peter Collingbourne2016-11-093-7/+13
| | | | | | | | | represents a relocatable immediate.", with a fix for 32-bit x86. Teach X86InstrInfo::analyzeCompare() not to crash on CMP and SUB instructions that take a global address operand. llvm-svn: 286420
* Revert r286384, "X86: Introduce the "relocImm" ComplexPattern, which ↵Peter Collingbourne2016-11-093-13/+7
| | | | | | | | | represents a relocatable immediate." Suspected to be the cause of a sanitizer-windows bot failure: Assertion failed: isImm() && "Wrong MachineOperand accessor", file C:\b\slave\sanitizer-windows\llvm\include\llvm/CodeGen/MachineOperand.h, line 420 llvm-svn: 286385
* X86: Introduce the "relocImm" ComplexPattern, which represents a relocatable ↵Peter Collingbourne2016-11-093-7/+13
| | | | | | | | | | | | | | | immediate. A relocatable immediate is either an immediate operand or an operand that can be relocated by the linker to an immediate, such as a regular symbol in non-PIC code. Start using relocImm for 32-bit and 64-bit MOV instructions, and for operands of type "imm32_su". Remove a number of now-redundant patterns. Differential Revision: https://reviews.llvm.org/D25812 llvm-svn: 286384
* [opt-viewer] Avoid division by zeroAdam Nemet2016-11-071-1/+1
| | | | llvm-svn: 286172
* [OptDiag, opt-viewer] Save callee's location and display as linkAdam Nemet2016-11-071-8/+24
| | | | | | | | | | | | | With this we get a new field in the YAML record if the value being streamed out has a debug location. For examples, please see the changes to the tests. This is then used in opt-viewer to display a link for the callee function in the inlining remarks. Differential Revision: https://reviews.llvm.org/D26366 llvm-svn: 286169
* [lit] Print negative exit codes on Windows in hexReid Kleckner2016-11-071-2/+8
| | | | | | | Negative exit codes are usually exceptions. They're easier to recognize in hex. Compare -1073741502 to 0xc0000142. llvm-svn: 286150
* Fix `git-llvm` script to handle `git worktree` setups correctlyMehdi Amini2016-11-071-1/+2
| | | | llvm-svn: 286140
* Add some facilities to work with a git monorepo (experimental setup)Mehdi Amini2016-11-071-0/+278
| | | | | | | | | | | | | | | Add a new script in llvm/utils/git-svn/. When present in the $PATH, it enables a `git llvm` command. It is providing at this point only the ability to push from the git monorepo: `git llvm push`. It is intended to evolves with more features, for instance I plan on features like `git llvm show r284955` to help working with sequential revision numbers. The push feature is taken from Justin Lebar's script available here: https://github.com/jlebar/llvm-repo-tools/ Differential Revision: https://reviews.llvm.org/D26334 llvm-svn: 286138
* [X86] Fix test checks script to satisfy pyflakesZvi Rackover2016-11-071-5/+4
| | | | | | | | - Remove unused imports. - Initialize the variable 'name' before its (static) uses, and rename it to a more descriptive name. llvm-svn: 286128
* [X86] Fix test checks script to handle run lines with no pipe checksZvi Rackover2016-11-071-1/+5
| | | | | | | Fixes crashes in tests such as test/CodeGen/X86/masked_gather_scatter.ll which contains a RUN: with no pipe chain. llvm-svn: 286125
* Revert "Add some facilities to work with a git monorepo (experimental setup)"Mehdi Amini2016-11-071-296/+0
| | | | | | This reverts commit r286123, accidentally commited while testing itself... llvm-svn: 286124
* Add some facilities to work with a git monorepo (experimental setup)Mehdi Amini2016-11-071-0/+296
| | | | | | | | | | | | | | | | | | | | | | | | Summary: Some changes are made to cmake, especially the addition of a new LLVM_ENABLE_PROJECTS option that makes the build system aware of the monorepo directory structure. Also a new script is added in llvm/utils/git-svn/. When present in the $PATH, it enables a `git llvm` command. It is providing at this point only the ability to push from the git monorepo: `git llvm push`. It is intended to evolves with more features, for instance I plan on features like `git llvm show r284955` to help working with sequential revision numbers. The push feature is taken from Justin Lebar's script available here: https://github.com/jlebar/llvm-repo-tools/ Reviewers: jlebar Subscribers: mgorny, modocache, llvm-commits Differential Revision: https://reviews.llvm.org/D26334 llvm-svn: 286123
* [lit] Remove TODOBrian Gesiak2016-11-032-175/+3
| | | | | | | | | | | | | | | | | | | | | | Summary: Instead of keeping track of TODOs for lit in a file checked into source control, use LLVM's bug tracker. The TODOs have been migrated to the following bugs: * https://llvm.org/bugs/show_bug.cgi?id=30666 * https://llvm.org/bugs/show_bug.cgi?id=30667 * https://llvm.org/bugs/show_bug.cgi?id=30668 * https://llvm.org/bugs/show_bug.cgi?id=30669 * https://llvm.org/bugs/show_bug.cgi?id=30670 * https://llvm.org/bugs/show_bug.cgi?id=30671 Reviewers: ddunbar, beanz, echristo, delcypher Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25496 llvm-svn: 285973
* vim: special case the CHECK prefixSaleem Abdulrasool2016-11-031-0/+1
| | | | | | | | | A large number of tests in the LLVM tree use the default (CHECK) prefix to indicate checked expressions via FileCheck. Highlight it as a special comment. Although this wont get all the instances of the checked patters, it is strictly better than the current state. llvm-svn: 285927
* Expandload and Compressstore intrinsicsElena Demikhovsky2016-11-032-6/+8
| | | | | | | | 2 new intrinsics covering AVX-512 compress/expand functionality. This implementation includes syntax, DAG builder, operation lowering and tests. Does not include: handling of illegal data types, codegen prepare pass and the cost model. llvm-svn: 285876
* [TableGen] Move OperandMatchResultTy enum to MCTargetAsmParser.hAlex Bradbury2016-11-011-9/+2
| | | | | | | | | | | | | | | As it stands, the OperandMatchResultTy is only included in the generated header if there is custom operand parsing. However, almost all backends make use of MatchOperand_Success and friends from OperandMatchResultTy for e.g. parseRegister. This is a pain when starting an AsmParser for a new backend that doesn't yet have custom operand parsing. Move the enum to MCTargetAsmParser.h. This patch is a prerequisite for D23563 Differential Revision: https://reviews.llvm.org/D23496 llvm-svn: 285705
* Fix per-processor model scheduler definition completeness checkUlrich Weigand2016-10-311-1/+2
| | | | | | | | | | | | | | | The CodeGenSchedModels::checkCompleteness routine in TableGen/ CodeGenSchedule.cpp is supposed to verify for each processor model that is marked as "complete" that it actually defines a scheduling class for each instruction. However, this did not work correctly due to an incorrect check whether a scheduling class has an itinerary. Reviewer: atrick Differential revision: https://reviews.llvm.org/D26156 llvm-svn: 285622
* [utils] Add a '--unified-report' option to the code coverage prep scriptVedant Kumar2016-10-261-12/+29
| | | | | | | | | | | In --unified-report mode, a single coverage report is prepared for all specified binaries and written to *report_dir*. This mode is compatible with all existing script options, including the --restrict mode which is used to limit coverage reporting to certain files or directories. This should not break any existing users of the script. llvm-svn: 285249
* [utils] Use print_function in the code coverage prep script, NFC.Vedant Kumar2016-10-261-5/+7
| | | | llvm-svn: 285248
* [utils] Add an '--only-merge' option to the code coverage prep scriptVedant Kumar2016-10-261-3/+11
| | | | | | | | | | | In --only-merge mode, the script terminates after the profile merging step. This makes the script less stateful: it's more natural to split the merge out into a separate step instead of relying on the first invocation of the script to do it. This should not break any existing users of the script. llvm-svn: 285247
* [lit] Work around Windows MSys command line tokenization bugReid Kleckner2016-10-261-0/+61
| | | | | | | | | | | | | | Summary: This will allow us to revert LLD r284768, which added spaces to get MSys echo to print what we want. Reviewers: ruiu, inglorion, rafael Subscribers: modocache, llvm-commits Differential Revision: https://reviews.llvm.org/D26009 llvm-svn: 285237
* Revert 285087.Nico Weber2016-10-251-0/+8
| | | | | | | | | | | | | The sanitizer-windows bot turned red with: FAILED: utils/TableGen/CMakeFiles/obj.llvm-tblgen.dir/IntrinsicEmitter.cpp.obj C:\PROGRA~2\MICROS~1.0\VC\bin\AMD64_~2\cl.exe ... -c C:\...\llvm\utils\TableGen\IntrinsicEmitter.cpp c:\...\llvm\utils\tablegen\intrinsicemitter.cpp(254) : fatal error C1001: An internal error has occurred in the compiler. http://lab.llvm.org:8011/builders/sanitizer-windows/builds/114/steps/build%20clang%20lld/logs/stdio llvm-svn: 285089
* Try removing an MSVC2010 workaround.Nico Weber2016-10-251-8/+0
| | | | | | | Things seem to build fine locally without this, so let's see what the bots think. llvm-svn: 285087
* [lit] Add more testing instructions to READMEBrian Gesiak2016-10-221-0/+15
| | | | | | | | | | | | | | | Summary: r283710 introduced two regressions, one to llvm-lit, and the other to lit executables that were installed via setuptools. Add instructions on how to test for these regressions in the future. Reviewers: ddunbar, delcypher, beanz, chapuni, cmatthews, echristo Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25459 llvm-svn: 284919
* Switch SmallSetVector to use DenseSet when it overflows its inline space.Justin Lebar2016-10-212-20/+23
| | | | | | | | | | | | | | | | | | | | Summary: SetVector already used DenseSet, but SmallSetVector used std::set. This leads to surprising performance differences. Moreover, it means that the set of key types accepted by SetVector and SmallSetVector are quite different! In order to make this change, we had to convert some callsites that used SmallSetVector<std::string, N> to use SmallSetVector<CachedHashString, N> instead. Reviewers: timshen Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D25648 llvm-svn: 284887
* Improve tablegen gen-subtarget diagnostics for missing machine models.Andrew Trick2016-10-181-5/+8
| | | | | | | | | | | | -debug-only=subtarget-emitter prints a lot of machine model diagnostics. This prunes the output so that the "No machine model for XXX on processor YYY" only appears when there is definitely no machine model for that opcode. Previously it was printing that error even if the opcode was covered by a more general scheduling class. <rdar://problem/15919845> [TableGen][CodeGenSchedule] Debug output does not help spotting the missing scheduling classes llvm-svn: 284452
* vim: add `norecurse` attributeSaleem Abdulrasool2016-10-141-0/+1
| | | | | | Add missing attribute to the keyword set. llvm-svn: 284270
* vim: add `comdat` keywordSaleem Abdulrasool2016-10-141-0/+1
| | | | | | The attribute may be applied to a function. Highlight it as a keyword. llvm-svn: 284269
* [lit] Fix test shtest-timeout.py for modern outputMichal Gorny2016-10-121-10/+9
| | | | | | | | | | Update the CHECK lines in the shtest-timeout.py lit test to account for the current output. The output has been changed in r271610 without adjusting the tests. Differential Revision: https://reviews.llvm.org/D25236 llvm-svn: 284057
* [lit] Fix FormatError on individual test timeoutMichal Gorny2016-10-121-1/+1
| | | | | | Differential Revision: https://reviews.llvm.org/D25195 llvm-svn: 284056
* [lit] Run unit tests as part of lit test suiteBrian Gesiak2016-10-122-108/+112
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: The Python file `utils/lit/lit/ShUtil.py` contains: 1. Logic used by lit itself 2. A set of unit tests for that logic, which can be run by invoking `python utils/lit/lit/ShUtil.py` Move these unit tests to a `tests/unit` subdirectory of lit, and run the tests as part of lit's test suite. This ensures that, should the lit test suite be included in LLVM's own regression test suite, these unit tests will also be run. (Instructions on how to run lit's test suite can be found in `utils/lit/README.txt`.) Reviewers: ddunbar, echristo, delcypher, beanz Subscribers: mehdi_amini, llvm-commits Differential Revision: https://reviews.llvm.org/D25411 llvm-svn: 283968
* [opt-viewer] Remove unnecessary call to demangleAdam Nemet2016-10-111-1/+1
| | | | llvm-svn: 283898
* [opt-viewer] Print hotness as percentage of the maximum hotnessAdam Nemet2016-10-111-2/+9
| | | | llvm-svn: 283897
* [opt-viewer] Convert another HTML output to use a multiline stringAdam Nemet2016-10-111-10/+16
| | | | llvm-svn: 283896
* Fix issue which cases lit installed with setup.py to not resolve mainChris Matthews2016-10-101-0/+2
| | | | llvm-svn: 283818
* Fix llvm-lit.in corresponding to r283710.NAKAMURA Takumi2016-10-101-2/+2
| | | | | | | | | | | Traceback (most recent call last): File "bin/llvm-lit", line 44, in <module> lit.main(builtin_parameters) AttributeError: 'module' object has no attribute 'main' Suggested by Artem Belevich. llvm-svn: 283816
* Revert r283690, "MC: Remove unused entities."Peter Collingbourne2016-10-101-1/+1
| | | | llvm-svn: 283814
* Use StringRef in TableGen generated Intrinsics.gen file (NFC)Mehdi Amini2016-10-101-7/+5
| | | | llvm-svn: 283792
* [lit] Remove (or allow specific) unused importsBrian Gesiak2016-10-104-10/+12
| | | | | | | | | | | | | | | | | | | | | Summary: Using Python linter flake8 on the utils/lit reveals several linter warnings designated "F401: Unused import". Fix or silence these warnings. Some of these unused imports are legitimate, while some are part of lit's API. For example, users of lit expect to be able to access `lit.formats.ShTest` in their `lit.cfg`, despite the module hierarchy for that symbol actually being `lit.formats.shtest.ShTest`. To silence linter errors for these lines, include a "noqa" directive. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: mehdi_amini, llvm-commits Differential Revision: https://reviews.llvm.org/D25407 llvm-svn: 283710
* [lit] Remove unused TestingProgressDisplay attrBrian Gesiak2016-10-101-1/+0
| | | | | | | | | | | | | | Summary: `TestingProgressDisplay` initializes its `current` attribute to `None`, but never reads or writes the value again. Remove it. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25415 llvm-svn: 283709
* [lit] Fix undefined symbol ArgumentErrorBrian Gesiak2016-10-101-2/+2
| | | | | | | | | | | | | | | | | | | Summary: `ArgumentError` is not defined by the Python standard library. Executing this line of code would throw a exception, but not the intended one. It would throw a `NameError` exception, since `ArgumentError` is undefined. Use `ValueError` instead, which is defined by the Python standard library. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25410 llvm-svn: 283708
* [lit] Remove semicolons in Python codeBrian Gesiak2016-10-102-3/+3
| | | | | | | | | | | | | | | Summary: Semicolons aren't necessary as statement terminators in Python, and each of these uses are superfluous as they appear at the end of a line. The convention is to not use semicolons where not needed, so remove them. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25409 llvm-svn: 283707
* [lit] Remove unused variable in googletest formatBrian Gesiak2016-10-101-1/+0
| | | | | | | | | | | | Summary: `prefix` is written to but never read. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25408 llvm-svn: 283706
* [lit] Remove Python 2.6 and below exec workaroundBrian Gesiak2016-10-101-12/+7
| | | | | | | | | | | | | | Summary: The minimum version of Python required to run LLVM's test suite is 2.7. Remove a workaround for older Python versions. Reviewers: echristo, delcypher, beanz, ddunbar Subscribers: llvm-commits, mehdi_amini Differential Revision: https://reviews.llvm.org/D25400 llvm-svn: 283705
* MC: Remove unused entities.Peter Collingbourne2016-10-091-1/+1
| | | | llvm-svn: 283691
* Turn cl::values() (for enum) from a vararg function to using C++ variadic ↵Mehdi Amini2016-10-081-2/+1
| | | | | | | | | | | | | | | template The core of the change is supposed to be NFC, however it also fixes what I believe was an undefined behavior when calling: va_start(ValueArgs, Desc); with Desc being a StringRef. Differential Revision: https://reviews.llvm.org/D25342 llvm-svn: 283671
* New utility to visualize optimization recordsAdam Nemet2016-10-072-0/+314
| | | | | | | | | | | | | | | | | | | | This is a new tool built on top of the new YAML ouput generated from optimization remarks. It produces HTML for easy navigation and visualization. The tool assumes that hotness information for the remarks is available (the YAML file was produced with PGO). It uses hotness to list the remarks prioritized by the hotness on the index page. Clicking the source location of the remark in the list takes you the source where the remarks are rendedered inline in the source. For now, the tool is meant as prototype. It's written in Python. It uses PyYAML to parse the input. Differential Revision: https://reviews.llvm.org/D25348 llvm-svn: 283571
* FastISel: Remove unused/un-overridden entry points. NFCI.Peter Collingbourne2016-10-051-2/+1
| | | | llvm-svn: 283366
* Use StringRef in TableGen (NFC)Mehdi Amini2016-10-042-3/+3
| | | | llvm-svn: 283273
* Use StringRef in TableGen emitted API for attribute (NFC)Mehdi Amini2016-10-041-1/+1
| | | | llvm-svn: 283268
OpenPOWER on IntegriCloud