Changeset 352 for soft


Ignore:
Timestamp:
Jun 29, 2014, 1:16:24 PM (10 years ago)
Author:
alain
Message:

Avoid GCC warnings for some missing initialisations.

Location:
soft/giet_vm/giet_libs
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_libs/barrier.c

    r345 r352  
    3434    volatile unsigned int * pcount = (unsigned int *) &barrier->count;
    3535    volatile unsigned int maxcount = barrier->init;
    36     volatile unsigned int count;
     36    volatile unsigned int count = 0;
    3737
    3838    // parallel decrement barrier counter using atomic instructions LL/SC
  • soft/giet_vm/giet_libs/stdio.c

    r345 r352  
    2222////////////////////////////////////////////////////////////////////////////////////
    2323
    24 ////////////////////////////////////////
     24///////////////////////////////////////////////////////////////////////
    2525static int __printf( char* format, unsigned int channel, va_list* args)
    2626{
     
    329329                                channel,
    330330                                0 );
    331                 if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
     331                if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
    332332            }
    333333        }
     
    368368                            channel,
    369369                            0 );
    370             if ( ret < 0 ) giet_exit("error in giet_tty_gets()");
     370            if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
    371371        }
    372372        // echo character '0'
     
    377377                        channel,
    378378                        0 );
    379         if ( ret < 0 ) giet_exit();
     379        if ( ret < 0 ) giet_exit("error in giet_tty_getw()");
    380380
    381381        // return 0 value
     
    670670}
    671671
    672 
    673672// Local Variables:
    674673// tab-width: 4
  • soft/giet_vm/giet_libs/stdio.h

    r345 r352  
    427427                            unsigned int* size );
    428428
    429 
    430429#endif
    431430
  • soft/giet_vm/giet_libs/stdlib.c

    r271 r352  
    3737// GCC requires this function. Taken from MutekH.
    3838////////////////////////////////////////////////////////////////////////////////////////
    39 void * memcpy(void *_dst, const void * _src, unsigned int size) {
     39void * memcpy(void *_dst, const void * _src, unsigned int size)
     40{
    4041    unsigned int * dst = _dst;
    4142    const unsigned int * src = _src;
    4243    if (!((unsigned int) dst & 3) && !((unsigned int) src & 3) )
    43         while (size > 3) {
     44    {
     45        while (size > 3)
     46        {
    4447            *dst++ = *src++;
    4548            size -= 4;
    4649        }
     50    }
    4751
    4852    unsigned char *cdst = (unsigned char*)dst;
    4953    unsigned char *csrc = (unsigned char*)src;
    5054
    51     while (size--) {
     55    while (size--)
     56    {
    5257        *cdst++ = *csrc++;
    5358    }
     
    5762
    5863////////////////////////////////////////////////////////////////////////////////////////
    59 //  mempcy()
     64//  memset()
    6065// GCC requires this function. Taken from MutekH.
    6166////////////////////////////////////////////////////////////////////////////////////////
    62 inline void * memset(void * dst, int s, unsigned int count) {
     67inline void * memset(void * dst, int s, unsigned int count)
     68{
    6369    char * a = (char *) dst;
    64     while (count--){
     70    while (count--)
     71    {
    6572        *a++ = (char)s;
    6673    }
Note: See TracChangeset for help on using the changeset viewer.