         for (int ITEM = 0; ITEM < ITEMS_PER_THREAD; ++ITEM)
         {
             segment_ids[ITEM]   = -1;
-            value_offsets[ITEM] = -1;
+            value_offsets[ITEM] = thread_idx.b_idx;
 
             // Whether or not we slide (a) right along the segment path or (b) down the value path
             if (valid_segment && (!valid_value || (segment_end_offset <= thread_idx.b_idx)))

            #pragma unroll
            for (int ITEM = 0; ITEM < ITEMS_PER_THREAD; ++ITEM)
            {
                values[ITEM] = (value_offsets[ITEM] == -1) ?
                    identity :
                    temp_storage.cached_values[value_offsets[ITEM] - block_idx.b_idx];
            }
        }
        else


        // Load values
        Value values[ITEMS_PER_THREAD];
        if (USE_SMEM_VALUE_CACHE)
        {
            // Barrier for smem reuse
