cpp11training icon indicating copy to clipboard operation
cpp11training copied to clipboard

Part of move-exercise is optimized-away

Open xtofl opened this issue 6 years ago • 0 comments

The exercise called 'speed_this_up_by_adding_move_support' has a duration call for a lambda that seems to be compiled away in release builds.

The expectation

    EXPECT_LT(consuming_objects, constructing_objects * 1.1)
        << "consuming: " << consuming_objects
        << " vs. constructing: " << constructing_objects

becomes impossible to meet (consuming: ~1500ms vs. constructing: ~13ms)

xtofl avatar Mar 17 '19 13:03 xtofl