Quantcast
Channel: lkml.org : Ganesh Sittampalam
Viewing all articles
Browse latest Browse all 627

Re: [GIT PULL] x86/build changes for v4.17

$
0
0
Linus Torvalds writes: (Summary) wrote:

[...]

compiler optimization to change.
I actually mis-read your example - in your case it obviously does pass the array itself down to the call, and yes, it obviously needs to be allocated.
allocated.
I had a test-case at one point where gcc avoided the stack allocation entirely for a regular array, but not for a VLA (of the same constant size) because the VLA logic is apparently different enough - even when the size of the array is a compile-time constant.
the size of the array is a compile-time constant.
We had that issue because we had a lot of trouble coming up with a "max()" macro that was still an I-C-E (and we had a number of array sizes that used "max()").

Viewing all articles
Browse latest Browse all 627

Trending Articles