1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 12:33:33 +02:00
llvm-mirror/unittests
Duncan P. N. Exon Smith cd73eace2f CodeGen: Assert that bundle iterators are valid
Add an assertion to the MachineInstrBundleIterator from instr_iterator
that the underlying iterator is valid.  This is possible know that we
can check ilist_node::isSentinel (since r281168), and is consistent with
the constructors from MachineInstr* and MachineInstr&.

Avoiding the new assertion in operator== and operator!= requires four
(!!!!) new overloads each.

(As an aside, I'm strongly in favour of:
- making the conversion from instr_iterator explicit;
- making the conversion from pointer explicit;
- making the conversion from reference explicit; and
- removing all the extra overloads of operator== and operator!= except
  const_instr_iterator.

I'm not signing up for that at this point, but being clear about when
something is an MachineInstr-iterator (possibly instr_end()) vs
MachineInstr-bundle-iterator (possibly end()) vs MachineInstr* (possibly
nullptr) vs MachineInstr& (known valid) would surely make code
cleaner... and it would remove a ton of boilerplate from
MachineInstrBundleIterator operators.)

llvm-svn: 281170
2016-09-11 17:12:28 +00:00
..
ADT ADT: Add sentinel tracking and custom tags to ilists 2016-09-11 16:20:53 +00:00
Analysis [PM] Revert r280447: Add a unittest for invalidating module analyses with an SCC pass. 2016-09-04 08:42:31 +00:00
AsmParser Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
Bitcode Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
CodeGen CodeGen: Assert that bundle iterators are valid 2016-09-11 17:12:28 +00:00
DebugInfo [msf] Resubmit "Rename Msf -> MSF". 2016-07-29 20:56:36 +00:00
ExecutionEngine Re-instate recent RPC updates (r280016, r280017, r280027, r280051) with a 2016-08-30 19:56:15 +00:00
IR Formatting with clang-format patch r280700 2016-09-06 17:03:02 +00:00
LineEditor
Linker Remangle intrinsics names when types are renamed 2016-06-24 15:10:29 +00:00
MC
MI CodeGen: Remove MachineFunctionAnalysis => Enable (Machine)ModulePasses 2016-08-24 01:52:46 +00:00
ObjectYAML
Option Option parser: class for consuming a joined arg in addition to all remaining args 2016-04-15 00:23:30 +00:00
ProfileData Use the range variant of find_if instead of unpacking begin/end 2016-08-12 00:18:03 +00:00
Support [YAMLIO] Add the ability to map with context. 2016-09-08 18:22:44 +00:00
Transforms Formatting with clang-format patch r280700 2016-09-06 17:03:02 +00:00
CMakeLists.txt [CMake] Use CMake's default RPATH for the unit tests 2016-09-07 08:37:15 +00:00