Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #51695

Re: A New Forth

From anton@mips.complang.tuwien.ac.at (Anton Ertl)
Newsgroups comp.lang.forth
Subject Re: A New Forth
Date 2016-10-08 13:08 +0000
Organization Institut fuer Computersprachen, Technische Universitaet Wien
Message-ID <2016Oct8.150800@mips.complang.tuwien.ac.at> (permalink)
References <9dc136b0-5a06-4bad-b719-0e94358896f1@googlegroups.com>

Show all headers | View raw


tabcomputing@gmail.com writes:
>I am planning to build a new variant of the Forth language. I plan to do so in Assembly, but I am wondering if I might be better off doing that in LLVM IR. Anyone have any recommendations as to why or why not I should use LLVM?

I would not use it, for the reasons outlined in my PAF paper
[ertl13-paf]:

|Unfortunately, [LLVM] shares many of the problems of C: In particular, you
|have to divide the code into functions that follow some calling
|convention, restricting the kind of control flow that is possible.  To
|work around this problem, it is possible to add your own calling
|convention, but that is not easy.\footnote{Usenet message
|  \url{<KYGdnTH8PMyMpM7MnZ2dnUVZ_j-dnZ2d@supernews.com>}}
|
|LLVM was also promised to be a useful intermediate representation for
|JIT compilers, but reportedly its code generation is too slow for most
|JIT compiler uses.
|
|LLVM supports fewer targets than C.  Given that it also seems to share
|many of the disadvantages of C, it does not appear to be an attractive
|portable assembly language to me, despite the buzz it has generated.

If you want portability, take a look at GNU Lightning; it has a lot of
targets now.

