forked from microsoft/onnxruntime
-
Notifications
You must be signed in to change notification settings - Fork 57
CVS-175119-[OVEP] Fixed possibility of array index out of bounds in subgraph partitioning #838
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 3 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
479b319
added a line to add initializers to be a part of meta_def -> inputs
RajeevSekar 9406caf
fixed possible array index out of bound problem which caused some mod…
RajeevSekar dd51bde
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar 154d895
changed loop logic
RajeevSekar 9609408
Merge branch 'rajeev/get_capability_fix' of https://github.com/intel/…
RajeevSekar 4ed9884
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar b04746f
reverting to the previous logic to ensure j value is retained and not…
RajeevSekar 92714b4
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar b63bc77
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar 8cf2fa3
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar b24d874
updated loop logic
RajeevSekar 338c03b
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar a43d040
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar ef414c0
Merge branch 'ovep-develop' into rajeev/get_capability_fix
RajeevSekar e86fb0a
Merge branch 'ovep-develop' into rajeev/get_capability_fix
preetha-intel File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we add the increment part of loop so that the additional check can be removed.
something like
while (++j < total_clusters && !append_node)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Preetha, I have made that change, thanks for pointing it out
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Preetha, due to this change of adding the increment part in the loop, an issue was created.
Old logic (larger loop)
In the case where j < total_clusters is true but append node is also true (the loop is not entered), j is not incremented
New logic (shorter loop)
In the case ++j is still < total_clusters but append node is true, the loop is not entered but j is aldready incremented (unlike the first logic).
so, just after the loop, in this block
if (append_node) {
connected_clusters[j].emplace_back(index);
}
incorrect value of j is used which causes some model to fail.
So we cant use "while (++j < total_clusters && !append_node)"
Is there a way to optimize the loop logic but retain the j if we exit the loop due to append_node == true