From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-eopbgr130134.outbound.protection.outlook.com [40.107.13.134]) by sourceware.org (Postfix) with ESMTPS id EDA60383E82B for ; Mon, 11 May 2020 15:14:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org EDA60383E82B Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=redheads.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=moritz.struebe@redheads.de ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JTIXledWiEKUth54wyfgBP36DJw7nxxZ7v2Qtls46z3RAMtFGxGSkPswukuJbwu6QPp2XIaltCjyJnKHoHDjbXnuhVWpNUrh7htqISaAa0uRXGKByPwGX0cCfynQpFuYFDkjUeDyaGmXZW2PBExDmlPDRhCEkgh+74GbkmuiAexYUXrVeo6OVqjwVJqkcX++cVLuxN38jdn/WPc1egtECu3dVkmf0cP0KBdVenac4Owan8+kCh+kSt7vEaOfcKlB40KbMgqRG1enqDPc+yd1+U1TlqbVJjEQQuvRIxZpm0mRfaSKTc1frlg6gtLOklQr62XbkL7fLxVM+Ec425nC2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=d8CDTKzOTn+2Idc1SN+pZdS74mvG8JE4FhvmHSABDh4=; b=k/QoU5RZFen8IC/2WXcAhJndzPgByZeE3PR1h1bj2FKjInXcy9fYzELMzCD9b1+hRHZ2WKYOBoo9F8lqN1LHpauBYzS2tDZC4hDgqilQ7RHymtjzZWeyZ6qk4Xzam9xF+n29VLP9yNnF5/pQ/vplEy2OE973BihNfoOpyCC2/h4i6FOlpnrc29rbDhlRAk/jfWxPrQqfPVQ6N+/jUJD5aoQtyHXjwMQfCuyPlKoKWHThvmjVtO4ybG32pJT0XWWLB9ainHA3vZ5GD42ofMt2QACY2/XM6vC2bbUAXs9JOxsvbIiaCYtQUDh5CZ/w+mIlQz6iC1xq0oF1f6oer2lPXQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=redheads.de; dmarc=pass action=none header.from=redheads.de; dkim=pass header.d=redheads.de; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redheadsltd.onmicrosoft.com; s=selector2-redheadsltd-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=d8CDTKzOTn+2Idc1SN+pZdS74mvG8JE4FhvmHSABDh4=; b=E/6roxJkJwkE4BxMa9+CBr/edkJrLf7tS2E8nU7yDDa2YiKYhM/81E9hC78h3OLBQ/RM0LPmv+ikGwj5Ltcy0agL+dbpMqFt4vRhjwzlWwi8KxLMvga4DbumKkdHWzBOpvoydJMMo8HPNjacxQkZDd8/UlehhPfztZ68l2sig24= Authentication-Results: gcc.gnu.org; dkim=none (message not signed) header.d=none;gcc.gnu.org; dmarc=none action=none header.from=redheads.de; Received: from AM0PR04MB7169.eurprd04.prod.outlook.com (2603:10a6:208:19a::24) by AM0PR04MB4355.eurprd04.prod.outlook.com (2603:10a6:208:5a::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.27; Mon, 11 May 2020 15:14:41 +0000 Received: from AM0PR04MB7169.eurprd04.prod.outlook.com ([fe80::684e:7bd2:3cc7:56d3]) by AM0PR04MB7169.eurprd04.prod.outlook.com ([fe80::684e:7bd2:3cc7:56d3%9]) with mapi id 15.20.2979.033; Mon, 11 May 2020 15:14:41 +0000 Subject: size of exception handling (Was: performance of exception handling) To: gcc@gcc.gnu.org References: <0bbdaab7-c083-e14e-6227-27713dab9657@users.sourceforge.net> <874ksmg3fb.fsf@oldenburg2.str.redhat.com> <929cc727-20c6-480c-3412-d3f7a08f7544@users.sourceforge.net> From: =?UTF-8?Q?Moritz_Str=c3=bcbe?= Message-ID: <1ca27c9f-235d-5e97-a506-e6267aeb81c6@redheads.de> Date: Mon, 11 May 2020 17:14:39 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 In-Reply-To: <929cc727-20c6-480c-3412-d3f7a08f7544@users.sourceforge.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-ClientProxiedBy: AM3PR05CA0149.eurprd05.prod.outlook.com (2603:10a6:207:3::27) To AM0PR04MB7169.eurprd04.prod.outlook.com (2603:10a6:208:19a::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.104] (188.195.0.100) by AM3PR05CA0149.eurprd05.prod.outlook.com (2603:10a6:207:3::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2979.30 via Frontend Transport; Mon, 11 May 2020 15:14:41 +0000 X-Originating-IP: [188.195.0.100] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6507038c-65bc-4cea-6ff1-08d7f5be075b X-MS-TrafficTypeDiagnostic: AM0PR04MB4355: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7691; X-Forefront-PRVS: 04004D94E2 X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: P8Ganx78Cicx2zOR4jVJ2Z75zXhOTgZY74FroZJeYE5UcvZtU1VMVJHEnwGvJOyvEvexDcDVnMWuyUx4il2V1GJbpD6iBXbPg6c8s6PKuyi5R5yw/vf11n6eFjpWLUngZLPlZ6uAcnl+juiSoJcXrR62vONlDn4lajx+UtXPeycAawRRI04gspbhdcqP1G5UiorXauHYNVVzkJeZXs5FReieewE5nQUXSU45tE3dlIm965DyqCMpW/RquXtFCngynTjPJs88GlaXdBP/FWVRp4639+8JOA9kUAjc9DDSEYJGKqRzNGykxL2uVk0ZZlGrbyBCCt2Wvcm8A7nq+R0wKVmQt6asKIugUL1mbPmKfH2gxeKMRGWbq3Np9ax3LLRlh/o/uTmAa5K357b6iIqAUfiGsg43Fk7+WZmi11kzZ15LOk7/8WpJJs0WB1IcsDVfIO+/cZ30NPtw4bwGH/k4zxWYOHLWQs4ewSsVWTdOrdk/A5EFSQ2FbF/pSnlO/0UNzRyKsPvEuCxWsp9DCYOw7aQ+oGlZsv1R4PfUZhtfhvRnMIo6j8AZhpvM27KPJqDz4n3QA5qPMn6r1wms8ox/rzuhd6J4HWSTDcx+5219KDGHlWFNboXTxuBaAmE//9phsJDxJH47gPGht6K8bUlFdg== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM0PR04MB7169.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(136003)(366004)(39830400003)(346002)(376002)(396003)(33430700001)(186003)(66946007)(26005)(66476007)(83080400001)(2616005)(956004)(16526019)(15974865002)(16576012)(316002)(31686004)(2906002)(52116002)(66556008)(6916009)(508600001)(33440700001)(5660300002)(31696002)(8676002)(36756003)(6486002)(66574014)(86362001)(8936002)(43740500002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData: S0Bz26MbMxSP5qVYWjJhfYsef2v+QFjk5a7v1DkM/VOUob8d4onWzh5Z5tVh2xaHpWZRkgjKYnVT6Q6ovays6LObnwENOq+fIV2c07518Sk7pYjjc7leipgL94TgRVDlWFXm5Y5yOdc4qnjo031nqRu2k2nGACrrxmIBrnkTiVaHGuYV+o20XgrwmQvYaPXSBfuZ4Dcb6IcT2HZZ7+nCbdMp7wJZNMVGQ6csKsFux3r1HAku/qTLQzcX9KOrD/lfpelm3PVPlzyCaJP/lmUosoveLtVoANaYeTgELQHbu5mWD2oWolevpGD3m55Mvdw/fxJIdxi3f4GUdVu2ZoejrO2B33vs0QupUNyYVPJWkYP9wUh+7Vr0ww7Jg42gn0c7VEJAe8dVRNOw9o/lNkOIenB2J7FI2ZOqo4nXegEk7ITzaBdSSH6xcVX+Ix5Qhys5yf3plpGgBvQXYxPEQbuAkqfUKb7hjDqZNjiLHtl9/0k= X-OriginatorOrg: redheads.de X-MS-Exchange-CrossTenant-Network-Message-Id: 6507038c-65bc-4cea-6ff1-08d7f5be075b X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 May 2020 15:14:41.3184 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 683a389d-180e-4c17-8fda-8c0df8dfd02b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: xCceEYmQ7dId86E20XM2YHMgduhMzOC/p/eEQ+axvZVyArNPt6NCze8jzfErEKSuRxQHhMFfuoabDE5TptR1bh6XLbtNH/aErXaxnkNRsHw= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB4355 X-Spam-Status: No, score=3.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FOREIGN_BODY1, MSGID_FROM_MTA_HEADER, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Level: *** X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 May 2020 15:14:50 -0000 Hey. Am 11.05.2020 um 15:59 schrieb Thomas Neumann via Gcc: > In a way I am disagreeing with the paper, of course, in that I propose > to make the existing exception mechanism faster instead of inventing a > new exception mechanism. But what I agree on with P0709 is that it is > unfortunate that many projects disable exceptions due to performance > concerns. And I think the performance problems can be solved. I just wanted to point out that Herbceptions do not only fix performance issues, but also code-size problems. While anything below 4GB of RAM is considered under-powered for a PC, typical deep embedded environments have something around 32k of program memory and 2K of ram. And even those running Linux often have around 32MB program memory and 8MB of RAM. Also most of these systems are very cost sensitive, so each byte matters. Therefore RTTI and exceptions are one of the main reasons why parts of the embedded community consider C++ unusable: They do some experiments using C++ and the code size explodes.  And even if you know what you are doing and turn interrupts and RTTI off, adding a std::nothrow to every "new" to do decent error handling is pretty annoying. Not mentioning the parts of the C++ library that don't provide exception-free error-handling. So yes, improving the performance is nice, but ISO C++ will still be unusable for most computer systems: There are way more emdedded systems with less than 32MB program memory out there than PCs, Servers and mobile phones together. Cheers Morty -- Redheads Ltd. Softwaredienstleistungen Schillerstr. 14 90409 Nürnberg Telefon: +49 (0)911 180778-50 E-Mail: moritz.struebe@redheads.de | Web: www.redheads.de Geschäftsführer: Andreas Hanke Sitz der Gesellschaft: Lauf Amtsgericht Nürnberg HRB 22681 Ust-ID: DE 249436843