update tracy from 11.0 to 13.1 and fix build with tracy enabled

This commit is contained in:
Sven Balzer
2026-05-01 18:24:04 +02:00
parent 7fa5294e02
commit 2adf75973a
304 changed files with 20579 additions and 170182 deletions
+1 -2
View File
@@ -2,7 +2,6 @@ cmake_minimum_required(VERSION 3.16)
option(NO_ISA_EXTENSIONS "Disable ISA extensions (don't pass -march=native or -mcpu=native to the compiler)" OFF)
option(NO_STATISTICS "Disable calculation of statistics" ON)
option(NO_PARALLEL_STL "Disable parallel STL" OFF)
include(${CMAKE_CURRENT_LIST_DIR}/../cmake/version.cmake)
@@ -21,7 +20,7 @@ include(${CMAKE_CURRENT_LIST_DIR}/../cmake/server.cmake)
add_executable(tracy-import-chrome
src/import-chrome.cpp
)
target_link_libraries(tracy-import-chrome PRIVATE TracyServer)
target_link_libraries(tracy-import-chrome PRIVATE TracyServer nlohmann_json::nlohmann_json)
add_executable(tracy-import-fuchsia
src/import-fuchsia.cpp
+3 -5
View File
@@ -3,13 +3,14 @@
#endif
#include <fstream>
#include <nlohmann/json.hpp>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unordered_map>
#include <sys/stat.h>
#include <unordered_map>
#include <zstd.h>
#ifdef _MSC_VER
# define stat64 _stat64
@@ -18,12 +19,9 @@
# define stat64 stat
#endif
#include "json.hpp"
#include "../../server/TracyFileWrite.hpp"
#include "../../server/TracyMmap.hpp"
#include "../../server/TracyWorker.hpp"
#include "../../zstd/zstd.h"
using json = nlohmann::json;
+8 -3
View File
@@ -15,10 +15,10 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <unordered_map>
#include <variant>
#include <sys/stat.h>
#include <zstd.h>
#ifdef _MSC_VER
#define stat64 _stat64
@@ -30,7 +30,6 @@
#include "../../server/TracyFileWrite.hpp"
#include "../../server/TracyMmap.hpp"
#include "../../server/TracyWorker.hpp"
#include "../../zstd/zstd.h"
void Usage() {
printf("Usage: import-fuchsia input.json output.tracy\n\n");
@@ -189,6 +188,12 @@ std::pair<bool, Record> read_next_record(std::vector<uint8_t> const &input, size
CHECK_BOUND(offset + 8*len_word);
Record r{(uint64_t *)&input[offset], len_word, header};
if (len_word == 0) {
fprintf(stderr, "warning: invalid record with length=0 at offset %" PRIu64 "\n", offset); \
return std::make_pair(false,Record{}); \
}
offset += 8 * len_word;
return std::make_pair(true, r);
}
File diff suppressed because it is too large Load Diff