Skip to content

Add an underlying type to the halide_buffer_flags to prevent UB in C++#8690

Merged
mcourteaux merged 2 commits intohalide:mainfrom
mcourteaux:fix-8688
Aug 1, 2025
Merged

Add an underlying type to the halide_buffer_flags to prevent UB in C++#8690
mcourteaux merged 2 commits intohalide:mainfrom
mcourteaux:fix-8688

Conversation

@mcourteaux
Copy link
Contributor

@mcourteaux mcourteaux commented Jul 14, 2025

Fix halide#8688).

Co-authored-by: Alex Reinking <alex.reinking@gmail.com>
@mcourteaux
Copy link
Contributor Author

Can @abadams or @zvookin confirm that this is not an ABI breaking change?

@mcourteaux
Copy link
Contributor Author

@alexreinking error: cannot open '.git/FETCH_HEAD': No space left on device 😨

@alexreinking
Copy link
Member

Fuzz test failed:

4154495015
Error: Signed integer overflow occurred during constant-folding. Signed integer overflow for int32 and int64 is undefined behavior in Halide.

Copy link
Member

@abadams abadams left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe there are no ABI implications because the only thing this is ever passed to is always_inline.

@mcourteaux mcourteaux merged commit 55084ef into halide:main Aug 1, 2025
16 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Proposal: change halide_buffer_flags from enum to uint64_t.

3 participants