Skip to content

Commit c02dc10

Browse files
dvdgrgrttcodebot
authored andcommitted
all: more srsgnb-to-srsran renaming
srsgnb_terminate -> srsran_terminate srsgnb_srsvec_assert_size -> srsran_srsvec_assert_size
1 parent 341f2ad commit c02dc10

File tree

24 files changed

+60
-60
lines changed

24 files changed

+60
-60
lines changed

include/srsran/adt/unique_function.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class empty_table_t final : public oper_table_t<R, Args...>
5656
constexpr empty_table_t() = default;
5757
R call(void* src, Args... args) const override
5858
{
59-
srsgnb_terminate("bad function call (cause: function ptr is empty)");
59+
srsran_terminate("bad function call (cause: function ptr is empty)");
6060
}
6161
void move(void* src, void* dest) const override {}
6262
void dtor(void* src) const override {}

include/srsran/srsvec/binary.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ void binary_xor(const T& x, const U& y, V&& z)
2525
"Template type is not compatible with a span of integers");
2626
static_assert(detail::is_integral_span_compatible<V>::value,
2727
"Template type is not compatible with a span of integers");
28-
srsgnb_srsvec_assert_size(x, y);
29-
srsgnb_srsvec_assert_size(x, z);
28+
srsran_srsvec_assert_size(x, y);
29+
srsran_srsvec_assert_size(x, z);
3030

3131
for (std::size_t i = 0, len = x.size(); i != len; ++i) {
3232
z[i] = x[i] ^ y[i];
@@ -42,8 +42,8 @@ void binary_and(const T& x, const U& y, V&& z)
4242
"Template type is not compatible with a span of integers");
4343
static_assert(detail::is_integral_span_compatible<V>::value,
4444
"Template type is not compatible with a span of integers");
45-
srsgnb_srsvec_assert_size(x, y);
46-
srsgnb_srsvec_assert_size(x, z);
45+
srsran_srsvec_assert_size(x, y);
46+
srsran_srsvec_assert_size(x, z);
4747

4848
for (std::size_t i = 0, len = x.size(); i != len; ++i) {
4949
z[i] = x[i] & y[i];
@@ -59,8 +59,8 @@ void binary_or(const T& x, const U& y, V&& z)
5959
"Template type is not compatible with a span of integers");
6060
static_assert(detail::is_integral_span_compatible<V>::value,
6161
"Template type is not compatible with a span of integers");
62-
srsgnb_srsvec_assert_size(x, y);
63-
srsgnb_srsvec_assert_size(x, z);
62+
srsran_srsvec_assert_size(x, y);
63+
srsran_srsvec_assert_size(x, z);
6464

6565
for (std::size_t i = 0, len = x.size(); i != len; ++i) {
6666
z[i] = x[i] | y[i];

include/srsran/srsvec/compare.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ bool equal(const T1& s1, const T2& s2)
2525
{
2626
static_assert(detail::is_span_compatible<T1>::value, "Template type is not compatible with a span");
2727
static_assert(detail::is_span_compatible<T2>::value, "Template type is not compatible with a span");
28-
srsgnb_srsvec_assert_size(s1, s2);
28+
srsran_srsvec_assert_size(s1, s2);
2929

3030
return std::equal(s1.begin(), s1.end(), s2.begin(), s2.end());
3131
}

include/srsran/srsvec/copy.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ void copy(T&& dst, const U& src)
2121
{
2222
static_assert(detail::is_span_compatible<T>::value, "Template type is not compatible with a span");
2323
static_assert(detail::is_span_compatible<U>::value, "Template type is not compatible with a span");
24-
srsgnb_srsvec_assert_size(dst, src);
24+
srsran_srsvec_assert_size(dst, src);
2525

2626
std::copy(src.begin(), src.end(), dst.begin());
2727
}

include/srsran/srsvec/dot_prod.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ inline V dot_prod(const T& x, const U& y, V init)
4343
"Template type is not compatible with a span of arithmetics");
4444
static_assert(detail::is_arithmetic_span_compatible<U>::value,
4545
"Template type is not compatible with a span of arithmetics");
46-
srsgnb_srsvec_assert_size(x, y);
46+
srsran_srsvec_assert_size(x, y);
4747
return std::inner_product(x.begin(), x.end(), y.begin(), init);
4848
}
4949

