BYTE versus WORD and time


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2006
    Location
    Omaha, Nebraska USA
    Posts
    263

    Question BYTE versus WORD and time

    If I use BYTE variables in this expression rather than WORDs . . .

    A = A + B

    . . . how much faster is the execution? May I assume that if A and B are BYTEs, it will be about twice as fast than if they are WORDs? Or does the manipulation for WORDs add even more overhead?

    I did search but did not identify a thread that addressed this. If there is one, please send me there.

    Thanks.
    Russ
    N0EVC, xWB6ONT, xWN6ONT

    "Easy to use" is easy to say.

  2. #2
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    There's this ...

    instruction execution time
    http://www.picbasic.co.uk/forum/showthread.php?t=365

    and this ...

    Code Timer - How long does it take to execute XYZ command?
    http://www.picbasic.co.uk/forum/showthread.php?t=9350

    hth,
    DT

  3. #3
    Join Date
    Aug 2006
    Location
    Omaha, Nebraska USA
    Posts
    263


    Did you find this post helpful? Yes | No

    Default

    Thanks, Darrel.

    It looks, though, like a simpler approach in my situation might be to just toggle a pin and look at the oscilloscope. I don't need to know down to a gnat's whisker, just wanted a general idea.
    Russ
    N0EVC, xWB6ONT, xWN6ONT

    "Easy to use" is easy to say.

Similar Threads

  1. Minimizing code space
    By Tobias in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 30th May 2009, 07:25
  2. How to set sequence of interrupt for PIC
    By chai98a in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 21st June 2008, 11:17
  3. Migrating from PIC16F690 to PIC18F4525 and having LCD issues
    By jblackann in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 6th June 2008, 20:05
  4. byte compression
    By Norbert in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 16th June 2007, 18:04
  5. 16F877 RAM Question
    By Art in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 6th August 2005, 11:47

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts