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

[DevMSAN] Fix missed symbols __msan_memset & __msan_warning #16477

Open
wants to merge 4 commits into
base: sycl
Choose a base branch
from

Conversation

zhaomaosu
Copy link
Contributor

No description provided.

@zhaomaosu zhaomaosu requested a review from a team as a code owner December 26, 2024 03:25
Comment on lines 208 to 210
MSAN_MEMSET(0);
MSAN_MEMSET(1);
MSAN_MEMSET(3);
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
MSAN_MEMSET(0);
MSAN_MEMSET(1);
MSAN_MEMSET(3);
MSAN_MEMSET(0)
MSAN_MEMSET(1)
MSAN_MEMSET(3)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

const std::string Suffix = "_p" + itostr(FirstArgAS);
PointerType *FirstArgPtrTy = IRB.getPtrTy(FirstArgAS);
MemsetOffloadFn[FirstArgAS] = M.getOrInsertFunction(
"__msan_memset" + Suffix, TLI.getAttrList(C, {1}, true),
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
"__msan_memset" + Suffix, TLI.getAttrList(C, {1}, true),
"__msan_memset" + Suffix, TLI.getAttrList(C, {1}, /*Signed=*/true),

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

Comment on lines +17 to +19
sycl::range<1>{2}, [=](sycl::id<1> ID) {
B[ID] = sycl::int3{(sycl::int3)ID[0]} / B[ID];
});
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it a memset test?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's hard to construct a stable memset test since the call to memset is insert by compiler.

Copy link
Contributor

@AllanZyne AllanZyne left a comment

Choose a reason for hiding this comment

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

LGTM

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.

2 participants