Page MenuHomePhabricator

[IR] Mark memset.* intrinsics as IntrWriteMem.
ClosedPublic

Authored by fhahn on Jan 15 2020, 10:18 AM.

Details

Summary

llvm.memset intrinsics do only write memory, but are missing
IntrWriteMem, so they doesNotReadMemory() returns false for them.

The test change is due to the test checking the fn attribute ids at the
call sites, which got bumped up due to a new combination with writeonly
appearing in the test file.

Diff Detail

Event Timeline

fhahn created this revision.Jan 15 2020, 10:18 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 15 2020, 10:18 AM

Unit tests: fail. 61900 tests passed, 3 failed and 782 were skipped.

failed: LLVM.Analysis/BasicAA/cs-cs.ll
failed: LLVM.Transforms/InstCombine/malloc-free-delete.ll
failed: LLVM.Transforms/ObjCARC/nested.ll

clang-tidy: unknown.

clang-format: pass.

Build artifacts: diff.json, clang-format.patch, CMakeCache.txt, console-log.txt, test-results.xml

Can you comment on the test failures?

jdoerfert accepted this revision.Jan 15 2020, 11:04 AM

Can you comment on the test failures?

I looked at them and they are harmless.

Assuming you fix the tests this LGTM.

This revision is now accepted and ready to land.Jan 15 2020, 11:04 AM
fhahn updated this revision to Diff 238327.Jan 15 2020, 11:50 AM

Fix test failures, caused by checking fn attribute ids and now memset creates a new attribute combo.

jdoerfert accepted this revision.Jan 15 2020, 12:05 PM

LGTM :)

Unit tests: pass. 61905 tests passed, 0 failed and 782 were skipped.

clang-tidy: unknown.

clang-format: pass.

Build artifacts: diff.json, clang-format.patch, CMakeCache.txt, console-log.txt, test-results.xml

This revision was automatically updated to reflect the committed changes.