Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Sep 1997 19:53:57 +0000 (GMT)
From:      Terry Lambert <tlambert@primenet.com>
To:        Temcguire@aol.com
Cc:        hackers@FreeBSD.ORG
Subject:   Re: Interpreter compilers
Message-ID:  <199709091953.MAA28976@usr03.primenet.com>
In-Reply-To: <970909142903_-131376035@emout04.mail.aol.com> from "Temcguire@aol.com" at Sep 9, 97 02:31:46 pm

next in thread | previous in thread | raw e-mail | index | archive | help
> Recently, I installed FreeBSD (2.2.2) on a Pentium Pro in an attempt to
> upgrade from SPARC.  When I attempted to build awkcc (from AT&T Toolchest) I
> discovered that flex (GNU) was not happy with awk.lx.l in the awkcc source.
>  Seems, that flex -l option also would not accommodate the lack of POSIX
> compliance in awk.lx.l.  I have tried blex (Berkeley port?) and had similar
> results.
> 
> Question#1: Any suggestions on how to get around differences between AT&T lex
> and GNU flex differences within FreeBSD?

Yes.  I can help you, but I need to know the specific error messages
you got when you attempted this.  There are a number of differences.
If you can't disclose the messages because they contain source, you
will need to do the job yourself.  I recommend:

	lex & yacc
	John R. Levine, Tony Mason, Doug Brown
	O'Reilly & Associates, Inc.
	ISBN 1-56592-000-7

which describes the conversion process in detail.  It assumes a working
knowledge of lex (or yacc, which isn't important in your case).


> In the realm of rapid prototyping with interpretive languages, there appear
> to be several options in FreeBSD (1997).  I noticed tcl/tk, JAVA and PERL in
> particular and observed scheme and python.  It appears that a compiler exists
> for scheme (scheme-to-C).
> 
> Question#2:  Can PERL scripts be translated into C and compiled into
> executables?  Do regular expressions and associative arrays (awk) exist in
> any other languages that can be translated and compiled?

I have not seen a PERL to C translator, but I have not really looked.
There exist both translators and JITs (Just-In-Time-compilers) for
JAVA.  Search Yahoo for Kaffe and follow the links around to 20 or more
of them.


> P.S.,
> The Pentium Pro I purchased (Micron Inc.) has the option of a second
> processor.  I have 64Mb of memory and wonder if I installed another
> processor, would FreeBSD operate much faster?

If you run SMP FreeBSD, it should, for concurrent tasks.  SMP FreeBSD
is current experimental, meaning it is not a release.

Normal processes are intrinsically bound to a single CPU, so adding CPU's
typically won't buy you anything, uless you are running a multiprocess
server (mail services, ftp services, http services) AND you are currently
CPU bound (you will get a concurrency win in that case).

Threaded processes are currently not SMP scalable, but are expected to
become so in the future.  After that, single processes with multiple
threads of control willget concurrency wins under SMP as well.


					Terry Lambert
					terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199709091953.MAA28976>