-
Notifications
You must be signed in to change notification settings - Fork 12k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[mlir] Lit tests fail after 2d2da25 #55992
Comments
@llvm/issue-subscribers-mlir-llvm |
Hello, with @joker-eph 's commends, I can reproduce the fail locally. I spent one day to investigate the problem, but I still didn't root cause it due to limited knowledge on mlir. Here are what I got for now:
Error message
Backtrace at the crash point:
I can find the problem is
I once traced from frame Note, the patch has beed reverted, please apply 2d2da25 if you want to help with this. Thanks! |
there shouldn’t be much that is MLIR specific here: MLIR will emit LLVM IT and JIT it before executing it. @aartbik should be able to help to get the IR and maybe a reproducer that does not involve the JIT |
Does the patch change the ABI in any way? We are trying to call
but perhaps the f16 has some "padding" applied, causing corruptions of all other parameters.
we "fixed" this as
See around
|
Thanks @joker-eph @aartbik
If you are asking the
Not padding but register class. IIUC, the problem is the jitted code passes the data in FPR while the ExecutionEngine expected the data is in GPR? If this is true, I think it's a problem of ExecutionEngine that has false ABI assumption on half type: https://github.com/llvm/llvm-project/blob/main/mlir/lib/ExecutionEngine/Float16bits.cpp#L33 Previously, Clang doesn't have ABI for half type and blocks arguments passing for it. The implementation above looks like a workaround to me. My patch is to enable the ABI and (will) allow pass half type by In conclusion, I think I can land the patch and disable both tests temporaryly. I'll put comments to point to this issue, but I may not be able to fix it. WDYT? |
It's not clear to me that we need to think in terms of register class here. I see it as an LLVM IR problem: we write our runtime in C/C++ and we are trying to interact with it when generating LLVM IR ourselves from a non-C source (MLIR). The question to me is whether we can generate the right signatures for our runtime in LLVM IR that matches what clang will generate when compiling the runtime. |
I understand the problem is the runtime uses a workaround that using I think the right direction is to use |
I am okay if you disable the two tests for now just so you can make progress. Please add this bug somewhere in the comment when you do so, so we can find a proper fix afterwards. |
…e psABI" Disabled 2 mlir tests due to the runtime doesn't support `_Float16`, see the issue here #55992
Note that https://reviews.llvm.org/D128018 fixes the ABI issues hopefully once and for all (since we use memref's now for all non-trivially typed data). We should be able to re-enable the tests again. |
Sparse library ABI issues are fixed. #55992 Reviewed By: bkramer Differential Revision: https://reviews.llvm.org/D128086
@llvm/issue-subscribers-mlir |
Supposedly our ABI issues were fixed, per issue: #55992 However, with a recent changes to bf16, these tests fail again; not sure why yet: https://reviews.llvm.org/D130832 https://lab.llvm.org/buildbot/#/builders/61/builds/30600 So we disable the tests for now. Issue is tracked in: #57042 Differential Revision: https://reviews.llvm.org/D131621
Supposedly our ABI issues were fixed, per issue: llvm/llvm-project#55992 However, with a recent changes to bf16, these tests fail again; not sure why yet: https://reviews.llvm.org/D130832 https://lab.llvm.org/buildbot/#/builders/61/builds/30600 So we disable the tests for now. Issue is tracked in: llvm/llvm-project#57042 Differential Revision: https://reviews.llvm.org/D131621 (cherry picked from commit 6b74591)
Supposedly our ABI issues were fixed, per issue: llvm/llvm-project#55992 However, with a recent changes to bf16, these tests fail again; not sure why yet: https://reviews.llvm.org/D130832 https://lab.llvm.org/buildbot/#/builders/61/builds/30600 So we disable the tests for now. Issue is tracked in: llvm/llvm-project#57042 Differential Revision: https://reviews.llvm.org/D131621 (cherry picked from commit 6b74591)
Supposedly our ABI issues were fixed, per issue: llvm/llvm-project#55992 However, with a recent changes to bf16, these tests fail again; not sure why yet: https://reviews.llvm.org/D130832 https://lab.llvm.org/buildbot/#/builders/61/builds/30600 So we disable the tests for now. Issue is tracked in: llvm/llvm-project#57042 Differential Revision: https://reviews.llvm.org/D131621 (cherry picked from commit 6b74591)
…e psABI" Disabled 2 mlir tests due to the runtime doesn't support `_Float16`, see the issue here llvm/llvm-project#55992
Supposedly our ABI issues were fixed, per issue: llvm/llvm-project#55992 However, with a recent changes to bf16, these tests fail again; not sure why yet: https://reviews.llvm.org/D130832 https://lab.llvm.org/buildbot/#/builders/61/builds/30600 So we disable the tests for now. Issue is tracked in: llvm/llvm-project#57042 Differential Revision: https://reviews.llvm.org/D131621 (cherry picked from commit 6b7459115f7b1c43f81ad8dfb5da9d206d3b1e06)
Hello, I just landed a patch to support FP16 emulation on X86: 2d2da25. Then I received a Buildbot notifaction from https://lab.llvm.org/buildbot#builders/61/builds/27616, where reported 2 failed tests:
I don't have any experiences on mlir and my local run show "Unsupported" on both tests.
Could anyone tell me how can I reproduce it locally, or help to generate a LLVM IR for me? Thanks!
The text was updated successfully, but these errors were encountered: