2014-01-05 05:46:18

by Antti Heikkinen

[permalink] [raw]
Subject: Propose for LINUX kernel and PERL

To Dear Perl and LINUX kernel development community:

My propose to you at your list: is possible to write operate system in
PERL? I am student in university, looked for interest project to
conclude my study on LINUX kernel.

This semester, I take beginner PERL course and learn power of
procedural language. I automate many daily task with use of it. Very
impressive ability to make many thing work, interpret or can compile
also.

Also about LINUX, I talk to much fellow students and professors, and
take a operate system course use FreeBSD and LINUX. FreeBSD okay, but
they say LINUX kernel is too big and bloat, run poor with too many
developer. And too much quick decision from leader with ego is too big
and bloat too, kekeke.

LINUX kernel can perform more good if written in not C and C++ but
Perl? Just certain portion of LINUX kernel to rewrite? For instant,
schedule or support of multithread? If so, should use Perl5 or Perl6,
focus to x86 or x86-64? Can you want to join me this my project? But
to hear your expertise.

Am excited to learn and begin study project. Can you want to join this
my project? Please direct reply of email to myself.

Much thank to you,
Antti Heikkinen


2014-01-05 08:19:11

by bulk88

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

Antti Heikkinen wrote:
> To Dear Perl and LINUX kernel development community:
>
> My propose to you at your list: is possible to write operate system in
> PERL? I am student in university, looked for interest project to
> conclude my study on LINUX kernel.
>
> This semester, I take beginner PERL course and learn power of
> procedural language. I automate many daily task with use of it. Very
> impressive ability to make many thing work, interpret or can compile
> also.
>
> Also about LINUX, I talk to much fellow students and professors, and
> take a operate system course use FreeBSD and LINUX. FreeBSD okay, but
> they say LINUX kernel is too big and bloat, run poor with too many
> developer. And too much quick decision from leader with ego is too big
> and bloat too, kekeke.
>

I agree, Linux kernel is hacks on hacks with no top to bottom
architecture. Linux had the BKL longer than its competitors. Linux was
never whiteboarded before the project began. FreeBSD is more organized
and uniform. There is also NT Kernel whose API was speced out before the
kernel was written.

> LINUX kernel can perform more good if written in not C and C++ but
> Perl? Just certain portion of LINUX kernel to rewrite? For instant,
> schedule or support of multithread? If so, should use Perl5 or Perl6,
> focus to x86 or x86-64? Can you want to join me this my project? But
> to hear your expertise.

Since Perl is Turing complete you can run the Linux kernel inside Perl.
Although Perl doesn't run in kernel mode ATM, I don't see why I can't be
ported to be a LKM, maybe with RPC to glibc. You could also have Perl
running as user mode driver or some kind daemon with calls from a kernel
driver to the user space daemon Perl. You can use Perl version 5 or 6.

2014-01-05 09:10:12

by Richard Foley

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

A useful Monks link here:

http://www.perlmonks.org/?node=339754

and:

http://www.foo.be/docs/tpj/issues/vol5_2/tpj0502-0009.html

--
Ciao

Richard Foley

http://www.rfi.net/books.html

On Sun, Jan 05, 2014 at 12:46:00AM -0500, Antti Heikkinen wrote:
> To Dear Perl and LINUX kernel development community:
>
> My propose to you at your list: is possible to write operate system in
> PERL? I am student in university, looked for interest project to
> conclude my study on LINUX kernel.
>
> This semester, I take beginner PERL course and learn power of
> procedural language. I automate many daily task with use of it. Very
> impressive ability to make many thing work, interpret or can compile
> also.
>
> Also about LINUX, I talk to much fellow students and professors, and
> take a operate system course use FreeBSD and LINUX. FreeBSD okay, but
> they say LINUX kernel is too big and bloat, run poor with too many
> developer. And too much quick decision from leader with ego is too big
> and bloat too, kekeke.
>
> LINUX kernel can perform more good if written in not C and C++ but
> Perl? Just certain portion of LINUX kernel to rewrite? For instant,
> schedule or support of multithread? If so, should use Perl5 or Perl6,
> focus to x86 or x86-64? Can you want to join me this my project? But
> to hear your expertise.
>
> Am excited to learn and begin study project. Can you want to join this
> my project? Please direct reply of email to myself.
>
> Much thank to you,
> Antti Heikkinen

