UnaryQ31.cpp 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #include "UnaryQ31.h"
  2. #include "Error.h"
  3. void UnaryQ31::test_mat_scale_q31()
  4. {
  5. arm_mat_scale_q31(&this->in1,0x40000000,1,&this->out);
  6. }
  7. void UnaryQ31::test_mat_trans_q31()
  8. {
  9. arm_mat_trans_q31(&this->in1,&this->out);
  10. }
  11. void UnaryQ31::test_mat_add_q31()
  12. {
  13. arm_mat_add_q31(&this->in1,&this->in1,&this->out);
  14. }
  15. void UnaryQ31::test_mat_sub_q31()
  16. {
  17. arm_mat_sub_q31(&this->in1,&this->in1,&this->out);
  18. }
  19. void UnaryQ31::setUp(Testing::testID_t id,std::vector<Testing::param_t>& params,Client::PatternMgr *mgr)
  20. {
  21. std::vector<Testing::param_t>::iterator it = params.begin();
  22. this->nbr = *it++;
  23. this->nbc = *it;
  24. input1.reload(UnaryQ31::INPUTA_Q31_ID,mgr,this->nbr*this->nbc);
  25. output.create(this->nbr*this->nbc,UnaryQ31::OUT_Q31_ID,mgr);
  26. this->in1.numRows = this->nbr;
  27. this->in1.numCols = this->nbc;
  28. this->in1.pData = input1.ptr();
  29. this->out.numRows = this->nbr;
  30. this->out.numCols = this->nbc;
  31. this->out.pData = output.ptr();
  32. }
  33. void UnaryQ31::tearDown(Testing::testID_t id,Client::PatternMgr *mgr)
  34. {
  35. }