Changeset 527 for trunk/boot


Ignore:
Timestamp:
Aug 30, 2018, 10:26:27 PM (6 years ago)
Author:
viala@…
Message:

Rewrite if-then-else return function into switch case.

For safety reason and performance:

1) Safety: GCC complain with a warning if you forgot an enum variant.
2) code-gen just outperform naive if-then-else.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/boot/tsar_mips32/boot.c

    r524 r527  
    670670 * It returns the number of CP0s actually activated.
    671671 ********************************************************************************/
    672 static uint32_t boot_wake_all_cp0s()
     672static uint32_t boot_wake_all_cp0s( void )
    673673{
    674674    archinfo_header_t*  header;         // Pointer on ARCHINFO header
Note: See TracChangeset for help on using the changeset viewer.