Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ struct SumATA2{
vtype sum_at2 = Context::vzero();
vtype sum_at3 = Context::vzero();

if (VECTOR_LENGTH > 1){
if constexpr (VECTOR_LENGTH > 1){
size_t align = (size_t)T % (VECTOR_LENGTH * sizeof(float));
if (align){
align /= sizeof(float);
Expand Down Expand Up @@ -95,11 +95,13 @@ struct SumATA2{
ptrT += 1;
length -= VECTOR_LENGTH;
}
if (VECTOR_LENGTH > 1 && length){
vtype a0, t0;
Context::load2_partial_front(length, a0, ptrT, t0, ptrA);
sum_at0 = Context::vpma(a0, t0, sum_at0);
sum_as0 = Context::vpma(a0, a0, sum_as0);
if constexpr (VECTOR_LENGTH > 1){
if (length){
vtype a0, t0;
Context::load2_partial_front(length, a0, ptrT, t0, ptrA);
sum_at0 = Context::vpma(a0, t0, sum_at0);
sum_as0 = Context::vpma(a0, a0, sum_as0);
}
}

sum_A2 = Context::vadd(sum_A2, sum_as0);
Expand All @@ -115,7 +117,7 @@ struct SumATA2{
vtype sum_at2 = Context::vzero();
vtype sum_at3 = Context::vzero();

if (VECTOR_LENGTH > 1){
if constexpr (VECTOR_LENGTH > 1){
size_t align = (size_t)TW % (VECTOR_LENGTH * sizeof(float));
if (align){
align /= sizeof(float);
Expand Down Expand Up @@ -219,7 +221,7 @@ struct SumError{
vtype sum2 = Context::vzero();
vtype sum3 = Context::vzero();

if (VECTOR_LENGTH > 1){
if constexpr (VECTOR_LENGTH > 1){
size_t align = (size_t)T % (VECTOR_LENGTH * sizeof(float));
if (align){
align /= sizeof(float);
Expand Down Expand Up @@ -282,7 +284,7 @@ struct SumError{
vtype sum2 = Context::vzero();
vtype sum3 = Context::vzero();

if (VECTOR_LENGTH > 1){
if constexpr (VECTOR_LENGTH > 1){
size_t align = (size_t)TW % (VECTOR_LENGTH * sizeof(float));
if (align){
align /= sizeof(float);
Expand Down
Loading