5467 posts The Dude Abides
  • Top Monthly Author
  • Trendsetter
  • Weekly Top Seller
  • United States
+13 more
CodingJack
says

point is, any basic compiler would optimize example2 into example1 coz fixed values are always faster then variables

This is why I don’t quite understand it either. For a variable, dooesn’t Flash have to look up what the value is? Whereas for a value itself, there’s nothing to look up…

2054 posts
  • Affiliate Level 3
  • Author Level 11
  • Collector Level 2
  • Elite Author
+11 more
bitfade
says
This is why I don’t quite understand it either. For a variable, dooesn’t Flash have to look up what the value is? Whereas for a value itself, there’s nothing to look up…
yes, that exactly how it should works
my guess is, since using different values the thing works as expected, maybe 0xFFFFFFFF is converted to number instead of uint
Then the opposite number to uint conversion is done tons of times in the inner loop causing the slowdown.

4140 posts
  • 7 Years of Membership
  • Affiliate Level 1
  • Author Level 4
  • Brazil
+5 more
tsafi
says
i’m having hard time trying to undestand what are you talking’ ....
buongiorno Bit`
If you didn’t get me on my 1&2 post you wont get me at me at 3&4&5 and so on …… :P
2054 posts
  • Affiliate Level 3
  • Author Level 11
  • Collector Level 2
  • Elite Author
+11 more
bitfade
says
buongiorno Bit`
If you didn’t get me on my 1&2 post you wont get me at me at 3&4&5 and so on …… :P
grazie, anche a te Tsafi
i’m sorry if it sounded rude, it was not meant to
but english is not my language, half ot the times i don’t even undestand what i’m talking about.
4140 posts
  • 7 Years of Membership
  • Affiliate Level 1
  • Author Level 4
  • Brazil
+5 more
tsafi
says
buongiorno Bit`
If you didn’t get me on my 1&2 post you wont get me at me at 3&4&5 and so on …… :P
grazie, anche a te Tsafi
i’m sorry if it sounded rude, it was not meant to
but english is not my language, half ot the times i don’t even undestand what i’m talking about.

+1 :D

non ti preoccupare il suo ok :P
vorrei che il mio italiano è stato leggermente migliore il mio inglese, portoghese, ebraico e così via (:

2054 posts
  • Affiliate Level 3
  • Author Level 11
  • Collector Level 2
  • Elite Author
+11 more
bitfade
says

now, this is quite interesting (well, at least for me)

just run some benchs about read/write memory performances comparing Vectors and flash fast memory opcodes (values are cpu usage)

Vector    40%
FastMem   13%
what a massive speed up

the test involved making 4 read and 4 write on 590×300 Vector/ByteArray, then data was loaded into a BitmapData

2054 posts
  • Affiliate Level 3
  • Author Level 11
  • Collector Level 2
  • Elite Author
+11 more
bitfade
says

@wickedpixel
i didn’t tested Arrays coz they are ways slower then Vectors

by
by
by
by
by
by