mem.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /* mem.h --- interface to memory for M32C simulator.
  2. Copyright (C) 2005-2022 Free Software Foundation, Inc.
  3. Contributed by Red Hat, Inc.
  4. This file is part of the GNU simulators.
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 3 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program. If not, see <http://www.gnu.org/licenses/>. */
  15. void init_mem (void);
  16. void mem_usage_stats (void);
  17. void mem_put_qi (int address, unsigned char value);
  18. void mem_put_hi (int address, unsigned short value);
  19. void mem_put_psi (int address, unsigned long value);
  20. void mem_put_si (int address, unsigned long value);
  21. void mem_put_blk (int address, const void *bufptr, int nbytes);
  22. unsigned char mem_get_pc (void);
  23. unsigned char mem_get_qi (int address);
  24. unsigned short mem_get_hi (int address);
  25. unsigned long mem_get_psi (int address);
  26. unsigned long mem_get_si (int address);
  27. void mem_get_blk (int address, void *bufptr, int nbytes);
  28. int sign_ext (int v, int bits);
  29. void m32c_sim_restore_console (void);
  30. extern int m32c_use_raw_console;