iree icon indicating copy to clipboard operation
iree copied to clipboard

When --iree-llvmcpu-sanitize=address is enabled, we should auto set --iree-llvmcpu-link-embedded=false

Open stellaraccident opened this issue 2 years ago • 12 comments

The test suite futzes with this at the CMake level but that still leaves the footgun in the compiler. Specifying the first flag causes an opaque link error about missing ASAN symbols with no clue as to how to fix it.

Recommend just making this work correctly when --iree-llvmcpu-sanitize=address is specified. Then also remove the checks and manual massaging done at the CMake level for the test suite to manage the --iree-llvmcpu-link-embedded flag.

stellaraccident avatar Nov 10 '23 02:11 stellaraccident

hello,Could you give me a chance to solve this issue? Although I have limited experience in IREE, I am really interested in IREE and MLIR. @stellaraccident

harrisonGPU avatar Nov 21 '23 15:11 harrisonGPU

Go for it. Post a PR?

stellaraccident avatar Nov 21 '23 16:11 stellaraccident

Go for it. Post a PR?

Wow!Thanks for you!I'll try to reproduce this problem first, thank you very much for giving me this opportunity!

harrisonGPU avatar Nov 21 '23 23:11 harrisonGPU

Sorry, I clicked the wrong option. Could you please assign this task to me again? @stellaraccident

harrisonGPU avatar Nov 22 '23 03:11 harrisonGPU

Just let us know if you end up dropping it or not being able to do it and we'll reassign. Have fun!

stellaraccident avatar Nov 22 '23 04:11 stellaraccident

Just let us know if you end up dropping it or not being able to do it and we'll reassign. Have fun!

Okay, I will try my best to do it.

harrisonGPU avatar Nov 22 '23 04:11 harrisonGPU

hello, @stellaraccident : I have built this project using the following CMake commands:

# in iree file
cmake -G Ninja -B ../iree-build/ -S . \
    -DCMAKE_BUILD_TYPE=RelWithDebInfo \
    -DIREE_ENABLE_ASSERTIONS=ON \
    -DIREE_ENABLE_SPLIT_DWARF=ON \
    -DCMAKE_C_COMPILER=clang \
    -DCMAKE_CXX_COMPILER=clang++ \
    -DIREE_ENABLE_LLD=ON \
    -DIREE_ENABLE_ASAN=ON
# in iree-build file
cmake --build .

Could you tell me how to reproduce this issue or how to trigger a link error about missing ASAN problem? Could you please give me some advice? My platform is mac-os. Thanks to you!

harrisonGPU avatar Nov 22 '23 15:11 harrisonGPU

This commit fixes the issue. Please review: https://github.com/TSWorld1314/iree/commit/be05fdbbbfa87125b43e0bad942589958bf5b04a I submitted the code too late, I'm very sorry and thank you very much for giving me a chance as a student

harrisonGPU avatar Dec 14 '23 16:12 harrisonGPU

https://github.com/openxla/iree/pull/15934

harrisonGPU avatar Dec 15 '23 00:12 harrisonGPU

hello, @stellaraccident ,this is my Pull Request,I submitted the code too late, I'm very sorry and thank you very much for giving me a chance as a student,https://github.com/openxla/iree/pull/15934

harrisonGPU avatar Dec 15 '23 00:12 harrisonGPU

@ScottTodd I think this ticket can be closed, because of the improvements that were made in: https://github.com/openxla/iree/pull/16452

peymanbr avatar Mar 04 '24 13:03 peymanbr

@ScottTodd I think this ticket can be closed, because of the improvements that were made in: #16452

Sort of - I only changed the CMake configuration. The compiler code could still be changed (linking the flags together or giving a clear error message when one is set but not the other).

ScottTodd avatar Mar 04 '24 15:03 ScottTodd