On Thu, 2021-07-08 at 16:42 +0000, Mahmood N via Gcc-help wrote: > Hi > > I see that my program works fine in the debug mode, but not in the > release mode. With GDB I was able to find the function that got error. > The code looks like > > > > std::vector<std::vector<inst_trace_t> *> threadblock_traces; > ... > printf("hello %d\n",threadblock_traces.size()); At least you can't use "%d" to print the result of std::vector<T>::size() (which is not an `int`). > trace_kernel.get_next_threadblock_traces(threadblock_traces); > Try to find the bug of your code with warnings, sanitizers, or -D_GLIBCXX_DEBUG. -- Xi Ruoyao <xry111@xxxxxxxxxxxxxxxx> School of Aerospace Science and Technology, Xidian University