Re: [Mono-dev] Jit and C# Compiler

2006-10-06 Thread Paolo Molaro
On 10/05/06 Khaled A. K. Mohammed wrote:
 I am briefly describing the project below. 
 The project will aim to improve the execution of CIL image on multicore
 processors. First step is to change the C# compiler to insert custom
 instructions into the managed binary (just like how the line #s are
 stored). These instructions will be parsed by JIT to pick valuable

You may want to handle this at the IL code level, so that other
languages than C# can be supported. You'd use Cecil or some other such
library to load the compiled assembly, change the IL code and save it
back.
Depending on what you really want to do to the code, in most cases it
might be enough to just change method calls to go through a runtime
library you can write in C# that will dispatch the call to a pool of
threads (obviously only for a selected subset of calls).


lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Jit and C# Compiler

2006-10-05 Thread Cedric Vivier
Hi!Sounds very interesting!If I am correct you want to detect (thus extract) parallelism from a CIL image right?Do you have any research paper describing the algorithm you plan to use ?Please keep us informed of your advancement :)
--cv2006/10/5, Khaled A. K. Mohammed [EMAIL PROTECTED]
:
Hi,I am doing a course on compiler. I am planning to choose a project basedon .NET Framework/Mono.I am briefly describing the project below.The project will aim to improve the execution of CIL image on multicore
processors. First step is to change the C# compiler to insert custominstructions into the managed binary (just like how the line #s arestored). These instructions will be parsed by JIT to pick valuableinformation about instruction dependency and will be able to make smart
decisions. Yes, the size of binaries will grow. We will work for aoptimal solutions - may be by having a percentage size threshold.This is a research/school project to prove a concept.Lots of comments/suggestions are welcomed.
Regards,Khaled___Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Jit and C# Compiler

2006-10-05 Thread Martin Hinks
Do you plan to automatically detect when parallel usage is possible or
will it be something that the C# program's author can specify?

Martin

On 10/5/06, Cedric Vivier [EMAIL PROTECTED] wrote:
 Hi!

 Sounds very interesting!
 If I am correct you want to detect (thus extract) parallelism from a CIL
 image right?
 Do you have any research paper describing the algorithm you plan to use ?

 Please keep us informed of your advancement :)

 --
 cv

 2006/10/5, Khaled A. K. Mohammed [EMAIL PROTECTED] :
  Hi,
 
  I am doing a course on compiler. I am planning to choose a project based
  on .NET Framework/Mono.
 
  I am briefly describing the project below.
  The project will aim to improve the execution of CIL image on multicore
  processors. First step is to change the C# compiler to insert custom
  instructions into the managed binary (just like how the line #s are
  stored). These instructions will be parsed by JIT to pick valuable
  information about instruction dependency and will be able to make smart
  decisions. Yes, the size of binaries will grow. We will work for a
  optimal solutions - may be by having a percentage size threshold.
 
  This is a research/school project to prove a concept.
 
  Lots of comments/suggestions are welcomed.
 
  Regards,
  Khaled
 
  ___
  Mono-devel-list mailing list
  Mono-devel-list@lists.ximian.com
 
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 


 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list





-- 
Martin Hinks
http://www.m-s-d.net
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Jit and C# Compiler

2006-10-05 Thread tcmichals
To simply this task maybe use OpenMP http://www.openmp.org
Martin Hinks [EMAIL PROTECTED] wrote in message 
news:[EMAIL PROTECTED]
 Do you plan to automatically detect when parallel usage is possible or
 will it be something that the C# program's author can specify?

 Martin

 On 10/5/06, Cedric Vivier [EMAIL PROTECTED] wrote:
 Hi!

 Sounds very interesting!
 If I am correct you want to detect (thus extract) parallelism from a CIL
 image right?
 Do you have any research paper describing the algorithm you plan to use ?

 Please keep us informed of your advancement :)

 --
 cv

 2006/10/5, Khaled A. K. Mohammed [EMAIL PROTECTED] :
  Hi,
 
  I am doing a course on compiler. I am planning to choose a project 
  based
  on .NET Framework/Mono.
 
  I am briefly describing the project below.
  The project will aim to improve the execution of CIL image on multicore
  processors. First step is to change the C# compiler to insert custom
  instructions into the managed binary (just like how the line #s are
  stored). These instructions will be parsed by JIT to pick valuable
  information about instruction dependency and will be able to make smart
  decisions. Yes, the size of binaries will grow. We will work for a
  optimal solutions - may be by having a percentage size threshold.
 
  This is a research/school project to prove a concept.
 
  Lots of comments/suggestions are welcomed.
 
  Regards,
  Khaled
 
  ___
  Mono-devel-list mailing list
  Mono-devel-list@lists.ximian.com
 
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 


 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list





 -- 
 Martin Hinks
 http://www.m-s-d.net 



