scc 2026.07
SystemC components library
simple_ace_target.h
1/*
2 * Copyright 2020 Arteris IP
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.axi_util.cpp
15 */
16
17#pragma once
18
19#include <axi/pe/ace_target_pe.h>
20
22namespace axi {
24namespace pe {
25
26template <unsigned int BUSWIDTH = 32, typename TYPES = axi::axi_protocol_types, int N = 1,
27 sc_core::sc_port_policy POL = sc_core::SC_ONE_OR_MORE_BOUND>
29public:
30 using base = ace_target_pe;
31 using payload_type = base::payload_type;
32 using phase_type = base::phase_type;
33
39 : // @suppress("Class members should be properly initialized")
40 simple_ace_target(sc_core::sc_gen_unique_name("simple_ace_target"), socket) {}
41
42 simple_ace_target(const sc_core::sc_module_name& nm, axi::ace_target_socket<BUSWIDTH, TYPES, N, POL>& socket)
43 : ace_target_pe(nm, BUSWIDTH)
44 , socket(socket) {
45 socket(*this);
46 this->instance_name = name();
47 }
48
49 simple_ace_target() = delete;
50
51 simple_ace_target(simple_ace_target const&) = delete;
52
54
55 simple_ace_target& operator=(simple_ace_target const&) = delete;
56
57 simple_ace_target& operator=(simple_ace_target&&) = delete;
58
59protected:
61
62 void end_of_elaboration() override {
63 base::end_of_elaboration();
64 set_bw_interface(socket.get_base_port().operator->());
65 }
66};
67
68} // namespace pe
69} // namespace axi
ace_target_pe(const sc_core::sc_module_name &nm, size_t transfer_width)
simple_ace_target(axi::ace_target_socket< BUSWIDTH, TYPES, N, POL > &socket)
the constructor
protocol engine implementations
TLM2.0 components modeling AHB.