[M3devel] LONGINT
Rodney M. Bates
rodney.bates at wichita.edu
Thu Jul 19 15:13:05 CEST 2007
I'll volunteer to do the update to the language definition, as that is an
interest of mine.
Tony Hosking wrote:
> I've successfully bootstrapped a CM3 compiler that supports LONGINT as
> a 64-bit integer type (equivalent to "long long" in C) in addition to
> INTEGER (same as "long" in C). This will be useful for simplifying
> interfaces to C library routines that expect to be able to treat 64-bit
> integers such as "off_t" for lseek, etc.
>
> Currently, the compiler does not treat LONGINT as an ordinal type (I'm
> not sure this would ever be a good idea) so it cannot be used to index
> arrays, define enumerations etc., though the simple operations ABS,
> MAX, MIN, addition, comparisons, MOD, multiplication, subtraction,
> assignment, are all supported. This includes changes to m3core (with
> support for Long.T similar to Word.T, plus RTTipe and RTTypeMap, etc.)
> and libm3 for Pickle2, as well as to m3middle, m3front, and the
> gcc-based compiler backend. There is still work that needs to be done
> to support and test all the other M3 tools such as network objects,
> etc., with support and testing needed in m3tk for the new type, as well
> as in other tools like m3browser.
>
> How best should I proceed to get this out to the community. I am
> tempted to push it into the CVS head just so that it gets some testing,
> but perhaps that is premature. I can confirm a complete bootstrap via
> "do-cm3-std.sh" that appears to produce perfectly functional
> executables, including mentor, etc.
>
>
--
-------------------------------------------------------------
Rodney M. Bates, retired assistant professor
Dept. of Computer Science, Wichita State University
Wichita, KS 67260-0083
316-978-3922
rodney.bates at wichita.edu
More information about the M3devel
mailing list