mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-09 22:24:37 +00:00
InstrProf: Don't combine expansion regions with code regions
This was leading to duplicate counts when a code region happened to overlap exactly with an expansion. The combining behaviour only makes sense for code regions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229723 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -314,7 +314,7 @@ public:
|
||||
popRegion();
|
||||
if (PrevRegion && PrevRegion->startLoc() == Region.startLoc() &&
|
||||
PrevRegion->endLoc() == Region.endLoc()) {
|
||||
if (Region.Kind != coverage::CounterMappingRegion::SkippedRegion)
|
||||
if (Region.Kind == coverage::CounterMappingRegion::CodeRegion)
|
||||
Segments.back().addCount(Region.ExecutionCount);
|
||||
} else {
|
||||
// Add this region to the stack.
|
||||
|
Reference in New Issue
Block a user