Skip to content

Conversation

xuhancn
Copy link
Collaborator

@xuhancn xuhancn commented Jun 26, 2025

Background:

During my development work, I found Windows msvc don't support to compile zero size array, please reference: #153180

As discussed with MSFT engineer, we found zero size array don't align to c++ standard, though gcc/clang can support it. When we add -pedantic option to gcc, it should check and raise c++ standard strictly. Reference: #153180 (comment)

So this PR add -pedantic to torch inductor build option list to constraint codegen generate c++ standard well code.
Additional, It also fixed a halide zero size array code.

cc @voznesenskym @penguinwu @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @ipiszy @chenyang78 @kadeng @muchulee8 @amjames @chauhang @aakhundov

Copy link

pytorch-bot bot commented Jun 26, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/156914

Note: Links to docs will display an error until the docs builds have been completed.

✅ You can merge normally! (1 Unrelated Failure)

As of commit 6439c1f with merge base fe1f1a3 (image):

UNSTABLE - The following job is marked as unstable, possibly due to flakiness on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@xuhancn xuhancn added topic: not user facing topic category ciflow/trunk Trigger trunk jobs on your pull request labels Jun 26, 2025
@xuhancn
Copy link
Collaborator Author

xuhancn commented Jun 26, 2025

@pytorchbot rebase

@pytorchmergebot
Copy link
Collaborator

@pytorchbot started a rebase job onto refs/remotes/origin/viable/strict. Check the current status here

@pytorchmergebot
Copy link
Collaborator

Successfully rebased xu_add_pedabtic_opt onto refs/remotes/origin/viable/strict, please pull locally before adding more changes (for example, via git checkout xu_add_pedabtic_opt && git pull --rebase)

@xuhancn xuhancn changed the title add pedantic to limit inductor code follow standard. [don't merge] add pedantic to limit inductor code follow standard. Jun 26, 2025
@xuhancn xuhancn changed the title [don't merge] add pedantic to limit inductor code follow standard. [Inductor] add pedantic to limit inductor code follow standard. Jun 30, 2025
@xuhancn xuhancn requested a review from jansel June 30, 2025 07:58
@xuhancn
Copy link
Collaborator Author

xuhancn commented Jun 30, 2025

Hi @jansel This PR is extend the PR: #156543, which fixed zero size array issue. Please review it, thanks.

@jansel
Copy link
Contributor

jansel commented Jun 30, 2025

@pytorchbot merge

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants