Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.compilers > #2841
| From | gah4 <gah4@u.washington.edu> |
|---|---|
| Newsgroups | comp.compilers |
| Subject | Re: What is the meaning of an expression? |
| Date | 2022-01-18 15:18 -0800 |
| Organization | Compilers Central |
| Message-ID | <22-01-068@comp.compilers> (permalink) |
| References | <AdgJPKhi/NiNfECvRNaA6+4Wq/M8OQ==> <22-01-052@comp.compilers> <22-01-060@comp.compilers> <22-01-066@comp.compilers> <22-01-067@comp.compilers> |
(snip, and our moderator wrote) > [If you go back the the start of the thread, someone asked about > a statement that "The meaning of an expression is the value of the expression." > I suppose we could ask what it means to a compiler but that seems awfully > anthropomorphic. -John] This is reminding me too much about the episodes of Star Trek where Kirk and Spock have to destroy a computer. (None of which ever seem to have a compiler.) They give a logical inconsistency, which the computer works on for a while, until smoke comes out and we know it is dead. (And the computers always talk, making the anthropomorphising easier.) As for actual compilers, what do they do with logical inconsistencies? As above, normally they should just compile what they are given, and not try to actually process it. But more and more compilers optimize code, which means (often enough) that they do processing that would otherwise be done at run time. My favorite optimization story, which I heard many years ago when it was already old, is from the OS/360 Fortran H days. It seems that there was a popular Fortran benchmark program that evaluated some very complicated expression, mostly with the use of statement functions. (The sometimes useful, but now deprecated Fortran feature.) Fortran H expands statement function inline (it seems unlike others at the time.) The result of this, was that the compiler evaluated the whole complex expression at compile time (very slowly), and printed the result at run time (very quickly). So, back to anthropomorphic computers and logical inconsistencies. How good are compilers, especially ones that evaluate constant expressions at compile time, at dealing with logic failure? And especially, as the question needs, expressions that don't have a value?
Back to comp.compilers | Previous | Next — Previous in thread | Next in thread | Find similar
What is the meaning of an expression? Roger L Costello <costello@mitre.org> - 2022-01-14 12:15 +0000
Re: What is the meaning of an expression? anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2022-01-14 18:20 +0000
Re: What is the meaning of an expression? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2022-01-15 00:28 +0100
Re: What is the meaning of an expression? gah4 <gah4@u.washington.edu> - 2022-01-14 17:58 -0800
Re: What is the meaning of an expression? George Neuner <gneuner2@comcast.net> - 2022-01-15 02:05 -0500
Re: What is the meaning of an expression? "matt.ti...@gmail.com" <matt.timmermans@gmail.com> - 2022-01-15 06:21 -0800
Re: What is the meaning of an expression? Johann 'Myrkraverk' Oskarsson <johann@myrkraverk.invalid> - 2022-02-03 12:50 +0000
Re: What is the meaning of an expression? Jan Ziak <0xe2.0x9a.0x9b@gmail.com> - 2022-01-16 07:44 -0800
Re: What is the meaning of an expression? Jan Ziak <0xe2.0x9a.0x9b@gmail.com> - 2022-01-17 15:45 -0800
Re: What is the meaning of an expression? Jan Ziak <0xe2.0x9a.0x9b@gmail.com> - 2022-01-18 10:03 -0800
Re: What is the meaning of an expression? gah4 <gah4@u.washington.edu> - 2022-01-18 15:18 -0800
Re: What is the meaning of an expression? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2022-01-19 11:54 +0100
Re: What is the meaning of an expression? Jan Ziak <0xe2.0x9a.0x9b@gmail.com> - 2022-01-19 09:17 -0800
Re: What is the meaning of an expression? gah4 <gah4@u.washington.edu> - 2022-01-19 14:03 -0800
Re: What is the meaning of an expression? Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2022-01-20 13:02 +0100
Re: What is the meaning of an expression? dave_thompson_2@comcast.net - 2022-01-30 22:51 -0500
Re: What is the meaning of an expression? Christopher F Clark <christopher.f.clark@compiler-resources.com> - 2022-01-19 20:13 +0200
Re: What is the meaning of an expression? Thomas Koenig <tkoenig@netcologne.de> - 2022-01-22 20:46 +0000
Re: What is the meaning of an expression? Thomas Koenig <tkoenig@netcologne.de> - 2022-01-19 20:51 +0000
csiph-web