timing.c 646 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #include <tomcrypt_test.h>
  2. int main(void)
  3. {
  4. init_timer();
  5. reg_algs();
  6. #ifdef USE_LTM
  7. ltc_mp = ltm_desc;
  8. #elif defined(USE_TFM)
  9. ltc_mp = tfm_desc;
  10. #elif defined(USE_GMP)
  11. ltc_mp = gmp_desc;
  12. #else
  13. extern ltc_math_descriptor EXT_MATH_LIB;
  14. ltc_mp = EXT_MATH_LIB;
  15. #endif
  16. time_keysched();
  17. time_cipher();
  18. time_cipher2();
  19. time_cipher3();
  20. time_cipher4();
  21. time_hash();
  22. time_macs();
  23. time_encmacs();
  24. time_prng();
  25. time_mult();
  26. time_sqr();
  27. time_rsa();
  28. time_ecc();
  29. #ifdef USE_LTM
  30. time_katja();
  31. #endif
  32. return EXIT_SUCCESS;
  33. }
  34. /* $Source: /cvs/libtom/libtomcrypt/demos/timing.c,v $ */
  35. /* $Revision: 1.61 $ */
  36. /* $Date: 2006/12/03 03:08:35 $ */