Skip to content

LLVM ERROR: Cannot select issue when compiling LLVM module on s390x architecture #44362

@Sidong-Wei

Description

@Sidong-Wei

System information

  • Have I written custom code (as opposed to using a stock example script provided in TensorFlow): No
  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04
  • Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: N/A
  • TensorFlow installed from (source or binary): source
  • TensorFlow version (use command below): 2.3.1
  • Python version: 3.8.5
  • Bazel version (if compiling from source): 3.1.0
  • GCC/Compiler version (if compiling from source): Ubuntu 9.3.0-17ubuntu1~20.04
  • CUDA/cuDNN version: N/A
  • GPU model and memory: N/A

Describe the current behavior
When running the test case //tensorflow/python/keras/optimizer_v2:adam_test on s390x machine, please see below for the full error stack. Apparently, it is an issue within the compiler code and the same issue is causing a lot of other test cases failures under //tensorflow/compiler/... test suite.

I investigated the issue a little bit, and I noticed that the error is thrown when executing this line

cantFail(compile_layer_.addModule(key, std::move(module)));
, i.e., when compiling the LLVM IR code into machine code. Since LLVM is supporting s390x architecture (as "SystemZ") and I manually merged the commit to include it into build target, it should be able to execute the compilation without any issue. Since the error message does not have much readable info about the error, I am kind of stuck in figuring out the cause of the issue. If anyone who is familiar with LLVM could help with debugging this issue, I will really appreciate it, thanks.

Describe the expected behavior
The compilation should work, and the test case should pass.

Other info / logs
adam_test.log

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions