From patchwork Mon Mar 18 21:10:05 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Kaehlcke X-Patchwork-Id: 10858565 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 558291390 for ; Mon, 18 Mar 2019 21:10:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3CF79290D0 for ; Mon, 18 Mar 2019 21:10:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3B30628844; Mon, 18 Mar 2019 21:10:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7C00A290D0 for ; Mon, 18 Mar 2019 21:10:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727055AbfCRVKH (ORCPT ); Mon, 18 Mar 2019 17:10:07 -0400 Received: from mail-yw1-f67.google.com ([209.85.161.67]:34746 "EHLO mail-yw1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727008AbfCRVKG (ORCPT ); Mon, 18 Mar 2019 17:10:06 -0400 Received: by mail-yw1-f67.google.com with SMTP id x129so14146291ywc.1 for ; Mon, 18 Mar 2019 14:10:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:mime-version:date:message-id:subject:to:cc; bh=1OBzRxbq45MhxmYJZgYt4Mvsa34RcIxjDNusHwtkkv0=; b=gcUsFJxTSM1wKN21LmYugvJKSXvsGO5kOXoF8UyH9gG9jiVeZvgktr5r0B0xuI8pvf SMUxPMiZGYVFYZ48uLsUMb92HLyvrTFy+XxwfCeJLqPPeAlKP7A58vaMgYjQW7ccQKBr 5oamPVbuWwgmWJo9sap5tdjsQKQFHABCSR9Z0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:date:message-id:subject:to:cc; bh=1OBzRxbq45MhxmYJZgYt4Mvsa34RcIxjDNusHwtkkv0=; b=TDNjpYtzv4lwt3ej5eE8CnrR/EMnkHGrD8wRn8uRbT5saVcwDpUAK3iKrCftam6sFB hT4KzhHJ2wpxkLcRfiRShzXAoGrzRHznillmA9ORxOXrMkjjzvD1fHtENM+v/m0PxX+i ZPM9QedZe5ZS69YQi5wGzMCtFYw0OkCBPKcKBNm4jPktXkIgFuDrYCyfDpgxbJfulLhj r6szRJ17cnUHqUU0tuzcr8PYfWzvwdqG5srpUW9yT8cfJQgRCcLWASlk7c2dH5k2DuTq q3oCv4bYwRNRfdv161GlHd8BolvHf5iyVouw2Zg5CkG6ccJKYaYSL/l3sPrO+TGSdUEV h5dw== X-Gm-Message-State: APjAAAVdHci+77LNP6h88QkRL9R71UwGm0tN1BtYQVVJ1HfX1b/AKUti 0+gDN9V32eH++TAcXH6VZk41eUCAb1OV3qw2VNV9zw== X-Google-Smtp-Source: APXvYqzlMa55s7tT1p3mN2NmihYAypU7eFmPj9padX14399ugbtVzb1L0yI11z4Ojbcz+Yc1otPAME21+5AaQpN+Zx8= X-Received: by 2002:a81:32c3:: with SMTP id y186mr15873975ywy.144.1552943406087; Mon, 18 Mar 2019 14:10:06 -0700 (PDT) Received: from 764776645087 named unknown by gmailapi.google.com with HTTPREST; Mon, 18 Mar 2019 17:10:05 -0400 From: Matthias Kaehlcke X-Mailer: git-send-email 2.21.0.225.g810b269d1ac-goog MIME-Version: 1.0 Date: Mon, 18 Mar 2019 17:10:05 -0400 Message-ID: Subject: [PATCH] Revert "kbuild: use -Oz instead of -Os when using clang" To: Masahiro Yamada , Michal Marek Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, Behan Webster , Peter Zijlstra , "H . Peter Anvin" , Nick Desaulniers , Manoj Gupta , Tiancong Wang , Stephen Hines , clang-built-linux@googlegroups.com, Matthias Kaehlcke Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The clang option -Oz enables *aggressive* optimization for size, which doesn't necessarily result in smaller images, but can have negative impact on performance. Switch back to the less aggressive -Os. This reverts commit 6748cb3c299de1ffbe56733647b01dbcc398c419. Suggested-by: Peter Zijlstra Signed-off-by: Matthias Kaehlcke Reviewed-by: Nick Desaulniers --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 9ef547fc7ffe..191f3ce3cb5e 100644 --- a/Makefile +++ b/Makefile @@ -667,7 +667,7 @@ KBUILD_CFLAGS += $(call cc-disable-warning, format-overflow) KBUILD_CFLAGS += $(call cc-disable-warning, int-in-bool-context) ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE -KBUILD_CFLAGS += $(call cc-option,-Oz,-Os) +KBUILD_CFLAGS += -Os else KBUILD_CFLAGS += -O2 endif