diff options
| author | Stephen Hines <srhines@google.com> | 2013-03-20 04:35:40 +0000 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2013-03-20 04:35:40 +0000 |
| commit | 6cb1cc8a104c032246b2473cd31741450fcaf846 (patch) | |
| tree | 90c0395880593bf195fb818c2af1139cb7e846df /lib/MC/MCContext.cpp | |
| parent | e316ed5b5b1ea97934302f6f53c37c0a3334a974 (diff) | |
| parent | 3dd51ae3a043f2edf9dd2bc7c906c3f602967e5a (diff) | |
| download | external_llvm-6cb1cc8a104c032246b2473cd31741450fcaf846.zip external_llvm-6cb1cc8a104c032246b2473cd31741450fcaf846.tar.gz external_llvm-6cb1cc8a104c032246b2473cd31741450fcaf846.tar.bz2 | |
am 3dd51ae3: am 2d4629c5: Merge branch \'upstream\' into merge_2013_03_18
* commit '3dd51ae3a043f2edf9dd2bc7c906c3f602967e5a': (424 commits)
Change NULL to 0.
Register the flush function for each compile unit.
Remove trailing spaces.
Fix PPC unaligned 64-bit loads and stores
ARM cost model: Make some vector integer to float casts cheaper
ARM cost model: Correct cost for some cheap float to integer conversions
Extend global merge pass to optionally consider global constant variables. Also add some checks to not merge globals used within landing pad instructions or marked as "used".
Change test cases to handle unaligned references.
Remove unnecessary leading comment characters in lit-only file
Add SchedRW annotations to most of X86InstrSSE.td.
Annotate X86 arithmetic instructions with SchedRW lists.
Check whether a pointer is non-null (isKnownNonNull) in isKnownNonZero.
TableGen fix for the new machine model.
Include '.test' suffix in target specific lit configs that need it
Make the fields in the diagram match the descriptive text above them.
Update
Fix 80-col. violations in PPCCTRLoops
Fix large count and negative constant count handling in PPCCTRLoops
Cleanup initial-value constants in PPCCTRLoops
Fix integer comparison in DIEInteger::BestForm.
...
Diffstat (limited to 'lib/MC/MCContext.cpp')
| -rw-r--r-- | lib/MC/MCContext.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/MC/MCContext.cpp b/lib/MC/MCContext.cpp index 1a7df60..9adcc02 100644 --- a/lib/MC/MCContext.cpp +++ b/lib/MC/MCContext.cpp @@ -77,8 +77,8 @@ void MCContext::reset() { Symbols.clear(); Allocator.Reset(); Instances.clear(); - MCDwarfFiles.clear(); - MCDwarfDirs.clear(); + MCDwarfFilesCUMap.clear(); + MCDwarfDirsCUMap.clear(); MCGenDwarfLabelEntries.clear(); DwarfDebugFlags = StringRef(); MCLineSections.clear(); @@ -299,11 +299,13 @@ const MCSection *MCContext::getCOFFSection(StringRef Section, /// error and zero is returned and the client reports the error, else the /// allocated file number is returned. The file numbers may be in any order. unsigned MCContext::GetDwarfFile(StringRef Directory, StringRef FileName, - unsigned FileNumber) { + unsigned FileNumber, unsigned CUID) { // TODO: a FileNumber of zero says to use the next available file number. // Note: in GenericAsmParser::ParseDirectiveFile() FileNumber was checked // to not be less than one. This needs to be change to be not less than zero. + SmallVectorImpl<MCDwarfFile *>& MCDwarfFiles = MCDwarfFilesCUMap[CUID]; + SmallVectorImpl<StringRef>& MCDwarfDirs = MCDwarfDirsCUMap[CUID]; // Make space for this FileNumber in the MCDwarfFiles vector if needed. if (FileNumber >= MCDwarfFiles.size()) { MCDwarfFiles.resize(FileNumber + 1); @@ -363,7 +365,8 @@ unsigned MCContext::GetDwarfFile(StringRef Directory, StringRef FileName, /// isValidDwarfFileNumber - takes a dwarf file number and returns true if it /// currently is assigned and false otherwise. -bool MCContext::isValidDwarfFileNumber(unsigned FileNumber) { +bool MCContext::isValidDwarfFileNumber(unsigned FileNumber, unsigned CUID) { + SmallVectorImpl<MCDwarfFile *>& MCDwarfFiles = MCDwarfFilesCUMap[CUID]; if(FileNumber == 0 || FileNumber >= MCDwarfFiles.size()) return false; |
