From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 110292,45b50f14dadfce5b X-Google-Attributes: gid110292,public X-Google-Thread: 1164f8,45b50f14dadfce5b X-Google-Attributes: gid1164f8,public X-Google-Thread: 102b75,45b50f14dadfce5b X-Google-Attributes: gid102b75,public From: Patricia Shanahan Subject: Re: Final kick at the "Merced Guessing Game" Date: 1997/10/13 Message-ID: <34430B63.AD177272@acm.org>#1/1 X-Deja-AN: 280415994 References: <61g30t$o2n@news-rocq.inria.fr> <61ho3v$3m0$1@goanna.cs.rmit.edu.au> <343CE2F4.362D80F0@tonys.ecology.umn.edu> <61k9g2$2fa@mulga.cs.mu.OZ.AU> <34406444.A9D6EF97@tonys.ecology.umn.edu> Organization: Who? Me? Organized? Newsgroups: comp.sys.intel,comp.arch,comp.sys.dec boo wrote: ... > Because eventually, someone or something is going to have > to map the dimensionality of your "arrays" to the dimensionality > of the computer memory. I don't expect you to understand this, > though, so why don't you just let your Fortran compiler do > the thinking for you. ... And someone or something is going to have to map the dimensionality of your flat address space onto the dimensionality of the memory hardware. It is all just abstractions and mappings - the issue is which abstractions and mappings to use where and how. Which gets right back to the issue of language/hardware interaction. On the left, there is a large set of problems that need to be solved. On the right, there are some relatively well-understood pieces such as processor pipeline structures, cache structures, various types of memory chips, I/O devices, and glue for sticking them together to make a computer system. In the middle, there are transformations that can be done by compilers, operating systems (for example managing virtual memory mapping), and hardware (for example, mapping flat addresses into the realities of memory hardware). However much one may argue about which languages should be used for which problems, the first stage of mapping of the problems has to be done by programmers writing in some machine-processable language. However the hardware pieces are put together, getting data to the right places in the right processors is a key problem. Are there changes that can be made in languages or the architectures that would make the intermediate transformations go better, so that way the program runs and the way the data is stored and moved around the system would fit together better? Generally, a lot of attention has been focussed on architectures that run existing programs well, so if there is mileage here, at least some of it has to come from the language end. >From this point of view "restrictiveness" in the source language is by no means always a bad thing. Contraints that prevent the programmer from doing something weird may help the rest of the system by limiting what might be going on but almost always isn't. The classic problem that got this discussion started was the variable aliasing problem. Distinct formal parameters ALMOST always refer to different objects. There are memory access re-orderings that work if they actually refer to different objects, but that break the program if they are the same object. I didn't like how Fortran77 handled this, because the aliasing rule was too non-local. It was very easy for a programmer changing an existing program to introduce a violation without noticing it. There is little point in having a rule if it is unenforceable in the compiler, not necessarily understood by the programmer, and difficult to test a program for conformance. Are there rules that would be testable and enforceable that would help programs run well?