Newsgroups: | comp.arch,comp.compilers |
From: | amos@nsof.co.il |
Keywords: | optimize, C |
Organization: | Compilers Central |
References: | 94-10-108 94-10-157 |
Date: | Tue, 1 Nov 1994 02:41:45 GMT |
robertb@HING.LCS.MIT.EDU (Robert Bedichek) writes:
>Many programs would not work after being compiled by a compiler that
>freely reorganized structures. If you add such a "feature" to a C
>compiler, you'll have to make it a non-default compiler option.
>Consider what will break:
>1. Device drivers (...)
>2. Network code (...)
>3. Operating system and library code (...)
>4. Applications and utilities that make system calls (...)
>5. OS/Apps/Utils that read structures from disk (...)
Of these points, 2, 3, and 4 are matters of OS interface, not the compiler;
it is assumed an OS is compiled along the same alignment restrictions
implied for user code, and provide interface routines where needed (such as
the XDR routines used in UNIX for network interface).
The other points are actually the results of compiling code for one machine
and expecting it to interface another machine (this includes the device
controller in point 1); IMHO this problem is outside the scope of what a
compiler should be expected to do, and should not affect language standards.
- --
Amos Shapir Net: amos@nsof.co.il
Paper: nSOF Parallel Software, Ltd.
Givat-Hashlosha 49905, Israel
Tel: +972 3 9388551 Fax: +972 3 9388552 GEO: 34 55 15 E / 32 05 52 N
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.