@InProceedings{ertl13-paf,
  author =       {M. Anton Ertl},
  title =        {{PAF}: A Portable Assembly Language},
  crossref =     {euroforth13},
  pages =        {30--38},
  url =          {http://www.complang.tuwien.ac.at/anton/euroforth/ef13/papers/ertl-paf.pdf},
  OPTnote =      {not refereed},
  abstract =     {A portable assembly language provides access to
                  machine-level features like memory addresses,
                  machine words, code addresses, and modulo
                  arithmetics, like assembly language, but abstracts
                  away differences between architectures like the
                  assembly language syntax, instruction encoding,
                  register set size, and addressing modes.  Forth
                  already satisfies a number of the characteristics of
                  a portable assembly language, and is therefore a
                  good basis.  This paper presents PAF, a portable
                  assembly language based on Forth, and specifically
                  discusses language features that other portable
                  assembly languages do not have, and their benefits;
                  it also discusses the differences from Forth.  The
                  main innovations of PAF are: tags indicate the
                  control flow for indirect branches and calls; and
                  PAF has two kinds of calls and definitions: the ABI
                  ones follow the platform's calling convention and
                  are useful for interfacing to the outside world,
                  while the PAF ones allow tail-call elimination and
                  are useful for implementing general control
                  structures.}
}
@Proceedings{euroforth13,
  title = 	 {29th EuroForth Conference},
  booktitle = 	 {29th EuroForth Conference},
  year = 	 {2013},
  key =		 {EuroForth'13},
  url =          {http://www.complang.tuwien.ac.at/anton/euroforth/ef13/papers/proceedings.pdf}
}

- anton
-- 
M. Anton Ertl  http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
     New standard: http://www.forth200x.org/forth200x.html
   EuroForth 2016: http://www.euroforth.org/ef16/

Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

A New Forth tabcomputing@gmail.com - 2016-10-07 17:56 -0700
  Re: A New Forth Rod Pemberton <NeedNotReplyHere@xrsevnneqk.cem> - 2016-10-07 23:05 -0400
    Re: A New Forth Walter Banks <walter@bytecraft.com> - 2016-10-08 10:07 -0400
  Re: A New Forth anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-10-08 13:08 +0000
    Re: A New Forth trans <transfire@gmail.com> - 2016-10-08 10:54 -0700
      Re: A New Forth anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2016-10-08 18:03 +0000
        Re: A New Forth trans <transfire@gmail.com> - 2016-10-08 11:13 -0700
    Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-08 11:17 -0700
    Re: A New Forth hughaguilar96@gmail.com - 2016-10-13 14:44 -0700
      Re: A New Forth hughaguilar96@gmail.com - 2016-10-13 14:53 -0700
        Re: A New Forth hughaguilar96@gmail.com - 2016-10-13 15:04 -0700
        Re: A New Forth rickman <gnuarm@gmail.com> - 2016-10-13 22:55 -0400
  Re: A New Forth trans <transfire@gmail.com> - 2016-10-08 12:11 -0700
    Re: A New Forth albert@cherry.spenarnc.xs4all.nl (Albert van der Horst) - 2016-10-08 21:31 +0200
      Re: A New Forth trans <transfire@gmail.com> - 2016-10-08 17:07 -0700
    Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-08 12:33 -0700
      Re: A New Forth missycurl@gmail.com - 2016-10-08 12:54 -0700
        Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-08 13:29 -0700
      Re: A New Forth trans <transfire@gmail.com> - 2016-10-08 17:28 -0700
        Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-08 18:00 -0700
          Re: A New Forth trans <transfire@gmail.com> - 2016-10-09 09:00 -0700
            Re: A New Forth luser droog <mijoryx@yahoo.com> - 2016-10-09 11:19 -0700
            Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-10 01:09 -0700
              Re: A New Forth trans <transfire@gmail.com> - 2016-10-10 08:24 -0700
                Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-10 13:28 -0700
                Re: A New Forth "Elizabeth D. Rather" <erather@forth.com> - 2016-10-10 11:14 -1000
                Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-10 15:11 -0700
                Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-11 21:46 -0400
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-10 16:26 -0700
                Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-10 18:58 -0700
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-10 20:15 -0700
              Re: A New Forth Ron Aaron <rambamist@gmail.com> - 2016-10-11 07:26 +0300
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 03:09 -0700
                Re: A New Forth Ron Aaron <rambamist@gmail.com> - 2016-10-11 13:27 +0300
                Re: A New Forth lawrencedo99@gmail.com - 2016-10-13 18:41 -0700
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-13 19:08 -0700
                Re: A New Forth Ron Aaron <rambamist@gmail.com> - 2016-10-14 07:58 +0300
          Re: A New Forth franck.bensusan@gmail.com - 2016-10-09 11:09 -0700
          Re: A New Forth lawrencedo99@gmail.com - 2016-10-13 18:45 -0700
        Re: A New Forth albert@cherry.spenarnc.xs4all.nl (Albert van der Horst) - 2016-10-09 10:54 +0200
          Re: A New Forth missycurl@gmail.com - 2016-10-09 07:35 -0700
          Re: A New Forth Melzzzzz <mel@zzzzz.com> - 2016-10-11 06:23 +0200
          Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-10 21:31 -0700
          Re: A New Forth franck.bensusan@gmail.com - 2016-10-15 00:26 -0700
        Re: A New Forth Melzzzzz <mel@zzzzz.com> - 2016-10-13 19:16 +0200
          Re: A New Forth trans <transfire@gmail.com> - 2016-10-13 11:46 -0700
            Re: A New Forth Melzzzzz <Melzzzzz@zzzzz.com> - 2016-10-13 19:04 +0000
        Re: A New Forth "WJ" <w_a_x_man@yahoo.com> - 2016-10-15 20:07 +0000
    Re: A New Forth luser droog <mijoryx@yahoo.com> - 2016-10-08 13:56 -0700
  Re: A New Forth polymorph self <jackvanc3@gmail.com> - 2016-10-08 19:58 -0700
  Re: A New Forth Chris Curl <ccurl609@gmail.com> - 2016-10-10 19:22 -0700
    Re: A New Forth trans <transfire@gmail.com> - 2016-10-10 20:18 -0700
      Re: A New Forth Chris Curl <ccurl609@gmail.com> - 2016-10-11 11:14 -0700
        Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 14:22 -0700
          Re: A New Forth jim.brakefield@ieee.org - 2016-10-11 15:11 -0700
            Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 18:03 -0700
          Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-11 15:13 -0700
            Re: A New Forth Chris Curl <ccurl609@gmail.com> - 2016-10-11 17:52 -0700
              Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 19:55 -0700
              Re: A New Forth hughaguilar96@gmail.com - 2016-10-13 14:21 -0700
                Re: A New Forth hughaguilar96@gmail.com - 2016-10-13 14:36 -0700
            Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 18:08 -0700
              Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-11 18:21 -0700
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 20:01 -0700
        Re: A New Forth trans <transfire@gmail.com> - 2016-10-11 20:33 -0700
          Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-12 01:15 -0400
            Re: A New Forth trans <transfire@gmail.com> - 2016-10-12 05:44 -0700
              Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-12 11:51 -0400
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-12 09:47 -0700
                Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-12 10:08 -0700
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-12 11:48 -0700
                Re: A New Forth Paul Rubin <no.email@nospam.invalid> - 2016-10-12 11:56 -0700
                Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-12 13:41 -0400
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-12 11:57 -0700
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-12 12:02 -0700
                Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-13 09:24 -0400
                Re: A New Forth Doug Hoffman <glidedog@gmail.com> - 2016-10-13 10:33 -0400
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-13 10:05 -0700
                Re: A New Forth jim <anon@example.com> - 2016-10-12 19:01 +0100
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-13 09:53 -0700
                Re: A New Forth fred <anon@example.com> - 2016-10-14 12:37 +0100
                Re: A New Forth jim <anon@example.com> - 2016-10-14 14:49 +0100
                Re: A New Forth trans <transfire@gmail.com> - 2016-10-14 07:20 -0700
                Re: A New Forth jim <anon@example.com> - 2016-10-15 11:58 +0100
                Re: A New Forth tabcomputing@gmail.com - 2016-10-15 10:21 -0700
          Re: A New Forth Chris Curl <ccurl609@gmail.com> - 2016-10-12 04:33 -0700
  Re: A New Forth Whammo <sidciavic@gmail.com> - 2016-10-15 12:23 -0700

csiph-web