include/srsran/srsvec/types.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@
2424
//
2525
// To make the span constant use srsran::span<const T>.
2626

27-
#define srsgnb_srsvec_assert_size(X, Y) \
27+
#define srsran_srsvec_assert_size(X, Y) \
2828
srsran_assert( \
2929
X.size() == Y.size(), "The size " #X " (i.e., {}) and " #Y " (i.e., {}) must be equal.", X.size(), Y.size())

include/srsran/support/error_handling.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ namespace srsran {
1818
/// Attribute noinline is used to signal to the compiler that this path should rarely occur and therefore doesn't need
1919
/// to get optimized.
2020
template <typename... Args>
21-
[[gnu::noinline, noreturn]] inline bool srsgnb_terminate(const char* fmt, Args&&... args) noexcept
21+
[[gnu::noinline, noreturn]] inline bool srsran_terminate(const char* fmt, Args&&... args) noexcept
2222
{
2323
srslog::flush();
2424
fmt::print(stderr, fmt, std::forward<Args>(args)...);
@@ -40,7 +40,7 @@ template <typename... Args>
4040
template <typename... Args>
4141
[[gnu::noinline, noreturn]] inline void report_fatal_error(const char* reason_fmt, Args&&... args) noexcept
4242
{
43-
srsgnb_terminate("srsGNB FATAL ERROR: {}\n", fmt::format(reason_fmt, std::forward<Args>(args)...));
43+
srsran_terminate("srsGNB FATAL ERROR: {}\n", fmt::format(reason_fmt, std::forward<Args>(args)...));
4444
}
4545

4646
/// \brief Verifies if condition is true. If not, report a fatal error and close application.

lib/mac/mac_dl/mac_cell_processor.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ static dci_payload encode_dci(const pdcch_dl_information& pdcch)
263263
case dci_dl_rnti_config_type::tc_rnti_f1_0:
264264
return dci_1_0_tc_rnti_pack(pdcch.dci.tc_rnti_f1_0);
265265
default:
266-
srsgnb_terminate("Invalid DCI format");
266+
srsran_terminate("Invalid DCI format");
267267
}
268268
}
269269

@@ -276,7 +276,7 @@ static dci_payload encode_dci(const pdcch_ul_information& pdcch)
276276
case dci_ul_rnti_config_type::tc_rnti_f0_0:
277277
return dci_0_0_tc_rnti_pack(pdcch.dci.tc_rnti_f0_0);
278278
default:
279-
srsgnb_terminate("Invalid DCI format");
279+
srsran_terminate("Invalid DCI format");
280280
}
281281
}
282282

lib/phy/lower/amplitude_controller/amplitude_controller_clipping_impl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ using namespace srsran;
1818

1919
amplitude_controller_metrics amplitude_controller_clipping_impl::process(span<cf_t> output, span<const cf_t> input)
2020
{
21-
srsgnb_srsvec_assert_size(output, input);
21+
srsran_srsvec_assert_size(output, input);
2222

2323
// Report clipping status.
2424
metrics.clipping_enabled = clipping_enabled;

lib/phy/upper/sequence_generators/low_papr_sequence_generator_impl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ void low_papr_sequence_generator_impl::r_uv_arg(span<float> tmp_arg, uint32_t u,
177177
} else if (M_zc >= 36) {
178178
r_uv_arg_mprb(tmp_arg, u, v);
179179
} else {
180-
srsgnb_terminate("Invalid sequence length {}", M_zc);
180+
srsran_terminate("Invalid sequence length {}", M_zc);
181181
}
182182
}
183183

0 commit comments

Comments
 (0)