Compiler is optimizng the size calcuation and moving parameters for memset differently.
| 61 | if (g_zdsp_init == 0) |
| 62 | { |
| 63 | memset(depot, 0, sizeof(st_ZDISPATCH_DEPOT)); |
| 64 | } |
| 65 | } |
| 66 | |
| 67 | st_ZDISPATCH_DATA* zDispatcher_memPool(S32 cnt) |
| 68 | { |
| 69 | st_ZDISPATCH_DATA* pool; |
| 70 | st_ZDISPATCH_DEPOT* depot = &g_zdsp_depot; |
| 71 | if (cnt < 1) |
| 72 | { |
| 73 | return NULL; |
| 74 | } |
| 75 | else |
| 76 | { |
| 77 | pool = (st_ZDISPATCH_DATA*)xMemAlloc(gActiveHeap, cnt * sizeof(st_ZDISPATCH_DATA), 0); |
| 78 | memset(pool, 0, cnt * sizeof(st_ZDISPATCH_DATA)); |
| 79 | depot->raw_pool = pool; |
| 80 | depot->raw_cnt = cnt; |
| 81 | return pool; |
| 82 | } |
no test coverage detected