From d0b4ffd154885085294e233519fe68348a306109 Mon Sep 17 00:00:00 2001 From: Dennis Luxen Date: Mon, 28 Apr 2014 18:23:56 +0200 Subject: [PATCH] fix openmp woes on linux --- Extractor/PBFParser.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Extractor/PBFParser.cpp b/Extractor/PBFParser.cpp index 9126be8a1..f9f87adb4 100644 --- a/Extractor/PBFParser.cpp +++ b/Extractor/PBFParser.cpp @@ -352,9 +352,6 @@ inline void PBFParser::parseWay(_ThreadData * threadData) { } } -#pragma omp parallel -{ - const int thread_num = omp_get_thread_num(); #pragma omp parallel for schedule ( guided ) for(int i = 0; i < number_of_ways; ++i) { @@ -363,11 +360,10 @@ inline void PBFParser::parseWay(_ThreadData * threadData) { { ParseWayInLua( extraction_way, - scripting_environment.getLuaStateForThreadID(thread_num) + scripting_environment.getLuaStateForThreadID(omp_get_thread_num()) ); } } -} BOOST_FOREACH(ExtractionWay & extraction_way, parsed_way_vector) {