I'm using C++ Builder XE6, and i'm trying to do some tests with move constructor, to compare the results with copy constructor. Anyway, my compiler forces RVO optimization even though it's checked "Disable all optimizations" in the compiler settings. Is there some additional parameter that needs to be send to compiler?
Asked
Active
Viewed 1,229 times
4
-
but why would you do this? – SwiftMango Dec 21 '14 at 20:12
1 Answers
4
You're looking for -fno-elide-constructors
.
I don't see this documented anywhere in Embarcadero's docs; however that is the flag that clang uses, and it did have the intended effect when I tried it with bcc64 6.70.

M.M
- 138,810
- 21
- 208
- 365