2 ms·
Here's the pending GCC 15 release notes: https://gcc.gnu.org/gcc-15/changes.html https://gcc.gnu.org/gcc-15/changes.html (since the link in the article points t
by jart 2y ago
Here's the pending GCC 15 release notes: https://gcc.gnu.org/gcc-15/changes.html https://gcc.gnu.org/gcc-15/changes.html (since the link in the article points to GCC 14)
- I'd love to see godbolt examples of the sort of optimizations [[unsequenced]] and [[reproducible]] can do.
- GCC has always been in my experience smart enough to know how to optimize normal C code into ROL and ROR instructions. I've never had any issues with it. So what's the point of __builtin_stdc_rotate_left()? Why create a builtin when it is not needed? What I wish GCC and Clang would do instead, is formally document the magic ANSI C89 incantations that trigger the optimization, e.g. `#define ROL(x, n) (((x) << (n)) | ((x) >> (64 - (n))))`. That way we can have clean portable code with less #ifdef hell along with assurances it'll go fast when -O is passed.
- What is "Abs Without Undefined Behavior (addition of builtins for use in future C library <stdlib.h> headers)."?
- What is "Allow zero length operations on null pointers"?
- Re: "Introduce complex literals." How about some __int128 literals?
- "The "redzone" clobber is now allowed in inline assembler statements" wooo I've wanted something like this for a while.
Great work from the greatest compiler team!
- fuhsnn 2y ago> How about some __int128 literals There are _BitInt literals (wb and uwb), look adequate https://godbolt.org/z/xjEEM5Pa4 https://godbolt.org/z/xjEEM5Pa4 despite clang's "is a C23 extension" noise.
- jart 2y agoWait I missed that. They finally implemented _BitInt? YESSS
- saagarjha 2y ago> What I wish GCC and Clang would do instead, is formally document the magic ANSI C89 incantations that trigger the optimization, e.g. `#define ROL(x, n) (((x) << (n)) | ((x) >> (64 - (n))))`. That way we can have clean portable code with less #ifdef hell along with assurances it'll go fast when -O is passed. Well they don’t commit to that happening, so they want to provide you with an alternative.