Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Comparison QB64 compiled with gcc optimizations and without
#21
Picture unroller. Author James D Jarvis. Found in the forum.

8.5x seconds : program compiled with qb64 -O3
8.5x seconds : program compiled with original qb64

Tested with an image with a resolution of 1024x768.

no gain with the use of _PutImage. surprising.
Code: (Select All)
' James D Jarvis : Picture unroller
img& = _LoadImage("pic3.jpg", 32) 'your image here
w = _Width(img&)
h = _Height(img&)
sc& = _NewImage(w, h, 32)
Screen sc&
_Delay 0.1
_ScreenMove _Middle
Cls: s = 3
start = Timer(.001)
For yc = 0 To h Step s:
    _Limit 30
    _PutImage (0, 0), img&, sc&, (0, 0)-(w, yc)
    _PutImage (0, yc - 6)-(w, yc + 6), img&, sc&, (0, yc)-(w, yc + 3)
Next yc
Print Timer(.001) - start; "seconds"
Reply


Messages In This Thread
RE: Comparison QB64 compiled with Ofast and without - by Coolman - 05-09-2022, 05:50 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  niXman gcc-13.1.0 Jack 8 1,851 10-04-2023, 12:51 PM
Last Post: a740g
  BASIC's Comparison Matrix: ideas for content? CharlieJV 28 6,725 10-03-2022, 01:27 AM
Last Post: CharlieJV
  String comparison oddity...[SOLVED] Pete 6 1,292 08-05-2022, 07:16 PM
Last Post: Pete
  Found a BUG with the QB64 editor compiled with the -O3 option Coolman 2 826 06-02-2022, 06:27 PM
Last Post: Coolman

Forum Jump:


Users browsing this thread: 1 Guest(s)