mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Replace parallel STL with PPQSort.
PPQSort is supposedly quite fast: https://github.com/GabTux/PPQSort More importantly, it does not depend on TBB fuckery, so there's no longer a need to link with an external library that people may or may not have. The NO_PARALLEL_STL option is out, as it was provided solely to deal with TBB being not available. Sequential sorting is still used on emscripten.
This commit is contained in:
@@ -13,11 +13,11 @@
|
||||
#include "TracyImGui.hpp"
|
||||
#include "TracyMicroArchitecture.hpp"
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracySort.hpp"
|
||||
#include "TracySourceView.hpp"
|
||||
#include "TracyUtility.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "TracyWorker.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
#include "IconsFontAwesome6.h"
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "TracyUtility.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "TracyWorker.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "TracyImGui.hpp"
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "TracyTimelineContext.hpp"
|
||||
#include "TracyTimelineDraw.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "TracyTimelineItem.hpp"
|
||||
#include "TracyTimelineContext.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
constexpr float MinVisSize = 3;
|
||||
|
||||
|
||||
@@ -7,7 +7,9 @@
|
||||
#include "TracyImGui.hpp"
|
||||
#include "TracyMouse.hpp"
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracySort.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
@@ -507,10 +509,10 @@ void View::DrawFindZone()
|
||||
}
|
||||
}
|
||||
auto mid = vec.begin() + vszorig;
|
||||
#ifdef NO_PARALLEL_SORT
|
||||
#ifdef __EMSCRIPTEN__
|
||||
pdqsort_branchless( mid, vec.end() );
|
||||
#else
|
||||
std::sort( std::execution::par_unseq, mid, vec.end() );
|
||||
ppqsort::sort( ppqsort::execution::par, mid, vec.end() );
|
||||
#endif
|
||||
std::inplace_merge( vec.begin(), mid, vec.end() );
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "TracyImGui.hpp"
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include "TracyMouse.hpp"
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "TracyTimelineContext.hpp"
|
||||
#include "TracyTimelineDraw.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "TracyPrint.hpp"
|
||||
#include "TracyMouse.hpp"
|
||||
#include "TracyView.hpp"
|
||||
#include "tracy_pdqsort.h"
|
||||
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user