add_value Subroutine

private subroutine add_value(this, hval, index, pos)

Add an input value to the stored values, assuming we already know the offsets @param[in] hval value to be stored @param[in] index index belonging to this value @param[out] pos on return, the position where this value was stored

Type Bound

shared_rhash_t

Arguments

Type IntentOptional Attributes Name
class(shared_rhash_t), intent(inout) :: this
integer(kind=int64), intent(in) :: hval
integer(kind=int64), intent(in) :: index
integer(kind=int64), intent(out) :: pos

Contents

Source Code


Source Code

    subroutine add_value(this, hval, index, pos)
        class(shared_rhash_t), intent(inout) :: this
        integer(int64), intent(in) :: hval, index
        integer(int64), intent(out) :: pos

        if (iProcIndex_intra == 0) then
            pos = this%hval_offsets%ptr(hval) + this%mult(hval)
            this%indices%ptr(pos) = index
            this%mult(hval) = this%mult(hval) + 1
        end if
    end subroutine add_value