Conflicting defs and clobbers lead to panic rather than clean error from allocator
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Reproduce the panic using the supplied function or JSON representation with regalloc2 v0.12.0. Start at ion/process.rs:1253 and trace the allocator path handling the conflicting definitions and clobbers. Done means this input produces a clean allocation error rather than a panic.
Written by the indexing model from the issue text.
Description
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
}
- Dominant language
- Rust
- Stars
- 266
- Forks
- 54
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from bytecodealliance/regalloc2
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
bytecodealliance/regalloc2#265 · 8 comments ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
bytecodealliance/regalloc2#247 · 3 comments ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
bytecodealliance/regalloc2#206 · 2 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
bytecodealliance/regalloc2#194 · 7 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 38/100
bytecodealliance/regalloc2#191 · 3 comments ·
All issues in bytecodealliance/regalloc2
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
state:needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
zed-industries/zed#64680 · 2 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
RustPython/RustPython#8802 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
TheLarkInn/aipm#2390 ·