Use bidirectional bundle flags to simplify important functions.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Tue, 18 Dec 2012 23:21:49 +0000 (23:21 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Tue, 18 Dec 2012 23:21:49 +0000 (23:21 +0000)
commitd742533dbc43f54798becb48ed7d3a2d97cf8150
treea00a722b2af872c00555326077674bef7e3de4af
parent1cd71a771cbec872ea820f9226bcffb73c99efe8
Use bidirectional bundle flags to simplify important functions.

The bundle_iterator::operator++ function now doesn't need to dig out the
basic block and check against end(). It can use the isBundledWithSucc()
flag to find the last bundled instruction safely.

Similarly, MachineInstr::isBundled() no longer needs to look at
iterators etc. It only has to look at flags.

llvm-svn: 170473
llvm/include/llvm/CodeGen/MachineBasicBlock.h
llvm/include/llvm/CodeGen/MachineInstr.h
llvm/lib/CodeGen/MachineInstr.cpp