___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Jit and C# Compiler

2006-10-05 Thread Khaled A. K. Mohammed
Hello,

On Thu, 2006-10-05 at 14:18 +0200, Cedric Vivier wrote:
 Hi!
 
 Sounds very interesting!
 If I am correct you want to detect (thus extract) parallelism from a
 CIL image right?
Yes, the extra information will help JIT to understand the nature of the
program.

 Do you have any research paper describing the algorithm you plan to
 use ?

Well, one of the student of Prof. Tarek (University of Toronto) have
modified Jikes (the IBM java compiler) to do something similar. His
changes in compiler created two files: a java byte code and a registry
for runtime environment. And his changes in JIT will thread any method
it finds and will use the registry information to handle dependency
issues. 
http://www.eecg.toronto.edu/zjava/
Prof. Tarek has done a lot of research on inserting extra information in
binary image. So I am guessing he has what I would need. 

The first step is to research on .NET to find out what kind of
optimization for multicore processor (parellelism) is currently
available?

 Please keep us informed of your advancement :)
Sure, thanks.
  
 
 --
 cv
 
 2006/10/5, Khaled A. K. Mohammed [EMAIL PROTECTED]:
 Hi,
 
 I am doing a course on compiler. I am planning to choose a
 project based
 on .NET Framework/Mono.
 
 I am briefly describing the project below.
 The project will aim to improve the execution of CIL image on
 multicore 
 processors. First step is to change the C# compiler to insert
 custom
 instructions into the managed binary (just like how the line
 #s are
 stored). These instructions will be parsed by JIT to pick
 valuable
 information about instruction dependency and will be able to
 make smart 
 decisions. Yes, the size of binaries will grow. We will work
 for a
 optimal solutions - may be by having a percentage size
 threshold.
 
 This is a research/school project to prove a concept.
 
 Lots of comments/suggestions are welcomed. 
 
 Regards,
 Khaled
 
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Jit and C# Compiler

2006-10-05 Thread Khaled A. K. Mohammed
Hi,
On Thu, 2006-10-05 at 13:21 +0100, Martin Hinks wrote:
 Do you plan to automatically detect when parallel usage is possible or
 will it be something that the C# program's author can specify?
Automatic is the plan for now. I might use the compiler to add
Attributes [(...)] to methods during compilation, which can probably
be added by application developers too. 

If you have other suggestions, please let me know. 

 
 Martin
 
 On 10/5/06, Cedric Vivier [EMAIL PROTECTED] wrote:
  Hi!
 
  Sounds very interesting!
  If I am correct you want to detect (thus extract) parallelism from a CIL
  image right?
  Do you have any research paper describing the algorithm you plan to use ?
 
  Please keep us informed of your advancement :)
 
  --
  cv
 
  2006/10/5, Khaled A. K. Mohammed [EMAIL PROTECTED] :
   Hi,
  
   I am doing a course on compiler. I am planning to choose a project based
   on .NET Framework/Mono.
  
   I am briefly describing the project below.
   The project will aim to improve the execution of CIL image on multicore
   processors. First step is to change the C# compiler to insert custom
   instructions into the managed binary (just like how the line #s are
   stored). These instructions will be parsed by JIT to pick valuable
   information about instruction dependency and will be able to make smart
   decisions. Yes, the size of binaries will grow. We will work for a
   optimal solutions - may be by having a percentage size threshold.
  
   This is a research/school project to prove a concept.
  
   Lots of comments/suggestions are welcomed.
  
   Regards,
   Khaled
  
   ___
   Mono-devel-list mailing list
   Mono-devel-list@lists.ximian.com
  
  http://lists.ximian.com/mailman/listinfo/mono-devel-list
  
 
 
  ___
  Mono-devel-list mailing list
  Mono-devel-list@lists.ximian.com
  http://lists.ximian.com/mailman/listinfo/mono-devel-list
 
 
 
 
 

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list