2014-01-05 17:53:56

by Austin S Hemmelgarn

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On 01/05/2014 12:46 AM, Antti Heikkinen wrote:
> To Dear Perl and LINUX kernel development community:
>
> My propose to you at your list: is possible to write operate system
> in PERL? I am student in university, looked for interest project
> to conclude my study on LINUX kernel.
>
> This semester, I take beginner PERL course and learn power of
> procedural language. I automate many daily task with use of it.
> Very impressive ability to make many thing work, interpret or can
> compile also.
>
> Also about LINUX, I talk to much fellow students and professors,
> and take a operate system course use FreeBSD and LINUX. FreeBSD
> okay, but they say LINUX kernel is too big and bloat, run poor with
> too many developer. And too much quick decision from leader with
> ego is too big and bloat too, kekeke.
>
> LINUX kernel can perform more good if written in not C and C++ but
> Perl? Just certain portion of LINUX kernel to rewrite? For
> instant, schedule or support of multithread? If so, should use
> Perl5 or Perl6, focus to x86 or x86-64? Can you want to join me
> this my project? But to hear your expertise.
No offense, but anyone who thinks that Perl (or any other interpreted
language except Lua) code will run faster than C is rather out of touch.
C code doesn't have any of the translation overhead that interpreted
languages do. Perl is an extremely high level language, and thus suffers
from this even more (although it has been getting better about this in
recent years). The only reason in fact that Lua manages to do almost as
well as native machine code compiled from C is that it uses a very
simple VM that is very similar in many respects to most modern processors.
>
> Am excited to learn and begin study project. Can you want to join
> this my project? Please direct reply of email to myself.
>
> Much thank to you, Antti Heikkinen
While I personally would never advocate a beginner trying to write an
entire OS because it is a HUGE undertaking (even more so in an
interpreted language like Perl), you might look into running Perl on
top of a micro-kernel like L4. This would allow you to run Perl in
Ring 0/Kernel Mode. If you wanted to use Lua instead (It's amazingly
easy to learn) then L4 would definitely be a good choice because the
init program for it already uses Lua.

2014-01-05 22:32:15

by Steven Rostedt

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On Sun, Jan 05, 2014 at 12:46:00AM -0500, Antti Heikkinen wrote:
>
> LINUX kernel can perform more good if written in not C and C++ but
> Perl? Just certain portion of LINUX kernel to rewrite? For instant,
> schedule or support of multithread? If so, should use Perl5 or Perl6,
> focus to x86 or x86-64? Can you want to join me this my project? But
> to hear your expertise.

OMFG! You are my idol!

I've been trying hard for years to just get a Perl interpreter into the kernel,
but here you are requesting to REWRITE LINUX IN PERL! That's so F$@King awesome!

Please do so! And if you succeed, I will personally claim that you have a bigger
set of oysters than I do! ;-)

But be warned, there's a conspiracy out there to rewrite Linux in Python.. **shudder**

-- Steve

2014-01-05 23:43:12

by Theodore Ts'o

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On Sun, Jan 05, 2014 at 03:12:17AM -0500, bulk88 wrote:
> I agree, Linux kernel is hacks on hacks with no top to bottom
> architecture. Linux had the BKL longer than its competitors. Linux
> was never whiteboarded before the project began. FreeBSD is more
> organized and uniform. There is also NT Kernel whose API was speced
> out before the kernel was written.

For the record, Linux had the BKL longer because it has had SMP longer
than its competitors. Linux got rid of the last of the BKL in
mid-2012. As of 2013, FreeBSD, NetBSD, and OpenBSD still has the
giant lock (BSD's equivalent of the BKL) in some of their subsystems.
And of course, in general Linux has had much better scalability than
the *BSD's for much of the past couple of years, with SGI using Linux
on systems with hundreds of processors, and with people using Linux on
32 and 64 processors systems for the past decade. In contrast,
FreeBSD was boasting in 2013 of improving its 16 processor
scalability...

> Since Perl is Turing complete you can run the Linux kernel inside
> Perl. Although Perl doesn't run in kernel mode ATM, I don't see why
> I can't be ported to be a LKM, maybe with RPC to glibc. You could
> also have Perl running as user mode driver or some kind daemon with
> calls from a kernel driver to the user space daemon Perl. You can
> use Perl version 5 or 6.

My favorite suggestion, going back several decades to the early 90's,
was those who suggested porting BSD 4.3 to Emacs LISP, so that you
could run your entire system under GNU Emacs. :-)

