Remove OMP usage, it leads to performance issues at runtime on machines with few cores (e.g. 2)

This commit is contained in:
Flamefire committed 2014-05-10 18:35:52 +02:00
1 parent ae2672247c
commit e975d0d5c5
2 files changed
-6

No files matched your search

-2
View File
@@ -135,7 +135,6 @@
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<FloatingPointModel>Fast</FloatingPointModel>
<OmitFramePointers>false</OmitFramePointers>
<OpenMPSupport>true</OpenMPSupport>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
@@ -158,7 +157,6 @@
<SDLCheck>true</SDLCheck>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<FloatingPointModel>Fast</FloatingPointModel>
<OpenMPSupport>true</OpenMPSupport>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
-4
View File
@@ -179,15 +179,11 @@ int PtAKF::_GetNote(float samples[_SampleCt], float* restrict maxVolume, float w
float maxWeight = 0.f;
//TODO: When using FFT this can be speed up a lot by only checking around the AKF peaks
#pragma omp parallel for schedule(static)
for (int toneIndex = 0; toneIndex <= _MaxHalfTone; toneIndex++){
float curWeight = _AnalyzeByTone(samples, samplesWindowed, toneIndex);
weights[toneIndex] = curWeight;
}
for (int toneIndex = 0; toneIndex <= _MaxHalfTone; toneIndex++){
float curWeight = weights[toneIndex];
if(curWeight > maxWeight){
maxWeight = curWeight;
}