MCTS-GEB: Monte Carlo Tree Search is a Good E-graph Builder

03/08/2023
by   Guoliang He, et al.
0

Rewrite systems [6, 10, 12] have been widely employing equality saturation [9], which is an optimisation methodology that uses a saturated e-graph to represent all possible sequences of rewrite simultaneously, and then extracts the optimal one. As such, optimal results can be achieved by avoiding the phase-ordering problem. However, we observe that when the e-graph is not saturated, it cannot represent all possible rewrite opportunities and therefore the phase-ordering problem is re-introduced during the construction phase of the e-graph. To address this problem, we propose MCTS-GEB, a domain-general rewrite system that applies reinforcement learning (RL) to e-graph construction. At its core, MCTS-GEB uses a Monte Carlo Tree Search (MCTS) [3] to efficiently plan for the optimal e-graph construction, and therefore it can effectively eliminate the phase-ordering problem at the construction phase and achieve better performance within a reasonable time. Evaluation in two different domains shows MCTS-GEB can outperform the state-of-the-art rewrite systems by up to 49x, while the optimisation can generally take less than an hour, indicating MCTS-GEB is a promising building block for the future generation of rewrite systems.

READ FULL TEXT

page 5

page 6

research
05/14/2020

Solve Traveling Salesman Problem by Monte Carlo Tree Search and Deep Neural Network

We present a self-learning approach that combines deep reinforcement lea...
research
02/11/2021

Hedging of Financial Derivative Contracts via Monte Carlo Tree Search

The construction of approximate replication strategies for pricing and h...
research
10/28/2018

P-MCGS: Parallel Monte Carlo Acyclic Graph Search

Recently, there have been great interests in Monte Carlo Tree Search (MC...
research
03/02/2020

AutoPhase: Juggling HLS Phase Orderings in Random Forests with Deep Reinforcement Learning

The performance of the code a compiler generates depends on the order in...
research
02/12/2018

ReinforceWalk: Learning to Walk in Graph with Monte Carlo Tree Search

Learning to walk over a graph towards a target node for a given input qu...
research
08/28/2023

Target-independent XLA optimization using Reinforcement Learning

An important challenge in Machine Learning compilers like XLA is multi-p...
research
05/27/2021

Anomalous phase separation and hidden coarsening of super-clusters in the Falicov-Kimball model

We show that the celebrated Falicov-Kimball model exhibits rich and intr...

Please sign up or login with your details

Forgot password? Click here to reset