It's currently in the committee pipeline. Perhaps someone should tell them this is an use-case. ^^ @timur_audio
Something like std::assume_aligned would be very helpful. Given that, WRT compiler optimizations, const guarantees in C[++] are pretty weak (i.e. ptr-to-const doesn't allow compiler to assume memory won't change on its own), I'm a bit hesitant to reuse 'const' for it though.
-
-
Yeah that was just a spontaneous idea. Probably better to call it something long and ugly like std::assume_value_unchanged? But again, before spending time on such a proposal, I would be interested in any existing practice and implementability
-
I looked at gcc and clang, and neither currently expose it as intrinsics/builtins as far as I am aware. I have successfully used LLVM's IR invariant builtin as part of JIT codegen though.
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.