- Ted

2014-01-06 01:01:42

by Al Viro

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On Sun, Jan 05, 2014 at 06:43:07PM -0500, Theodore Ts'o wrote:

> > Since Perl is Turing complete you can run the Linux kernel inside
> > Perl. Although Perl doesn't run in kernel mode ATM, I don't see why
> > I can't be ported to be a LKM, maybe with RPC to glibc. You could
> > also have Perl running as user mode driver or some kind daemon with
> > calls from a kernel driver to the user space daemon Perl. You can
> > use Perl version 5 or 6.
>
> My favorite suggestion, going back several decades to the early 90's,
> was those who suggested porting BSD 4.3 to Emacs LISP, so that you
> could run your entire system under GNU Emacs. :-)

ISAGN: drivers/staging/vi[1]. As a TTY line discipline. Surely once that
thing is in, somebody will come up with Perl interpreter in vi macros.
And once _that_ is done, the rest will be easy...

[1] or drivers/staging/sam, for extra credits - as far as macros go,
it'd be more convenient implementation platform...

2014-01-06 01:45:43

by Jovi Zhangwei

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On Mon, Jan 6, 2014 at 1:48 AM, Austin S Hemmelgarn
<[email protected]> wrote:
> On 01/05/2014 12:46 AM, Antti Heikkinen wrote:
>> To Dear Perl and LINUX kernel development community:
>>
>> My propose to you at your list: is possible to write operate system
>> in PERL? I am student in university, looked for interest project
>> to conclude my study on LINUX kernel.
>>
>> This semester, I take beginner PERL course and learn power of
>> procedural language. I automate many daily task with use of it.
>> Very impressive ability to make many thing work, interpret or can
>> compile also.
>>
>> Also about LINUX, I talk to much fellow students and professors,
>> and take a operate system course use FreeBSD and LINUX. FreeBSD
>> okay, but they say LINUX kernel is too big and bloat, run poor with
>> too many developer. And too much quick decision from leader with
>> ego is too big and bloat too, kekeke.
>>
>> LINUX kernel can perform more good if written in not C and C++ but
>> Perl? Just certain portion of LINUX kernel to rewrite? For
>> instant, schedule or support of multithread? If so, should use
>> Perl5 or Perl6, focus to x86 or x86-64? Can you want to join me
>> this my project? But to hear your expertise.
> No offense, but anyone who thinks that Perl (or any other interpreted
> language except Lua) code will run faster than C is rather out of touch.
> C code doesn't have any of the translation overhead that interpreted
> languages do. Perl is an extremely high level language, and thus suffers
> from this even more (although it has been getting better about this in
> recent years). The only reason in fact that Lua manages to do almost as
> well as native machine code compiled from C is that it uses a very
> simple VM that is very similar in many respects to most modern processors.
>>
Just FYI, ktap is for "lua in Linux kernel". :)
The lua VM is pretty simple and the instruction could translate to machine
code easily, the cool thing is luajit project already proved this.

Thanks,

Jovi

2014-01-06 01:49:57

by Jovi Zhangwei

[permalink] [raw]
Subject: Re: Propose for LINUX kernel and PERL

On Mon, Jan 6, 2014 at 6:32 AM, Steven Rostedt <[email protected]> wrote:
> On Sun, Jan 05, 2014 at 12:46:00AM -0500, Antti Heikkinen wrote:
>>
>> LINUX kernel can perform more good if written in not C and C++ but
>> Perl? Just certain portion of LINUX kernel to rewrite? For instant,
>> schedule or support of multithread? If so, should use Perl5 or Perl6,
>> focus to x86 or x86-64? Can you want to join me this my project? But
>> to hear your expertise.
>
> OMFG! You are my idol!
>
> I've been trying hard for years to just get a Perl interpreter into the kernel,

Steven, I'm so curious on this kernel Perl interpreter, would you please share
some info to me? what's the main usecases?:)

Thanks,

Jovi