https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88993

--- Comment #11 from Martin Sebor <msebor at gcc dot gnu.org> ---
There is no reliable way.  The limit may not be fixed, or can be different for
different directives or format strings.  A test case like the one in the Red
Hat bug #441945 linked at comment #2 might tell you there is a limit but not
necessarily what it is.  A case that interposes a custom malloc/free that fails
at different points/different sizes might expose other limits (or bugs)
altogether.  If that doesn't cause any trouble it's pretty safe to assume that
there is no limit.  I tried both approaches with a few systems in the compile
farm (I think AIX, FreeBSD, NetBSD, Glibc, and Solaris) and only got Glibc to
fail (as in either return an error or crash).

Reply via email to