X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:subject:to:references:from:message-id:date
	:mime-version:in-reply-to:content-type
	:content-transfer-encoding; q=dns; s=default; b=w0Nm1ARu+Mx6x8q7
	MkZfGkR4AmUB4BgFeWEHBAdHybpFNkUtSgmMRE6kBIdUq2xrlgCyfzBx73Yck41v
	geM1HtBRwc079dR5KPutjdbOe0PR8NaJ59MN+VdjqXAH+4M4BezqtLSD5wKDezmJ
	Vv4pVycrihBp/vfICIg/QkdXWM8=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:subject:to:references:from:message-id:date
	:mime-version:in-reply-to:content-type
	:content-transfer-encoding; s=default; bh=ASER377YZxryeSwdXzT6fM
	h7738=; b=oG+q9xqJLsB6I7hVNDn63mbBiBzqfX1qEUK4JD1CYTQcVGi2XiBlkw
	ATS/CKjOvIrCNw9MzBuuAB+1Iy8dGo43KnGs6fbJgA82f3FpAapCIi7j1ccdbjO1
	3gyG7HduTA5Md8ZhnXgB6UByh7IJqB0ZjHtP2rKE4NXrVmpa/QZ8A=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 spammy=H*M:9587, Nope
X-HELO: gateway36.websitewelcome.com
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=agner.org;	 s=default; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:MIME-Version	:Date:Message-ID:From:References:To:Subject:Sender:Reply-To:Cc:Content-ID:	Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc	:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:	List-Post:List-Owner:List-Archive;	bh=LGPlKygfu5eelf38OVLPXRKdLpk41+Ijw40r+IKHSKI=; b=Fij9EwK+GKY07sXtQ4mckk4ctc	Ptqc8cQwDpNHdZ87eb3FS/ntiqj2DCfGLmlDcTtZ/mV2SbdPWJgCigWbpOUZ5tcxl26mIod8JN+//	4Q5mndSZMcZBiu/1/txNkmzvFkVTrj/m50HTqvRDqdUO3BhCsh2tnnxIqn24BhC3ARcGBkJN1+9wi	U6Bi2YlReGBmpYXbiUQRDsa/cG/3OsaUv4KWDmk3PvbVxWRjQz1B2w382J/8OANc6S0ixSww3kQD5	RE8PElv0IbEavYbX1+oxHsD6A10KE/VxobI2EaaeW1yn2JAg+tTgMheTR8sPWjfRDc7LAcLqi1XKG	xPw3rBJw==;
Subject: Re: Clang is using the wrong memory model
To: cygwin@cygwin.com
References: <024ce5b5-6024-b371-e382-5eef5d1d4a90@agner.org> <075477ca-e031-39ea-3dfe-bc8bc2fc8fa6@agner.org> <20190816082603.GR11632@calimero.vinschen.de> <8d594f4d-17e0-447a-8b18-1ed620815e0f@agner.org> <20190816095200.GU11632@calimero.vinschen.de> <2024f551-66e6-47c5-a0b6-2dfa735a690d@agner.org> <20190816111133.GV11632@calimero.vinschen.de> <6008d30a-cd6c-5449-2933-a041e804856c@agner.org> <20190817081605.GX11632@calimero.vinschen.de> <17081147-f46a-51bf-65e9-3df7748b1780@agner.org> <20190818115739.GD11632@calimero.vinschen.de>
From: Agner Fog <agner@agner.org>
Message-ID: <f2852c05-4f0b-9587-2c4c-bf37485b7455@agner.org>
Date: Sun, 18 Aug 2019 18:24:18 +0200
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0
MIME-Version: 1.0
In-Reply-To: <20190818115739.GD11632@calimero.vinschen.de>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-IsSubscribed: yes

On 18/08/2019 13.57, Corinna Vinschen wrote:
> Nope, Cygwin uses the Windows loader. 

Then, how do you do the extra linking? What is producing the "Cygwin 
runtime failure" message when loading/linking a DLL fails?

>   If the medium model is wasteful in clang, that's a clang
> optimization problem, not a Cygwin problem.

The medium model in Clang is not wasteful. It does exactly what it is 
designed to do. It was never designed with Cygwin in mind. The program 
build with a medium model is wasteful because it makes all addresses 64 
bits when few or no addresses actually need to be 64 bits.

> If you want to use the small model in your own projects, great, if it
> works for you.
It is not for my own project. I am writing manuals on how to optimize 
software.

Agner


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

