Skip to content

Commit c669844

Browse files
aengelkeronlieb
authored andcommitted
[IR] Don't verify module flags on every access (llvm#102153)
8b4306c introduced validity checks for every module flag access, because the auto-upgrader uses named metadata before verifying the module. This causes overhead for all other accesses, and the check is, in fact, only need at that single place. Change the upgrader to be careful when accessing module flags before the module is verified and remove the checks on all other occasions. There are two tangential optimizations included: first, when querying a specific flag, don't enumerate all other flags into a vector as well. Second, don't use a Twine for getNamedMetadata(), which has materialization overhead -- all call sites use simple strings that can be implicitly converted to a StringRef. Change-Id: I724c67e52f080caba6bc16ec983f6118429408a1
1 parent 125dba7 commit c669844

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

revert_patches.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,6 @@ dfeb3991fb48 Remove the `x86_mmx` IR type. (#98505)
103103
b7e4fba6e5dc Cleanup x86_mmx after removing IR type (#100646) (Reason: dependent on dfeb3991fb48)
104104
Ron: still broken 9-6-24
105105
---
106-
Revert: causing issues with IRVerifiery heterodebug
107-
[IR] Don't verify module flags on every access (#102153)
108-
Ron
109-
---
110106
revert: 1ca9fe6db334 Reapply "[Attributor][AMDGPU] Enable AAIndirectCallInfo for AMDAttributor
111107
---
112108
revert : breaks build of amdgpu flat intrinsics

0 commit comments

Comments
 (0)