xref: /qemu/target/hexagon/op_helper.h (revision 29b62a10)
1 /*
2  *  Copyright(c) 2019-2021 Qualcomm Innovation Center, Inc. All Rights Reserved.
3  *
4  *  This program is free software; you can redistribute it and/or modify
5  *  it under the terms of the GNU General Public License as published by
6  *  the Free Software Foundation; either version 2 of the License, or
7  *  (at your option) any later version.
8  *
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  *
14  *  You should have received a copy of the GNU General Public License
15  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef HEXAGON_OP_HELPER_H
19 #define HEXAGON_OP_HELPER_H
20 
21 /* Misc functions */
22 void cancel_slot(CPUHexagonState *env, uint32_t slot);
23 void write_new_pc(CPUHexagonState *env, bool pkt_has_multi_cof, target_ulong addr);
24 
25 uint8_t mem_load1(CPUHexagonState *env, uint32_t slot, target_ulong vaddr);
26 uint16_t mem_load2(CPUHexagonState *env, uint32_t slot, target_ulong vaddr);
27 uint32_t mem_load4(CPUHexagonState *env, uint32_t slot, target_ulong vaddr);
28 uint64_t mem_load8(CPUHexagonState *env, uint32_t slot, target_ulong vaddr);
29 
30 void log_reg_write(CPUHexagonState *env, int rnum,
31                    target_ulong val, uint32_t slot);
32 void log_store64(CPUHexagonState *env, target_ulong addr,
33                  int64_t val, int width, int slot);
34 void log_store32(CPUHexagonState *env, target_ulong addr,
35                  target_ulong val, int width, int slot);
36 
37 #endif
38