Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ir] Remove unnecessary field_dims_ in ArgLoadStmt (taichi-dev#7755)
Issue: # ### Brief Summary <!-- copilot:summary --> ### <samp>🤖 Generated by Copilot at 3b1f7b3</samp> This pull request refactors the `ArgLoadStmt` class and the related passes to simplify the handling of external tensors. It removes the redundant fields `external_dims` and `field_dims_` from the `ArgLoadStmt` class, and updates the `lower_matrix_ptr` and `type_check` passes accordingly. ### Walkthrough <!-- copilot:walkthrough --> ### <samp>🤖 Generated by Copilot at 3b1f7b3</samp> * Remove the external_dims field and the field_dims_ field from the ArgLoadStmt class to simplify the handling of external tensors ([link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-a6e92dd2dd707d705dc44ef91463ddc0423575188e6e8e0555de9e439db88c35L591-L593), [link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-917d9436dcaafa0f1e41ae9bad90273a303f036f00da94e417788a7fa1dc5260L183-R183), [link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-917d9436dcaafa0f1e41ae9bad90273a303f036f00da94e417788a7fa1dc5260L190-L192), [link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-917d9436dcaafa0f1e41ae9bad90273a303f036f00da94e417788a7fa1dc5260L201-R200)) * Update the ret_type of the base_ptr of the ExternalPtrStmt in the lower_matrix_ptr pass to match the ret_type of the ExternalPtrStmt with flattened indices ([link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-9b36b48490841b4018aca81632ae1beac3b2fdf1ee95a5c65eb42b676654b82eL69-R72)) * Simplify the logic of the type check pass for the ExternalPtrStmt by using the ret_type of the base_ptr as the default ret_type of the ExternalPtrStmt ([link](https://github.com/taichi-dev/taichi/pull/7755/files?diff=unified&w=0#diff-dd572dab7be4dbb5edc1043d6d6339b931ef35198b8657761ebf45a83e76ac2bL453-R459))
- Loading branch information