mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-25 00:24:26 +00:00
Update SetVector to rely on the underlying set's insert to return a pair<iterator, bool>
This is to be consistent with StringSet and ultimately with the standard library's associative container insert function. This lead to updating SmallSet::insert to return pair<iterator, bool>, and then to update SmallPtrSet::insert to return pair<iterator, bool>, and then to update all the existing users of those functions... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222334 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -182,7 +182,7 @@ void CodeGenSchedModels::addProcModel(Record *ProcDef) {
|
||||
// Recursively find all reachable SchedReadWrite records.
|
||||
static void scanSchedRW(Record *RWDef, RecVec &RWDefs,
|
||||
SmallPtrSet<Record*, 16> &RWSet) {
|
||||
if (!RWSet.insert(RWDef))
|
||||
if (!RWSet.insert(RWDef).second)
|
||||
return;
|
||||
RWDefs.push_back(RWDef);
|
||||
// Reads don't current have sequence records, but it can be added later.
|
||||
@ -751,7 +751,7 @@ void CodeGenSchedModels::createInstRWClass(Record *InstRWDef) {
|
||||
for (ArrayRef<Record*>::const_iterator
|
||||
II = InstDefs.begin(), IE = InstDefs.end(); II != IE; ++II) {
|
||||
unsigned OldSCIdx = InstrClassMap[*II];
|
||||
if (OldSCIdx && RemappedClassIDs.insert(OldSCIdx)) {
|
||||
if (OldSCIdx && RemappedClassIDs.insert(OldSCIdx).second) {
|
||||
for (RecIter RI = SchedClasses[OldSCIdx].InstRWs.begin(),
|
||||
RE = SchedClasses[OldSCIdx].InstRWs.end(); RI != RE; ++RI) {
|
||||
if ((*RI)->getValueAsDef("SchedModel") == RWModelDef) {
|
||||
|
Reference in New Issue
Block a user