[Gridflow-cvs] [svn] commit: r3638 - /trunk/base/mmx.rb

gridflow-cvs at artengine.ca gridflow-cvs at artengine.ca
Mon Apr 21 00:31:20 EDT 2008


Author: matju
Date: Mon Apr 21 00:31:20 2008
New Revision: 3638

Log:
nothing

Modified:
    trunk/base/mmx.rb

Modified: trunk/base/mmx.rb
==============================================================================
--- trunk/base/mmx.rb (original)
+++ trunk/base/mmx.rb Mon Apr 21 00:31:20 2008
@@ -2,7 +2,7 @@
 	$Id$
 
 	GridFlow
-	Copyright (c) 2001,2002,2003,2004 by Mathieu Bouchard
+	Copyright (c) 2001-2008 by Mathieu Bouchard
 
 	This program is free software; you can redistribute it and/or
 	modify it under the terms of the GNU General Public License
@@ -25,8 +25,7 @@
 $loader = File.open ARGV[1], "w"
 $count = 0
 $lines = 0
-
-puts "; generated by/for GridFlow 0.8.2"
+puts "; generated by/for GridFlow 0.9.2"
 $loader.puts "#include \"../gridflow.h.fcs\"\nextern \"C\" {"
 
 # this class is not really used yet (only self.make)
@@ -45,7 +44,7 @@
 		a = @label_count
 		b = @label_count+1
 		@label_count+=2
-		ops[-1]<<" #{@name}_#{b}"
+		ops[-1] << " #{@name}_#{b}"
 		puts "#{@name}_#{a}: ", *ops
 		yield
 		puts "jmp #{@name}_#{a}"
@@ -61,13 +60,11 @@
 	:float32 => 4,
 	:float64 => 8,
 }
-
 $accum = {
 	:uint8 => "al",
 	:int16 => "ax",
 	:int32 => "eax",
 }
-
 $asm_type = {
 	:uint8 => "byte",
 	:int16 => "word",
@@ -101,7 +98,6 @@
 	op.map! {|x| if x=="_" then nil else x end }
 	STDERR.puts op.inspect
 }
-
 $decls = ""
 $install = ""
 
@@ -127,7 +123,7 @@
 				for i in 0...nn do puts "#{mopcode} mm#{i},mm7" end
 				for i in 0...nn do puts "movq [esi+#{o[i]}],mm#{i}" end
 				}
-				puts "lea esi,[esi+#{8*n}]", "lea ecx,[ecx-#{8/size*n}]"
+				puts "lea esi,[esi+#{8*n}]", "lea ecx,[ecx-#{8 / size*n}]"
 			}
 		}
 		foo.call 4
@@ -144,7 +140,7 @@
 end
 
 def make_fun_zip(op,type)
-s="mmx_#{type}_zip_#{op}"
+	s="mmx_#{type}_zip_#{op}"
 	size = $sizeof[type]
 	accum = $accum[type]
 	sym = $opcodes[op][0]



More information about the Gridflow-cvs mailing list