I checked, I am linking the file into executable. Linker command: g++ -rdynamic -g -Wall -m32 -O0 -Wl,--start-group rand_hfile.o <lst of other files & libs> -Wl,--end-group -ldl -lpthread -o rand_handler.sct compiler command: gcc -m32 -g -Wall < file and other info> thanks, Pramod. -- View this message in context: http://gcc.1065356.n5.nabble.com/How-to-disable-GCC-optimization-tp967456p967473.html Sent from the gcc - Help mailing list archive at Nabble.com.