Searching \ for '[PIC] MPLAB C18 optimized printf. Was:{OT} Legal s' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: piclist.org/techref/microchip/languages.htm?key=mplab
Search entire site for: 'MPLAB C18 optimized printf. Was:{OT} Legal s'.

Exact match. Not showing close matches.
PICList Thread
'[PIC] MPLAB C18 optimized printf. Was:{OT} Legal s'
2012\02\16@063741 by Isaac Marino Bavaresco

flavicon
face
Changing tag because I think it entered the PIC domain.


Just finished benchmarking my custom PIC18 'printf' against Microchip's
original:

Test code vas:

unsigned long value = 1;
while( 1 )
   {
   printf( "%lu", value );
   value *= 10;
   }

int _user_putc( char c )
   {
   return 0;
   }


Please note that the function '_user_putc' was "neutralized" just to
remove hardware times from the benchmark. We are testing just the
mathematical portions of the process. Function "_user_putc" is what
ultimately displays each character.


Times for Microchip's original 'printf':

value -> cycles
1 -> 2104
10 -> 3756
100 -> 5440
1,000 -> 7108
10,000 -> 8840
100,000 -> 10556
1,000,000 -> 12288
10,000,000 -> 14036
100,000,000 -> 15800
1,000,000,000 -> 17628


Times for my improved 'printf':

value -> cycles
1 -> 1255
10 -> 1347
100 -> 1621
1,000 -> 1895
10,000 -> 2229
100,000 -> 2503
1,000,000 -> 2777
10,000,000 -> 3111
100,000,000 -> 3385
1,000,000,000 -> 3659


I think my routine is worth sharing but I'm afraid of doing this without
knowing the legal implications, that's why I posted the original question.


Regards,

Isaac



Em 15/2/2012 15:27, Isaac Marino Bavaresco escreveu:
{Quote hidden}

>

2012\02\16@070722 by Walter Banks

flavicon
face
Isaac,

The most definitive answer is to contact Microchip directly. I have had a lot of
dealings with Microchip over the years and you will get a clear definitive answer.

The process could take a few days.

Walter..


Isaac Marino Bavaresco wrote:

{Quote hidden}

>

2012\02\16@075517 by alan.b.pearce

face picon face
> Isaac,
>
> The most definitive answer is to contact Microchip directly. I have had a lot of
> dealings with Microchip over the years and you will get a clear definitive answer.
>
> The process could take a few days.
>
> Walter..

They may even want to include your code in the release. I note that in the C30 release, I think it is, there are credits to individuals for library code. This may be only because it comes as part of the GNU compiler, but may be for other reasons.


-- Scanned by iCritical.

2012\02\16@204135 by piclist4

flavicon
face
On Thu, 16 Feb 2012, spam_OUTalan.b.pearceTakeThisOuTspamstfc.ac.uk wrote:

>> The most definitive answer is to contact Microchip directly. I have had a lot of
>> dealings with Microchip over the years and you will get a clear definitive answer.
>>
> They may even want to include your code in the release.

All indications are that C18 has no future, so that seems unlikely.  I
can't imagine Microchip devoting the time to test and release new
library code for C18.

--
John W. Temples, II

More... (looser matching)
- Last day of these posts
- In 2012 , 2013 only
- Today
- New search...