Automatic initialization of variables in C++ experiences

Johan Engelen j at j.nl
Tue Jan 22 10:51:20 UTC 2019


Hi all,
   Clang-folks are working on an option to automatically 
initialize local variables, similar to what D does.  (only local 
variables, not heap allocated variables)

Read this thread if you are interested in performance 
measurements and discussion about perf impact (currently about 
1%) and compiler improvements to try to mitigate it:
https://lists.llvm.org/pipermail/cfe-dev/2019-January/060878.html

("zero-init" = initialize with all zeros, "pattern-init" = 
initialize with a specific bit pattern)

-Johan



More information about the Digitalmars-d mailing list