[llvm-commits] [llvm] r172622 - /llvm/trunk/include/llvm/MC/MCAssembler.h
Eli Bendersky
eliben at google.com
Wed Jan 16 08:52:09 PST 2013
Author: eliben
Date: Wed Jan 16 10:52:08 2013
New Revision: 172622
URL: http://llvm.org/viewvc/llvm-project?rev=172622&view=rev
Log:
Replace virtual hasFixups with explicit fragment type checks
Modified:
llvm/trunk/include/llvm/MC/MCAssembler.h
Modified: llvm/trunk/include/llvm/MC/MCAssembler.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/MC/MCAssembler.h?rev=172622&r1=172621&r2=172622&view=diff
==============================================================================
--- llvm/trunk/include/llvm/MC/MCAssembler.h (original)
+++ llvm/trunk/include/llvm/MC/MCAssembler.h Wed Jan 16 10:52:08 2013
@@ -122,10 +122,6 @@
virtual void setBundlePadding(uint8_t N) {
}
- virtual bool hasFixups() const {
- return false;
- }
-
void dump();
};
@@ -182,10 +178,6 @@
virtual ~MCEncodedFragmentWithFixups();
- virtual bool hasFixups() const {
- return true;
- }
-
typedef SmallVectorImpl<MCFixup>::const_iterator const_fixup_iterator;
typedef SmallVectorImpl<MCFixup>::iterator fixup_iterator;
@@ -198,7 +190,8 @@
virtual const_fixup_iterator fixup_end() const = 0;
static bool classof(const MCFragment *F) {
- return isa<MCEncodedFragment>(F) && F->hasFixups();
+ MCFragment::FragmentType Kind = F->getKind();
+ return Kind == MCFragment::FT_Relaxable || Kind == MCFragment::FT_Data;
}
};
More information about the llvm-commits
mailing list