- Nov 02, 2016
-
-
Peter Collingbourne authored
We need to zero extend the byte in order to correctly shift it into a 64-bit value. llvm-svn: 285785
-
Brad Smith authored
It was noticed this caused performance regressions and deadlocks. PR30768. Reorder the code to make it clearer what is tested. PPC now disables the use of std::call_once only with libstdc++ with the reordering of the code, as was the original intent. llvm-svn: 285782
-
Michael Gottesman authored
This is the reverse_iterator analogue of getIterator(). llvm-svn: 285780
-
Peter Collingbourne authored
Should unbreak ocaml binding tests. Also added an llvm-dis test that checks for the same thing. llvm-svn: 285777
-
Peter Collingbourne authored
These interfaces are no longer used. Differential Revision: https://reviews.llvm.org/D26222 llvm-svn: 285774
-
Peter Collingbourne authored
As proposed on llvm-dev: http://lists.llvm.org/pipermail/llvm-dev/2016-October/106595.html This change also fixes an API oddity where BitstreamCursor::Read() would return zero for the first read past the end of the bitstream, but would report_fatal_error for subsequent reads. Now we always report_fatal_error for all reads past the end. Updated clients to check for the end of the bitstream before reading from it. I also needed to add padding to the invalid bitcode tests in test/Bitcode/. This is because the streaming interface was not checking that the file size is a multiple of 4. Differential Revision: https://reviews.llvm.org/D26219 llvm-svn: 285773
-
Vedant Kumar authored
llvm-svn: 285772
-
Alex Bradbury authored
This is enough to compile and link but doesn't yet do anything particularly useful. Once an ASM parser and printer are added in the next two patches, the whole thing can be usefully tested. Differential Revision: https://reviews.llvm.org/D23562 llvm-svn: 285770
-
Alex Bradbury authored
For now, only add instruction definitions for basic ALU operations. Our initial target is a working MC layer rather than codegen, so appropriate SelectionDAG patterns will come later. Differential Revision: https://reviews.llvm.org/D23561 llvm-svn: 285769
-
Matt Arsenault authored
llvm-svn: 285768
-
Matt Arsenault authored
This is already done with VGPR immediates and saves 4 bytes. llvm-svn: 285765
-
- Nov 01, 2016
-
-
Matt Arsenault authored
This is the conservatively correct way because it's easy to move or replace a scalar immediate. This was incorrect in the case when the register class wasn't known from the static instruction definition, but still needed to be an SGPR. The main example of this is inlineasm has an SGPR constraint. Also start verifying the register classes of inlineasm operands. llvm-svn: 285762
-
Eric Christopher authored
Move the initialization of PreferredLoopExit into runOnMachineFunction to be near the other function specific initializations. llvm-svn: 285758
-
Sam McCall authored
Summary: Currently PreferredLoopExit is set only in buildLoopChains, which is never called if there are no MachineLoops. MSan is currently broken by this: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/145/steps/check-llvm%20msan/logs/stdio This is a naive fix to get things green again. iteratee: you may have a better fix. This change will also mean PreferredLoopExit will not carry over if buildCFGChains() is called a second time in runOnMachineFunction, this appears to be the right thing. Reviewers: bkramer, iteratee, echristo Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D26069 llvm-svn: 285757
-
Matt Arsenault authored
These are only used in the spill to VMEM path. Move them to the one use. llvm-svn: 285756
-
Rafael Espindola authored
This saves a field that is not always used. It also avoids failing a program that doesn't need the section names. llvm-svn: 285753
-
George Burgess IV authored
Patch by bryant. Differential Revision: https://reviews.llvm.org/D26126 llvm-svn: 285750
-
Rafael Espindola authored
The description in the ELF spec is just --------------------------- If the section name string table section index is greater than or equal to SHN_LORESERVE (0xff00), this member has the value SHN_XINDEX (0xffff) and the actual index of the section name string table section is contained in the sh_link field of the section header at index 0. --------------------------- So we only have to check for it being SHN_XINDEX. Also, sh_link is always 32 bits, so don't return an uintX_t. llvm-svn: 285747
-
Sanjay Patel authored
InstCombine should always canonicalize patterns like the one shown in the comment when visiting 'select' insts in adjustMinMax(). Scalars were already handled there, and vector splats are handled after: https://reviews.llvm.org/rL285732 llvm-svn: 285744
-
Matt Arsenault authored
Instructions with a 32-bit base encoding with an optional 32-bit literal encoded after them report their size as 4 for the disassembler. Consider these when computing the MachineInstr size. This fixes problems caused by size estimate consistency in BranchRelaxation. llvm-svn: 285743
-
Rafael Espindola authored
This avoids calling exit with a partially constructed object. llvm-svn: 285738
-
Chris Bieneman authored
Summary: This fixes a few things that used to work with a Makefile build, but were broken in cmake. 1. Treat MINGW like a Linux system. 2. The shlib should never contain other shared libraries. Patch By: Valentin Churavy Reviewers: axw, beanz Subscribers: modocache, beanz, mgorny Differential Revision: https://reviews.llvm.org/D25865 llvm-svn: 285737
-
Sanjay Patel authored
llvm-svn: 285732
-
Alex Bradbury authored
llvm-svn: 285730
-
Sanjay Patel authored
This transforms %a = shl nuw %x, c1 %b = icmp {ugt|ule} %a, c0 into %b = icmp {ugt|ule} %x, (c0 >> c1) z3: (declare-const x (_ BitVec 64)) (declare-const c0 (_ BitVec 64)) (declare-const c1 (_ BitVec 64)) (push) (assert (= x (bvlshr (bvshl x c1) c1))) ; nuw (assert (not (= (bvugt (bvshl x c1) c0) (bvugt x (bvlshr c0 c1))))) (check-sat) (get-model) (pop) (push) (assert (= x (bvlshr (bvshl x c1) c1))) ; nuw (assert (not (= (bvule (bvshl x c1) c0) (bvule x (bvlshr c0 c1))))) (check-sat) (get-model) (pop) Patch by bryant! Differential Revision: https://reviews.llvm.org/D25913 llvm-svn: 285729
-
Krzysztof Parzyszek authored
For example, rename s6Ext to s6_0Ext. The names for shifted integers include the underscore and this will make the naming consistent. It also exposed a few duplicates that were removed. llvm-svn: 285728
-
Matt Arsenault authored
It's likely if a conditional branch needs to be expanded, the following unconditional branch will also need expansion. By expanding the unconditional branch first, the conditional branch can be simply inverted to jump over the inserted indirect branch block. If the conditional branch is expanded first, it results in an additional branch. This avoids test regressions in future commits. llvm-svn: 285722
-
Sanjay Patel authored
1. Change param names for readability 2. Change pointer param to ref 3. Early exit to reduce indent 4. Change switch to if/else llvm-svn: 285718
-
Erich Keane authored
llvm-svn: 285717
-
Konstantin Zhuravlyov authored
This will prevent following regression when enabling i16 support (D18049): test/CodeGen/AMDGPU/ctlz.ll test/CodeGen/AMDGPU/ctlz_zero_undef.ll Differential Revision: https://reviews.llvm.org/D25802 llvm-svn: 285716
-
Sanjay Patel authored
This is just a cut and paste; clean-up and enhancements to follow. llvm-svn: 285715
-
Chris Bieneman authored
This patch was produced in conjunction with Michał Górny. It should resolve the issues that were trying to be solved by D25304. This moves rpath handling into `llvm_add_library` and `add_llvm_executable` so that it is available to all projects using AddLLVM whether built in-tree or out-of-tree. llvm-svn: 285714
-
Sanjay Patel authored
llvm-svn: 285713
-
Alex Bradbury authored
This contains just enough for lib/Target/RISCV to compile. Notably a basic RISCVTargetMachine and RISCVTargetInfo. At this point you can attempt llc -march=riscv32 myinput.ll and will find it fails due to the lack of MCAsmInfo. See http://lists.llvm.org/pipermail/llvm-dev/2016-August/103748.html for further discussion Differential Revision: https://reviews.llvm.org/D23560 llvm-svn: 285712
-
Tom Stellard authored
llvm-svn: 285711
-
Alex Bradbury authored
Fix rL285708 llvm-svn: 285709
-
Alex Bradbury authored
Add the necessary definitions for RISC-V ELF files, including relocs. Also make necessary trivial change to ELFYaml, llvm-objdump, and llvm-readobj in order to work with RISC-V ELFs. Differential Revision: https://reviews.llvm.org/D23557 llvm-svn: 285708
-
Alex Bradbury authored
This is the first in a series of 10 initial patches that incrementally add an MC layer for RISC-V to LLVM. See <http://lists.llvm.org/pipermail/llvm-dev/2016-August/103748.html> for more discussion. Differential Revision: https://reviews.llvm.org/D23557 llvm-svn: 285707
-
Sanjay Patel authored
I think the former 'test50' had a typo making it functionally equivalent to the former 'test49'; changed the predicate to provide more coverage. llvm-svn: 285706
-
Alex Bradbury authored
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
-