Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Conflicting defs and clobbers lead to panic rather than clean error from allocator

オープン
#222 コメント 4 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
rust
領域
compilers

調査の方向性

regalloc2 v0.12.0 で、提供された関数または JSON 表現を使用して panic を再現します。ion/process.rs:1253 から開始し、競合する定義と clobbers を処理する allocator の経路を追跡します。この入力が panic ではなく正常な allocator エラーを生成すれば完了です。

索引モデルが issue の本文から書いたものです。

説明

regalloc2 v0.12.0

thread 'main' panicked at /home/maxv/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/regalloc2-0.12.0/src/ion/process.rs:1253:17:
Could not allocate minimal bundle, but the allocation problem should be possible to solve

Function which causes a panic:

Debug repr
{
  machine_env: MachineEnv {
    preferred_regs_by_class: [
        [
            PReg(hw = 0, class = Int, index = 0),
            PReg(hw = 1, class = Int, index = 1),
            PReg(hw = 2, class = Int, index = 2),
        ],
        [],
        [],
    ],
    non_preferred_regs_by_class: [
        [],
        [],
        [],
    ],
    scratch_by_class: [
        None,
        None,
        None,
    ],
    fixed_stack_slots: [],
}
  spillslot_size(Int): 1
  spillslot_size(Float): 1
  spillslot_size(Vector): 1
  multi_spillslot_named_by_last_slot: false
  allow_multiple_vreg_defs: false
  block0(): # succs:[] preds:[]
    inst0: op Def: v0i any
    inst1: op Def: v1i fixed(p0i), Use: v0i fixed(p1i), Clobber: p0i, Clobber: p1i, Clobber: p2i
    inst2: ret Use: v1i fixed(p0i)
}
JSON repr
{
  "machine_env": {
    "preferred_regs_by_class": [
      [
        {
          "bits": 0
        },
        {
          "bits": 1
        },
        {
          "bits": 2
        }
      ],
      [],
      []
    ],
    "non_preferred_regs_by_class": [
      [],
      [],
      []
    ],
    "scratch_by_class": [
      null,
      null,
      null
    ],
    "fixed_stack_slots": []
  },
  "entry_block": 0,
  "insts": [
    {
      "op": "Op",
      "operands": [
        {
          "bits": 8388609
        }
      ],
      "clobbers": {
        "bits": [
          0,
          0,
          0,
          0
        ]
      }
    },
    {
      "op": "Op",
      "operands": [
        {
          "bits": 2155872256
        },
        {
          "bits": 2197815297
        }
      ],
      "clobbers": {
        "bits": [
          7,
          0,
          0,
          0
        ]
      }
    },
    {
      "op": "Ret",
      "operands": [
        {
          "bits": 2164260864
        }
      ],
      "clobbers": {
        "bits": [
          0,
          0,
          0,
          0
        ]
      }
    }
  ],
  "blocks": [
    [
      0,
      3
    ]
  ],
  "block_preds": [
    []
  ],
  "block_succs": [
    []
  ],
  "block_params_in": [
    []
  ],
  "block_params_out": [
    []
  ],
  "num_vregs": 2,
  "debug_value_labels": [],
  "spillslot_size": [
    1,
    1,
    1
  ],
  "multi_spillslot_named_by_last_slot": false,
  "allow_multiple_vreg_defs": false
}
主要言語
Rust
スター
266
フォーク
55
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

bytecodealliance/regalloc2 のほかの issue

bytecodealliance/regalloc2 の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。