Stream: git-wasmtime

Topic: wasmtime / issue #3743 Cranelift: ISLE extraction panics


view this post on Zulip Wasmtime GitHub notifications bot (Jan 29 2022 at 00:07):

abrown opened issue #3743:

When I create a new extractor, one to extract the comparison flag from a comparison referenced by select, ISLE panics.

Steps to Reproduce

Add:

(decl select_fcmp_flag (FloatCC) Inst)
(extractor (select_fcmp_flag comparison_flag)
      (select (def_inst (fcmp comparison_flag a b)) x y))

Then run:

cargo build -p cranelift-codegen --features rebuild-isle

Expected Results

The ISLE code to generate without failure.

Actual Results

  --- stderr
  thread 'main' panicked at 'assertion failed: !tyenv.errors.is_empty()', cranelift/isle/isle/src/sema.rs:1055:29
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Versions and Environment

Cranelift version or commit: latest HEAD

view this post on Zulip Wasmtime GitHub notifications bot (Jan 29 2022 at 00:07):

abrown labeled issue #3743:

When I create a new extractor, one to extract the comparison flag from a comparison referenced by select, ISLE panics.

Steps to Reproduce

Add:

(decl select_fcmp_flag (FloatCC) Inst)
(extractor (select_fcmp_flag comparison_flag)
      (select (def_inst (fcmp comparison_flag a b)) x y))

Then run:

cargo build -p cranelift-codegen --features rebuild-isle

Expected Results

The ISLE code to generate without failure.

Actual Results

  --- stderr
  thread 'main' panicked at 'assertion failed: !tyenv.errors.is_empty()', cranelift/isle/isle/src/sema.rs:1055:29
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Versions and Environment

Cranelift version or commit: latest HEAD

view this post on Zulip Wasmtime GitHub notifications bot (Jan 29 2022 at 00:07):

abrown labeled issue #3743:

When I create a new extractor, one to extract the comparison flag from a comparison referenced by select, ISLE panics.

Steps to Reproduce

Add:

(decl select_fcmp_flag (FloatCC) Inst)
(extractor (select_fcmp_flag comparison_flag)
      (select (def_inst (fcmp comparison_flag a b)) x y))

Then run:

cargo build -p cranelift-codegen --features rebuild-isle

Expected Results

The ISLE code to generate without failure.

Actual Results

  --- stderr
  thread 'main' panicked at 'assertion failed: !tyenv.errors.is_empty()', cranelift/isle/isle/src/sema.rs:1055:29
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Versions and Environment

Cranelift version or commit: latest HEAD

view this post on Zulip Wasmtime GitHub notifications bot (Jan 29 2022 at 00:07):

abrown commented on issue #3743:

cc: @fitzgen

view this post on Zulip Wasmtime GitHub notifications bot (Jan 31 2022 at 18:20):

fitzgen commented on issue #3743:

Standalone reproducer test case:

(type FloatCC (enum))
(type Inst (enum))
(type Value (enum))

(type ValueArray2 (enum))
(decl value_array_2 (Value Value) ValueArray2)
(extern constructor value_array_2 pack_value_array_2)
(extern extractor infallible value_array_2 unpack_value_array_2)

(type ValueArray3 (enum))
(decl value_array_3 (Value Value Value) ValueArray3)
(extern constructor value_array_3 pack_value_array_3)
(extern extractor infallible value_array_3 unpack_value_array_3)

(decl inst_data (InstructionData) Inst)
(extern extractor infallible inst_data inst_data)

(type Opcode extern (enum Fcmp Select))

(type InstructionData (enum (FloatCompare (opcode Opcode) (args ValueArray2) (cond FloatCC))
                            (Ternary (opcode Opcode) (args ValueArray3))))

(decl def_inst (Inst) Value)
(extern extractor def_inst def_inst)

(decl fcmp (FloatCC Value Value) Inst)
(extractor
 (fcmp Cond x y)
 (inst_data (InstructionData.FloatCompare (Opcode.Fcmp) (value_array_2 x y) Cond)))

(decl select (Value Value Value) Inst)
(extractor
 (select c x y)
 (inst_data (InstructionData.Ternary (Opcode.Select) (value_array_3 c x y))))

(decl select_fcmp_flag (FloatCC) Inst)
(extractor (select_fcmp_flag comparison_flag)
           (select (def_inst (fcmp comparison_flag a b)) x y))

view this post on Zulip Wasmtime GitHub notifications bot (Feb 14 2022 at 19:22):

fitzgen labeled issue #3743:

When I create a new extractor, one to extract the comparison flag from a comparison referenced by select, ISLE panics.

Steps to Reproduce

Add:

(decl select_fcmp_flag (FloatCC) Inst)
(extractor (select_fcmp_flag comparison_flag)
      (select (def_inst (fcmp comparison_flag a b)) x y))

Then run:

cargo build -p cranelift-codegen --features rebuild-isle

Expected Results

The ISLE code to generate without failure.

Actual Results

  --- stderr
  thread 'main' panicked at 'assertion failed: !tyenv.errors.is_empty()', cranelift/isle/isle/src/sema.rs:1055:29
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Versions and Environment

Cranelift version or commit: latest HEAD

view this post on Zulip Wasmtime GitHub notifications bot (Feb 14 2022 at 19:25):

github-actions[bot] commented on issue #3743:

Subscribe to Label Action

cc @cfallin, @fitzgen

<details>
This issue or pull request has been labeled: "isle"

Thus the following users have been cc'd because of the following labels:

To subscribe or unsubscribe from this label, edit the <code>.github/subscribe-to-label.json</code> configuration file.

Learn more.
</details>


Last updated: Nov 22 2024 at 16:03 UTC