File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 9
9
#ifndef LLVM_MC_MCOBJECTSTREAMER_H
10
10
#define LLVM_MC_MCOBJECTSTREAMER_H
11
11
12
- #include " llvm/ADT/SetVector.h"
13
12
#include " llvm/ADT/SmallVector.h"
14
13
#include " llvm/MC/MCAssembler.h"
15
14
#include " llvm/MC/MCSection.h"
@@ -39,7 +38,7 @@ class MCObjectStreamer : public MCStreamer {
39
38
bool EmitEHFrame;
40
39
bool EmitDebugFrame;
41
40
SmallVector<MCSymbol *, 2 > PendingLabels;
42
- SmallSetVector <MCSection *, 4 > PendingLabelSections;
41
+ SmallVector <MCSection*, 2 > PendingLabelSections;
43
42
unsigned CurSubsectionIdx;
44
43
struct PendingMCFixup {
45
44
const MCSymbol *Sym;
Original file line number Diff line number Diff line change @@ -59,8 +59,12 @@ void MCObjectStreamer::addPendingLabel(MCSymbol* S) {
59
59
CurSection->addPendingLabel (S, CurSubsectionIdx);
60
60
61
61
// Add this Section to the list of PendingLabelSections.
62
- PendingLabelSections.insert (CurSection);
63
- } else
62
+ auto SecIt = std::find (PendingLabelSections.begin (),
63
+ PendingLabelSections.end (), CurSection);
64
+ if (SecIt == PendingLabelSections.end ())
65
+ PendingLabelSections.push_back (CurSection);
66
+ }
67
+ else
64
68
// There is no Section / Subsection for this label yet.
65
69
PendingLabels.push_back (S);
66
70
}
You can’t perform that action at this time.
0 commit comments