Skip to content
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

Supply more unique UUIDs for PDIs in aie2xclbin #1163

Closed
wants to merge 1 commit into from

Conversation

erieaton-amd
Copy link
Collaborator

Windows driver expects these values to actually be unique, it causes a problem if you try to create multiple hardware contexts for multiple xclbins.

@@ -441,7 +441,7 @@ static LogicalResult generateXCLBin(MLIRContext *context, ModuleOp moduleOp,
openOutputFile(aiePartitionJsonFile, &errorMessage);
if (!aiePartitionJsonOut)
return moduleOp.emitOpError(errorMessage);

uint64_t time = std::chrono::high_resolution_clock::now().time_since_epoch().count();
Copy link
Collaborator

Choose a reason for hiding this comment

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

Would hashing the design be more reasonable?

Copy link
Collaborator

Choose a reason for hiding this comment

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

In aiecc.py we use a random int with a small range, which is not super collision resistant. Maybe hash the time plus the design? So that parallel builds (same time) or rebuilds of the same design (e.g. after a fix) don't collide?

Windows driver expects these values to actually be unique, it causes a
problem if you try to create multiple hardware contexts for multiple
xclbins.
@kumardeepakamd
Copy link

Windows driver expects these values to actually be unique, it causes a problem if you try to create multiple hardware contexts for multiple xclbins.

@kumardeepakamd
Copy link

Should we not actually generate a uuid / guid by making a call such as RPC_STATUS status = UuidCreate(&uuid);

@stephenneuendorffer
Copy link
Collaborator

Obsoleted by #1513

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.

None yet

4 participants