Commit 72fad53
committed
Remove allocations due to copying target Triple to local variable.
The isPlatformActive() function wants to choose between Target and TargetVariant.
It currently copies in to a local to do this, but Triple contains strings which result
in allocations for the copy.
This uses a pointer instead, to avoid the allocations entirely, reducing total allocations
in the compiler by 5%.
rdar://1178797681 parent b7d8a9b commit 72fad53
1 file changed
+3
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | | - | |
147 | | - | |
148 | 146 | | |
149 | 147 | | |
150 | | - | |
| 148 | + | |
| 149 | + | |
151 | 150 | | |
152 | 151 | | |
153 | | - | |
| 152 | + | |
154 | 153 | | |
155 | 154 | | |
156 | 155 | | |
| |||
0 commit comments