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

            Bug ID: 89337
           Summary: Bogus "exceeds maximum object size" on unreachable
                    code
           Product: gcc
           Version: 9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rafael at espindo dot la
  Target Milestone: ---

Created attachment 45704
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=45704&action=edit
testcase

In the attached testcase the function drop3 has the precondition that the
provided string has a size of at least 3.

Given that, the body of the resize function is dead, but gcc doesn't realize it
and warns that we are passing -3 to memcpy.

Reply via email to