Skip to content

Commit

Permalink
DaemonManager.cpp: disable JIT on macOS ARM
Browse files Browse the repository at this point in the history
  • Loading branch information
selsta committed Apr 19, 2023
1 parent f650e96 commit 6c4a8fb
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/daemon/DaemonManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,17 @@ bool DaemonManager::start(const QString &flags, NetworkType::Type nettype, const
connect(m_daemon.get(), SIGNAL(readyReadStandardOutput()), this, SLOT(printOutput()));
connect(m_daemon.get(), SIGNAL(readyReadStandardError()), this, SLOT(printError()));

// Start monerod
bool started = m_daemon->startDetached(m_monerod, arguments);
#if defined(Q_OS_MAC) && defined(__aarch64__)
// RandomX crashes with JIT enabled when started as a detached process, disable it for now
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
env.insert("MONERO_RANDOMX_UMASK", "8");
m_daemon->setProcessEnvironment(env);
#endif

m_daemon->setProgram(m_monerod);
m_daemon->setArguments(arguments);
bool started = m_daemon->startDetached();


// add state changed listener
connect(m_daemon.get(), SIGNAL(stateChanged(QProcess::ProcessState)), this, SLOT(stateChanged(QProcess::ProcessState)));
Expand Down

0 comments on commit 6c4a8fb

Please sign in to comment.