kernel/eka/euser/us_func.cpp
changeset 275 2b433474f2ba
parent 0 a41df078684a
child 293 0659d0e1a03c
equal deleted inserted replaced
274:c7e97f847492 275:2b433474f2ba
  2015 	0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf,
  2015 	0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf,
  2016 	0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94,
  2016 	0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94,
  2017 	0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d
  2017 	0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d
  2018 	};
  2018 	};
  2019 
  2019 
       
  2020 /* RVCT 3.1 and 4.0 read past the end of arrays when unrolling loops.
       
  2021  * This only happens when using -O3 -Otime, so force to -O2.
       
  2022  */
       
  2023 #pragma push
       
  2024 #pragma O2
       
  2025 
  2020 /**
  2026 /**
  2021 Performs a CCITT CRC-32 checksum on the specified data.
  2027 Performs a CCITT CRC-32 checksum on the specified data.
  2022 
  2028 
  2023 On return from this function, the referenced 32 bit integer contains the CRC
  2029 On return from this function, the referenced 32 bit integer contains the CRC
  2024 value.
  2030 value.
  2034 	TUint32 crc = aCrc;
  2040 	TUint32 crc = aCrc;
  2035 	while (p < q)
  2041 	while (p < q)
  2036 		crc = (crc >> 8) ^ CrcTab32[(crc ^ *p++) & 0xff];
  2042 		crc = (crc >> 8) ^ CrcTab32[(crc ^ *p++) & 0xff];
  2037 	aCrc = crc;
  2043 	aCrc = crc;
  2038 	}
  2044 	}
       
  2045 #pragma pop