From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by sourceware.org (Postfix) with ESMTPS id 163ED3840C3A for ; Tue, 19 May 2020 19:16:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 163ED3840C3A Received: by mail-ej1-x62e.google.com with SMTP id j21so317940ejy.1 for ; Tue, 19 May 2020 12:16:34 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=stfPjc4VfFyZnzxqOtPhrEJ3Ww9b0lkUxnK+GxE3tU8=; b=ucPtrJ19kEx2904jw+c3aJX5d4+zVFYwBVxL+4jG95gTILTdTcaCuANS0dYigoAcE1 /2qcPJIeZ5hDT8WqK8JZmp6PPiNOhb0bdms5csQOoCDnCAPXUWfD54Hn9r6SsoMHg33O 5zxZPJm8TXHV6v456rh2GtmtzeumG8Q/1UcOVBNkwo9C9/kCuZwOGD+axbOuE50bST7X 4EUL8VVqbBwKaI1//+BTJK1dN6DaFgfLHxKimvwibTI7yLoo5IEkfN730JP1o4vUTa1J gjpzEB9g0kGijzh4+3h+CjQMLR9I+iGHOUiyOqQEiXXs5L4KsLI+MO7/7n3yG9gG9wKk H51A== X-Gm-Message-State: AOAM531Elr5Dts4hk1HjXP4fA+yRcXKYKqBmsF601mvHBY9kko/bWTDx zUwxR4GjDLX2ajm+4P+K8DeJzxN7rFX0Q5LaLJQm+w== X-Google-Smtp-Source: ABdhPJznVIWTJXehOXUwL4SKhLLVylAXLA1uynKJjdTw42GbZS/8moAOKCwlko44wQwDJXPw8IQ5RfBnMvj3cFPbm28= X-Received: by 2002:a17:906:509:: with SMTP id j9mr679892eja.152.1589915792783; Tue, 19 May 2020 12:16:32 -0700 (PDT) MIME-Version: 1.0 From: Dave Flogeras Date: Tue, 19 May 2020 16:16:23 -0300 Message-ID: Subject: snprintf in newlib-3.3.0 vs 3.1.0 To: newlib@sourceware.org X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, HTML_MESSAGE, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: newlib@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Newlib mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 May 2020 19:16:35 -0000 Hi list, I use a Gentoo crossdev toolchain for developing armv7m microcontroller code. Recently Gentoo switched to newlib-3.3.0 as a result of the CVEs reported in pre-3.3.0 releases. I noticed a fairly significant increase (about 6k) in my .data section of a project after upgrading the toolchain. All else is held equal, the newlib 3.1.0 -> 3.3.0 upgrade is the only change. Looking at the map/list files, it seems related to my usage of s(n)print. Is this much increase to be expected, or am I potentially suffering from a misconfiguration? Certainly not exhaustive, but the main size offenders seem to be new functions being linked in _vfiprintf_r and __sfvwrite_r. I noticed that the default of REENT_CHECK_VERIFY was switched from false to true, so I tried recompiling with that reverted to false, but it didn't seem to change the outcome. Not a huge deal, I just wanted to know if it is expected, or something gone awry. Any advise is appreciated Best regards, Dave