On 24/08/18 14:51, Akhilesh chirlancha wrote: > Hello All, > > I'm using gcc 5.4.0 for armhf target. > > I was compiling simple stack over flow test code with '-mapcs-stack-check' > option. > # gcc -mapcs-stack-check test.c > test.c:1:0: warning: -mapcs-stack-check incompatible with -mno-apcs-frame > #include<stdio.h> > ^ > > As per my understanding from the above warning is -mapcs-stack-check option > depends on -mapcs-frame. Is my understanding correct?? If yes, gcc should > work for -mapcs-frame. > But I found this in GCC online docs( > https://gcc.gnu.org/onlinedocs/gcc-5.4.0/gcc.pdf) > -mapcs-frame > Generate a stack frame that is compliant with the ARM Procedure > Call Standard for all functions, even if this is not strictly necessary for > correct execution of the code. Specifying '-fomit-frame-pointer' with this > option causes the stack frames not to be generated for leaf functions. The > default is '-mno-apcs-frame'. This option is deprecated. > > Document saying '-mapcs-frame' option is deprecated. Does it mean I can't > use -mapcs-stack-check option? > It wouldn't help even if you did. I don't think APSC-style stack checking was ever fully implemented in GCC. R. > Thanks in advance, > > Best Regards > -Akhilesh >