This is an archive of the discontinued LLVM Phabricator instance.

[Attributor] Use the whitelist for attributes consistently
ClosedPublic

Authored by jdoerfert on Aug 28 2019, 4:31 PM.

Details

Summary

We create attributes on-demand so we need to check the whitelist
on-demand. This also unifies the location at which we create and
initialize new abstract attributes.

Diff Detail

Repository
rL LLVM

Event Timeline

jdoerfert created this revision.Aug 28 2019, 4:31 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 28 2019, 4:31 PM
jdoerfert updated this revision to Diff 217762.Aug 28 2019, 7:29 PM

Update tests

uenoku added inline comments.Aug 29 2019, 12:18 AM
llvm/include/llvm/Transforms/IPO/Attributor.h
777 ↗(On Diff #217762)

register

llvm/lib/Transforms/IPO/Attributor.cpp
1308–1309 ↗(On Diff #217762)

I'm not sure why this check is here. Why not in initialize?

jdoerfert marked an inline comment as done.Aug 29 2019, 5:54 AM
jdoerfert added inline comments.
llvm/lib/Transforms/IPO/Attributor.cpp
1308–1309 ↗(On Diff #217762)

Fair point, I'll move them in to initialize.

jdoerfert updated this revision to Diff 217867.Aug 29 2019, 7:09 AM

Update according to comments

uenoku accepted this revision.Aug 29 2019, 7:51 AM

LGTM

This revision is now accepted and ready to land.Aug 29 2019, 7:51 AM
This revision was automatically updated to reflect the committed changes.