Back to Eliza

AlphaChip Macro Placement Research Index

packages/chip/research/alpha_chip_macro_placement/00_index.md

2.0.12.7 KB
Original Source

AlphaChip Macro Placement Research Index

Goal: get E1 to the point where macro placement candidates can be generated by Google Circuit Training / AlphaChip, imported into the existing OpenLane/OpenROAD flow, and judged by physical-design evidence rather than proxy reward alone.

Current setup

  • external/circuit_training: Google Circuit Training checkout, pinned to r0.0.4 for the stable Docker path.
  • external/MacroPlacement: TILOS MacroPlacement checkout for public datasets, format translators, and evaluator context.
  • scripts/alphachip/: local wrappers for Docker build, smoke tests, toy training, setup checks, and Nebius H200 notes.
  • /tmp/e1-alphachip/: generated local logs and checkpoints when repo-local build/ is not writable. The current checkout has a root-owned build/ directory, so wrappers fall back to this path.

Verified locally

  • Circuit Training Docker image circuit_training:e1-r0.0.4 builds and runs.
  • Google GCS binaries for plc_wrapper_main and DREAMPlace were inaccessible during setup. The image uses the Farama A2Perf plc_wrapper_main binary and a DREAMPlace import stub, which is valid only with --std_cell_placer_mode=fd.
  • Toy AlphaChip training completed with Reverb, two collect workers, learner, policy checkpoints, and saved policies under /tmp/e1-alphachip/toy.
  • OpenLane Docker flow completed for e1_pd_smoke_top and produced final DEF, GDS, ODB, and metrics under pd/openlane/runs/RUN_2026-05-19_03-33-45/final.

Practical pipeline

  1. Build the Circuit Training Docker image.
  2. Run upstream smoke/toy training to validate the environment.
  3. Generate or collect E1 LEF/DEF/netlist collateral from OpenLane/OpenROAD.
  4. Convert E1 placement input to Circuit Training protobuf plus initial PLC.
  5. Run AlphaChip training or fine-tuning.
  6. Convert candidate placement back to DEF.
  7. Import DEF into an exploratory OpenLane config with FP_DEF_TEMPLATE.
  8. Accept/reject candidates using OpenLane/OpenROAD timing, routing, DRC, LVS, antenna, power, and PDN evidence.

First commands

sh
scripts/alphachip/check_setup.sh
scripts/alphachip/build_container.sh
scripts/alphachip/run_toy_training.sh

The current local image defaults to force-directed standard-cell placement:

sh
STD_CELL_PLACER_MODE=fd scripts/alphachip/run_toy_training.sh

For local GPU smoke, build the GPU image and run:

sh
ALPHACHIP_GPU_IMAGE=1 scripts/alphachip/build_container.sh
USE_GPU=True scripts/alphachip/run_toy_training.sh

Key caveat

AlphaChip optimizes proxy wirelength/congestion/density. It is not signoff. The source of truth remains the E1 physical-design flow under pd/, especially OpenLane/OpenROAD runs and scripts/check_pd_signoff.py.