MCPcopy Create free account
hub / github.com/FEX-Emu/FEX / InitFile

Method InitFile

FEXCore/Source/Common/JitSymbols.cpp:18–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16}
17
18void JITSymbols::InitFile() {
19 // We can't use FILE here since we must be robust against forking processes closing our FD from under us.
20#ifdef __ANDROID__
21 // Android simpleperf looks in /data/local/tmp instead of /tmp
22 const auto PerfMap = fextl::fmt::format("/data/local/tmp/perf-{}.map", getpid());
23#else
24 const auto PerfMap = fextl::fmt::format("/tmp/perf-{}.map", getpid());
25#endif
26 fd = open(PerfMap.c_str(), O_CREAT | O_TRUNC | O_WRONLY | O_APPEND, 0644);
27}
28
29void JITSymbols::RegisterNamedRegion(const void* HostAddr, uint32_t CodeSize, std::string_view Name) {
30 if (fd == -1) {

Callers 1

ContextImplMethod · 0.80

Calls 2

formatFunction · 0.85
getpidFunction · 0.85

Tested by

no test coverage detected