Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[HWToLLVM] Don't crash on OOB accesses #8214

Open
maerhart opened this issue Feb 10, 2025 · 1 comment
Open

[HWToLLVM] Don't crash on OOB accesses #8214

maerhart opened this issue Feb 10, 2025 · 1 comment

Comments

@maerhart
Copy link
Member

Operations like hw.array_get produce undefined result values, but no immediate UB. OOB loads in LLVM can cause immediate UB, so the lowerings should guard against that.

@fzi-hielscher
Copy link
Contributor

#6949 #6956

I can resurrect that PR if desired. I had the impression there was no real consensus on how to deal with this properly. Blindly running into UB is obviously a bad idea. But I'm personally not a huge fan of just sweeping the nondeterminism under the carpet. IMHO OOB accesses have a fair chance of being indicative of an actual design problem.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants