First Last Prev Next    No search results available
Details
: -fstack-check is not supported
Bug#: 2008
: tools
: gnat
Status: NEW
Resolution:
: Other
: Linux
: trunk
: P2
: enhancement
: ---

:
:
:
:
  Show dependency tree - Show dependency graph
People
Reporter: Duncan Sands <baldrick@free.fr>
Assigned To: Unassigned LLVM Bugs <unassignedbugs@nondot.org>

Attachments


Note

You need to log in before you can comment on or make changes to this bug.

Related actions


Description:   Opened: 2008-02-10 07:17
Compiling a program with -fstack-check is supposed to add
code to check for stack overflow.  This does not happen
with llvm-gcc.  I've filed this option under tools/gnat
because in mainline this option only works with the Ada
front-end.  However patches to mainline have been proposed
that generalize this functionality to all languages.  It
seems like a useful feature for LLVM to support.
------- Comment #1 From Chris Lattner 2008-02-10 11:36:38 -------
Is this related to the -fstack-protector option?  I thought 4.2 had some
support for stack canaries. 
------- Comment #2 From Duncan Sands 2008-02-10 12:13:20 -------
It's not related to -fstack-protector: that's trying to prevent people
from overwriting your stack.  -fstack-check is about checking that (via
recursion or whatever) you do not make the stack so big that it runs into
the heap or some other bad place.  Ada doesn't really have a buffer overflow
problem since the compiler is required to insert code to check that there
are no out of range accesses, so -fstack-protector isn't really useful for
it.  However stack overflow is a potential problem.
------- Comment #3 From Chris Lattner 2008-02-10 12:17:46 -------
ah, ok!

First Last Prev Next    No search results available