rpc_malloc_test.txt 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. RPC Exports for malloc_test
  2. ===========================
  3. [ this file is autogenerated, do not edit ]
  4. 1. mt.mem_alloc
  5. Allocates the specified number of bytes (debugging/test
  6. function).Use b|k|m|g to specify the desired size unit
  7. 2. mt.mem_free
  8. Frees the specified number of bytes, previously allocated by
  9. one of the other malloc_test functions (e.g. mt.mem_alloc or
  10. the script mt_mem_alloc). Use b|k|m|g to specify the desired
  11. size unit.Returns the number of bytes freed (can be higher or
  12. smaller then the requested size)
  13. 3. mt.mem_realloc
  14. Reallocates the specified number of bytes from a pre-allocated
  15. randomly selected memory chunk. If no pre-allocated memory
  16. chunks exists, it will fail. Make sure mt.mem_used is non 0 or
  17. call mt.mem_alloc prior to calling this function. Returns the
  18. difference in bytes (<0 if bytes were freed, >0 if more bytes
  19. were allocated).Use b|k|m|g to specify the desired size unit
  20. 4. mt.mem_used
  21. Returns how many memory chunks and how many bytes are currently
  22. allocated via the mem_alloc module functions. Use b|k|m|g to
  23. specify the desired size unit.
  24. 5. mt.mem_rnd_alloc
  25. Takes 4 parameters: min, max, total_size and an optional unit
  26. (b|k|m|g). It will allocate total_size memory, in pieces of
  27. random size betweenmin .. max (inclusive).
  28. 6. mt.mem_test_start
  29. Takes 7 parameters: min, max, total_size, min_interval,
  30. max_interval, test_time and an optional size unit (b|k|m|g).
  31. All the time units are ms. It will run a memory allocation test
  32. for test_time ms. At a random interval between min_interval and
  33. max_interval ms. it will allocate a memory chunk with random
  34. size, between min and max. Each time total_size is reached, it
  35. will free all the memory allocated and start again.Returns the
  36. test id (integer)
  37. 7. mt.mem_test_stop
  38. Takes 1 parameter: the test id. It will stop the corresponding
  39. test.Note: the test is stopped, but not destroyed.
  40. 8. mt.mem_test_destroy
  41. Takes 1 parameter: the test id. It will destroy the
  42. corresponding test.
  43. 9. mt.mem_test_destroy_all
  44. It will destroy all the tests (running or stopped).
  45. 10. mt.mem_test_list
  46. If a test id parameter is provided it will list the
  47. corresponding test, else it will list all of them. Use b |k | m
  48. | g as a second parameter for the size units (default bytes)