From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Fri, 23 May 2003 16:00:56 +0400 From: "Alexey I. Froloff" To: =?koi8-r?B?4szJziwgy8HLINbFIMTP09TBzMkg19PRy8nFIMvMz9XO2SDTIMvSydfP?= =?koi8-r?B?zsHT1NLPxc7O2c3JINDP3tTP3snUwczLwc3J?= Subject: Re: [Comm] Re[2]: [Comm] =?koi8-r?B?z9DD?= =?koi8-r?B?yck=?= gcc Message-ID: <20030523120056.GP3117@inferno.immo> Mail-Followup-To: =?koi8-r?B?4szJziwgy8HLINbFIMTP09TBzMkg19PRy8nFIMvMz9XO?= =?koi8-r?B?2SDTIMvSydfPzsHT1NLPxc7O2c3JINDP3tTP3snUwczLwc3J?= References: <20030523104851.59eeab73.maykov@simauto.ru> <20030523102908.GO3117@inferno.immo> <158156351641.20030523173341@mail.ru> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="yK/6QRnH3Zanb0EF" Content-Disposition: inline In-Reply-To: <158156351641.20030523173341@mail.ru> User-Agent: Mutt/1.4.1i X-Envelope-To: community@altlinux.ru Sender: community-admin@altlinux.ru Errors-To: community-admin@altlinux.ru X-BeenThere: community@altlinux.ru X-Mailman-Version: 2.0.9 Precedence: bulk Reply-To: community@altlinux.ru List-Unsubscribe: , List-Id: List-Post: List-Help: List-Subscribe: , List-Archive: Archived-At: List-Archive: List-Post: --yK/6QRnH3Zanb0EF Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: 8bit * Рахматуллин Андрей (wRAR) [030523 15:48]: > AIF> -march=i386 - использовать систему команд процессора i386 (т.е. > AIF> никаких mmx/sse и cmpxchg8b) > AIF> -mcpu=i686 - при генерации кода учитывать особенности > AIF> распаралеливания команд на i686 (PPro, P2, и т.д). Старым машинам > AIF> всё равно, а на новых побыстрее будет. > Хм, ИМХО наоборот, -mcpu=i686 генерит код с учетом "mmx/sse и > cmpxchg8b" (грубо говоря), а -march=i386 означает, что собираем > бинарник под х86-архитектуру, а не под PowerPC, например. Не будем гадать на кофейной гуще, а глянем в доку: Intel 386 and AMD x86-64 Options These -m options are defined for the i386 and x86-64 family of comput- ers: -mcpu=cpu-type Tune to cpu-type everything applicable about the generated code, except for the ABI and the set of available instructions. The > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ choices for cpu-type are i386, i486, i586, i686, pentium, pentium- mmx, pentiumpro, pentium2, pentium3, pentium4, k6, k6-2, k6-3, athlon, athlon-tbird, athlon-4, athlon-xp and athlon-mp. While picking a specific cpu-type will schedule things appropri- ately for that particular chip, the compiler will not generate any > ^^^^^^^^^^^^^^^^^^^^^ code that does not run on the i386 without the -march=cpu-type > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ option being used. i586 is equivalent to pentium and i686 is equivalent to pentiumpro. k6 and athlon are the AMD chips as opposed to the Intel ones. -march=cpu-type Generate instructions for the machine type cpu-type. The choices > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ for cpu-type are the same as for -mcpu. Moreover, specifying -march=cpu-type implies -mcpu=cpu-type. Так что я не ошибся ;-) P.S. А иначе какой смысл пользоваться инструкциями PPro, и опитимизировать код под i386? -- Regards, Alexey I. Froloff AIF5-RIPN, AIF5-RIPE ------------------------------------------ Inform-Mobil, Ltd. System Adminitrator http://www.inform-mobil.ru/ Tel: +7(095)504-4709, Fax: +7(095)513-1006 --yK/6QRnH3Zanb0EF Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) iD8DBQE+zg14VqT7+fkT8woRAt4xAKCPuL1bQhhojPIg7lm5D2YmJxLKvgCgzyOn uoVgFwod3/lmNJXhvoUU68k= =qoo4 -----END PGP SIGNATURE----- --yK/6QRnH3Zanb0EF--