Skip to content

Failure to infer %arg is a constant #85559

Open
@dianqk

Description

@dianqk

I tried the following code:

define i64 @src(i64 noundef %arg) {
bb:
  switch i64 %arg, label %bb1 [
    i64 0, label %bb2
    i64 1, label %bb1
  ]

bb1:
  unreachable

bb2:
  ret i64 %arg
}

define i64 @tgt(i64 noundef %arg) {
bb:
  ret i64 0
}

We can know that %arg is zero.

alive2: https://alive2.llvm.org/ce/z/iqgz5F

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions