45 using scalar_type = simd::Scalar_t<VectorType>;
46 using type = ConstLane<LaneIndex, VectorType>;
50 ace ConstLane(VectorType& vec) : vec_{vec} {}
51 ace
operator scalar_type()
const {
return Get(); }
52 ace argon_type operator=(
const scalar_type b) {
return vec_ = Set(b); }
53 ace argon_type Load(
const scalar_type* ptr) {
54#ifdef ARGON_PLATFORM_MVE
57 if constexpr (simd::is_quadword_v<VectorType>) {
58 return simd::load1_lane_quad<LaneIndex>(ptr, vec_);
60 return simd::load1_lane<LaneIndex>(ptr, vec_);
64 ace argon_type Set(
const scalar_type b) {
return simd::set_lane<LaneIndex>(vec_, b); }
65 ace scalar_type Get()
const {
return simd::get_lane<LaneIndex>(vec_); }
68 ace VectorType vec() {
return vec_; }
69 ace
const int lane() {
return LaneIndex; }
71 ace neon::Vec64_t<scalar_type> vec() {
72 if constexpr (simd::is_doubleword_v<VectorType>) {
74 }
else if constexpr (simd::is_quadword_v<VectorType>) {
76 return simd::get_high(vec_);
78 return simd::get_low(vec_);
83 if constexpr (simd::is_doubleword_v<VectorType>) {
85 }
else if constexpr (simd::is_quadword_v<VectorType>) {
103 using scalar_type = simd::Scalar_t<VectorType>;
104 using type = Lane<VectorType>;
108 ace Lane(VectorType& vec,
const int lane) : vec_{vec}, lane_{lane} {}
109 ace argon_type operator=(
const scalar_type b) {
return vec_ = Set(b); }
110 [[nodiscard]] ace argon_type Load(
const scalar_type* ptr) {
111#ifdef ARGON_PLATFORM_MVE
114 return simd::load1_lane(vec_, lane_, ptr);
117 ace argon_type Set(
const scalar_type b) {
return simd::set_lane(vec_, lane_, b); }
118 ace scalar_type Get()
const {
return simd::get_lane(vec_, lane_); }
119 ace
operator scalar_type()
const {
return Get(); }
122 ace VectorType vec() {
return vec_; }
123 ace
const int lane() {
return lane_; }
125 ace neon::Vec64_t<scalar_type> vec() {
126 if constexpr (simd::is_doubleword_v<VectorType>) {
128 }
else if constexpr (simd::is_quadword_v<VectorType>) {
130 return simd::get_high(vec_);
132 return simd::get_low(vec_);
137 if constexpr (simd::is_doubleword_v<VectorType>) {
139 }
else if constexpr (simd::is_quadword_v<VectorType>) {
typename ArgonFor< std::remove_cv_t< T > >::type ArgonFor_t
Helper alias to get the Argon type for a given vector type.
Definition argon_for.hpp:45